Package net.minestom.server.event.player
Class PlayerSkinInitEvent
java.lang.Object
net.minestom.server.event.player.PlayerSkinInitEvent
- All Implemented Interfaces:
Event,EntityEvent,PlayerEvent
Called at the player connection to initialize his skin.
-
Constructor Summary
ConstructorsConstructorDescriptionPlayerSkinInitEvent(@NotNull Player player, @Nullable PlayerSkin currentSkin) -
Method Summary
Modifier and TypeMethodDescription@NotNull PlayerGets the player.@Nullable PlayerSkingetSkin()Gets the spawning skin of the player.voidsetSkin(@Nullable PlayerSkin skin) Sets the spawning skin of the player.Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface net.minestom.server.event.trait.PlayerEvent
getEntity
-
Constructor Details
-
PlayerSkinInitEvent
public PlayerSkinInitEvent(@NotNull @NotNull Player player, @Nullable @Nullable PlayerSkin currentSkin)
-
-
Method Details
-
getSkin
Gets the spawning skin of the player.- Returns:
- the player skin, or null if not any
-
setSkin
Sets the spawning skin of the player.- Parameters:
skin- the new player skin
-
getPlayer
Description copied from interface:PlayerEventGets the player.- Specified by:
getPlayerin interfacePlayerEvent- Returns:
- the player
-