Gun refactor (#8301)

Co-authored-by: Kara <lunarautomaton6@gmail.com>
Co-authored-by: T-Stalker <le0nel_1van@hotmail.com>
Co-authored-by: T-Stalker <43253663+DogZeroX@users.noreply.github.com>
Co-authored-by: ElectroJr <leonsfriedrich@gmail.com>
Co-authored-by: metalgearsloth <metalgearsloth@gmail.com>
This commit is contained in:
metalgearsloth
2022-06-01 19:59:58 +10:00
committed by GitHub
parent 1ced3c5002
commit fb943a61dc
1051 changed files with 8230 additions and 99090 deletions

View File

@@ -14,6 +14,7 @@ using Robust.Shared.Audio;
using Robust.Shared.Physics.Dynamics;
using Robust.Shared.Player;
using Robust.Shared.Prototypes;
using GunSystem = Content.Server.Weapon.Ranged.Systems.GunSystem;
namespace Content.Server.Projectiles
{
@@ -51,7 +52,7 @@ namespace Content.Server.Projectiles
$"Projectile {ToPrettyString(component.Owner):projectile} shot by {ToPrettyString(component.Shooter):user} hit {ToPrettyString(otherEntity):target} and dealt {modifiedDamage.Total:damage} damage");
}
_guns.PlaySound(otherEntity, modifiedDamage, component.SoundHit, component.ForceSound);
_guns.PlayImpactSound(otherEntity, modifiedDamage, component.SoundHit, component.ForceSound);
// Damaging it can delete it
if (HasComp<CameraRecoilComponent>(otherEntity))