I'm trying to change a projectile so it does additional damage if it hits a core or a power node, as yet haven't managed to get it working, I was under the impression that if you pick something higher up the actor tree, it affects children of that actor, but so far the below doesn't seem to do anything.
Would I need to put in additional code to know what team the projectile owner is on, and then check for objects belonging to an opposing team?
simulated function ProcessTouch (Actor Other, Vector HitLocation)
{
hitnodecore=False;
if ( Other.Isa('ONSPowerCore') || Other.Isa('ONSPowerNode'))
{
hitnodecore=True;
log(hitnodecore);
}
if ( (Other != instigator) && (!Other.IsA('Projectile') || Other.bProjTarget))
{
Explode(HitLocation, vect(0,0,1));
}
}
Would I need to put in additional code to know what team the projectile owner is on, and then check for objects belonging to an opposing team?
simulated function ProcessTouch (Actor Other, Vector HitLocation)
{
hitnodecore=False;
if ( Other.Isa('ONSPowerCore') || Other.Isa('ONSPowerNode'))
{
hitnodecore=True;
log(hitnodecore);
}
if ( (Other != instigator) && (!Other.IsA('Projectile') || Other.bProjTarget))
{
Explode(HitLocation, vect(0,0,1));
}
}
Last edited: