From 8c64ee7f2d741489c9b638b635733a335bee8f69 Mon Sep 17 00:00:00 2001 From: Marisa Kirisame Date: Fri, 6 Sep 2019 01:41:34 +0200 Subject: [PATCH] Missed some Sentry stuff. Death FX still not done, oops. --- Readme.md | 1 - zscript/miscitems.zsc | 21 ++++++++++++++++++--- 2 files changed, 18 insertions(+), 4 deletions(-) diff --git a/Readme.md b/Readme.md index 06d7c46..f297fad 100644 --- a/Readme.md +++ b/Readme.md @@ -53,7 +53,6 @@ Doom Tournament (currently the devel branch is required). - Rifle (slot 9) (replaces plasma rifle) - Minigun (slot 0) (replaces chaingun) - ## Planned - Unreal Bible & prototype build behaviour restoration diff --git a/zscript/miscitems.zsc b/zscript/miscitems.zsc index 8b3ec3d..80dd54a 100644 --- a/zscript/miscitems.zsc +++ b/zscript/miscitems.zsc @@ -1418,6 +1418,16 @@ Class SentryItem : UnrealInventory Charge = tracer.Health; if ( Charge <= 0 ) DepleteOrDestroy(); } + override void Travelled() + { + Super.Travelled(); + if ( bActive && !tracer ) + { + bUNTOSSABLE = false; + bUNDROPPABLE = false; + DepleteOrDestroy(); + } + } States { Spawn: @@ -1538,7 +1548,7 @@ Class MinigunSentry : Actor special1 = max(0,special1-1); if ( (special1 <= 0) && master.master && master.master.CheckLocalView() ) Console.Printf(StringTable.Localize("$M_SENTRYDRY")); A_SentryFaceTarget(); - master.A_AlertMonsters(); + master.A_AlertMonsters(0,AMF_TARGETEMITTER); A_PlaySound("sentry/fire",CHAN_WEAPON); Vector3 x, y, z, origin; [x, y, z] = dt_CoordUtil.GetAxes(pitch,angle,roll); @@ -1593,7 +1603,11 @@ Class MinigunSentry : Actor { Spawn: SENT A 15; - SENT A 0 A_PlaySound("sentry/raise"); + SENT A 0 + { + A_PlaySound("sentry/raise"); + master.A_AlertMonsters(0,AMF_TARGETEMITTER); + } SENR ABCDEFGHIJKLMNO 3; Goto Idle; Idle: @@ -1641,7 +1655,7 @@ Class MinigunSentry : Actor SENW A 0 { A_PlaySound("sentry/wind",looping:true); - master.A_AlertMonsters(); + master.A_AlertMonsters(0,AMF_TARGETEMITTER); master.SetStateLabel("Missile"); } SENW ABCDEFGHIJKLMNOPQR 1 A_SentryFaceTarget(); @@ -1692,6 +1706,7 @@ Class MinigunSentry : Actor SENI A 0 { A_PlaySound("sentry/raise"); + master.A_AlertMonsters(0,AMF_TARGETEMITTER); master.SetStateLabel("DoPackUp"); } SENR ONMLKJIHGFEDCBA 3;