From 30fbfafa5c2a1a7a02c3bea9337274a2f93c4daa Mon Sep 17 00:00:00 2001 From: Marisa Kirisame Date: Sat, 23 May 2020 14:07:12 +0200 Subject: [PATCH] Rebalances to dashing/boosting: - Doubled fuel capacity. - Increased fuel usage of dashing by 1.5x. - Reduced deceleration of boosting when holding jump. - Changed the fuel bar graphic to reflect new capacity. Increased air control. Fixed reported fuel usage (the fuel cells are 4L). --- graphics/HUD/FuelBar.png | Bin 115 -> 128 bytes language.version | 2 +- zscript/swwm_common.zsc | 4 ++-- zscript/swwm_hud.zsc | 2 +- zscript/swwm_menu.zsc | 2 +- zscript/swwm_player.zsc | 10 +++++----- 6 files changed, 10 insertions(+), 10 deletions(-) diff --git a/graphics/HUD/FuelBar.png b/graphics/HUD/FuelBar.png index 262f9eb22c0983aa3fc811f30da791a8cb937e75..e710d11ec7278343f63c23e64e1bba04a0aee52f 100644 GIT binary patch delta 110 zcmXSJV4NV4!NSbIz_4olwZ{w$3~~WJA+8MJ3=9bj3~Lw|4lpo0WnlQv;N|5N6cjXN z%9N!`mvS;>u4Z6hko9zN4B@z*oRHuVbg4j*-++TlOgg%461#-PMoEU5O@>!>zW2m1 QFfcH9y85}Sb4q9e0LIcFb^rhX delta 97 zcmZo*ES?|{&B4aNz!1@R`T_$3gO#U?V~EA+ 20) || ((gametic%10) < 5) ) alph = 1.; Screen.DrawTexture(DashTex,false,margin+2,ss.y-(margin+20),DTA_VirtualWidthF,ss.x,DTA_VirtualHeightF,ss.y,DTA_KeepRatio,true,DTA_WindowRight,dw,DTA_Alpha,alph); - int fw = FuelInter.GetValue(); + int fw = FuelInter.GetValue()/2; Screen.DrawTexture(FuelTex,false,margin+2,ss.y-(margin+24),DTA_VirtualWidthF,ss.x,DTA_VirtualHeightF,ss.y,DTA_KeepRatio,true,DTA_WindowRight,fw); int ht = clamp(HealthInter.GetValue(),0,10000); int hw = min(ht,100); diff --git a/zscript/swwm_menu.zsc b/zscript/swwm_menu.zsc index 6cc0771d9..7724a906c 100644 --- a/zscript/swwm_menu.zsc +++ b/zscript/swwm_menu.zsc @@ -1932,7 +1932,7 @@ Class SWWMKnowledgeBaseMenu : GenericMenu str = String.Format("\cx%s\c-%d",StringTable.Localize("$SWWM_STATSTOMP"),stats.stompcount); Screen.DrawText(fnt,Font.CR_WHITE,origin.x+xx,origin.y+yy,str,DTA_VirtualWidthF,ss.x,DTA_VirtualHeightF,ss.y,DTA_KeepRatio,true); yy += 16; - str = String.Format("\cx%s\c-%g\cul\c-",StringTable.Localize("$SWWM_STATFUEL"),stats.fuelusage/6.); + str = String.Format("\cx%s\c-%g\cul\c-",StringTable.Localize("$SWWM_STATFUEL"),stats.fuelusage/60.); Screen.DrawText(fnt,Font.CR_WHITE,origin.x+xx,origin.y+yy,str,DTA_VirtualWidthF,ss.x,DTA_VirtualHeightF,ss.y,DTA_KeepRatio,true); yy += 16; str = String.Format("\cx%s\c-%g\cukm/h\c-",StringTable.Localize("$SWWM_STATSPEED"),stats.topspeed*32000./(3600*Thinker.TICRATE)); diff --git a/zscript/swwm_player.zsc b/zscript/swwm_player.zsc index 220caad78..579f24168 100644 --- a/zscript/swwm_player.zsc +++ b/zscript/swwm_player.zsc @@ -285,8 +285,8 @@ Class Demolitionist : PlayerPawn if ( swwm_extraalert ) A_AlertMonsters(800); dashboost *= (player.cmd.buttons&BT_USER2)?.8:.1; } - mystats.fuelusage += dashfuel-max(0.,dashfuel-dashboost); - dashfuel = max(0.,dashfuel-dashboost); + mystats.fuelusage += dashfuel-max(0.,dashfuel-dashboost*1.5); + dashfuel = max(0.,dashfuel-dashboost*1.5); dashcooldown = min(40,max(10,int(dashcooldown*1.4))); fuelcooldown = max(60,fuelcooldown); if ( (dashfuel <= 0.) || (dashboost <= 0.) ) @@ -300,7 +300,7 @@ Class Demolitionist : PlayerPawn else { if ( swwm_extraalert ) A_AlertMonsters(800); - dashboost *= (player.cmd.buttons&BT_JUMP)?.9:.4; + dashboost *= (player.cmd.buttons&BT_JUMP)?.95:.4; last_boost = level.maptime+1; } mystats.fuelusage += dashfuel-max(0.,dashfuel-dashboost); @@ -548,7 +548,7 @@ Class Demolitionist : PlayerPawn dashcooldown = max(0,dashcooldown-1); boostcooldown = max(0,boostcooldown-1); if ( fuelcooldown <= 0 ) - dashfuel = min(120.,dashfuel+max(dashfuel*.01,.05)); + dashfuel = min(240.,dashfuel+max(dashfuel*.01,.05)); if ( (dashboost > 0.) && (InStateSequence(CurState,FindState("Dash")) || (InStateSequence(CurState,FindState("Jump")) && player.cmd.buttons&BT_JUMP)) ) dashsnd = true; else @@ -779,7 +779,7 @@ Class Demolitionist : PlayerPawn double fs = TweakSpeeds(1.,0.); if ( CanCrouch() && (player.crouchfactor != -1) ) fs *= player.crouchfactor; Vector3 accel = (RotateVector((player.cmd.forwardmove,-player.cmd.sidemove),angle),0); - accel *= fs/960.; + accel *= fs/512.; double spd = vel.length(); if ( spd > 10. ) vel = (vel+accel/TICRATE).unit()*spd; else vel = vel+accel/TICRATE;