👩💻 Joueur
Les joueurs sont des entités qui représentent la personne derrière le clavier et la souris. Les joueurs apparaissent automatiquement lorsqu'ils se connectent au serveur.
🟥 Vous ne pouvez pas faire apparaître ou détruire des joueurs.
🎒 Exemples
-- Spawns and possess a Character when a Player joins the server
Player.Subscribe("Spawn", function(player)
local new_char = Character(Vector(), Rotator(), "nanos-world::SK_Male")
player:Possess(new_char)
end)
-- Destroys the Character when the Player leaves the server
Player.Subscribe("Destroy", function(player)
local character = player:GetControlledCharacter()
if (character) then
character:Destroy()
end
end)
🗿 Fonctions statiques
Inherited Entity Static Functions
Base Entityscripting-reference/classes/base-classes/entity
| Returns | Name | Description | |
|---|---|---|---|
| table of Base Entity | GetAll | Returns a table containing all Entities of the class this is called on | |
| Base Entity | GetByIndex | Returns a specific Entity of this class at an index | |
| integer | GetCount | Returns how many Entities of this class exist | |
| table of table | GetInheritedClasses | Gets a list of all directly inherited classes from this Class created with the Inheriting System | |
| iterator | GetPairs | Returns an iterator with all Entities of this class to be used with pairs() | |
| table or nil | GetParentClass | Gets the parent class if this Class was created with the Inheriting System | |
| table | Inherit | Inherits this class with the Inheriting System | |
| boolean | IsChildOf | Gets if this Class is child of another class if this Class was created with the Inheriting System | |
| function | Subscribe | Subscribes to an Event for all entities of this Class | |
| function | SubscribeRemote | Subscribes to a custom event called from server | |
Unsubscribe | Unsubscribes all callbacks from this Event in this Class within this Package, or only the callback passed |
| Returns | Name | Description | |
|---|---|---|---|
| Player or nil | GetBySteamID | Récupérer un joueur via son Steam ID |
Slow

GetBySteamID
Récupérer un joueur via son Steam ID
local player = Player.GetBySteamID(steam_id)
Parameters
| Type | Parameter | Default | Description |
|---|---|---|---|
| string | steam_id | Required parameter | The Steam ID (SteamID64) to look for |
🦠 Fonctions
Inherited Entity Functions
Base Entityscripting-reference/classes/base-classes/entity
| Returns | Name | Description | |
|---|---|---|---|
BroadcastRemoteEvent | Calls a custom remote event directly on this entity to all Players | ||
BroadcastRemoteInRadiusEvent | Appelle un événement distant personnalisé directement sur cette entité pour tous les Joueurs dans un rayon donné | ||
CallRemoteEvent | Calls a custom remote event directly on this entity to a specific Player | ||
CallRemoteEvent | Calls a custom remote event directly on this entity | ||
CallRemotePlayersEvent | Appelle un événement distant personnalisé directement sur cette entité pour une liste de Joueurs | ||
Destroy | Destroys this Entity | ||
FinishSpawn | Finish the spawning process and send the entity to clients if it was spawned with a deferred spawn_mode | ||
| table of string | GetAllValuesKeys | Gets a list of all values keys | |
| table | GetClass | Gets the class of this entity | |
| integer | GetID | Gets the universal network ID of this Entity (same on both client and server) | |
| any | GetValue | Gets a Value stored on this Entity at the given key | |
| boolean | HasAuthority | Gets if the local context has authority over this Entity (true if spawned by the client, false if spawned by the server) | |
| boolean | IsA | Recursively checks if this entity is inherited from a Class | |
| boolean | IsBeingDestroyed | Returns true if this Entity is being destroyed | |
| boolean | IsSpawned | Gets if this Entity finished spawning | |
| boolean | IsValid | Returns true if this Entity is valid (i.e. wasn't destroyed and points to a valid Entity) | |
SetSpawnMode | Overrides when this Entity finishes spawning, from the Constructor of an Inherited Class | ||
SetValue | Sets a Value in this Entity | ||
| function | Subscribe | Subscribes to an Event on this specific entity | |
| function | SubscribeRemote | Subscribes to a custom event called from server on this specific entity | |
Unsubscribe | Unsubscribes all callbacks from this Event in this Entity within this Package, or only the callback passed |
| Returns | Name | Description | |
|---|---|---|---|
AttachCameraTo | Attaches the Player's Camera to an Actor | ||
Ban | Bannit le joueur du serveur | ||
Connect | Redirige le joueur vers un autre serveur | ||
| string | GetAccountIconURL | Renvoie une URL utilisable dans l'interface Web (WebUI) et les widgets pour afficher l'avatar Steam du joueur (64x64) | |
| string | GetAccountID | Gets the Player's nanos world account ID | |
| string | GetAccountName | Gets the Player's nanos world account name | |
| float | GetCameraArmLength | Gets the Player's camera arm (spring arm) length | |
| Vector | GetCameraLocation | Gets the location of the Player's camera | |
| Rotator | GetCameraRotation | Gets the rotation of the Player's camera | |
| Base Pawn or nil | GetControlledCharacter | Gets the Pawn (Character) this Player is currently possessing | |
| integer | GetDimension | Récupère la dimension du joueur | |
| string | GetIP | Gets the Player's IP address | |
| string | GetName | Gets the Player's name | |
| integer | GetPing | Gets the Player's ping | |
| string | GetSteamID | Gets the Player's Steam ID | |
| table of integer | GetVOIPListeningChannels | Renvoie la liste des canaux VOIP écoutés par le joueur | |
| table of integer | GetVOIPSpeakingChannels | Renvoie la liste des canaux VOIP dans lesquels le joueur parle actuellement | |
| boolean | IsHost | Gets if this Player is the host of a P2P (listen) server | |
| boolean | IsLocalPlayer | Gets if this Player is the local Player (the one running this client) | |
| boolean | IsVOIPMuted | Renvoie si la VOIP est coupée pour ce joueur | |
Kick | Expulse le joueur du serveur | ||
Possess | Makes this Player possess and control a Pawn (Character) | ||
ResetCamera | Réinitialise la caméra à son état par défaut (arrête le mode spectateur et la détache) | ||
RotateCameraTo | Déplace de manière fluide la rotation de la caméra du joueur | ||
SetCameraArmLength | Sets the Player's Camera Arm Length (Spring Arm length) | ||
SetCameraFOV | Sets the Player's Camera FOV (if not possessing a Character) | ||
SetCameraLocation | Sets the Player's Camera Location (only works if not possessing any Character) | ||
SetCameraRotation | Définir la rotation de la caméra du joueur | ||
SetCameraSocketOffset | Sets the Player's Camera Socket Offset (Spring Arm Offset) | ||
SetCameraSpeedSettings | Sets the Player's Camera Speed Settings (if not possessing a Character) | ||
SetDimension | Définit la dimension du joueur | ||
SetDistanceOptimizationMultiplier | Sets the multiplier for how much this Player's is affected by distance optimization from other actors | ||
SetManualCameraFade | Active le fondu de la caméra à l'opacité donnée | ||
SetName | Définir le nom du joueur | ||
SetVOIPGlobalAllChannelsSetting | Définit les paramètres VOIP pour tous les canaux globaux | ||
SetVOIPGlobalChannelSetting | Définit le paramètre VOIP pour un canal global spécifique | ||
SetVOIPGlobalHighPassFilter | Définit la fréquence de seuil globale de filtre à forte passe VOIP | ||
SetVOIPGlobalLowPassFilter | Définit la fréquence de coupure globale du filtre low-pass (passe-bas) de la VOIP | ||
SetVOIPGlobalVolume | Définit le volume global de la VOIP (concerne uniquement les canaux globaux) | ||
SetVOIPLocalMaxDistance | Définit la distance maximale de la VOIP locale (proximité). Affecte aussi les performances réseau | ||
SetVOIPLocalSetting | Définit le paramètre VOIP pour le canal local/de proximité | ||
SetVOIPLocalVolume | Définit le volume d'entrée/sortie de la VOIP de proximité (concerne uniquement le canal de proximité) | ||
SetVOIPMuted | Coupe ou réactive la VOIP pour ce joueur | ||
Spectate | Makes this Player spectate another Player | ||
StartCameraFade | Does a camera fade to/from a solid color | ||
StopCameraFade | Stops camera fading. | ||
TranslateCameraTo | Smoothly moves the Player's Camera Location (only works if not possessing any Character) | ||
UnPossess | Libérer le joueur du personnage |
Optimal

AttachCameraTo
Attaches the Player's Camera to an Actor
my_player:AttachCameraTo(actor, socket_offset?, blend_speed?)
Parameters
| Type | Parameter | Default | Description |
|---|---|---|---|
| Base Actor | actor | Required parameter | The Actor to attach the camera to |
| Vector | socket_offset? | Vector(0, 0, 0) | Offset of the camera relative to the Actor |
| float | blend_speed? | 0.0 | Speed of the camera blend, 0 to snap immediately |
Slow

Ban
Bannit le joueur du serveur
my_player:Ban(reason)
Parameters
| Type | Parameter | Default | Description |
|---|---|---|---|
| string | reason | Required parameter | The reason shown to the Player |
Optimal

Connect
Redirige le joueur vers un autre serveur
my_player:Connect(ip, password?)
Parameters
| Type | Parameter | Default | Description |
|---|---|---|---|
| string | ip | Required parameter | The server address to connect to, in the format IP:PORT |
| string | password? | | Mot de passe du serveur |
Optimal

GetAccountIconURL
Renvoie une URL utilisable dans l'interface Web (WebUI) et les widgets pour afficher l'avatar Steam du joueur (64x64)
local account_icon_url = my_player:GetAccountIconURL()
Returns
| Type | Description |
|---|---|
| string | URL of the Steam avatar image |
Optimal

GetAccountID
Gets the Player's nanos world account ID
local account_id = my_player:GetAccountID()
Returns
| Type | Description |
|---|---|
| string | The nanos world account ID |
Optimal

GetAccountName
Gets the Player's nanos world account name
local account_name = my_player:GetAccountName()
Returns
| Type | Description |
|---|---|
| string | The account name |
Optimal

GetCameraArmLength
Gets the Player's camera arm (spring arm) length
local length = my_player:GetCameraArmLength(return_base?)
Parameters
| Type | Parameter | Default | Description |
|---|---|---|---|
| boolean | return_base? | false | Indique s'il faut renvoyer la valeur actuelle (false) ou de base (true). La valeur de base correspond à celle définie par SetCameraArmLength(). Utilisez la valeur de base si vous souhaitez obtenir la valeur d'origine définie par SetCameraArmLength() et non la valeur actuelle (interpolée). |
Returns
| Type | Description |
|---|---|
| float | The camera arm length, in units |
See also SetCameraArmLength.
Optimal

GetCameraLocation
Gets the location of the Player's camera
local location = my_player:GetCameraLocation()
Returns
| Type | Description |
|---|---|
| Vector | The camera location |
See also SetCameraLocation.
Optimal

GetCameraRotation
Gets the rotation of the Player's camera
local rotation = my_player:GetCameraRotation()
Returns
| Type | Description |
|---|---|
| Rotator | The camera rotation |
See also SetCameraRotation.
Optimal

GetControlledCharacter
Gets the Pawn (Character) this Player is currently possessing
local controlled_character = my_player:GetControlledCharacter()
Optimal

GetDimension
Récupère la dimension du joueur
local dimension = my_player:GetDimension()
Returns
| Type | Description |
|---|---|
| integer | This Player's dimension |
See also SetDimension, DimensionChange.
Optimal

GetIP
Gets the Player's IP address
local ip = my_player:GetIP()
Returns
| Type | Description |
|---|---|
| string | The IP address |
Optimal

GetName
Gets the Player's name
local player_name = my_player:GetName()
Returns
| Type | Description |
|---|---|
| string | The Player's name |
See also SetName.
Optimal

GetPing
Gets the Player's ping
local ping = my_player:GetPing()
Returns
| Type | Description |
|---|---|
| integer | The ping, in milliseconds |
Optimal

GetSteamID
Gets the Player's Steam ID
local steam_id = my_player:GetSteamID()
Returns
| Type | Description |
|---|---|
| string | The Steam ID (SteamID64) |
Moderate

GetVOIPListeningChannels
Renvoie la liste des canaux VOIP écoutés par le joueur
local ret = my_player:GetVOIPListeningChannels()
Moderate

GetVOIPSpeakingChannels
Renvoie la liste des canaux VOIP dans lesquels le joueur parle actuellement
local ret = my_player:GetVOIPSpeakingChannels()
Optimal

IsHost
Gets if this Player is the host of a P2P (listen) server
local is_host = my_player:IsHost()
Returns
| Type | Description |
|---|---|
| boolean | Whether this Player is the host |
Optimal

IsLocalPlayer
Gets if this Player is the local Player (the one running this client)
local is_local_player = my_player:IsLocalPlayer()
Returns
| Type | Description |
|---|---|
| boolean | Whether this is the local Player |
Optimal

IsVOIPMuted
Renvoie si la VOIP est coupée pour ce joueur
local ret = my_player:IsVOIPMuted()
Returns
| Type | Description |
|---|---|
| boolean | Whether VOIP is muted for this player |
See also SetVOIPMuted.
Moderate

Kick
Expulse le joueur du serveur
my_player:Kick(reason)
Parameters
| Type | Parameter | Default | Description |
|---|---|---|---|
| string | reason | Required parameter | The reason shown to the Player |
Moderate

Possess
Makes this Player possess and control a Pawn (Character)
my_player:Possess(new_pawn, blend_time?, exp?)
Parameters
| Type | Parameter | Default | Description |
|---|---|---|---|
| Base Pawn | new_pawn | Required parameter | The Pawn to possess |
| float | blend_time? | 0 | Seconds to smoothly blend the camera to the new Pawn |
| float | exp? | 0 | Exponent used to smooth the blend, use 0 for linear |
Optimal

ResetCamera
Réinitialise la caméra à son état par défaut (arrête le mode spectateur et la détache)
my_player:ResetCamera()
Optimal

RotateCameraTo
Déplace de manière fluide la rotation de la caméra du joueur
my_player:RotateCameraTo(rotation, time, exp?)
Parameters
| Type | Parameter | Default | Description |
|---|---|---|---|
| Rotator | rotation | Required parameter | The target camera rotation |
| float | time | Required parameter | Seconds to reach the target |
| float | exp? | 0 | Exponential used to smooth interp, use 0 for linear movement |
Optimal

SetCameraArmLength
Sets the Player's Camera Arm Length (Spring Arm length)
my_player:SetCameraArmLength(length, force?)
Parameters
| Type | Parameter | Default | Description |
|---|---|---|---|
| float | length | Required parameter | Length of the camera spring arm, in units |
| boolean | force? | false | Whether to bypass interpolation and set the target to its value directly |
See also GetCameraArmLength.
Optimal

SetCameraFOV
Sets the Player's Camera FOV (if not possessing a Character)
my_player:SetCameraFOV(fov?)
Parameters
| Type | Parameter | Default | Description |
|---|---|---|---|
| float | fov? | 90 | La valeur doit être comprise entre 5 et 170. Entrez une valeur vide pour rétablir la valeur par défaut |
Optimal

SetCameraLocation
Sets the Player's Camera Location (only works if not possessing any Character)
my_player:SetCameraLocation(location)
Parameters
| Type | Parameter | Default | Description |
|---|---|---|---|
| Vector | location | Required parameter | The new Player's Camera Location |
See also GetCameraLocation.
Optimal

SetCameraRotation
Définir la rotation de la caméra du joueur
my_player:SetCameraRotation(rotation)
Parameters
| Type | Parameter | Default | Description |
|---|---|---|---|
| Rotator | rotation | Required parameter | The new Player's Camera Rotation |
See also GetCameraRotation.
Optimal

SetCameraSocketOffset
Sets the Player's Camera Socket Offset (Spring Arm Offset)
my_player:SetCameraSocketOffset(socket_offset)
Parameters
| Type | Parameter | Default | Description |
|---|---|---|---|
| Vector | socket_offset | Required parameter | The new Player's Camera Socket Offset |
Optimal

SetCameraSpeedSettings
Sets the Player's Camera Speed Settings (if not possessing a Character)
my_player:SetCameraSpeedSettings(max_speed?, acceleration?, deceleration?, turning_boost?)
Parameters
| Type | Parameter | Default | Description |
|---|---|---|---|
| float | max_speed? | 1200 | Maximum velocity magnitude allowed |
| float | acceleration? | 4000 | Acceleration applied by input (rate of change of velocity) |
| float | deceleration? | 4000 | Deceleration applied when there is no input (rate of change of velocity) |
| float | turning_boost? | 8 | Setting affecting extra force applied when changing direction, making turns have less drift and become more responsive. Velocity magnitude is not allowed to increase, that only happens due to normal acceleration. It may decrease with large direction changes. Larger values apply extra force to reach the target direction more quickly, while a zero value disables any extra turn force. |
Slow

SetDimension
Définit la dimension du joueur
my_player:SetDimension(dimension)
Parameters
| Type | Parameter | Default | Description |
|---|---|---|---|
| integer | dimension | Required parameter | The new dimension |
See also GetDimension, DimensionChange.
Optimal

SetDistanceOptimizationMultiplier
Sets the multiplier for how much this Player's is affected by distance optimization from other actors.
A value of 0 disables optimization. Values under 1 decrease the effect, while values over 1 increase it
my_player:SetDistanceOptimizationMultiplier(multiplier)
Parameters
| Type | Parameter | Default | Description |
|---|---|---|---|
| float | multiplier | Required parameter | The new multiplier for how much this Player's is affected by distance optimization from other actors |
Optimal

SetManualCameraFade
Turns on camera fading at the given opacity. Does not auto-animate, allowing user to animate themselves. Call StopCameraFade to turn fading back off.
my_player:SetManualCameraFade(in_fade_amount, color, in_fade_audio)
Parameters
| Type | Parameter | Default | Description |
|---|---|---|---|
| float | in_fade_amount | Required parameter | Range [0..1], where 0 is fully transparent and 1 is fully opaque solid color. |
| Color | color | Required parameter | The color to use |
| boolean | in_fade_audio | Required parameter | Whether to fade the audio as well |
Optimal

SetName
Définir le nom du joueur
my_player:SetName(player_name)
Parameters
| Type | Parameter | Default | Description |
|---|---|---|---|
| string | player_name | Required parameter | The new player's name |
See also GetName.
Optimal

SetVOIPGlobalAllChannelsSetting
Définit les paramètres VOIP pour tous les canaux globaux
my_player:SetVOIPGlobalAllChannelsSetting(setting)
Parameters
| Type | Parameter | Default | Description |
|---|---|---|---|
| VOIPSetting | setting | Required parameter | The new VOIP setting for all global channels |
See also SetVOIPGlobalChannelSetting, GetVOIPListeningChannels, GetVOIPSpeakingChannels, VOIPGlobalChannelSettingChange.
Optimal

SetVOIPGlobalChannelSetting
Définit le paramètre VOIP pour un canal global spécifique
my_player:SetVOIPGlobalChannelSetting(channel, setting)
Parameters
| Type | Parameter | Default | Description |
|---|---|---|---|
| integer | channel | Required parameter | Channel number, from 1 to 63 |
| VOIPSetting | setting | Required parameter | Whether this Player listens, speaks, both or none on this channel |
See also SetVOIPGlobalAllChannelsSetting, GetVOIPListeningChannels, GetVOIPSpeakingChannels, VOIPGlobalChannelSettingChange.
Optimal

SetVOIPGlobalHighPassFilter
Définit la fréquence de coupure globale du filtre high-pass (passe-haut) de la VOIP. Mettre à 0 pour désactiver
my_player:SetVOIPGlobalHighPassFilter(threshold)
Parameters
| Type | Parameter | Default | Description |
|---|---|---|---|
| integer | threshold | Required parameter | The new global VOIP high-pass filter threshold frequency |
See also SetVOIPGlobalLowPassFilter.
Optimal

SetVOIPGlobalLowPassFilter
Définit la fréquence de coupure globale du filtre low-pass (passe-bas) de la VOIP. Mettre à 0 pour désactiver
my_player:SetVOIPGlobalLowPassFilter(threshold)
Parameters
| Type | Parameter | Default | Description |
|---|---|---|---|
| integer | threshold | Required parameter | The new global VOIP low-pass filter threshold frequency |
See also SetVOIPGlobalHighPassFilter.
Optimal

SetVOIPGlobalVolume
Définit le volume global de la VOIP (concerne uniquement les canaux globaux)
my_player:SetVOIPGlobalVolume(volume)
Parameters
| Type | Parameter | Default | Description |
|---|---|---|---|
| float | volume | Required parameter | The new global VOIP volume. It only affects the global channels |
Optimal

SetVOIPLocalMaxDistance
Définit la distance maximale de la VOIP locale (proximité). Affecte aussi les performances réseau
my_player:SetVOIPLocalMaxDistance(max_distance)
Parameters
| Type | Parameter | Default | Description |
|---|---|---|---|
| integer | max_distance | Required parameter | Distance d'atténuation. Valeur par défaut : 3600 |
See also SetVOIPLocalSetting, SetVOIPLocalVolume.
Optimal

SetVOIPLocalSetting
Définit le paramètre VOIP pour le canal local/de proximité
my_player:SetVOIPLocalSetting(setting)
Parameters
| Type | Parameter | Default | Description |
|---|---|---|---|
| VOIPSetting | setting | Required parameter | The new VOIP setting for the local/proximity |
See also SetVOIPLocalMaxDistance, SetVOIPLocalVolume, VOIPLocalSettingChange.
Optimal

SetVOIPLocalVolume
Définit le volume d'entrée/sortie de la VOIP de proximité (concerne uniquement le canal de proximité)
my_player:SetVOIPLocalVolume(volume)
Parameters
| Type | Parameter | Default | Description |
|---|---|---|---|
| float | volume | Required parameter | The new local/proximity VOIP input/output volume. It only affects the local/proximity channel |
See also SetVOIPLocalSetting, SetVOIPLocalMaxDistance, VOIPLocalSettingChange.
Optimal

SetVOIPMuted
Mutes or unmutes VOIP for this player.
On server side, the player is muted for everyone. On client side, it is a local mute only.
my_player:SetVOIPMuted(is_muted)
Parameters
| Type | Parameter | Default | Description |
|---|---|---|---|
| boolean | is_muted | Required parameter | Whether VOIP is muted |
See also IsVOIPMuted.
Optimal

Spectate
Makes this Player spectate another Player
my_player:Spectate(player, blend_speed?)
Parameters
| Type | Parameter | Default | Description |
|---|---|---|---|
| Player | player | Required parameter | The Player |
| float | blend_speed? | 0 | Speed of the camera blend, 0 to snap immediately |
Moderate

StartCameraFade
Does a camera fade to/from a solid color. Animates automatically
my_player:StartCameraFade(from_alpha, to_alpha, duration, to_color, should_fade_audio?, hold_when_finished?)
Parameters
| Type | Parameter | Default | Description |
|---|---|---|---|
| float | from_alpha | Required parameter | Alpha at which to begin the fade. Range [0..1], where 0 is fully transparent and 1 is fully opaque solid color. |
| float | to_alpha | Required parameter | Alpha at which to finish the fade. |
| float | duration | Required parameter | How long the fade should take, in seconds. |
| Color | to_color | Required parameter | Color to fade to/from. |
| boolean | should_fade_audio? | false | True to fade audio volume along with the alpha of the solid color. |
| boolean | hold_when_finished? | false | True for fade to hold at the ToAlpha until explicitly stopped (e.g. with StopCameraFade) |
Optimal

StopCameraFade
Stops camera fading.
my_player:StopCameraFade()
Optimal

TranslateCameraTo
Smoothly moves the Player's Camera Location (only works if not possessing any Character)
my_player:TranslateCameraTo(location, time, exp?)
Parameters
| Type | Parameter | Default | Description |
|---|---|---|---|
| Vector | location | Required parameter | The target camera location |
| float | time | Required parameter | Seconds to reach the target |
| float | exp? | 0 | Exponential used to smooth interp, use 0 for linear movement |
Optimal

UnPossess
Libérer le joueur du personnage
my_player:UnPossess()
🚀 Événements
Inherited Entity Events
Base Entityscripting-reference/classes/base-classes/entity
| Name | Description | |
|---|---|---|
ClassRegister | Triggered when a new Class is registered with the Inheriting System | |
Destroy | Triggered when an Entity is destroyed | |
Spawn | Triggered when an Entity is spawned/created | |
ValueChange | Triggered when an Entity has a value changed with :SetValue() |
| Name | Description | |
|---|---|---|
DimensionChange | Triggered when a Player changes its dimension | |
Possess | Triggered when Player starts controlling a Pawn (Character) | |
Ready | Triggered when Player is ready (the client fully joined, loaded the map and all entities and is ready to play) | |
UnPossess | A Pawn (Character) was unpossessed from the Player | |
VOIP | Déclenché lorsqu'un joueur commence ou arrête d'utiliser la VOIP | |
VOIPGlobalChannelSettingChange | Déclenché lorsque le paramètre d'un canal VOIP global change pour ce joueur | |
VOIPLocalSettingChange | Déclenché lorsque le paramètre de la VOIP locale change pour ce joueur |

DimensionChange
Triggered when a Player changes its dimension
Player.Subscribe("DimensionChange", function(self, old_dimension, new_dimension)
-- DimensionChange was called
end)
Arguments
| Type | Argument | Description |
|---|---|---|
| Player | self | The Player that triggered the event |
| integer | old_dimension | The previous dimension |
| integer | new_dimension | The new dimension |
See also SetDimension, GetDimension.

Possess
Triggered when Player starts controlling a Pawn (Character)
Player.Subscribe("Possess", function(self, pawn)
-- Possess was called
end)
Arguments
| Type | Argument | Description |
|---|---|---|
| Player | self | The Player that triggered the event |
| Base Pawn | pawn | The Pawn being possessed |
See also GetControlledCharacter.

Ready
Triggered when Player is ready (the client fully joined, loaded the map and all entities and is ready to play)
Player.Subscribe("Ready", function(self)
-- Ready was called
end)
Arguments
| Type | Argument | Description |
|---|---|---|
| Player | self | The Player that triggered the event |

UnPossess
A Pawn (Character) was unpossessed from the Player
Player.Subscribe("UnPossess", function(self, pawn)
-- UnPossess was called
end)
Arguments
| Type | Argument | Description |
|---|---|---|
| Player | self | The Player that triggered the event |
| Base Pawn | pawn | The Pawn being unpossessed |
See also GetControlledCharacter.

VOIP
Déclenché lorsqu'un joueur commence ou arrête d'utiliser la VOIP
Si is_talking est true, renvoyer false pour bloquer ce flux vocal (bloqué pour tous sur le serveur, uniquement en local sur le client)
Player.Subscribe("VOIP", function(self, is_talking)
-- VOIP was called
return true
end)
Arguments
| Type | Argument | Description |
|---|---|---|
| Player | self | The Player that triggered the event |
| boolean | is_talking | Whether the Player started (true) or stopped (false) talking |

VOIPGlobalChannelSettingChange
Déclenché lorsque le paramètre d'un canal VOIP global change pour ce joueur
Player.Subscribe("VOIPGlobalChannelSettingChange", function(self, channel, old_setting, new_setting)
-- VOIPGlobalChannelSettingChange was called
end)
Arguments
| Type | Argument | Description |
|---|---|---|
| Player | self | The Player that triggered the event |
| integer | channel | The channel that changed (1-63) |
| VOIPSetting | old_setting | The previous setting |
| VOIPSetting | new_setting | The new setting |
See also SetVOIPGlobalChannelSetting, SetVOIPGlobalAllChannelsSetting.

VOIPLocalSettingChange
Déclenché lorsque le paramètre de la VOIP locale change pour ce joueur
Player.Subscribe("VOIPLocalSettingChange", function(self, old_setting, new_setting)
-- VOIPLocalSettingChange was called
end)
Arguments
| Type | Argument | Description |
|---|---|---|
| Player | self | The Player that triggered the event |
| VOIPSetting | old_setting | The previous setting |
| VOIPSetting | new_setting | The new setting |
See also SetVOIPLocalSetting.


