Properties
bool
[Hidden]
|
Describes the current game’s permission levels regarding custom avatar animations from the website |
bool
|
Sets whether the character will automatically jump when hitting an obstacle on a mobile device. |
float
|
The maximum distance the player’s default camera is allowed to zoom out in studs. |
float
|
The minimum distance in studs the player’s default camera is allowed to zoom in. |
CameraMode
|
Changes the default camera’s mode to either first or third person. |
float
|
Determines the starting value of |
float
|
Determines the starting value of |
float
|
Determines the starting value of |
bool
|
Determines the starting state of |
float
|
Determines the starting value of |
DevCameraOcclusionMode
|
Sets how the default camera handles objects between the camera and the player. |
DevComputerCameraMovementMode
|
Lets developer overwrite the default camera mode for each player if the player is on a computer. |
DevComputerMovementMode
|
Lets developer overwrite the player’s movement mode if the player is on a computer. |
DevTouchCameraMovementMode
|
Lets developer overwrite the default camera movement mode for each player if the player is on a mobile device. |
DevTouchMovementMode
|
Lets developer overwrite the player’s movement mode if the player is on a touch device. |
bool
|
Determines if a player can toggle mouse lock by default. |
int64
[Hidden]
[NotReplicated]
|
int64
[Hidden]
[NotReplicated]
|
int64
[Hidden]
[NotReplicated]
|
int64
[Hidden]
[NotReplicated]
|
int64
[Hidden]
[NotReplicated]
|
int64
[Hidden]
[NotReplicated]
|
int64
[Hidden]
[NotReplicated]
|
int64
[Hidden]
[NotReplicated]
|
int64
[Hidden]
[NotReplicated]
|
int64
[Hidden]
[NotReplicated]
|
GameAvatarType
[Hidden]
[NotReplicated]
|
R15CollisionType
[Hidden]
[NotReplicated]
|
NumberRange
[Hidden]
[NotReplicated]
|
NumberRange
[Hidden]
[NotReplicated]
|
NumberRange
[Hidden]
[NotReplicated]
|
NumberRange
[Hidden]
[NotReplicated]
|
NumberRange
[Hidden]
[NotReplicated]
|
float
|
Sets the distance at which this player will see other Humanoid’s health bars. If set to 0, the health bars will not be displayed. |
bool
|
Whether or not the appearance of a player’s character should be loaded. |
LoadCharacterLayeredClothing
[NotReplicated]
[NotScriptable]
|
Determines if the experience loads Layered Clothing accessories. |
float
|
Sets the distance at which this player will see other Humanoid’s names. If set to 0, names are hidden. |
bool
|
Determines if user-owned emotes are loaded when loading avatars. |
bool
|
Determines if an |
string
[ReadOnly]
[NotReplicated]
|
A read-only string representing the class this |
int
[Hidden]
[ReadOnly]
[NotReplicated]
[Deprecated]
|
The cost of saving the instance using data persistence. |
string
|
A non-unique identifier of the |
Instance
[NotReplicated]
|
Determines the hierarchical parent of the |
bool
[Hidden]
|
A deprecated property that used to protect |
int64
[Hidden]
[NotReplicated]
|
bool
[Hidden]
[NotReplicated]
[Deprecated]
|
string
[ReadOnly]
[NotReplicated]
[Deprecated]
|
Functions
void
|
void
|
This function destroys all of an |
Instance
|
Create a copy of an object and all its descendants, ignoring objects that are not |
void
|
Sets the |
Instance
|
Returns the first ancestor of the |
Instance
|
Returns the first ancestor of the |
Instance
|
Returns the first ancestor of the |
Instance
|
Returns the first child of the |
Instance
|
Returns the first child of the |
Instance
|
Returns the first child of the |
Instance
|
Returns the first descendant found with the given |
Actor
|
Returns the Actor associated with the Instance, usually the first Actor ancestor |
Variant
|
Returns the attribute which has been assigned to the given name |
RBXScriptSignal
|
Returns an event that fires when the given attribute changes |
Dictionary
|
Returns a dictionary of string → variant pairs for each of the |
Objects
|
Returns an array containing all of the |
string
[NotBrowsable]
|
Returns a coded string of the |
Array
[CustomLuaState]
|
Returns an array containing all of the descendants of the instance |
string
|
Returns a string describing the |
RBXScriptSignal
|
Get an event that fires when a given property of an object changes. |
bool
[CustomLuaState]
|
Returns true if an |
bool
|
Returns true if an |
bool
|
Returns true if an |
void
[Deprecated]
|
Sets the object’s Parent to nil, and does the same for all its descendants. |
void
|
Sets the attribute with the given name to the given value |
Instance
[CustomLuaState]
[CanYield]
|
Returns the child of the |
Objects
[Deprecated]
|
Returns an array of the object’s children. |
Instance
[Deprecated]
|
void
[Deprecated]
|
Instance
[Deprecated]
|
Objects
[Deprecated]
|
bool
[Deprecated]
[CustomLuaState]
|
bool
[Deprecated]
|
void
[Deprecated]
|
Events
RBXScriptSignal
|
Fires when the |
RBXScriptSignal
|
Fires whenever an attribute is changed on the |
RBXScriptSignal
|
Fired immediately after a property of an object changes. |
RBXScriptSignal
|
Fires after an object is parented to this |
RBXScriptSignal
|
Fires after a child is removed from this |
RBXScriptSignal
|
Fires after a descendant is added to the |
RBXScriptSignal
|
Fires immediately before a descendant of the |
RBXScriptSignal
|
Fires immediately before the instance is destroyed via |
RBXScriptSignal
[Deprecated]
|
Code Samples
Setting Camera Zoom Distance
The example demonstrates how to set a player’s camera minimum and maximum zoom distance.
In this example, we set the Player/CameraMinZoomDistance and Player/CameraMaxZoomDistance to set the min and max distance in studs a player’s camera can be from their character.
Note that since the example attempts to set the CameraMinZoomDistance to be greater than the CameraMaxZoomDistance, the CameraMinZoomDistance value will be decreased and set to the value of the max zoom distance.
To change the default min and max zoom distance values for a player when they first enter the game, you can change the StarterPlayer/CameraMinZoomDistance and StarterPlayer/CameraMaxZoomDistance properties.
Setting a Player's Replication Focus
This example creates a new BasePart and sets the Player’s Player/ReplicationFocus to that part.
This demonstrates the functionality of the ReplicationFocus property. You can easily change the part that the focus is set to to change the replication focus.
Displaying a Humanoid's Health and Name
This example demonstrates how to set a Humanoid’s Humanoid/DisplayerDistanceType, Humanoid/HealthDisplayDistance, and Humanoid/NameDisplayDistance properties. These properties determine how a humanoid’s healthbar and name are rendered for a player.
First, we change the DisplayDistanceType to Viewer using Enum/HumanoidDisplayDistanceType. When set to viewer, the humanoid’s Name and healthbar will be displayed based on the distance settings of the humanoid viewing them.
Then, the humanoid’s HealthDisplayDistance is set to 0. Setting the property to 0 hides the healthbar completely. It is not displayed at any distance.
Finally, the humanoid’s NameDisplayDistance is set to 100. This means that the humanoid’s name will be visible to other humanoid’s within 100 studs.
This example should work as expected when placed inside a Script that is a child of the humanoid.
