Break spike traps in Hexen when standing on them.
This commit is contained in:
parent
0ca52146a0
commit
685b7d6f91
5 changed files with 54 additions and 5 deletions
BIN
filter/hexen/sprites/TSPKX0.png
Normal file
BIN
filter/hexen/sprites/TSPKX0.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 1.1 KiB |
|
|
@ -1,3 +1,3 @@
|
|||
[default]
|
||||
SWWM_MODVER="\chSWWM \czGZ\c- \cw1.0.9 \cu(Sat 28 Aug 18:10:36 CEST 2021)\c-";
|
||||
SWWM_SHORTVER="\cw1.0.9 \cu(2021-08-28 18:10:36)\c-";
|
||||
SWWM_MODVER="\chSWWM \czGZ\c- \cw1.0.9 \cu(Sat 28 Aug 18:56:23 CEST 2021)\c-";
|
||||
SWWM_SHORTVER="\cw1.0.9 \cu(2021-08-28 18:56:23)\c-";
|
||||
|
|
|
|||
|
|
@ -7,3 +7,4 @@ HotMetal5 = "0:255=%[0.23,0.18,0.12]:[0.7,0.6,0.32]"
|
|||
HotMetal6 = "0:255=%[0.2,0.12,0.1]:[0.5,0.4,0.28]"
|
||||
HotMetal7 = "0:255=%[0.0,0.0,0.0]:[0.25,0.25,0.25]"
|
||||
Rubble = "0:255=%[0.0,0.0,0.0]:[0.2,0.2,0.2]"
|
||||
StoneSpike = "0:255=%[0.20,0.10,0.05]:[0.70,0.50,0.35]"
|
||||
|
|
|
|||
|
|
@ -1615,3 +1615,22 @@ Class SWWMSizzleSmoke2 : SWWMBaseSplash
|
|||
s.special1 = Random[ExploS](0,1);
|
||||
}
|
||||
}
|
||||
|
||||
// Hexen thing
|
||||
Class SWWMCrushedSpike : Actor
|
||||
{
|
||||
Default
|
||||
{
|
||||
Radius 20;
|
||||
Height 16;
|
||||
+SOLID;
|
||||
+FLOORCLIP;
|
||||
+NOTELEPORT;
|
||||
}
|
||||
States
|
||||
{
|
||||
Spawn:
|
||||
TSPK X -1;
|
||||
Stop;
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -1458,9 +1458,38 @@ Class Demolitionist : PlayerPawn
|
|||
let hnd = SWWMHandler(EventHandler.Find("SWWMHandler"));
|
||||
if ( hnd ) hnd.tookdamage[PlayerNumber()] = true;
|
||||
}
|
||||
// check if we can break any active crushers
|
||||
if ( (mod == 'Crush') && !inflictor && !source )
|
||||
CheckBreakCrusher();
|
||||
if ( mod == 'Crush' )
|
||||
{
|
||||
// check if we can break any active crushers
|
||||
if ( !inflictor && !source ) CheckBreakCrusher();
|
||||
// break a spike trap
|
||||
else if ( source is 'ThrustFloor' )
|
||||
{
|
||||
let q = Spawn("BustedQuake",source.pos);
|
||||
q.special1 = 4;
|
||||
int numpt = Random[ExploS](30,40);
|
||||
for ( int i=0; i<numpt; i++ )
|
||||
{
|
||||
let s = Spawn("SWWMChip",source.Vec3Angle(source.radius,FRandom[ExploS](0,360),1.+FRandom[ExploS](0,max(0.,source.height-source.floorclip))));
|
||||
s.vel = ((0,0,1)+(FRandom[ExploS](-.6,.6),FRandom[ExploS](-.6,.6),FRandom[ExploS](-.6,.6))).unit()*FRandom[ExploS](2.,16.);
|
||||
s.scale *= FRandom[ExploS](1.5,3.);
|
||||
s.A_SetTranslation('StoneSpike');
|
||||
}
|
||||
numpt = Random[ExploS](12,16);
|
||||
for ( int i=0; i<numpt; i++ )
|
||||
{
|
||||
let s = Spawn("SWWMHalfSmoke",source.Vec3Offset(0,0,1.+FRandom[ExploS](0,max(0.,source.height-source.floorclip))));
|
||||
s.vel = ((0,0,1)+(FRandom[ExploS](-1.,1.),FRandom[ExploS](-1.,1.),FRandom[ExploS](-1.,1.))).unit()*FRandom[ExploS](-2,8.);
|
||||
s.scale *= 2.5;
|
||||
s.special1 = Random[ExploS](3,8);
|
||||
s.SetShade(Color(5,4,3)*Random[ExploS](20,40));
|
||||
}
|
||||
Spawn("SWWMCrushedSpike",source.pos);
|
||||
if ( source.master ) source.master.Destroy();
|
||||
source.Destroy();
|
||||
damage = 20; // reduce so it's not instant kill
|
||||
}
|
||||
}
|
||||
// no damage whatsoever
|
||||
if ( scriptedinvul )
|
||||
return 0;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue