Re: [Newbie] [CODE]

From: Tony Robbins (tonyr@NWPACLINK.COM)
Date: 07/14/98

At 12:07 PM 7/14/98 -0400, you wrote:
>> comm.c--this is called from heartbeat() every 1 second (or is supposed
to be,
>> but seems to be occuring more often than that).
>why don't you post that code?
>[code snipped]
>>                         next_d = d->next;
>>                         log("Checking to make sure RT >= 0.");
>>                         if (GET_RT(d->character) < 0)
GET_RT(d->character) = 0;
>>                         log("Subracting 1 from RT");
>>                         if (GET_RT(d->character) > 0)
GET_RT(d->character) -= 1;
>well..let me ask this: what are you trying to do? from what i can infer,
>you are trying to have a combat system that will use calculated speed
>rather than standard 2 second rounds..if this is the case, i'd
>suggest using the dg_event system to create events that will call the
>hit() func (or whatever) would be much less CPU intensive (no
>decrementation of a roundtime var)..i did this a while ago using events
>based on the dg system (extracted from the dg src, not the patch that is
>now available), but didn't like the feel of event based combat..

I (as you may have read) went back and looked at dak's Combat Initiative
idea and implemented it in my MUD.  Rather simple, and now underwater
combat is slowed, and it takes into account for heavy armor, etc.  His idea
snippet is on Alex's site and tells you everything you need really, and
avoids having a whole new setup here. (instead of a new function, run it
out of pulse_violence()) anyway, check out the snippet.

     | Ensure that you have read the CircleMUD Mailing List FAQ:  |
     | |

This archive was generated by hypermail 2b30 : 12/15/00 PST