2022-11-13 18:07:54 +03:00
|
|
|
using System;
|
2022-03-10 23:18:11 +03:00
|
|
|
using System.Collections.Generic;
|
2022-12-01 23:30:02 +03:00
|
|
|
using Syntriax.Modules.ToggleState;
|
2022-03-08 10:13:27 +03:00
|
|
|
|
2022-03-05 18:59:41 +03:00
|
|
|
namespace Syntriax.Modules.Movement
|
|
|
|
{
|
2022-03-08 10:13:27 +03:00
|
|
|
public interface IMovementController
|
|
|
|
{
|
2022-12-01 23:30:02 +03:00
|
|
|
/// <summary>
|
|
|
|
/// Member Toggle State
|
|
|
|
/// </summary>
|
|
|
|
IToggleState ToggleState { get; }
|
|
|
|
|
2022-11-15 13:08:37 +03:00
|
|
|
/// <summary>
|
|
|
|
/// Currently active <see cref="IMovement"/>
|
|
|
|
/// </summary>
|
2022-03-08 10:13:27 +03:00
|
|
|
IMovement ActiveMovement { get; }
|
2022-11-15 13:08:37 +03:00
|
|
|
|
|
|
|
/// <summary>
|
|
|
|
/// List of all <see cref="IMovement"/>s controlled by this controller, can be updated by calling <see cref="RecacheMovements"/> method
|
|
|
|
/// </summary>
|
2022-03-10 23:18:11 +03:00
|
|
|
List<IMovement> Movements { get; }
|
2022-03-13 20:59:45 +03:00
|
|
|
|
2022-11-15 13:08:37 +03:00
|
|
|
/// <summary>
|
|
|
|
/// Called when a <see cref="IMovement"/> is deactivated when another <see cref="IMovement"/> takes over it's place
|
|
|
|
/// </summary>
|
|
|
|
/// <value>Deactived <see cref="IMovement"/></value>
|
2022-11-13 18:07:54 +03:00
|
|
|
Action<IMovement> OnMovementDeactivated { get; set; }
|
2022-11-15 13:08:37 +03:00
|
|
|
|
|
|
|
/// <summary>
|
|
|
|
/// Called when a new <see cref="IMovement"/> takes over by the controller
|
|
|
|
/// </summary>
|
|
|
|
/// <value>Actived <see cref="IMovement"/></value>
|
2022-11-13 18:07:54 +03:00
|
|
|
Action<IMovement> OnMovementActivated { get; set; }
|
2022-03-08 21:28:52 +03:00
|
|
|
|
2022-12-01 23:30:02 +03:00
|
|
|
/// <summary>
|
|
|
|
/// Called when <see cref="Move"/> is called
|
|
|
|
/// </summary>
|
|
|
|
/// <value>The x, y, z values of <see cref="Move"/></value>
|
|
|
|
Action<float, float, float> OnMoveCalled { get; set; }
|
|
|
|
|
2022-11-15 13:08:37 +03:00
|
|
|
/// <summary>
|
|
|
|
/// Updates the <see cref="Movements"/> list
|
|
|
|
/// </summary>
|
2022-03-08 21:28:52 +03:00
|
|
|
void RecacheMovements();
|
2022-11-15 13:08:37 +03:00
|
|
|
|
|
|
|
/// <summary>
|
|
|
|
/// Apply the movement data that <see cref="IMovement"/>s will use
|
|
|
|
/// </summary>
|
|
|
|
void Move(float x = 0, float y = 0, float z = 0);
|
2022-03-08 10:13:27 +03:00
|
|
|
}
|
2022-03-05 18:59:41 +03:00
|
|
|
}
|