Use Vec3FromAngles to create random unit vectors.
This commit is contained in:
parent
315a35e96a
commit
2f5ffdfe41
33 changed files with 211 additions and 211 deletions
|
|
@ -63,7 +63,7 @@ extend Class SWWMHandler
|
|||
// damage numbers, combat tracking, etc.
|
||||
private void DoDamageHandling( WorldEvent e )
|
||||
{
|
||||
SWWMDamNum.SpawnFromHandler(self,e.Damage,e.Thing.Vec3Offset(FRandom[ScoreBits](-8,8),FRandom[ScoreBits](-8,8),FRandom[ScoreBits](-8,8)+e.Thing.Height/2),e.DamageType);
|
||||
SWWMDamNum.SpawnFromHandler(self,e.Damage,level.Vec3Offset(e.Thing.pos,SWWMUtility.Vec3FromAngles(FRandom[ScoreBits](0,360),FRandom[ScoreBits](-90,90))*8.+(0,0,e.Thing.Height/2)),e.DamageType);
|
||||
// combat tracker updates if either an ally of the player is hit, or an ally hit this enemy
|
||||
// (this automatically also does the same for the player itself, of course)
|
||||
for ( int i=0; i<MAXPLAYERS; i++ )
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue