Rework the HoS's Energy Shotgun (Varying energy consumption depending on fire-mode + re-adds a toned down self recharge.) (#32104)
* Rebalance HoS's Energy Shotgun * SLIGHTLY Up the max charge so the gun properly recharges all of its charges, which matters a lot more with the self charge cooldown system. * Prevent recharge cooldown if 0 power is used. * Makes the clientside HUD actually update to reflect the changes in firecost and thus max/current charges. * Properly fix that recharging to just under full issue instead of applying a budget fix to only the eshotgun. * Clean up the client ammo UI fix. * Update the self recharger component to comply with maintainer request. Co-authored-by: slarticodefast <161409025+slarticodefast@users.noreply.github.com> * Remove code that was made redundant by a hotfix from another PR. * Make the recharge pause on EMP, document things where needed, clean up code as per maintainer request, add a note to make the code better when power is moved to shared. * Fix another internal issue * Code cleanup + fix the rapid recharge verb to remove pause. * cleanup --------- Co-authored-by: slarticodefast <161409025+slarticodefast@users.noreply.github.com> Co-authored-by: metalgearsloth <comedian_vs_clown@hotmail.com>
This commit is contained in:
@@ -77,6 +77,7 @@ public sealed partial class GunSystem : SharedGunSystem
|
||||
base.Initialize();
|
||||
UpdatesOutsidePrediction = true;
|
||||
SubscribeLocalEvent<AmmoCounterComponent, ItemStatusCollectMessage>(OnAmmoCounterCollect);
|
||||
SubscribeLocalEvent<AmmoCounterComponent, UpdateClientAmmoEvent>(OnUpdateClientAmmo);
|
||||
SubscribeAllEvent<MuzzleFlashEvent>(OnMuzzleFlash);
|
||||
|
||||
// Plays animated effects on the client.
|
||||
@@ -86,6 +87,11 @@ public sealed partial class GunSystem : SharedGunSystem
|
||||
InitializeSpentAmmo();
|
||||
}
|
||||
|
||||
private void OnUpdateClientAmmo(EntityUid uid, AmmoCounterComponent ammoComp, ref UpdateClientAmmoEvent args)
|
||||
{
|
||||
UpdateAmmoCount(uid, ammoComp);
|
||||
}
|
||||
|
||||
private void OnMuzzleFlash(MuzzleFlashEvent args)
|
||||
{
|
||||
var gunUid = GetEntity(args.Uid);
|
||||
|
||||
Reference in New Issue
Block a user