public override void HandleInput(MouseButtonEventArgs buttonEventArgs) { if (Mouse.IsButtonPressed(Mouse.Button.Left)) { if (_menuUI.Contains(buttonEventArgs.X, buttonEventArgs.Y)) { _menuUI.OnClick(buttonEventArgs.X, buttonEventArgs.Y); } } }
public override void Update(Vector2i mousePosition) { if (_gameUI.Contains(mousePosition.X, mousePosition.Y)) { _gameUI.OnHover(mousePosition.X, mousePosition.Y); } else { _gameUI.OnIdle(mousePosition.X, mousePosition.Y); } }