Enable HITOWNER on bounce for grenades (small hack was required), flak shrapnel, ripper blades.

Enable HITOWNER on biosludge after colliding with a surface. Not needed, but just done for the sake of it.
Enable HITOWNER on guided redeemer missiles after they're far away from the shooter.
This commit is contained in:
Marisa the Magician 2018-08-17 21:09:18 +02:00
commit 0c8a16807f
6 changed files with 14 additions and 1 deletions

View file

@ -933,7 +933,7 @@ Class UTMainHandler : StaticEventHandler
while ( bi.Next() )
{
Actor a = bi.Thing;
if ( !a || !a.bSHOOTABLE || !Source.CheckSight(a,0xf) || (a == Source) )
if ( !a || !a.bSHOOTABLE || !Source.CheckSight(a,0xf) || (a == Source) || (Source.Distance3D(a) > ExplosionRadius) )
continue;
Vector3 midpoint = a.Vec3Offset(0,0,a.height*0.5);
a.vel += Level.Vec3Diff(Source.pos,midpoint).unit()*(MomentumTransfer/(Thinker.TICRATE*a.mass));