Instance
an entity in the place tree; the components it holds add the members listed under each section
Members
52 members
Instance
- Activated:
Signal[read only] fires when the pointer clicks this element, client side only
- AnimLayers:
AnimLayers[server] [read only] animation layer rows of a character, indexed by layer
- attr:
{ [string]: any }[read only] attribute table of the entity, read and write as e.attr.Name
- Changed:
Signal[read only] fires after a property of the entity changes
- CollisionGroup:
string collision group name, Default when none is set
- DragMoved:
Signal[read only] fires while the pointer drags this element, client side only
- Hovered:
Signal[read only] fires when the pointer enters this element, client side only
- InputMove:
boolean whether local movement input drives this camera
- InputSteer:
boolean whether local pointer input steers this camera
- LocalOrientation:
vector YXZ Euler degrees relative to the parent
- LocalPosition:
vector offset in studs relative to the parent
- Material:
string[server] surface material name, empty when none is set
- Name:
string entity name, empty when unset
- Orientation:
vector world rotation as YXZ Euler degrees
- Parent:
Instance? parent entity, nil for a root
- Position:
vector | UDim2 world position in studs, a UDim2 on GUI elements
- Size:
vector | UDim2 part size in studs, a UDim2 on GUI elements
- ViewSource:
Instance? camera entity this screen renders from, nil when none
- ActiveAnimation
() -> string?[server] name of the playing animation clip, nil when none plays
- AddComponent
(name: string) -> Component | Instance attach a component by name and return it
Parameters
Name Type Description name string Name of the component to attach. returns Component | Instance — - AdvancePreview
() -> boolean[server] step the animation preview, false when no preview runs
- AnimationPreview
() -> AnimPreviewInfo?[server] state of the animation preview, nil when no preview runs
- AnimationWeight
(clip: string) -> number?[server] blend weight of a clip, nil when the entity has no animator
Parameters
Name Type Description clip string Name of the animation clip. returns number? — - ApplyForce
(force: vector, at: vector?) -> ()[server] push the physics body with a force, optionally at a point
Parameters
Name Type Description force vector Force in newtons. at vector? World point in studs; the center of mass by default. returns () — - ApplyImpulse
(impulse: vector, at: vector?) -> ()[server] kick the physics body with an impulse, optionally at a point
Parameters
Name Type Description impulse vector Impulse in newton-seconds. at vector? World point in studs; the center of mass by default. returns () — - ApplyTorque
(torque: vector) -> ()[server] spin the physics body with a torque
Parameters
Name Type Description torque vector Torque in newton-meters. returns () — - Clone
() -> Instance copy the entity with its descendants, the copy becomes a root
- Destroy
() -> ()[server] remove the entity and its descendants, no-op when already dead
- Emit
(name: string, ...any) -> () fire the named signal on the entity with the given arguments
Parameters
Name Type Description name string Name of the signal to fire. ...any any Arguments forwarded to connected callbacks. returns () — - FindFirstChild
(name: string) -> Instance? the direct child with the given name, nil when none
Parameters
Name Type Description name string Name of the direct child to locate. returns Instance? — - GetAngularVelocity
() -> vector[server] angular velocity of the physics body
- GetChildren
() -> {Instance} array of the direct children
- GetIdentity
() -> Identity? user id, display name, and admin flag, nil for non-players
- GetLinearVelocity
() -> vector[server] linear velocity of the physics body
- GetMass
() -> number? mass of the physics body, nil when the entity has none
- GetMoveIntent
() -> MoveIntent?[server] movement intent of a character, nil when the entity has none
- GetSignal
(name: string) -> Signal the named signal of the entity, created on first use
Parameters
Name Type Description name string Name of the signal to retrieve. returns Signal — - GetSwingTwistJoint
() -> SwingTwistJointInfo? swing-twist joint parameters, nil when the entity has no joint
- HasComponent
(name: string) -> boolean whether the entity holds the named component
Parameters
Name Type Description name string Name of the component to check. returns boolean — - IsAlive
() -> boolean whether the entity still exists in the world
- IsDescendantOf
(ancestor: Instance) -> boolean whether the entity sits below the given ancestor
Parameters
Name Type Description ancestor Instance Candidate ancestor entity in the hierarchy. returns boolean — - PlayAnimation
(clip: string, fade: number?, speed: number?) -> ()[server] play a clip with an optional fade time and speed
Parameters
Name Type Description clip string Name of the animation clip. fade number? Blend time in seconds. speed number? Playback rate, 1 being the authored speed. returns () — - PreviewAnimation
(clip: string, playing: boolean?, time: number?, speed: number?) -> boolean[server] start an animation preview, false when the clip is refused
Parameters
Name Type Description clip string Name of the animation clip. playing boolean? Whether the preview advances on its own. time number? Playhead position in seconds. speed number? Playback rate, 1 being the authored speed. returns boolean — - RemoveComponent
(name: string) -> () detach the named component from the entity
Parameters
Name Type Description name string Name of the component to detach. returns () — - Rotate
(axis: vector, angle: number) -> () rotate the entity around an axis by an angle in radians
Parameters
Name Type Description axis vector Unit vector to rotate around. angle number Rotation angle in radians. returns () — - SetAngularVelocity
(velocity: vector) -> ()[server] set the angular velocity of the physics body
Parameters
Name Type Description velocity vector Radians per second. returns () — - SetBodyMotion
(kind: string) -> ()[server] switch the physics body between dynamic and kinematic
Parameters
Name Type Description kind string Motion mode: "dynamic" or "kinematic". returns () — - SetLinearVelocity
(velocity: vector) -> ()[server] set the linear velocity of the physics body
Parameters
Name Type Description velocity vector Studs per second. returns () — - SetSwingTwistJoint
(joint: SwingTwistJointDesc) -> ()[server] configure the swing-twist joint of the entity
Parameters
Name Type Description joint SwingTwistJointDesc Anchor points, axes, and limits of the joint. returns () — - StopAnimation
() -> ()[server] stop all playing clips and close any preview
- StopPreview
() -> boolean[server] stop the animation preview, false when no preview ran
- TakeDamage
(amount: number, attacker: Instance?) -> ()[server] deal damage to the entity and record the attacker
Parameters
Name Type Description amount number Health points to subtract. attacker Instance? Entity responsible for the damage, or nil. returns () —
Appearance
9 members Access: read write
- Color:
vector Surface color of the part or mesh
- ShadowOff:
boolean No shadow from this entity; the shadow passes skip it
SurfaceAppearance
Per-mesh PBR texture overrides; a zero slot means no override
- Albedo:
string Base color texture override; 0 keeps the material texture
- Emissive:
string Emissive color texture added to the lighting; 0 adds none
- MetallicRoughness:
string Roughness in green and metallic in blue; 0 keeps the material
- Normal:
string Tangent-space normal map override; 0 keeps the material map
- Occlusion:
string Ambient occlusion texture, red channel; 0 keeps the material
- Underlay:
string Second albedo, alpha-composited under Albedo over the part colour; read only where a BrickColor makes the mesh a decal
- Transparency:
number Surface transparency, 0 opaque to 1 invisible
Character
13 members
- AutoRotate:
boolean The character turns to the move direction
CharacterAppearance
- Face:
string Texture asset of the face decal
- Pants:
string Texture asset of the pants
- Shirt:
string Texture asset of the shirt
Health
- Health:
number Current hit points; reaching 0 kills the character
- MaxHealth:
number Hit point cap that healing cannot exceed
HumanoidState
- State:
string[read only] Current state of the character state machine
- Invulnerable:
boolean TakeDamage does nothing while this tag exists
LastHit
The server adds this row when damage lands
Locomotion
- HipHeight:
number Clearance between the floor and the torso in studs
- JumpPower:
number Upward velocity given on jump in studs/s
- MaxSlopeAngle:
number Floor angle in degrees a character walks on
- WalkSpeed:
number Ground movement speed of the character in studs/s
Editor
1 member Access: read write
- Locked:
boolean Cannot be selected or moved in the editor viewport
Gameplay
18 members
Attachment
- IsRoot:
boolean This entity is the root of an accessory prefab
- Slot:
string Rig socket the accessory binds to
- AutoLocomotion:
boolean Automatic walk/idle/jump clip selection from velocity and state
Backpack
Holds equipped and stored tool prefab ids
- Active:
number Prefab id of the currently held item
- Slots:
{number} Prefab ids of items in backpack slots
BodyPart
Which body part this child entity is
- Part:
string Which body part of the rig this entity is
- Character:
boolean Marks the root entity of a humanoid character
- CharacterAnimation:
boolean Attaches an Animator once the six body parts exist
- CharacterPhysics:
boolean Opt-in dynamic torso body; Health and Locomotion alone are inert data
- CharacterRig:
boolean Kinematic limb bodies for the BodyPart children, ridden on the torso and pose
DisplayName
Account display name shown on nametags and the leaderboard
- DisplayNameId:
number[read only] Interned id of the account display name, set by the server session layer on join
Identity
Session fact on the character root; distinct from Name
- UserId:
string[read only] Account id of the player who controls this character
Lifetime
Countdown to destruction; the server subtracts the tick time and deletes the entity at zero
- Remaining:
number Seconds left before the server destroys the entity and its children
LimbAttachment
Joint frames; rewritten from the rig asset at attach
- NoContactFriction:
boolean Zero contact friction while present; the FSM holds it during GettingUp
- SpawnPoint:
boolean Players spawn at this part
Team
Groups entities that fight together
- Id:
number Team number of this entity. Team 0 means no team
Identity
2 members
Data
- NameId:
number[read only] Hash id of the entity name. Use the outliner to rename.
PrefabInstance
Names the prefab this entity instantiates; saving a prefab stores the reference instead of the expanded subtree
- PrefabId:
number Id of the prefab this instance was spawned from
Light
6 members Access: read write
Light
Local point light. A SpotCone on the entity makes it a spot light
- Intensity:
number Brightness of the emitted light; 0 turns it off
- LightColor:
vector Color of the emitted light
- Range:
number Distance the light reaches in studs
- LightShadowOff:
boolean The light casts no shadow. Absence means it casts
SpotCone
Cone half-angles in radians. Presence makes the Light a spot light
- InnerAngle:
number Half-angle in radians with full intensity inside the cone
- OuterAngle:
number Half-angle in radians where the light fades to zero
Physics
18 members Access: read write
- Anchored:
boolean Fixes the body in place; gravity and contacts cannot move it
Collider
Collision shape, decoupled from the visual; None opts out
- Collider:
string Auto derives from Shape (cone as cylinder, wedge as box)
Physics
- AngularDamping:
number Decay rate of angular velocity per second; 0 means no drag
- LinearDamping:
number Decay rate of linear velocity per second; 0 means no drag
Surface Override
- Density:
number Mass per unit of volume used to derive the body mass
- Friction:
number Friction coefficient of contacts on this surface, 0 to 2
- Restitution:
number Bounciness of contacts on this surface; 0 does not bounce
SwingTwistJoint
Authored swing-twist joint limit between this entity's body and its ECS parent's; materialized by the consuming system (e.g. character knockdown)
- Anchor:
vector Constraint pivot in the ECS parent's body frame
- FrictionTorque:
number Anti-jitter friction torque in Nm once the joint settles
- NormalCone:
number Swing half-angle perpendicular to Plane Axis; already degrees
- PlaneAxis:
vector Rest-pose swing ellipse axis, parent body frame
- PlaneCone:
number Swing half-angle toward Plane Axis; already degrees
- TwistAxis:
vector Rest-pose twist axis, parent body frame
- TwistMax:
number Twist limit about Twist Axis; already degrees
- TwistMin:
number Twist limit about Twist Axis; already degrees
Velocity
Linear velocity in studs/s
- Velocity:
vector Linear velocity in studs/s; live while the world simulates
Weld
Rigid weld to another entity; the weld system creates the joint and removes this row when the joint breaks
- Other:
Instance? The second welded entity; the weld holds the relative pose the two bodies had when the joint appeared
WeldBreak
Reaction force in Newtons that breaks the weld on this entity; the weld system removes the Weld row past it
- BreakForce:
number Joint reaction force in Newtons that breaks the weld; zero holds forever
UI
69 members Access: read write
CoreMenuAction
engine action this core Menu button fires; the Name does nothing
- Action:
string Engine action this core menu button triggers
CoreMenuPage
page of the core Menu this subtree belongs to
- Page:
number Core menu page this subtree belongs to
CoreSettingBind
device setting this core Menu widget shows or steps
- Op:
string Widget operation: Show the value, or Previous and Next to cycle it
- Setting:
string Device setting this widget shows or adjusts
- UIClickable:
boolean Opts into hit-testing and click/press events
UIClips
Scissors the descendants to this entity's rect
- ClipsDescendants:
boolean Scissors the descendants to this entity's rect
UICorner
Rounds the corners of the plate and the stroke
- CornerRadius:
number Pixels
UIDisabled
Draws the control dim and refuses the pointer and the key; absent means usable
- Disabled:
boolean Draws the control dim and refuses the pointer and the key; absent means usable
UIFrame
Filled rectangle background; the plate behind every Gui
- BackgroundColor3:
vector Background color of the frame
- BackgroundTransparency:
number Transparency of the frame background, 0 opaque to 1 invisible
UIGridLayout
Steps the children through uniform cells and owns their position and size
- CellPadding:
number Pixels between cells
- CellSize:
vector Size of one grid cell in pixels
- Columns:
number Cells across one grid line
- Margins:
Rect Inner margins in pixels: left, top, right, bottom
UIHidden
Hides the entity and its subtree; the renderer skips it
- Visible:
boolean Draws the entity and its subtree; false hides them
UIImage
Draws a texture inside the rect of this element
- Image:
string The texture asset this element draws. 0 draws nothing.
- ImageColor3:
vector Multiplies the texture; white keeps the source colors
- ImageTransparency:
number Transparency of the texture, 0 opaque to 1 invisible
UIListLayout
Stacks the children and owns their position, anchor, and the scroll canvas height; child size stays authored
- Align:
string Cross-axis alignment of the children: Start, Center, or End
- Axis:
string Direction the children stack: Vertical or Horizontal
- MarginBottom:
number Pixels inside the bottom edge
- MarginLeft:
number Pixels inside the left edge
- MarginRight:
number Pixels inside the right edge
- MarginTop:
number Pixels inside the top edge
- Spacing:
number Pixels between children
UIOrder
Draw and list order among siblings
- LayoutOrder:
number Place order under a parent that has a UIListLayout
- ZIndex:
number Draw order among siblings; the higher one draws last
UIRect
Screen-space rectangle; scale is a parent fraction, offset pixels
- AnchorPoint:
vector Pivot inside the rect, 0,0 top left to 1,1 bottom right
- MaxSize:
UDim2 Size cap, a fraction of the parent plus pixels; 0 means no cap
- SizeModeX:
number Fit sizes X to content. Grow splits the list remainder
- SizeModeY:
number Fit sizes Y to content. Grow splits the list remainder
- UIRoot:
boolean ScreenGui: top-level entity whose descendants form one overlay
UIScrollingFrame
Clips the children and moves them with the wheel; a zero canvas takes the extent of a vertical list layout
- CanvasSize:
UDim2 Scrollable canvas size, a fraction of the frame plus pixels
UISlider
A stepped track the player drags; the value is a place in a list, never a free number
- FillColor3:
vector Color of the track between its start and the thumb
- FillTransparency:
number Transparency of the track fill, 0 opaque to 1 invisible
- ThumbColor3:
vector Color of the draggable thumb
- ThumbSize:
number Pixels
- ThumbTransparency:
number Transparency of the thumb, 0 opaque to 1 invisible
- TrackColor3:
vector Color of the track behind the fill
- TrackThickness:
number Pixels
- TrackTransparency:
number Transparency of the track, 0 opaque to 1 invisible
UISliderState
The place a slider holds; a drag writes these two bytes and never the style
UIStroke
Border line around the plate of this Gui
- BorderColor3:
vector Color of the border stroke
- BorderSizePixel:
number Pixels
- BorderTransparency:
number Transparency of the border stroke, 0 opaque to 1 invisible
UITextInput
Editable text input; cursor and focus state stay client-side
- CursorColor3:
vector Color of the text input cursor
- CursorTransparency:
number Transparency of the text cursor, 0 opaque to 1 invisible
- Password:
boolean Mask typed characters
- PlaceholderText:
string Interned id of the placeholder text. Set PlaceholderText through the property panel or a script.
UITextSource
The authored text as an interned name id
- Text:
string Interned id of the authored text. Set Text through the property panel or a script.
UITextStyle
Text style, including horizontal and vertical alignment
- Bold:
boolean Draws the text with the bold font weight
- NoTranslate:
boolean Show this text as typed, with no translation
- TextColor3:
vector Color of the text
- TextSize:
number Pixels
- TextStrokeColor3:
vector Color of the text outline
- TextStrokeTransparency:
number Transparency of the text outline, 0 opaque to 1 invisible
- TextStrokeWidth:
number Zero disables the MSDF outline
- TextTransparency:
number Transparency of the text, 0 opaque to 1 invisible
- TextXAlignment:
number Horizontal text alignment: Left, Center, or Right
- TextYAlignment:
number Vertical text alignment: Top, Center, or Bottom
UIToggle
A two-state switch with a pill track and a round knob
- KnobColor3:
vector Color of the sliding knob
- KnobInset:
number Pixels between the knob and the track
- KnobTransparency:
number Transparency of the knob, 0 opaque to 1 invisible
- OffColor3:
vector Track color while the switch is off
- OffTransparency:
number Track transparency while off, 0 opaque to 1 invisible
- OnColor3:
vector Track color while the switch is on
- OnTransparency:
number Track transparency while on, 0 opaque to 1 invisible
UIToggleOn
The switch is in the on position
- On:
boolean The switch is in the on position
Visual
3 members Access: read write
- Mesh:
string The mesh asset this entity draws; 0 draws nothing
- RenderDisabled:
boolean No render slot; physics, replication, and raycasts untouched
Shape
Part shape identity as a value
- Type:
string CK_PARTS shape byte; one identity for render, raycast, physics
Spawning and Managing Instances
Lifecycle: Server
Spawned prefabs behave like any other instance: parent them into the world, reach their children by name, and destroy them when finished.
local door = game.Prefabs.Spawn("Door")if door then door.Parent = game.World local hinge = door:FindFirstChild("Hinge") if hinge then hinge:ApplyImpulse(Vector3.new(0, 10, 0)) end door:Destroy() print("Door destroyed")end