Goal
The finish: shows a message, gives a reward and sends the player back to the start.
- Inherits: Behavior → Instance
- Creatable: Yes:
new Goal(), orInstance.new('Goal', parent). - Replication: Server only: it, and everything inside it, is never sent to clients.
The finish: a message and a reward for each player who reaches it, then back to the start.
Properties
Section titled “Properties”message
Section titled “message”Type: string · Default: 'You win!' · Access: read/write · Replicates: no
What the player sees when they reach it.
Type: string · Default: '' · Access: read/write · Replicates: no
A stat it adds to (‘’ = none; made if they don’t have it).
amount
Section titled “amount”Type: number · Default: 0 · Access: read/write · Replicates: no
How much it adds to the stat.
sendBack
Section titled “sendBack”Type: number · Default: 3 · Range: 0 to 3,600 (clamped) · Access: read/write · Replicates: no
Seconds until the player goes back to the start (0 = they stay).
Inherited from Behavior: enabled, running
Inherited from Instance: name, archivable, id, className, parent, destroyed
Methods
Section titled “Methods”Inherited from Behavior: activate
Inherited from Instance: getPropertyChangedSignal, setAttribute, getAttribute, getAttributes, getAttributeChangedSignal, getChildren, getDescendants, findFirstChild, findFirstChildOfClass, findFirstChildWhichIsA, findFirstAncestor, findFirstAncestorWhichIsA, waitForChild, isA, isDescendantOf, isAncestorOf, getFullName, clearAllChildren, destroy, clone, toString
Events
Section titled “Events”Inherited from Instance: changed, childAdded, childRemoved, descendantAdded, descendantRemoving, ancestryChanged, destroying, attributeChanged