Drink from closed container fix (#26103)

This commit is contained in:
maylokana 2024-03-13 23:10:14 -05:00 committed by GitHub
parent e5f05b735d
commit 2f2cd4aab7
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
1 changed files with 3 additions and 0 deletions

View File

@ -311,6 +311,9 @@ public sealed class DrinkSystem : EntitySystem
if (args.Used is null || !_solutionContainer.TryGetSolution(args.Used.Value, args.Solution, out var soln, out var solution))
return;
if (_openable.IsClosed(args.Used.Value, args.Target.Value))
return;
// TODO this should really be checked every tick.
if (_food.IsMouthBlocked(args.Target.Value))
return;