Skip to content

Class endstone::PlayerShowActorEvent

ClassList > endstone > PlayerShowActorEvent

Called when a hidden actor is shown to a player. More...

  • #include <endstone/event/player/player_show_actor_event.h>

Inherits the following classes: endstone::PlayerEvent

Public Functions

Type Name
ENDSTONE_EVENT (PlayerShowActorEvent)
PlayerShowActorEvent (const NotNull< Player > & player, const NotNull< Actor > & actor)
const NotNull< Actor > & getActor () const
Gets the actor shown to the player.

Public Functions inherited from endstone::PlayerEvent

See endstone::PlayerEvent

Type Name
PlayerEvent (const NotNull< Player > & player)
const NotNull< Player > & getPlayer () const
Returns the player involved in this event.
~PlayerEvent () override

Public Functions inherited from endstone::Event

See endstone::Event

Type Name
Event (bool async=false)
Event (const Event &) = delete
Event (Event &&) = default
virtual std::string getEventName () const = 0
Gets a user-friendly identifier for this event.
bool isAsynchronous () const
Any custom event that should not by synchronized with other events must use the specific constructor.
Event & operator= (const Event &) = delete
Event & operator= (Event &&) = default
virtual ~Event () = default

Protected Attributes inherited from endstone::PlayerEvent

See endstone::PlayerEvent

Type Name
NotNull< Player > player_

Detailed Description

This event is only called when the actor's visibility status is actually changed. It is called regardless of whether the actor is within the player's tracking range.

See also: Player::showActor()

Public Functions Documentation

function ENDSTONE_EVENT

endstone::PlayerShowActorEvent::ENDSTONE_EVENT (
    PlayerShowActorEvent
) 

function PlayerShowActorEvent

inline endstone::PlayerShowActorEvent::PlayerShowActorEvent (
    const  NotNull < Player > & player,
    const  NotNull < Actor > & actor
) 

function getActor

Gets the actor shown to the player.

inline const  NotNull < Actor > & endstone::PlayerShowActorEvent::getActor () const

Returns:

the shown actor



The documentation for this class was generated from the following file include/endstone/event/player/player_show_actor_event.h