diff --git a/language.version b/language.version index 7e5085d5b..b04aac9c3 100644 --- a/language.version +++ b/language.version @@ -1,3 +1,3 @@ [default] -SWWM_MODVER="\cyDEMOLITIONIST \cw1.2pre r122 \cu(Sat 22 Jan 17:06:49 CET 2022)\c-"; -SWWM_SHORTVER="\cw1.2pre r122 \cu(2022-01-22 17:06:49)\c-"; +SWWM_MODVER="\cyDEMOLITIONIST \cw1.2pre r123 \cu(Sat 22 Jan 17:17:41 CET 2022)\c-"; +SWWM_SHORTVER="\cw1.2pre r123 \cu(2022-01-22 17:17:41)\c-"; diff --git a/sndinfo.txt b/sndinfo.txt index bfd78010d..01885b3f2 100644 --- a/sndinfo.txt +++ b/sndinfo.txt @@ -562,6 +562,7 @@ deepimpact/fire sounds/deepimpact/impfire.ogg deepimpact/charge sounds/deepimpact/impaltcharge.ogg deepimpact/altfire sounds/deepimpact/impaltfire.ogg deepimpact/dryfire sounds/deepimpact/impdryfire.ogg +deepimpact/dryaltfire sounds/deepimpact/impdryaltfire.ogg deepimpact/select sounds/deepimpact/impsel.ogg deepimpact/checkout sounds/deepimpact/impidle.ogg deepimpact/deselect sounds/deepimpact/impdown.ogg diff --git a/sounds/deepimpact/impdryaltfire.ogg b/sounds/deepimpact/impdryaltfire.ogg new file mode 100644 index 000000000..cd6475366 Binary files /dev/null and b/sounds/deepimpact/impdryaltfire.ogg differ diff --git a/zscript/weapons/swwm_deepdarkimpact.zsc b/zscript/weapons/swwm_deepdarkimpact.zsc index 0e77beb84..166f131df 100644 --- a/zscript/weapons/swwm_deepdarkimpact.zsc +++ b/zscript/weapons/swwm_deepdarkimpact.zsc @@ -46,6 +46,7 @@ Class DeepImpact : SWWMWeapon transient ui TextureID WeaponBox, AmmoBar; transient ui DynamicValueInterpolator ChargeInter; + transient int failtime; Property ClipCount : clipcount; @@ -56,8 +57,9 @@ Class DeepImpact : SWWMWeapon Screen.DrawTexture(WeaponBox,false,bx-36,by-54,DTA_VirtualWidthF,ss.x,DTA_VirtualHeightF,ss.y,DTA_KeepRatio,true); int chg = clamp(ChargeInter?ChargeInter.GetValue():clipcount,0,100); int ct = int(((by-2)-(chg*50./100.))*hs); - Screen.DrawTexture(AmmoBar,false,bx-7,by-52,DTA_VirtualWidthF,ss.x,DTA_VirtualHeightF,ss.y,DTA_KeepRatio,true,DTA_ClipTop,ct); - Screen.DrawText(smallfont,Font.CR_FIRE,bx-35,by-12,String.Format("%3d%%",chg),DTA_VirtualWidthF,ss.x,DTA_VirtualHeightF,ss.y,DTA_KeepRatio,true); + bool blinking = (failtime>gametic)&&((failtime-gametic)%8>=4); + Screen.DrawTexture(AmmoBar,false,bx-7,by-52,DTA_VirtualWidthF,ss.x,DTA_VirtualHeightF,ss.y,DTA_KeepRatio,true,DTA_ClipTop,ct,DTA_ColorOverlay,blinking?Color(128,0,0,0):Color(0,0,0,0)); + Screen.DrawText(smallfont,Font.CR_FIRE,bx-35,by-12,String.Format("%3d%%",chg),DTA_VirtualWidthF,ss.x,DTA_VirtualHeightF,ss.y,DTA_KeepRatio,true,DTA_ColorOverlay,blinking?Color(128,0,0,0):Color(0,0,0,0)); } override void HudTick() @@ -247,6 +249,12 @@ Class DeepImpact : SWWMWeapon } } + action void A_DryAltFire() + { + invoker.failtime = gametic+32; + A_StartSound("deepimpact/dryaltfire",CHAN_WEAPON,CHANF_OVERLAP); + } + action void A_AltBullet() { let weap = Weapon(invoker); @@ -363,11 +371,18 @@ Class DeepImpact : SWWMWeapon XZW2 STU 3; Goto Ready; AltFire: - XZW2 A 0 A_JumpIf(invoker.ClipCount<100,"Reload"); + XZW2 A 0 A_JumpIf(invoker.ClipCount<100,"DryAltFire"); XZW2 A 0 A_BeginCharge(); XZW2 A 1 A_ChargeUp(); XZW2 V 1 A_ChargeUp(); Wait; + DryAltFire: + // the useless goddess + XZW2 A 2 A_DryAltFire(); + XZW2 Q 4; + XZW2 U 5; + XZW2 A 2; + Goto Ready; AltRelease: XZW2 V 1 A_AltBullet(); XZW2 W 1;