Options
All
  • Public
  • Public/Protected
  • All
Menu

Class PlayerShapeshiftEvent<RoomType>

Emitted when a player (who is a shapeshifter) shapeshifts into another player.

Type parameters

  • RoomType: Hostable

Hierarchy

Implements

Index

Properties

Static eventName

eventName: "player.shapeshift" = ...

Readonly doAnimation

doAnimation: boolean

Readonly duration

duration: number

eventName

eventName: "player.shapeshift" = ...

Readonly message

message: undefined | ProtectPlayerMessage

The message that this event originated from.

Readonly player

player: PlayerData<RoomType>

The player that this event is for.

reverted

reverted: boolean

Readonly room

room: RoomType

The room or client that the event came from.

Readonly target

target: PlayerData<RoomType>

Accessors

alteredDoAnimation

  • get alteredDoAnimation(): boolean

alteredTarget

  • get alteredTarget(): PlayerData<RoomType>

Constructors

constructor

  • new PlayerShapeshiftEvent<RoomType>(room: RoomType, player: PlayerData<RoomType>, message: undefined | ProtectPlayerMessage, target: PlayerData<RoomType>, duration: number, doAnimation: boolean): PlayerShapeshiftEvent<RoomType>

Methods

revert

  • revert(): void

setDoAnimation

  • setDoAnimation(doAnimation: boolean): void
  • Change whether or not an animation will show the player shapeshifting.

    Parameters

    • doAnimation: boolean

      Whether or not to do show an animation of the player shape shifting.

    Returns void

setTarget

  • setTarget(target: PlayerData<RoomType>): void
  • Change the player that the player will shapeshift into.

    Parameters

    • target: PlayerData<RoomType>

      The player to shapeshift into instead.

    Returns void

Generated using TypeDoc