mirror of
https://github.com/ZDoom/Raze.git
synced 2024-12-11 13:21:49 +00:00
64 lines
973 B
Text
64 lines
973 B
Text
class DukeExplosion2 : DukeActor
|
|
{
|
|
default
|
|
{
|
|
pic "EXPLOSION2";
|
|
+FULLBRIGHT;
|
|
+FORCERUNCON;
|
|
+TRIGGER_IFHITSECTOR;
|
|
}
|
|
|
|
override bool animate(tspritetype t)
|
|
{
|
|
Duke.GetViewPlayer().visibility = -127;
|
|
Duke.setlastvisinc(32);
|
|
return false;
|
|
}
|
|
|
|
override void Initialize()
|
|
{
|
|
let owner = self.ownerActor;
|
|
|
|
if (owner && owner != self)
|
|
{
|
|
self.Angle = owner.Angle;
|
|
self.cstat = randomXFlip();
|
|
|
|
double c,f;
|
|
[c, f] = self.sector.getSlopes(self.pos.XY);
|
|
self.pos.Z = min(self.pos.Z, f - 12);
|
|
}
|
|
self.cstat |= CSTAT_SPRITE_YCENTER;
|
|
self.shade = -127;
|
|
self.Scale = (0.75, 0.75);
|
|
self.ChangeStat(STAT_MISC);
|
|
}
|
|
}
|
|
|
|
class DukeExplosion2Bot : DukeExplosion2
|
|
{
|
|
default
|
|
{
|
|
pic "EXPLOSION2BOT";
|
|
-TRIGGER_IFHITSECTOR;
|
|
}
|
|
}
|
|
|
|
class RedneckExplosion3 : DukeExplosion2
|
|
{
|
|
default
|
|
{
|
|
pic "EXPLOSION3";
|
|
}
|
|
|
|
override void Initialize()
|
|
{
|
|
self.scale = (2, 2);
|
|
}
|
|
|
|
override bool animate(tspritetype t)
|
|
{
|
|
t.shade = -127;
|
|
return false;
|
|
}
|
|
}
|