This commit is contained in:
2025-05-30 16:05:49 +03:00
committed by Syntriax
parent 846aa75dd5
commit b5140a94de
57 changed files with 437 additions and 462 deletions

View File

@@ -10,12 +10,12 @@ public interface IBehaviourController : IEntity, IHasUniverseObject
/// <summary>
/// Event triggered when a <see cref="IBehaviour"/> is added to the <see cref="IBehaviourController"/>.
/// </summary>
Event<IBehaviourController, IBehaviour> OnBehaviourAdded { get; }
Event<IBehaviourController, BehaviourAddedArguments> OnBehaviourAdded { get; }
/// <summary>
/// Event triggered when a <see cref="IBehaviour"/> is removed from the <see cref="IBehaviourController"/>.
/// </summary>
Event<IBehaviourController, IBehaviour> OnBehaviourRemoved { get; }
Event<IBehaviourController, BehaviourRemovedArguments> OnBehaviourRemoved { get; }
/// <summary>
/// Amount of <see cref="IBehaviour"/> collected.
@@ -78,6 +78,6 @@ public interface IBehaviourController : IEntity, IHasUniverseObject
/// <param name="behaviour">The <see cref="IBehaviour"/> to remove.</param>
void RemoveBehaviour<T>(T behaviour) where T : class, IBehaviour;
delegate void BehaviourAddedEventHandler(IBehaviourController sender, IBehaviour behaviourAdded);
delegate void BehaviourRemovedEventHandler(IBehaviourController sender, IBehaviour behaviourRemoved);
readonly record struct BehaviourAddedArguments(IBehaviour BehaviourAdded);
readonly record struct BehaviourRemovedArguments(IBehaviour BehaviourRemoved);
}