Mouse content (#7307)

This commit is contained in:
mirrorcult
2022-03-28 13:53:20 -07:00
committed by GitHub
parent 255192caf7
commit 3cc0eb5f33
4 changed files with 26 additions and 8 deletions

View File

@@ -46,7 +46,7 @@ namespace Content.Server.Nutrition.EntitySystems
SubscribeLocalEvent<FoodComponent, UseInHandEvent>(OnUseFoodInHand);
SubscribeLocalEvent<FoodComponent, AfterInteractEvent>(OnFeedFood);
SubscribeLocalEvent<FoodComponent, GetVerbsEvent<InteractionVerb>>(AddEatVerb);
SubscribeLocalEvent<FoodComponent, GetVerbsEvent<AlternativeVerb>>(AddEatVerb);
SubscribeLocalEvent<SharedBodyComponent, FeedEvent>(OnFeed);
SubscribeLocalEvent<ForceFeedCancelledEvent>(OnFeedCancelled);
SubscribeLocalEvent<InventoryComponent, IngestionAttemptEvent>(OnInventoryIngestAttempt);
@@ -235,7 +235,7 @@ namespace Content.Server.Nutrition.EntitySystems
EntityManager.QueueDeleteEntity(component.Owner);
}
private void AddEatVerb(EntityUid uid, FoodComponent component, GetVerbsEvent<InteractionVerb> ev)
private void AddEatVerb(EntityUid uid, FoodComponent component, GetVerbsEvent<AlternativeVerb> ev)
{
if (component.CancelToken != null)
return;
@@ -250,7 +250,7 @@ namespace Content.Server.Nutrition.EntitySystems
if (EntityManager.TryGetComponent<MobStateComponent>(uid, out var mobState) && mobState.IsAlive())
return;
InteractionVerb verb = new()
AlternativeVerb verb = new()
{
Act = () =>
{