Implement 4.7.1 features.
This commit is contained in:
parent
17921a15e1
commit
d735ce20bf
18 changed files with 202 additions and 131 deletions
|
|
@ -141,18 +141,6 @@ extend Class SWWMHandler
|
|||
if ( !c.CallTryPickup(p.mo) )
|
||||
c.Destroy();
|
||||
}
|
||||
// reset inventory (including unclearables) on forced pistol starts (must have visited at least one map, though)
|
||||
if ( p.mo.FindInventory("InventoryWipeToken") || (swwm_pistolstart && (s.lstats.Size() > 0) && ((s.lastcluster != level.cluster) || ((swwm_pistolstart == 1) && !(level.clusterflags&LevelLocals.CLUSTER_HUB)))) )
|
||||
SWWMUtility.WipeInventory(p.mo,swwm_resetscore);
|
||||
// play the select sound of the current weapon if we travelled
|
||||
if ( (p.ReadyWeapon is 'SWWMWeapon') && SWWMWeapon(p.ReadyWeapon).hastravelled )
|
||||
SWWMWeapon(p.ReadyWeapon).autoupsnd = level.maptime+1;
|
||||
// reset the travelled flag for all weapons
|
||||
for ( Inventory i=p.mo.inv; i; i=i.inv )
|
||||
{
|
||||
if ( !SWWMWeapon(i) ) continue;
|
||||
SWWMWeapon(i).hastravelled = false;
|
||||
}
|
||||
// cap health to 200
|
||||
if ( p.Health > 200 ) p.Health = p.mo.Health = 200;
|
||||
}
|
||||
|
|
|
|||
|
|
@ -104,13 +104,17 @@ extend Class SWWMHandler
|
|||
let c = SWWMCredits.Find(players[i]);
|
||||
if ( c ) c.credits = c.hcredits = 0;
|
||||
}
|
||||
// end of episode resets
|
||||
if ( level.nextsecretmap.Left(6) == "enDSeQ" )
|
||||
// end of episode resets and enforced pistol starts
|
||||
LevelInfo nextlv = LevelInfo.FindLevelInfo(e.NextMap);
|
||||
if ( (level.nextsecretmap.Left(6) == "enDSeQ")
|
||||
|| (swwm_pistolstart && nextlv && (level.cluster != nextlv.cluster))
|
||||
|| ((swwm_pistolstart == 1) && !(level.clusterflags&LevelLocals.CLUSTER_HUB)) )
|
||||
{
|
||||
for ( int i=0; i<MAXPLAYERS; i++ )
|
||||
{
|
||||
if ( !playeringame[i] || !players[i].mo ) continue;
|
||||
players[i].mo.GiveInventory("InventoryWipeToken",1);
|
||||
// the playerpawn will know what to do with this in its PreTravelled()
|
||||
}
|
||||
}
|
||||
// did we complete this map without collecting any of its keys? (doesn't work for hubs)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue