Re: Damage modification?

From: Ryan A.J. Biggs (ae744@freenet.toronto.on.ca)
Date: 07/17/96


> If you have figured out how to call damage() when the character enters 
> the room, I think the rest will be easy.  Modify damage() to take on 
> another parameter when called, an int probably.  Depending on the value 
> of the int, your function will know if a room or another character caused 
> the damage. (this involves modifiying the function a little to, to get 
> rid of attacker character refrences).  When you have that extra 
> parameter, it should act as a flag to determine the attack type, room or 
> normal, and you should use the character for both the victim and attacker 
> and just ignore the attacker code, using if (room_attacker) or something 
> like that.  Hope this helps.  

That should work....I do hope that there aren't too many damage calls :)  
I was thinking of trying to modify just the dam_message so that if 
ch=vict it would display a different set of messages, but I don't know 
how I could do that.  Any ideas on that?  It would probably require less 
coding, and less changes.

------------------------------------------------------------------
Ryan A.J. Biggs    email-ae744@freenet.toronto.on.ca
Doppleganger, Charon the Boatman and member of Dieties Anonymous
Owner of a 100% organic wibble and Plasma lamp, and rubber chicken
Keeper of the sacred butcher knife and the Cloak of Shadows
Compiler of the Net.Psionics.Handbook
------------------------------------------------------------------



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