Syntriax.Engine/Engine.Core/Abstract/IEntity.cs

21 lines
589 B
C#
Raw Permalink Normal View History

2024-02-02 12:11:51 +03:00
using System;
2023-11-23 22:07:49 +03:00
namespace Syntriax.Engine.Core.Abstract;
2024-02-01 12:14:53 +03:00
/// <summary>
/// Represents a basic entity in the engine.
/// </summary>
public interface IEntity : IInitialize, IAssignableStateEnable
2023-11-23 22:07:49 +03:00
{
2024-02-02 12:11:51 +03:00
/// <summary>
/// Event triggered when the <see cref="Id"/> of the <see cref="IEntity"/> changes.
/// The string action parameter is the previous <see cref="Id"/> of the <see cref="IEntity"/>.
/// </summary>
Action<IEntity, string>? OnIdChanged { get; set; }
/// <summary>
/// The ID of the <see cref="IEntity"/>.
/// </summary>
string Id { get; set; }
2023-11-23 22:07:49 +03:00
}