On Tue, 16 Jul 1996, Angela Loos wrote: > This may be a really stupid question - but can anyone tell me why having > a statement with a call to the following causes my mud to crash? > > #define ENCUMBPER(ch) ( (int) (( CAN_CARRY_W(ch) / IS_CARRYING_W(ch) ) * > 10)) Divide by zero error most likely. If the player is empty-handed, this macro will cause a segfault eevry time. You could probably change the IS_CARRYING_W part to (IS_CARRYING_W(ch) ? IS_CARRYING_W(ch) : 1) without throwing your equation off. You may also want to rethink the basic equation, since the more your players carry, the lower the encumberance. Sam
This archive was generated by hypermail 2b30 : 12/07/00 PST