Show Posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.


Messages - AskMeLater

Pages: [1]
1
Dead Souls Support / Re: One time stat or skill increase.
« on: December 27, 2008, 07:15:57 pm »
After restarting the mud, it appears to work.  I guess I wasn't updating correctly.  Anyway thanks for taking the time to respond.


2
Dead Souls Support / Re: One time stat or skill increase.
« on: December 27, 2008, 01:25:28 pm »
I added a string array and a function called HasRead to player.c.  I'm trying to use member_array to determine if the the string passed to HasRead exists in the array.  I keep getting an error saying:

*Bad argument 2 to member_array()
Expected: string or array Got: 0.


Here is the code:


string *books_read = ({});


int HasRead(string book_name) {
        return member_array(book_name, books_read);
}

Anyone know what I"m doing wrong?

Thanks,

3
Dead Souls Support / Re: One time stat or skill increase.
« on: December 26, 2008, 09:05:16 pm »
Thanks sluggy.  Create a reading list for the player.  I could do, as you suggested in another post, create a custom book object.  It would use the new functionality of player.c.  That way the reading list would be small and only include "special" books. 

4
Dead Souls Support / One time stat or skill increase.
« on: December 26, 2008, 06:28:04 pm »
I have a book that requires a user to be a certain level to read it.  I would also like this book to give the user a one time increase to their wisdom.  Currently I've overridden the book::GetRead function.  However, every time they read the book, their wisdom is increased.  Obviously that won't do.  What is a common way of adding one time stat or skill adjustments to actions that might be repeatedly performed by the player?  For example you want this stat or skill adjustment to only occur the first time the player performs this action.

Thanks,

5
I'm new to muds, LPC and coding.  I was wondering what the feeling is about overriding functions in a child object vs. extending the parent code.  Is the decision mostly based on is this new functionality specific to this one object or could be used by many similar objects?  Also, is it considered good form when overriding a parent function to call the parents function if you are just extending functionality?  Like all you are doing is adding something, but you want all the parents code to be run as well.  So you use <parent>::SomeFunc() to call the parents function before or after your modifications.

As an example I'll explain what I'm working on.  I have a book that I want only players over a certain level to be able to read.  In the code for this specific book I overrode the GetRead function from /lib/events/read.c (which is ineherited by item then book).  The code works like I want.  If you are not higher than a certain level you cannot read the book.  Anyway, I call book::GetRead() and it seems to work like expected.  I'm just curious what the best practices are for this kind of thing.

Thanks,

6
Intermud / Re: Help troubleshooting intermud connection
« on: December 25, 2008, 10:07:01 am »
Raudhrskal helped me to identify the problem.  I'm using Eset's Smart Security suite.  It is a firewall, antivirus and antispyware program.  Eset has an option for filtering HTTP traffic.  By default it filters traffic on port 80, 8080 and 3128.  The intermud router uses port 8080 to communicate.  With filtering enabled, intermud traffic is blocked by the eset software.

So if you have Eset Smart Security or possibly even Eset Nod32 antivirus.  You need to tell the software to not filter HTTP traffic on port 8080.  To do this, Toggle "Advanced mode" in the lower left corner of the Eset software.  Click setup, click "antivirus and antispyware", click "Advanced Antivirus and antispyware protection setup".  A new window will open up.  Below "Antivirus and antispyware" you will see a section for "Web access protection".  Below the "Web access protection" section is a "HTTP" section.  Click on the "HTTP" section and it will display the HTTP filter setup.  You will see a text box below "Ports used by HTTP protocol".  The default ports are 80, 8080, 3128.  Simply remove port 8080 from the text box.  Click "OK" to save your setup.  Now Eset  will not monitor traffic on port 8080.

7
Intermud / Re: Help troubleshooting intermud connection
« on: December 25, 2008, 09:00:58 am »
A Christmas Miracle!  Things started working this morning.  Thanks to Raudhrskal and Ninja for the help.

8
Intermud / Help troubleshooting intermud connection
« on: December 24, 2008, 05:33:58 pm »
I installed ds2.8.4 in cygwin running on Windows Vista 64.  Dead Souls seems to run fine.  However, I3 is offline and IMC2 is waiting for acceptance. 

Anyway, I briefly was able to use the ichat channel.  Mudlist has never worked.  ping dead souls and frontier does not work.  ds_test hello got a loud speaker response of i3 is offline. 

I've tried turning off my firewall.  I see where I'm connected to port 8080 on the i3 router.  Even with my firewall on, it shows that connection.  I have changed the name of my mud a few times.  Perhaps that is the problem.

Any suggestions would be appreciated.

Thanks,


Pages: [1]