namespace Impostor.Api.Events.Player
{
/// <summary>
- /// Event that allows changing or canceling an upcoming player murder.
+ /// Event that allows changing or canceling an upcoming player murder.
/// </summary>
+ /// <remarks>
/// Note that this event only triggers if the Host of the Game did not disable server authority.
///
/// If you want to get an event after the murder took place, listen to <see cref="IPlayerMurderEvent"/>.
+ /// </remarks>
public interface IPlayerCheckMurderEvent : IPlayerEvent, IEventCancelable
{
/// <summary>
- /// Gets the player who got murdered.
+ /// Gets the player who will be murdered.
/// </summary>
IInnerPlayerControl Victim { get; }
/// <summary>
- /// Gets or sets the result of this event.
+ /// Gets or sets the result of this event.
/// </summary>
+ /// <remarks>
/// Its initial value is what would have happened in the normal game flow.
/// - If set to Succeeded, the Victim will die.
/// - If set to FailedProtected, the Victim will be protected with a shield animation and the attacker will have a cooldown set.
+ /// </remarks>
MurderResultFlags Result { get; set; }
}
}
namespace Impostor.Api.Events.Player
{
/// <summary>
- /// Event that is called when a player is killed by another player.
+ /// Event that is called when a player is killed by another player.
/// </summary>
+ /// <remarks>
/// This event works regardless of server authority is enabled or not.
///
/// If you want to cancel this kill, listen to <see cref="IPlayerCheckMurderEvent"/>
/// If you want to know about players that were voted out, listed to <see cref="IPlayerExileEvent"/>
+ /// </remarks>
public interface IPlayerMurderEvent : IPlayerEvent
{
/// <summary>
/// <summary>
/// Gets the result of the event.
/// </summary>
+ /// <remarks>
/// Note that if FailedError or FailedProtected is set, the kill did not take place
+ /// </remarks>
MurderResultFlags Result { get; }
}
}
int HostId { get; }
/// <summary>
- /// Gets a value indicating whether the Host of the game has requested host authority.
+ /// Gets a value indicating whether the Host of the game has requested host authority.
/// </summary>
+ /// <remarks>
/// Vanilla Among Us does not request this, but certain client-side mods will.
+ /// </remarks>
bool IsHostAuthoritive { get; }
IClientPlayer? GetClientPlayer(int clientId);