diff --git a/Game/Behaviours/MovementMouseBehaviour.cs b/Game/Behaviours/MovementMouseBehaviour.cs deleted file mode 100644 index afdb67e..0000000 --- a/Game/Behaviours/MovementMouseBehaviour.cs +++ /dev/null @@ -1,13 +0,0 @@ -using System; -using Microsoft.Xna.Framework.Input; -using Syntriax.Engine.Core; - -namespace Pong.Behaviours; - -public class MovementMouseBehaviour : BehaviourOverride -{ - protected override void OnUpdate() - { - GameObject.Transform.Position = Mouse.GetState().Position.ToVector2D().ApplyDisplayScale(); - } -} diff --git a/Game/Behaviours/PlayAreaBehaviour.cs b/Game/Behaviours/PlayAreaBehaviour.cs deleted file mode 100644 index 0b0765e..0000000 --- a/Game/Behaviours/PlayAreaBehaviour.cs +++ /dev/null @@ -1,26 +0,0 @@ -using System; -using Microsoft.Xna.Framework; -using Syntriax.Engine.Core; - -namespace Pong.Behaviours; - -public class PlayAreaBehaviour : BehaviourOverride -{ - public Action? OnPlayAreaChanged { get; set; } = null; - - private Vector2 _playArea = Vector2.Zero; - - public Vector2 PlayArea - { - get => _playArea; - set - { - if (_playArea == value) - return; - - _playArea = value; - OnPlayAreaChanged?.Invoke(this); - } - } - -} diff --git a/Game/Behaviours/RotatableBehaviour.cs b/Game/Behaviours/RotatableBehaviour.cs deleted file mode 100644 index 09185c4..0000000 --- a/Game/Behaviours/RotatableBehaviour.cs +++ /dev/null @@ -1,25 +0,0 @@ -using Syntriax.Engine.Core; - -namespace Pong.Behaviours; - -public class RotatableBehaviour : BehaviourOverride -{ - private KeyboardInputsBehaviour? inputs = null; - - protected override void OnFirstActiveFrame() - { - if (!BehaviourController.TryGetBehaviour(out inputs)) - inputs = BehaviourController.AddBehaviour(); - } - - protected override void OnUpdate() - { - if (inputs is null) - return; - - if (inputs.IsPressed(Microsoft.Xna.Framework.Input.Keys.NumPad4)) - Transform.Rotation += Time.Elapsed.Nanoseconds * 0.0025f; - if (inputs.IsPressed(Microsoft.Xna.Framework.Input.Keys.NumPad6)) - Transform.Rotation -= Time.Elapsed.Nanoseconds * 0.0025f; - } -}