using Content.Server.Body.Components;
using Content.Server.Body.Systems;
-using Content.Server.Chemistry.Containers.EntitySystems;
+using Content.Shared.Chemistry.EntitySystems;
using Content.Server.Fluids.EntitySystems;
using Content.Server.Forensics;
using Content.Server.Popups;
[Dependency] private readonly HungerSystem _hunger = default!;
[Dependency] private readonly PopupSystem _popup = default!;
[Dependency] private readonly PuddleSystem _puddle = default!;
- [Dependency] private readonly SolutionContainerSystem _solutionContainer = default!;
+ [Dependency] private readonly SharedSolutionContainerSystem _solutionContainer = default!;
[Dependency] private readonly StunSystem _stun = default!;
[Dependency] private readonly ThirstSystem _thirst = default!;
[Dependency] private readonly ForensicsSystem _forensics = default!;
public void Vomit(EntityUid uid, float thirstAdded = -40f, float hungerAdded = -40f)
{
// Main requirement: You have a stomach
- var stomachList = _body.GetBodyOrganComponents<StomachComponent>(uid);
+ var stomachList = _body.GetBodyOrganEntityComps<StomachComponent>(uid);
if (stomachList.Count == 0)
return;
// Empty the stomach out into it
foreach (var stomach in stomachList)
{
- if (_solutionContainer.ResolveSolution(stomach.Comp.Owner, StomachSystem.DefaultSolutionName, ref stomach.Comp.Solution, out var sol))
+ if (_solutionContainer.ResolveSolution(stomach.Owner, StomachSystem.DefaultSolutionName, ref stomach.Comp1.Solution, out var sol))
{
solution.AddSolution(sol, _proto);
sol.RemoveAllSolution();
- _solutionContainer.UpdateChemicals(stomach.Comp.Solution.Value);
+ _solutionContainer.UpdateChemicals(stomach.Comp1.Solution.Value);
}
}
// Adds a tiny amount of the chem stream from earlier along with vomit
vomitChemstreamAmount.ScaleSolution(chemMultiplier);
solution.AddSolution(vomitChemstreamAmount, _proto);
- vomitAmount -= (float) vomitChemstreamAmount.Volume;
+ vomitAmount -= (float)vomitChemstreamAmount.Volume;
}
// Makes a vomit solution the size of 90% of the chemicals removed from the chemstream