Skip to content

Commit

Permalink
Fix verbs in mapping state (space-wizards#30631)
Browse files Browse the repository at this point in the history
  • Loading branch information
metalgearsloth authored and themias committed Aug 9, 2024
1 parent 8f7ed51 commit 0803d89
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions Content.Client/Verbs/UI/VerbMenuUIController.cs
Original file line number Diff line number Diff line change
Expand Up @@ -60,13 +60,18 @@ public void OnStateExited(GameplayState state)

public void OnStateEntered(MappingState state)
{
_context.OnContextKeyEvent += OnKeyBindDown;
_context.OnContextClosed += Close;
_verbSystem.OnVerbsResponse += HandleVerbsResponse;
}

public void OnStateExited(MappingState state)
{
_context.OnContextKeyEvent -= OnKeyBindDown;
_context.OnContextClosed -= Close;
if (_verbSystem != null)
_verbSystem.OnVerbsResponse -= HandleVerbsResponse;
Close();
}

/// <summary>
Expand Down

0 comments on commit 0803d89

Please sign in to comment.