перенос файлов сервера из папки White в _White

This commit is contained in:
Remuchi
2024-01-28 18:18:54 +07:00
parent 21dbccfec9
commit 1e4ad59270
309 changed files with 450 additions and 437 deletions

View File

@@ -0,0 +1,27 @@
using Content.Server.IgnitionSource;
using Content.Shared.Temperature;
using Content.Shared.Weapons.Ranged.Systems;
namespace Content.Server._White.Flamethrower;
public sealed class FlamethrowerSystem : EntitySystem
{
public override void Initialize()
{
base.Initialize();
SubscribeLocalEvent<FlamethrowerComponent, GunShotEvent>(OnShoot);
}
private void OnShoot(EntityUid uid, FlamethrowerComponent component, ref GunShotEvent args)
{
var hasIgnition = TryComp(uid, out IgnitionSourceComponent? ignition);
var isHotEvent = new IsHotEvent {IsHot = hasIgnition && ignition!.Ignited};
foreach (var (shotUid, _) in args.Ammo)
{
if(shotUid is not null)
RaiseLocalEvent(shotUid.Value, isHotEvent);
}
}
}