skeldjs
    Preparing search index...

    Class PlayerProtectEvent<RoomType>

    Emitted when a player (who is a guardian angel) protects another player.

    Due to technical limitations, this event cannot be reverted without advanced "breaking game", therefore it is out of scope of a single .revert() function. However, see PlayerCheckProtectEvent to see about canceling a protection before it happens if you are the host.

    Type Parameters

    Hierarchy (View Summary)

    Implements

    Index

    Constructors

    Properties

    duration: number

    The duration, in seconds, for how long the player is protected for.

    eventName: "player.protect" = ...
    message: undefined | ProtectPlayerMessage

    The message that this event originated from.

    player: Player<RoomType>

    The player that this event is for.

    room: RoomType

    The room or client that the event came from.

    target: Player<RoomType>

    The player that was protected.

    eventName: "player.protect" = ...