4.7.1 features here too.
This commit is contained in:
parent
c3dcc085b8
commit
f6efc5d3f2
18 changed files with 202 additions and 131 deletions
|
|
@ -1,3 +1,3 @@
|
|||
[default]
|
||||
SWWM_MODVER="\chSWWM \czGZ\c- \cw1.2pre r36 \cu(Wed 20 Oct 00:26:24 CEST 2021)\c-";
|
||||
SWWM_SHORTVER="\cw1.2pre r36 \cu(2021-10-20 00:26:24)\c-";
|
||||
SWWM_MODVER="\chSWWM \czGZ\c- \cw1.2pre r37 \cu(Thu 21 Oct 17:57:18 CEST 2021)\c-";
|
||||
SWWM_SHORTVER="\cw1.2pre r37 \cu(2021-10-21 17:57:18)\c-";
|
||||
|
|
|
|||
|
|
@ -283,7 +283,7 @@ ListMenu "MainMenu"
|
|||
SWWMTextItemM "$MNU_NEWGAME", "n", "PlayerclassMenu"
|
||||
SWWMTextItemM "$MNU_OPTIONS", "o", "OptionsMenu"
|
||||
SWWMTextItemM "$MNU_GAMEFILES", "g", "GameFilesMenu"
|
||||
SWWMTextItemM "$MNU_INFO", "i", "SWWMHelpMenu"
|
||||
SWWMTextItemM "$MNU_INFO", "i", "ReadThisMenu"
|
||||
SWWMTextItemM "$MNU_QUITGAME", "q", "QuitMenu"
|
||||
}
|
||||
ListMenu "MainMenuTextOnly"
|
||||
|
|
@ -298,7 +298,7 @@ ListMenu "MainMenuTextOnly"
|
|||
SWWMTextItemM "$MNU_NEWGAME", "n", "PlayerclassMenu"
|
||||
SWWMTextItemM "$MNU_OPTIONS", "o", "OptionsMenu"
|
||||
SWWMTextItemM "$MNU_GAMEFILES", "g", "GameFilesMenu"
|
||||
SWWMTextItemM "$MNU_INFO", "i", "SWWMHelpMenu"
|
||||
SWWMTextItemM "$MNU_INFO", "i", "ReadThisMenu"
|
||||
SWWMTextItemM "$MNU_QUITGAME", "q", "QuitMenu"
|
||||
}
|
||||
ListMenu "GameFilesMenu"
|
||||
|
|
|
|||
BIN
sprites/EIXTA0.png
Normal file
BIN
sprites/EIXTA0.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 926 B |
BIN
sprites/EIXTB0.png
Normal file
BIN
sprites/EIXTB0.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 925 B |
|
|
@ -32,6 +32,8 @@ GameInfo
|
|||
MenuSliderBackColor = "DarkGray"
|
||||
MenuBackButton = "graphics/swwmback.png"
|
||||
MessageBoxClass = "SWWMMessageBox"
|
||||
HelpMenuClass = "SWWMHelpMenu"
|
||||
MenuDelegateClass = "SWWMMenuDelegate"
|
||||
PauseSign = "graphics/swwmpause.png"
|
||||
BorderFlat = "graphics/bord_flat.png"
|
||||
Border = 2, 0, "graphics/bord_tr.png", "graphics/bord_t.png", "graphics/bord_tl.png", "graphics/bord_r.png", "graphics/bord_l.png", "graphics/bord_br.png", "graphics/bord_b.png", "graphics/bord_bl.png"
|
||||
|
|
|
|||
|
|
@ -1,4 +1,4 @@
|
|||
version "4.7"
|
||||
version "4.7.1"
|
||||
|
||||
/*
|
||||
SWWM GZ Main Codebase
|
||||
|
|
|
|||
|
|
@ -148,18 +148,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)
|
||||
|
|
|
|||
|
|
@ -10,7 +10,7 @@ Class SWWMStatusBar : BaseStatusBar
|
|||
{
|
||||
TextureID StatusTex, WeaponTex, ScoreTex[3], InventoryTex, ChatTex[6],
|
||||
HealthTex[6], FuelTex[2], DashTex, EnemyBTex, EnemyHTex[6],
|
||||
GenericAmmoTex[3], MiniBox, AutoPage;
|
||||
GenericAmmoTex[3], MiniBox, AutoPage, PauseTex, bgtex;
|
||||
HUDFont mTewiFont, mMiniwiFont, mMPlusFont, mk6x8Font;
|
||||
|
||||
Array<MsgLine> MainQueue, PickupQueue;
|
||||
|
|
@ -1162,6 +1162,8 @@ Class SWWMStatusBar : BaseStatusBar
|
|||
GenericAmmoTex[2] = TexMan.CheckForTexture("graphics/HUD/GenericAmmoBoxR.png",TexMan.Type_Any);
|
||||
MiniBox = TexMan.CheckForTexture("graphics/HUD/MinimapBox.png",TexMan.Type_Any);
|
||||
AutoPage = TexMan.CheckForTexture("AUTOPAGE",TexMan.Type_Autopage);
|
||||
PauseTex = TexMan.CheckForTexture("graphics/swwmpause.png",TexMan.Type_Any);
|
||||
bgtex = TexMan.CheckForTexture("graphics/tempbg.png",TexMan.Type_Any);
|
||||
minimapzoom = oldminimapzoom = 1.;
|
||||
mTewiFont = HUDFont.Create("TewiShaded");
|
||||
mMiniwiFont = HUDFont.Create("MiniwiShaded");
|
||||
|
|
@ -2610,6 +2612,30 @@ Class SWWMStatusBar : BaseStatusBar
|
|||
return true;
|
||||
}
|
||||
|
||||
override bool DrawPaused( int player )
|
||||
{
|
||||
if ( swwm_fuzz )
|
||||
{
|
||||
Vector2 tsize = TexMan.GetScaledSize(bgtex);
|
||||
double zoom = max(ceil(Screen.GetWidth()/tsize.x),ceil(Screen.GetHeight()/tsize.y));
|
||||
Vector2 vsize = (Screen.GetWidth(),Screen.GetHeight())/zoom;
|
||||
Screen.DrawTexture(bgtex,false,(vsize.x-tsize.x)/2,(vsize.y-tsize.y)/2,DTA_VirtualWidthF,vsize.x,DTA_VirtualHeightF,vsize.y,DTA_KeepRatio,true,DTA_ColorOverlay,Color(192,0,0,0),DTA_Alpha,.5);
|
||||
}
|
||||
else Screen.Dim("Black",.5,0,0,Screen.GetWidth(),Screen.GetHeight());
|
||||
Screen.DrawTexture(PauseTex,false,Screen.GetWidth()/2,Screen.GetHeight()/2,DTA_CleanNoMove,true,DTA_CenterOffset,true);
|
||||
if ( multiplayer && (player != -1) )
|
||||
{
|
||||
Font fnt = LangFont(mTewiFont);
|
||||
String str = String.Format(StringTable.Localize("$TXT_BY"),players[player].GetUserName());
|
||||
Vector2 sz = TexMan.GetScaledSize(PauseTex);
|
||||
double xx = (Screen.GetWidth()-fnt.StringWidth(str)*CleanXFac)/2;
|
||||
double yy = (Screen.GetHeight()+(sz.y+4)*CleanYFac)/2;
|
||||
Screen.DrawText(fnt,Font.CR_WHITE,xx,yy,str,DTA_CleanNoMove,true);
|
||||
}
|
||||
// TODO draw something extra to make the screen more visually interesting, maybe
|
||||
return true;
|
||||
}
|
||||
|
||||
override void DrawPowerups()
|
||||
{
|
||||
// don't do anything
|
||||
|
|
|
|||
|
|
@ -508,16 +508,17 @@ Class GhostArtifact : Inventory
|
|||
return true;
|
||||
}
|
||||
|
||||
override void PreTravelled()
|
||||
{
|
||||
if ( tracer ) tracer.Destroy();
|
||||
}
|
||||
override void Travelled()
|
||||
{
|
||||
Super.Travelled();
|
||||
if ( !tracer )
|
||||
{
|
||||
tracer = Spawn("GhostArtifactX",pos);
|
||||
tracer.angle = angle;
|
||||
tracer.target = self;
|
||||
tracer.FloatBobPhase = FloatBobPhase;
|
||||
}
|
||||
if ( tracer ) return;
|
||||
tracer = Spawn("GhostArtifactX",pos);
|
||||
tracer.angle = angle;
|
||||
tracer.target = self;
|
||||
tracer.FloatBobPhase = FloatBobPhase;
|
||||
}
|
||||
|
||||
override void PostBeginPlay()
|
||||
|
|
@ -661,16 +662,17 @@ Class GravitySuppressor : Inventory
|
|||
SWWMUtility.AchievementProgressInc("gravity",1,Owner.player);
|
||||
return true;
|
||||
}
|
||||
override void PreTravelled()
|
||||
{
|
||||
if ( tracer ) tracer.Destroy();
|
||||
}
|
||||
override void Travelled()
|
||||
{
|
||||
Super.Travelled();
|
||||
if ( !tracer )
|
||||
{
|
||||
tracer = Spawn("GravityX",pos);
|
||||
tracer.angle = angle;
|
||||
tracer.target = self;
|
||||
tracer.FloatBobPhase = FloatBobPhase;
|
||||
}
|
||||
if ( tracer ) return;
|
||||
tracer = Spawn("GravityX",pos);
|
||||
tracer.angle = angle;
|
||||
tracer.target = self;
|
||||
tracer.FloatBobPhase = FloatBobPhase;
|
||||
}
|
||||
override void PostBeginPlay()
|
||||
{
|
||||
|
|
@ -911,16 +913,17 @@ Class FuckingInvinciball : Inventory
|
|||
SWWMUtility.AchievementProgressInc("sunny",1,Owner.player);
|
||||
return true;
|
||||
}
|
||||
override void PreTravelled()
|
||||
{
|
||||
if ( tracer ) tracer.Destroy();
|
||||
}
|
||||
override void Travelled()
|
||||
{
|
||||
Super.Travelled();
|
||||
if ( !tracer )
|
||||
{
|
||||
tracer = Spawn("InvinciballX",pos);
|
||||
tracer.angle = angle;
|
||||
tracer.target = self;
|
||||
tracer.FloatBobPhase = FloatBobPhase;
|
||||
}
|
||||
if ( tracer ) return;
|
||||
tracer = Spawn("InvinciballX",pos);
|
||||
tracer.angle = angle;
|
||||
tracer.target = self;
|
||||
tracer.FloatBobPhase = FloatBobPhase;
|
||||
}
|
||||
override void PostBeginPlay()
|
||||
{
|
||||
|
|
@ -1202,16 +1205,17 @@ Class Ragekit : Inventory
|
|||
else Owner.GiveInventory("RagekitPower",1);
|
||||
return true;
|
||||
}
|
||||
override void PreTravelled()
|
||||
{
|
||||
if ( tracer ) tracer.Destroy();
|
||||
}
|
||||
override void Travelled()
|
||||
{
|
||||
Super.Travelled();
|
||||
if ( !tracer )
|
||||
{
|
||||
tracer = Spawn("RagekitX",pos);
|
||||
tracer.angle = angle;
|
||||
tracer.target = self;
|
||||
tracer.FloatBobPhase = FloatBobPhase;
|
||||
}
|
||||
if ( tracer ) return;
|
||||
tracer = Spawn("RagekitX",pos);
|
||||
tracer.angle = angle;
|
||||
tracer.target = self;
|
||||
tracer.FloatBobPhase = FloatBobPhase;
|
||||
}
|
||||
override void PostBeginPlay()
|
||||
{
|
||||
|
|
@ -1275,6 +1279,10 @@ Class Omnisight : Inventory
|
|||
Demolitionist(Owner).lastbump *= 1.1;
|
||||
level.allmap = true;
|
||||
}
|
||||
// activate all interest markers
|
||||
let ti = ThinkerIterator.Create("SWWMInterestMarker",STAT_MAPMARKER);
|
||||
Actor a;
|
||||
while ( a = Actor(ti.Next()) ) a.bDORMANT = false;
|
||||
// spread to all players
|
||||
for ( int i=0; i<MAXPLAYERS; i++ )
|
||||
{
|
||||
|
|
@ -1425,6 +1433,7 @@ Class LampMoth : Actor
|
|||
}
|
||||
}
|
||||
if ( !lamp || (lamp.frame == 0) || (Distance3D(lamp) > 250) || !CheckSight(lamp,SF_IGNOREVISIBILITY|SF_IGNOREWATERBOUNDARY) ) return false;
|
||||
if ( target && (target.Health > 0) && CheckSight(target) ) return false;
|
||||
return true;
|
||||
}
|
||||
void A_SmoothWander()
|
||||
|
|
@ -1551,7 +1560,8 @@ Class LampMoth : Actor
|
|||
override void Tick()
|
||||
{
|
||||
Super.Tick();
|
||||
if ( isFrozen() || isEntranced() )
|
||||
if ( isFrozen() ) return;
|
||||
if ( isEntranced() )
|
||||
{
|
||||
lifespan = 100;
|
||||
return;
|
||||
|
|
@ -1955,6 +1965,11 @@ Class SWWMLamp : Inventory
|
|||
if ( deathmatch ) return false;
|
||||
return Super.ShouldSpawn();
|
||||
}
|
||||
override void PreTravelled()
|
||||
{
|
||||
// remove the lamp
|
||||
if ( thelamp ) thelamp.Destroy();
|
||||
}
|
||||
override void DoEffect()
|
||||
{
|
||||
Super.DoEffect();
|
||||
|
|
@ -2187,16 +2202,18 @@ Class EBarrier : Inventory
|
|||
SWWMUtility.AchievementProgressInc("barrier",1,Owner.player);
|
||||
return true;
|
||||
}
|
||||
override void PreTravelled()
|
||||
{
|
||||
if ( tracer ) tracer.Destroy();
|
||||
}
|
||||
override void Travelled()
|
||||
{
|
||||
Super.Travelled();
|
||||
if ( !tracer )
|
||||
{
|
||||
tracer = Spawn("EBarrierX",pos);
|
||||
tracer.angle = angle;
|
||||
tracer.target = self;
|
||||
tracer.FloatBobPhase = FloatBobPhase;
|
||||
}
|
||||
if ( tracer ) return;
|
||||
tracer = Spawn("EBarrierX",pos);
|
||||
tracer.angle = angle;
|
||||
tracer.target = self;
|
||||
tracer.FloatBobPhase = FloatBobPhase;
|
||||
}
|
||||
override void PostBeginPlay()
|
||||
{
|
||||
|
|
@ -2891,6 +2908,15 @@ Class Mykradvo : Inventory
|
|||
return Super.CanPickup(toucher);
|
||||
}
|
||||
|
||||
override void PreTravelled()
|
||||
{
|
||||
if ( tracer ) tracer.Destroy();
|
||||
for ( int i=0; i<2; i++ )
|
||||
{
|
||||
if ( !ringa[i] ) continue;
|
||||
ringa[i].Destroy();
|
||||
}
|
||||
}
|
||||
override void Travelled()
|
||||
{
|
||||
Super.Travelled();
|
||||
|
|
@ -3330,16 +3356,18 @@ Class AngerySigil : Inventory
|
|||
else Owner.GiveInventory("AngeryPower",1);
|
||||
return true;
|
||||
}
|
||||
override void PreTravelled()
|
||||
{
|
||||
if ( tracer ) tracer.Destroy();
|
||||
}
|
||||
override void Travelled()
|
||||
{
|
||||
Super.Travelled();
|
||||
if ( !tracer )
|
||||
{
|
||||
tracer = Spawn("AngerySigilX",pos);
|
||||
tracer.angle = angle;
|
||||
tracer.target = self;
|
||||
tracer.FloatBobPhase = FloatBobPhase;
|
||||
}
|
||||
if ( tracer ) return;
|
||||
tracer = Spawn("AngerySigilX",pos);
|
||||
tracer.angle = angle;
|
||||
tracer.target = self;
|
||||
tracer.FloatBobPhase = FloatBobPhase;
|
||||
}
|
||||
override void PostBeginPlay()
|
||||
{
|
||||
|
|
@ -3602,16 +3630,17 @@ Class DivineSprite : Inventory
|
|||
SWWMUtility.AchievementProgressInc("divine",1,Owner.player);
|
||||
return true;
|
||||
}
|
||||
override void PreTravelled()
|
||||
{
|
||||
if ( tracer ) tracer.Destroy();
|
||||
}
|
||||
override void Travelled()
|
||||
{
|
||||
Super.Travelled();
|
||||
if ( !tracer )
|
||||
{
|
||||
tracer = Spawn("DivineSpriteX",pos);
|
||||
tracer.angle = angle;
|
||||
tracer.target = self;
|
||||
tracer.FloatBobPhase = FloatBobPhase;
|
||||
}
|
||||
if ( tracer ) return;
|
||||
tracer = Spawn("DivineSpriteX",pos);
|
||||
tracer.angle = angle;
|
||||
tracer.target = self;
|
||||
tracer.FloatBobPhase = FloatBobPhase;
|
||||
}
|
||||
override void PostBeginPlay()
|
||||
{
|
||||
|
|
|
|||
|
|
@ -512,6 +512,7 @@ Class Demolitionist : PlayerPawn
|
|||
if ( !thesight && !CheckSight(i,SF_IGNOREVISIBILITY|SF_IGNOREWATERBOUNDARY) ) continue;
|
||||
SWWMItemSense.Spawn(self,i);
|
||||
}
|
||||
bt.Destroy();
|
||||
}
|
||||
void CheckDefaceTexture()
|
||||
{
|
||||
|
|
@ -942,6 +943,7 @@ Class Demolitionist : PlayerPawn
|
|||
t.A_SpawnParticle(pcol,SPF_FULLBRIGHT,30,2.,0,ppos.x,ppos.y,ppos.z,dir.x*.2,dir.y*.2,dir.z*.2,0,0,.05,alph,-1,-2./30.);
|
||||
}
|
||||
}
|
||||
bt.Destroy();
|
||||
}
|
||||
override void CheckPoison()
|
||||
{
|
||||
|
|
@ -2717,6 +2719,17 @@ Class Demolitionist : PlayerPawn
|
|||
mystats.secrets++;
|
||||
return true;
|
||||
}
|
||||
override void RemoveInventory( Inventory item )
|
||||
{
|
||||
// stop any looping sounds our current weapon had
|
||||
if ( (item is 'SWWMWeapon') && player && (SWWMWeapon(item) == player.ReadyWeapon) )
|
||||
{
|
||||
A_StopSound(CHAN_WEAPONEXTRA);
|
||||
A_StopSound(CHAN_WEAPONEXTRA2);
|
||||
A_StopSound(CHAN_WEAPONEXTRA3);
|
||||
}
|
||||
Super.RemoveInventory(item);
|
||||
}
|
||||
override void AddInventory( Inventory item )
|
||||
{
|
||||
// hackaround for replaced keys
|
||||
|
|
@ -2931,6 +2944,14 @@ Class Demolitionist : PlayerPawn
|
|||
// we need the crouch button state to be preserved for other functions
|
||||
if ( wascrouching ) player.cmd.buttons |= BT_CROUCH;
|
||||
}
|
||||
override void PreTravelled()
|
||||
{
|
||||
// clean up attached actors
|
||||
if ( selflight ) selflight.Destroy();
|
||||
// inventory wipes
|
||||
if ( FindInventory("InventoryWipeToken") )
|
||||
SWWMUtility.WipeInventory(self,swwm_resetscore);
|
||||
}
|
||||
override void Travelled()
|
||||
{
|
||||
// reinitialize
|
||||
|
|
@ -2958,7 +2979,8 @@ Class Demolitionist : PlayerPawn
|
|||
}
|
||||
// re-add ourselves to the "suckable list" (otherwise the Ynykron Singularity won't hurt us)
|
||||
let hnd = SWWMHandler(EventHandler.Find("SWWMHandler"));
|
||||
if ( hnd ) hnd.SuckableActors.Push(self);
|
||||
if ( hnd && (hnd.SuckableActors.Find(self) >= hnd.SuckableActors.Size()) )
|
||||
hnd.SuckableActors.Push(self);
|
||||
// re-attach shadow
|
||||
if ( swwm_shadows <= 0 ) return;
|
||||
let ti = ThinkerIterator.Create("SWWMShadow");
|
||||
|
|
@ -2969,6 +2991,7 @@ Class Demolitionist : PlayerPawn
|
|||
return; // shadow already attached
|
||||
}
|
||||
SWWMShadow.Track(self);
|
||||
ti.Destroy();
|
||||
}
|
||||
override bool PreTeleport( Vector3 destpos, double destangle, int flags )
|
||||
{
|
||||
|
|
|
|||
|
|
@ -344,24 +344,6 @@ Class SWWMStaticHandler : StaticEventHandler
|
|||
|
||||
override void UiTick()
|
||||
{
|
||||
// HACK! Graf, please let us change this in a cleaner way
|
||||
if ( menuDelegate.GetClass() == 'DoomMenuDelegate' )
|
||||
{
|
||||
menuDelegate.Destroy();
|
||||
menuDelegate = new("SWWMMenuDelegate");
|
||||
}
|
||||
// Hey Graf how about you let us replace the class used for the
|
||||
// "Read This!" menu in mapinfo/gameinfo or something so I
|
||||
// don't have to do this hack here?
|
||||
Menu cur = Menu.GetCurrentMenu();
|
||||
if ( cur is 'ReadThisMenu' )
|
||||
{
|
||||
Menu oldpt = cur.mParentMenu;
|
||||
cur.Close();
|
||||
Menu.SetMenu('SWWMHelpMenu');
|
||||
cur = Menu.GetCurrentMenu();
|
||||
if ( cur ) cur.mParentMenu = oldpt;
|
||||
}
|
||||
// Fancy crash effect
|
||||
if ( (gamestate == GS_LEVEL) || (gamestate == GS_TITLELEVEL) )
|
||||
{
|
||||
|
|
|
|||
|
|
@ -145,11 +145,28 @@ enum EInterestType
|
|||
INT_Exit
|
||||
};
|
||||
|
||||
Class SWWMInterestMarker : MapMarker
|
||||
{
|
||||
Default
|
||||
{
|
||||
Scale 2.;
|
||||
Args 0, 0, 1;
|
||||
+DORMANT;
|
||||
}
|
||||
States
|
||||
{
|
||||
Spawn:
|
||||
EIXT AB -1;
|
||||
Stop;
|
||||
}
|
||||
}
|
||||
|
||||
Class SWWMInterest : Thinker
|
||||
{
|
||||
int type;
|
||||
Key trackedkey;
|
||||
Line trackedline;
|
||||
Actor marker;
|
||||
Vector3 pos;
|
||||
SWWMInterest prev, next;
|
||||
String keytag;
|
||||
|
|
@ -167,8 +184,23 @@ Class SWWMInterest : Thinker
|
|||
{
|
||||
i.type = INT_Key;
|
||||
i.keytag = thekey.GetTag();
|
||||
i.marker = Actor.Spawn("SWWMInterestMarker",thekey.pos);
|
||||
if ( thekey is 'SWWMKey' )
|
||||
{
|
||||
Class<Key> k = thekey.species;
|
||||
let def = GetDefaultByType(k);
|
||||
i.marker.picnum = def.SpawnState.GetSpriteTexture(0);
|
||||
}
|
||||
else i.marker.picnum = thekey.SpawnState.GetSpriteTexture(0);
|
||||
i.marker.target = thekey;
|
||||
}
|
||||
else if ( theline )
|
||||
{
|
||||
i.type = INT_Exit;
|
||||
i.marker = Actor.Spawn("SWWMInterestMarker",pos);
|
||||
if ( theline.special == Exit_Secret )
|
||||
i.marker.SetState(i.marker.SpawnState+1);
|
||||
}
|
||||
else if ( theline ) i.type = INT_Exit;
|
||||
else
|
||||
{
|
||||
i.Destroy();
|
||||
|
|
@ -205,8 +237,16 @@ Class SWWMInterest : Thinker
|
|||
override void Tick()
|
||||
{
|
||||
// update
|
||||
if ( (type == INT_Key) && (!trackedkey || trackedkey.Owner) ) Destroy();
|
||||
else if ( trackedkey ) pos = trackedkey.Vec3Offset(0,0,trackedkey.height/2);
|
||||
if ( (type == INT_Key) && (!trackedkey || trackedkey.Owner) )
|
||||
{
|
||||
marker.Destroy();
|
||||
Destroy();
|
||||
}
|
||||
else if ( trackedkey )
|
||||
{
|
||||
pos = trackedkey.Vec3Offset(0,0,trackedkey.height/2);
|
||||
marker.SetOrigin(pos,true);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -6,8 +6,6 @@ Class SWWMWeapon : Weapon abstract
|
|||
|
||||
bool wasused;
|
||||
bool bUsePickup;
|
||||
transient bool hastravelled;
|
||||
transient int autoupsnd;
|
||||
private int SWeaponFlags;
|
||||
String tooltip, getline;
|
||||
bool tooltipsent;
|
||||
|
|
@ -244,19 +242,10 @@ Class SWWMWeapon : Weapon abstract
|
|||
}
|
||||
GivenAsMorphWeapon = false;
|
||||
}
|
||||
override void DetachFromOwner()
|
||||
{
|
||||
Owner.A_StopSound(CHAN_WEAPON);
|
||||
Owner.A_StopSound(CHAN_WEAPONEXTRA);
|
||||
Owner.A_StopSound(CHAN_WEAPONEXTRA2);
|
||||
Owner.A_StopSound(CHAN_WEAPONEXTRA3);
|
||||
Super.DetachFromOwner();
|
||||
}
|
||||
override void OwnerDied()
|
||||
{
|
||||
if ( Owner.player && (Owner.player.ReadyWeapon == self) )
|
||||
{
|
||||
Owner.A_StopSound(CHAN_WEAPON);
|
||||
Owner.A_StopSound(CHAN_WEAPONEXTRA);
|
||||
Owner.A_StopSound(CHAN_WEAPONEXTRA2);
|
||||
Owner.A_StopSound(CHAN_WEAPONEXTRA3);
|
||||
|
|
@ -341,23 +330,12 @@ Class SWWMWeapon : Weapon abstract
|
|||
}
|
||||
override void PlayUpSound( Actor origin )
|
||||
{
|
||||
if ( hastravelled ) return;
|
||||
if ( UpSound ) origin.A_StartSound(UpSound,CHAN_WEAPON,CHANF_OVERLAP);
|
||||
}
|
||||
override void Travelled()
|
||||
{
|
||||
Super.Travelled();
|
||||
hastravelled = true;
|
||||
}
|
||||
override void Tick()
|
||||
{
|
||||
Super.Tick();
|
||||
if ( !Owner ) return;
|
||||
if ( autoupsnd && (level.maptime >= autoupsnd) )
|
||||
{
|
||||
autoupsnd = 0;
|
||||
PlayUpSound(Owner);
|
||||
}
|
||||
if ( !Owner.player || (Owner.player.ReadyWeapon != self) || !(Owner.player.WeaponState&WF_WEAPONSWITCHOK) || (Owner.player.WeaponState&WF_DISABLESWITCH) )
|
||||
{
|
||||
tooltipsent = false;
|
||||
|
|
|
|||
|
|
@ -584,16 +584,17 @@ Class Hellblazer : SWWMWeapon
|
|||
}
|
||||
}
|
||||
|
||||
override void PreTravelled()
|
||||
{
|
||||
if ( tracer ) tracer.Destroy();
|
||||
}
|
||||
override void Travelled()
|
||||
{
|
||||
Super.Travelled();
|
||||
if ( !tracer )
|
||||
{
|
||||
tracer = Spawn("HellblazerX",pos);
|
||||
tracer.angle = angle;
|
||||
tracer.target = self;
|
||||
tracer.FloatBobPhase = FloatBobPhase;
|
||||
}
|
||||
if ( tracer ) return;
|
||||
tracer = Spawn("HellblazerX",pos);
|
||||
tracer.angle = angle;
|
||||
tracer.target = self;
|
||||
tracer.FloatBobPhase = FloatBobPhase;
|
||||
}
|
||||
override void PostBeginPlay()
|
||||
{
|
||||
|
|
|
|||
|
|
@ -76,7 +76,6 @@ Class Ynykron : SWWMWeapon
|
|||
|
||||
override void Travelled()
|
||||
{
|
||||
Super.Travelled();
|
||||
if ( Owner.player && (Owner.player.Readyweapon == self) )
|
||||
{
|
||||
Owner.A_StartSound("ynykron/idle",CHAN_WEAPONEXTRA,CHANF_LOOP,.3,4.);
|
||||
|
|
|
|||
|
|
@ -293,7 +293,7 @@ Class PusherWeapon : SWWMWeapon
|
|||
A_StartSound("pusher/motor",CHAN_WEAPONEXTRA,CHANF_LOOP,pitch:1.5);
|
||||
}
|
||||
XZW2 M 2;
|
||||
XZW2 N 0 A_StartSound("pusher/drill",CHAN_WEAPON,CHANF_LOOP);
|
||||
XZW2 N 0 A_StartSound("pusher/drill",CHAN_WEAPONEXTRA2,CHANF_LOOP);
|
||||
Hold:
|
||||
XZW2 N 1
|
||||
{
|
||||
|
|
@ -321,7 +321,7 @@ Class PusherWeapon : SWWMWeapon
|
|||
A_Recoil(.5*cos(pitch));
|
||||
A_ClearRefire();
|
||||
A_WeaponOffset(0,32);
|
||||
A_StopSound(CHAN_WEAPON);
|
||||
A_StopSound(CHAN_WEAPONEXTRA2);
|
||||
A_StartSound("pusher/stop",CHAN_WEAPON,CHANF_OVERLAP);
|
||||
A_StartSound("pusher/motorend",CHAN_WEAPONEXTRA,CHANF_DEFAULT,pitch:1.5);
|
||||
return ResolveState(null);
|
||||
|
|
|
|||
|
|
@ -177,7 +177,6 @@ Class Sparkster : SWWMWeapon
|
|||
|
||||
override void Travelled()
|
||||
{
|
||||
Super.Travelled();
|
||||
if ( Owner.player && (Owner.player.Readyweapon == self) )
|
||||
{
|
||||
Owner.A_StartSound("biospark/idle",CHAN_WEAPONEXTRA,CHANF_LOOP,doublestacc?.6:.4,4.);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue