Re: Mirror image (fwd)

From: Graham Gilmore (
Date: 11/02/95

On Thu, 2 Nov 1995, Billy H. Chan (陈浩然) wrote:

> Or, somewhere inside struct char_data *ch, add unsigned byte image_number.
	Adding a byte to char_data makes things difficult.

> Make the spell a MAG_MANUAL | MAG_AFFECTS.
> In fight.c, when checking for a hit, do:
> 	if (dice(1, image_number) != 1) {
> 		act("blahblahblah' ... TO_CHAR);
> 		act("Blablahbalbh"... TO_ROOM);
> 		image_number = MAX(1, image_number - 1);
> 	}
> heck, you don't even need an AFFECT flag... just check if image_number > 1,
> and if it is... you're imaged... this sure beats the way I imp'ed it... 

	Instead, maybe you COULD use an affect flag.  When you cast it, 
it gives you APPLY_IMAGE by x, and each time an image is removed the 
modifier is reduced by 1 until you hit 0.. then you remove the bit.
	That way the # of images is stored in the affects structure, 
which already has a spot for the modifier.

	Graham Gilmore

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