Hellblazer pickups have translucent glass and show ammo state.
Added cvar for controlling blob shadow render distance. Folder reorganizing for post-release updates. Updated patron list.
This commit is contained in:
parent
c5051ea905
commit
ad2a96b676
34 changed files with 339 additions and 8 deletions
1
zscript/dlc2/swwm_demoland.zsc
Normal file
1
zscript/dlc2/swwm_demoland.zsc
Normal file
|
|
@ -0,0 +1 @@
|
|||
// Demo Land Adventure game code
|
||||
1
zscript/dlc2/swwm_demoquest.zsc
Normal file
1
zscript/dlc2/swwm_demoquest.zsc
Normal file
|
|
@ -0,0 +1 @@
|
|||
// Demolition Quest game code
|
||||
1
zscript/dlc2/swwm_demoshmup.zsc
Normal file
1
zscript/dlc2/swwm_demoshmup.zsc
Normal file
|
|
@ -0,0 +1 @@
|
|||
// Interplanetary Demolitionist game code
|
||||
1
zscript/dlc2/swwm_pong.zsc
Normal file
1
zscript/dlc2/swwm_pong.zsc
Normal file
|
|
@ -0,0 +1 @@
|
|||
// Pong game code
|
||||
1
zscript/dlc2/swwm_snake.zsc
Normal file
1
zscript/dlc2/swwm_snake.zsc
Normal file
|
|
@ -0,0 +1 @@
|
|||
// Snake game code
|
||||
1
zscript/dlc2/swwm_tetris.zsc
Normal file
1
zscript/dlc2/swwm_tetris.zsc
Normal file
|
|
@ -0,0 +1 @@
|
|||
// Tetris game code
|
||||
85
zscript/dlc3/swwm_hugeassrailgun.zsc
Normal file
85
zscript/dlc3/swwm_hugeassrailgun.zsc
Normal file
|
|
@ -0,0 +1,85 @@
|
|||
// Kmonn Shuna Grand Lance (planned for unreleased SWWM Iridium)
|
||||
// Slot 0, spawns shared with Ynykron Artifact
|
||||
|
||||
Class GrandSpear : MagAmmo
|
||||
{
|
||||
Default
|
||||
{
|
||||
Tag "$T_GRANDSPEAR";
|
||||
Inventory.PickupMessage "$T_GRANDSPEAR";
|
||||
Inventory.Icon "graphics/HUD/Icons/A_GrandSpear.png";
|
||||
MagAmmo.ParentAmmo "GrandAmmo";
|
||||
MagAmmo.ClipSize 5;
|
||||
Inventory.MaxAmount 10;
|
||||
Inventory.InterHubAmount 10;
|
||||
+FLOATBOB;
|
||||
FloatBobStrength 0.25;
|
||||
}
|
||||
States
|
||||
{
|
||||
Spawn:
|
||||
XZW1 A -1;
|
||||
Stop;
|
||||
}
|
||||
}
|
||||
|
||||
Class GrandAmmo : Ammo
|
||||
{
|
||||
Mixin SWWMAmmo;
|
||||
Mixin SWWMOverlapPickupSound;
|
||||
Mixin SWWMUseToPickup;
|
||||
|
||||
Default
|
||||
{
|
||||
Tag "$T_GRANDAMMO";
|
||||
Inventory.PickupMessage "$T_GRANDAMMO";
|
||||
Stamina 1200000;
|
||||
Inventory.Icon "graphics/HUD/Icons/A_RayAmmo.png";
|
||||
Inventory.Amount 1;
|
||||
Inventory.MaxAmount 2;
|
||||
Ammo.BackpackAmount 0;
|
||||
Ammo.BackpackMaxAmount 6;
|
||||
Ammo.DropAmount 1;
|
||||
+FLOATBOB;
|
||||
FloatBobStrength 0.25;
|
||||
}
|
||||
States
|
||||
{
|
||||
Spawn:
|
||||
XZW1 A -1;
|
||||
Stop;
|
||||
}
|
||||
}
|
||||
|
||||
Class GrandLance : SWWMWeapon
|
||||
{
|
||||
int clipcount;
|
||||
|
||||
Property ClipCount : clipcount;
|
||||
|
||||
Default
|
||||
{
|
||||
Tag "$T_GRANDLANCE";
|
||||
Inventory.PickupMessage "$I_GRANDLANCE";
|
||||
Obituary "$O_GRANDLANCE";
|
||||
Inventory.Icon "graphics/HUD/Icons/W_GrandLance.png";
|
||||
Weapon.SlotNumber 0;
|
||||
Weapon.SlotPriority 2.;
|
||||
Weapon.SelectionOrder 8000;
|
||||
Weapon.AmmoType1 "GrandAmmo";
|
||||
Weapon.AmmoGive1 1;
|
||||
SWWMWeapon.DropAmmoType "GrandAmmo";
|
||||
GrandLance.ClipCount 5;
|
||||
Stamina 4200000;
|
||||
+SWWMWEAPON.NOFIRSTGIVE;
|
||||
+WEAPON.BFG;
|
||||
+WEAPON.EXPLOSIVE;
|
||||
}
|
||||
States
|
||||
{
|
||||
Spawn:
|
||||
XZW1 A -1;
|
||||
Stop;
|
||||
}
|
||||
}
|
||||
|
||||
|
|
@ -1220,6 +1220,77 @@ Class HellblazerWarheadArm : Actor
|
|||
}
|
||||
}
|
||||
|
||||
Class HellblazerX : GhostArtifactX {}
|
||||
|
||||
Class HellblazerXSub : GhostArtifactX
|
||||
{
|
||||
Hellblazer weap;
|
||||
int ridx;
|
||||
|
||||
Default
|
||||
{
|
||||
RenderStyle "Normal";
|
||||
}
|
||||
void UpdateMe()
|
||||
{
|
||||
static const Class<Ammo> types[] = {"HellblazerMissiles","HellblazerCrackshots","HellblazerRavagers","HellblazerWarheads"};
|
||||
int curtype = 0;
|
||||
for ( int i=0; i<4; i++ )
|
||||
{
|
||||
if ( weap.loadammo != types[i] ) continue;
|
||||
curtype = i;
|
||||
break;
|
||||
}
|
||||
static const int sofs[] = {1,7,10,13}; // offsets from SpawnState for each ammo type state label
|
||||
int idx;
|
||||
switch ( curtype )
|
||||
{
|
||||
case 0:
|
||||
idx = ridx-weap.magpos;
|
||||
if ( idx > 5 ) idx -= 6;
|
||||
else if ( idx < 0 ) idx += 6;
|
||||
if ( weap.magstate[ridx] ) SetState(SpawnState);
|
||||
else SetState(SpawnState+sofs[0]+idx);
|
||||
break;
|
||||
case 1:
|
||||
idx = ridx-weap.magpos;
|
||||
if ( idx > 2 ) idx -= 3;
|
||||
else if ( idx < 0 ) idx += 3;
|
||||
if ( (ridx > 2) || weap.magstate[ridx] ) SetState(SpawnState);
|
||||
else SetState(SpawnState+sofs[1]+idx);
|
||||
break;
|
||||
case 2:
|
||||
idx = ridx-weap.magpos;
|
||||
if ( idx > 2 ) idx -= 3;
|
||||
else if ( idx < 0 ) idx += 3;
|
||||
if ( (ridx > 2) || weap.magstate[ridx] ) SetState(SpawnState);
|
||||
else SetState(SpawnState+sofs[2]+idx);
|
||||
break;
|
||||
case 3:
|
||||
idx = ridx-weap.magpos;
|
||||
if ( idx > 1 ) idx -= 2;
|
||||
else if ( idx < 0 ) idx += 2;
|
||||
if ( (ridx > 1) || weap.magstate[ridx] ) SetState(SpawnState);
|
||||
else SetState(SpawnState+sofs[3]+idx);
|
||||
break;
|
||||
}
|
||||
}
|
||||
States
|
||||
{
|
||||
Spawn:
|
||||
TNT1 A -1;
|
||||
Missiles:
|
||||
XZW1 ABCDEF -1;
|
||||
Crackshots:
|
||||
XZW2 ABC -1;
|
||||
Ravagers:
|
||||
XZW3 ABC -1;
|
||||
Nukes:
|
||||
XZW4 AB -1;
|
||||
Stop;
|
||||
}
|
||||
}
|
||||
|
||||
Class Hellblazer : SWWMWeapon
|
||||
{
|
||||
int clipcount;
|
||||
|
|
@ -1227,6 +1298,7 @@ Class Hellblazer : SWWMWeapon
|
|||
int magpos; // current rotation
|
||||
Class<Ammo> loadammo, nextammo;
|
||||
int spinskipped;
|
||||
HellblazerXSub pickuprockets[6];
|
||||
|
||||
Property ClipCount : clipcount;
|
||||
|
||||
|
|
@ -1542,6 +1614,41 @@ Class Hellblazer : SWWMWeapon
|
|||
}
|
||||
}
|
||||
|
||||
action void A_UpdatePickup()
|
||||
{
|
||||
static const Class<Ammo> types[] = {"HellblazerMissiles","HellblazerCrackshots","HellblazerRavagers","HellblazerWarheads"};
|
||||
for ( int i=0; i<6; i++ )
|
||||
{
|
||||
if ( !invoker.pickuprockets[i] )
|
||||
{
|
||||
invoker.pickuprockets[i] = HellblazerXSub(Spawn("HellblazerXSub",pos));
|
||||
invoker.pickuprockets[i].angle = angle;
|
||||
invoker.pickuprockets[i].target = invoker;
|
||||
invoker.pickuprockets[i].weap = invoker;
|
||||
invoker.pickuprockets[i].FloatBobPhase = FloatBobPhase;
|
||||
invoker.pickuprockets[i].ridx = i;
|
||||
}
|
||||
invoker.pickuprockets[i].UpdateMe();
|
||||
}
|
||||
int curtype = 0;
|
||||
for ( int i=0; i<4; i++ )
|
||||
{
|
||||
if ( invoker.loadammo != types[i] ) continue;
|
||||
curtype = i;
|
||||
break;
|
||||
}
|
||||
SetState(SpawnState+curtype+1);
|
||||
}
|
||||
|
||||
override void PostBeginPlay()
|
||||
{
|
||||
Super.PostBeginPlay();
|
||||
tracer = Spawn("HellblazerX",pos);
|
||||
tracer.angle = angle;
|
||||
tracer.target = self;
|
||||
tracer.FloatBobPhase = FloatBobPhase;
|
||||
}
|
||||
|
||||
Default
|
||||
{
|
||||
Tag "$T_HELLBLAZER";
|
||||
|
|
@ -1564,7 +1671,8 @@ Class Hellblazer : SWWMWeapon
|
|||
States
|
||||
{
|
||||
Spawn:
|
||||
XZW1 A -1;
|
||||
XZW1 A -1 NoDelay A_UpdatePickup();
|
||||
XZW1 ABCD -1;
|
||||
Stop;
|
||||
Select:
|
||||
XZW2 I 0
|
||||
|
|
|
|||
|
|
@ -1430,11 +1430,14 @@ Class SWWMBulletTrail : LineTracer
|
|||
Class SWWMShadow : Actor
|
||||
{
|
||||
Sector oldfloor;
|
||||
transient CVar sdist;
|
||||
|
||||
static void Track( Actor other )
|
||||
{
|
||||
// prevent infinite recursion
|
||||
if ( other is 'SWWMShadow' ) return;
|
||||
// no shadows for overlay actors
|
||||
if ( other is 'GhostArtifactX' ) return;
|
||||
let s = SWWMShadow(Spawn("SWWMShadow",other.pos));
|
||||
s.target = other;
|
||||
s.Update(true);
|
||||
|
|
@ -1448,6 +1451,10 @@ Class SWWMShadow : Actor
|
|||
{
|
||||
alpha = 1.-min(1.,.006*abs(target.pos.z-pos.z));
|
||||
alpha *= target.alpha;
|
||||
if ( !sdist ) sdist = CVar.GetCVar('swwm_shadowdist',players[consoleplayer]);
|
||||
int sd = sdist.GetInt();
|
||||
// breaks with chasecam, but it's fine
|
||||
if ( sd > 0 ) alpha *= clamp(4.*((sd-Distance3D(players[consoleplayer].Camera))/sd),0.,1.);
|
||||
double relz = target.pos.z-pos.z;
|
||||
if ( target.bFLOATBOB ) relz += BobSin(target.FloatBobPhase)*target.FloatBobStrength;
|
||||
double bscale = (target.radius/16.)*(1.-min(1.,.003*relz));
|
||||
|
|
@ -1481,6 +1488,7 @@ Class SWWMShadow : Actor
|
|||
{
|
||||
RenderStyle "Shaded";
|
||||
StencilColor "000000";
|
||||
DistanceCheck 'swwm_shadowdist';
|
||||
Radius .1;
|
||||
Height 0.;
|
||||
+NOBLOCKMAP;
|
||||
|
|
|
|||
|
|
@ -187,6 +187,7 @@ Class SWWMCreditsMenu : GenericMenu
|
|||
cpatrons.Push(new("SWWMCreditsEntry").Init(sfnt,"Pietro Gagliardi"));
|
||||
cpatrons.Push(new("SWWMCreditsEntry").Init(sfnt,"Xada Xephron"));
|
||||
cpatrons.Push(new("SWWMCreditsEntry").Init(sfnt,"Alexa Jones-Gonzales"));
|
||||
cpatrons.Push(new("SWWMCreditsEntry").Init(sfnt,"John"));
|
||||
cpatrons.Push(new("SWWMCreditsEntry").Init(sfnt,"NekoMithos"));
|
||||
cpatrons.Push(new("SWWMCreditsEntry").Init(sfnt,"Holly_Rook"));
|
||||
cpatrons.Push(new("SWWMCreditsEntry").Init(sfnt,"Namsan"));
|
||||
|
|
|
|||
|
|
@ -319,13 +319,15 @@ Class GhostArtifactX : Actor
|
|||
}
|
||||
override void Tick()
|
||||
{
|
||||
Super.Tick();
|
||||
if ( !target )
|
||||
{
|
||||
Destroy();
|
||||
return;
|
||||
}
|
||||
Warp(target,flags:WARPF_INTERPOLATE|WARPF_NOCHECKPOSITION);
|
||||
vel = target.vel;
|
||||
prev = target.prev;
|
||||
SetOrigin(target.pos+vel,true);
|
||||
A_SetAngle(target.angle,SPF_INTERPOLATE);
|
||||
FloatBobPhase = target.FloatBobPhase;
|
||||
bInvisible = target.bInvisible||!target.InStateSequence(target.CurState,target.FindState("Spawn"));
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue