ZepetoPlayers
ZEPETO.Character.Controller.ZepetoPlayers
Manager class designed for controlling both ZEPETO player and ZEPETO character.
Hierarchy
↳
ZepetoPlayers
Constructors
constructor
• new ZepetoPlayers()
Inherited from
UnityEngine.MonoBehaviour.constructor
Properties
OnAddedLocalPlayer
• OnAddedLocalPlayer: UnityEvent
Event triggered when a local player instance is created.
OnAddedPlayer
• OnAddedPlayer: UnityEvent$1
<string
>
Event triggered when a player instance is created.
OnRemovedPlayer
• OnRemovedPlayer: UnityEvent$1
<string
>
Event triggered when a player instance is removed.
cameraData
• cameraData: CameraData
Configuration for a ZepetoCamera
.
characterData
• characterData: CharacterData
Configuration for a ZepetoCharacter
.
controllerData
• controllerData: ControllerData
Configuration for a ZepetoPlayerControl
.
floatingUIData
• floatingUIData: FloatingUIData
Character-related UI settings.
Accessors
LocalPlayer
• get
LocalPlayer(): LocalPlayer
Local player.
Returns
ZepetoCamera
• get
ZepetoCamera(): ZepetoCamera
ZEPETO Camera.
Returns
instance
• Static
get
instance(): ZepetoPlayers
Singleton instance of ZepetoPlayers
.
Returns
Methods
DeformDefaultCostume
▸ DeformDefaultCostume(): void
Removes the body deformation items worn by every player's character. Reverts to the default body shape and applies the default ZEPETO outfit.
Returns
void
DeformDefaultProperties
▸ DeformDefaultProperties(): void
Removes the body deformation items worn by every player's character.
Returns
void
GetPlayer
▸ GetPlayer($id
): ZepetoPlayer
Retrieves the player instance associated with the specified session ID.
Parameters
Name | Type | Description |
---|---|---|
$id | string | Session ID |
Returns
Player object associated with the specified ID.
If a player with the given ID does not exist, this will return null
.
GetPlayerWithUserId
▸ GetPlayerWithUserId($userId
): ZepetoPlayer
Retrieves the player instance associated with the specified user ID.
Parameters
Name | Type | Description |
---|---|---|
$userId | string | User ID |
Returns
Player object associated with the specified user ID.
HasPlayer
▸ HasPlayer($id
): boolean
Checks if a player instance associated with the specified session ID exists.
Parameters
Name | Type | Description |
---|---|---|
$id | string | Session ID |
Returns
boolean
RemovePlayer
▸ RemovePlayer($id
): void
Removes the player instance associated with the specified session ID.
Parameters
Name | Type | Description |
---|---|---|
$id | string | Session ID |
Returns
void
add_onInitialized
▸ Static
add_onInitialized($value
): void
Adds handler function for the event invoked when the ZepetoPlayers
is initialized.
Parameters
Name | Type |
---|---|
$value | Action |
Returns
void
remove_onInitialized
▸ Static
remove_onInitialized($value
): void
Removes handler function for the event invoked when the ZepetoPlayers
is initialized.
Parameters
Name | Type |
---|---|
$value | Action |
Returns
void