Reply to Re: How to check what hit it
If you don't have an account, just leave the password field blank.
Usually missiles are from Dink. If the Enemy Shoot changes targets when it got hit by another Enemy Shoot-missile from Dink to the other shooter, then there's a way around it.
Here's my attempt:
int &crap = sp_brain(&missle_source, -1);
if (&crap == &missile_brain)
{
//I know there are two missile brains, but you get the idea.
int &p1 = sp_brain_parm(&missle_source, -1);
int &p2 = sp_brain_parm2(&missle_source, -1);
//Missiles traditionally have the caster and the shadow in their brain parms
&crap = &p1;
&p1 = sp_brain(&p1, -1);
if (&p1 == &shadow_brain)
{
&crap = &p2;
}
}
After this, &crap will hold the caster of the missile, assuming it's either in sp_brain_parm or sp_brain_parm2(). These parameters are sprites that the missile shouldn't damage.
Hey, it just might work.
Here's my attempt:
int &crap = sp_brain(&missle_source, -1);
if (&crap == &missile_brain)
{
//I know there are two missile brains, but you get the idea.
int &p1 = sp_brain_parm(&missle_source, -1);
int &p2 = sp_brain_parm2(&missle_source, -1);
//Missiles traditionally have the caster and the shadow in their brain parms
&crap = &p1;
&p1 = sp_brain(&p1, -1);
if (&p1 == &shadow_brain)
{
&crap = &p2;
}
}
After this, &crap will hold the caster of the missile, assuming it's either in sp_brain_parm or sp_brain_parm2(). These parameters are sprites that the missile shouldn't damage.
Hey, it just might work.







