2022-12-12 14:08:20 +00:00
|
|
|
class DukeLavaPool : DukeActor
|
|
|
|
{
|
|
|
|
default
|
|
|
|
{
|
|
|
|
pic "LAVAPOOL";
|
2022-12-16 11:47:30 +00:00
|
|
|
+FORCERUNCON;
|
2022-12-12 14:08:20 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
override void Initialize()
|
|
|
|
{
|
|
|
|
bool away = self.isAwayFromWall(6.75);
|
|
|
|
|
|
|
|
if (!away)
|
|
|
|
{
|
|
|
|
self.ChangeStat(STAT_MISC);
|
|
|
|
self.scale = (0, 0);
|
|
|
|
return;
|
|
|
|
}
|
|
|
|
|
|
|
|
if (self.sector.lotag == 1)
|
|
|
|
{
|
|
|
|
return;
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
self.cstat |= CSTAT_SPRITE_ALIGNMENT_FLOOR;
|
|
|
|
double c, f;
|
|
|
|
[c, f] = self.sector.getslopes(self.pos.XY);
|
|
|
|
self.pos.Z = f - 0.78125;
|
|
|
|
if (self != self.ownerActor)
|
|
|
|
self.scale = (REPEAT_SCALE, REPEAT_SCALE);
|
|
|
|
self.ChangeStat(STAT_MISC);
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
class DukeLavaPoolBubble : DukeActor
|
|
|
|
{
|
|
|
|
default
|
|
|
|
{
|
|
|
|
pic "LAVAPOOLBUBBLE";
|
2022-12-16 11:47:30 +00:00
|
|
|
+FORCERUNCON;
|
2022-12-12 14:08:20 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
override void Initialize()
|
|
|
|
{
|
|
|
|
let owner = self.ownerActor;
|
|
|
|
self.ChangeStat(STAT_MISC);
|
|
|
|
if (owner.scale.X < 0.46875)
|
|
|
|
{
|
|
|
|
self.scale = (0, 0);
|
|
|
|
return;
|
|
|
|
}
|
|
|
|
self.pos.X += frandom(-16, 16);
|
|
|
|
self.pos.Y += frandom(-16, 16);
|
|
|
|
self.scale = (0.25, 0.25);
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|