Class
LocalScript
An object that contains and runs Luau code on the client (player's device) instead of the server.
A LocalScript is a Luau source container that runs its contents on the
client (player's device) instead of the server. It is used to access
client-only objects such as the player's Camera.
For code run through LocalScripts, the
LocalPlayer property of the Players
service will return the player whose client is running the script.
See here for a table of valid
container services from which LocalScripts will execute.
Inherited members#
Inherited from BaseScript 4
Properties (4)
Inherited from Instance 58
Properties (10)
Archivable, archivable, Capabilities, IsInSandbox, Name, Parent, PredictionMode, RobloxLocked, Sandboxed, UniqueId
Methods (39)
AddTag, children, ClearAllChildren, Clone, clone, Destroy, destroy, FindFirstAncestor, FindFirstAncestorOfClass, FindFirstAncestorWhichIsA, FindFirstChild, findFirstChild, FindFirstChildOfClass, FindFirstChildWhichIsA, FindFirstDescendant, GetActor, GetAttribute, GetAttributeChangedSignal, GetAttributes, GetChildren, getChildren, GetDebugId, GetDescendants, GetFullName, GetStyled, GetStyledPropertyChangedSignal, GetTags, HasTag, IsAncestorOf, IsDescendantOf, isDescendantOf, IsPropertyModified, QueryDescendants, Remove, remove, RemoveTag, ResetPropertyToDefault, SetAttribute, WaitForChild