Skip to content

Engine errors

Engine runtime errors start with the script path and line, such as scripts/main.server.luau:12:, which member pages leave out.

Calls and arguments

  • invalid argument #<n> to '<Name>' (<expected> expected, got <actual>): argument <n> has the wrong type. Argument 1 of an entity method is self.
  • invalid argument #<n> to '<Name>' (<message>): the function rejects the value. Member pages list only <message>.
  • missing argument #<n> to '<Name>' (<expected> expected): the call has too few arguments.
  • Entity: unknown member '<name>' on '<entity>' and Entity: unknown property '<name>': the name is not a property, method, component or child of the entity.

Execution scope

  • <Name> can only be called from the server: send a Net.ToServer message so the server makes the call.
  • <Name> can only be called from a client script: the call needs a player's machine, such as local input or the camera.
  • <Service> has no member '<Name>': <Name> is not a member of <Service> on this side.

Script execution

  • script exceeded its instruction budget: one run of a script, until it yields or returns, made more than 1000000 loop iterations and calls. Split long work across frames with task.wait.
  • not enough memory: the server's scripts, or one player's client scripts, went past their shared 268435456-byte heap. Set tables you no longer need to nil.
  • '<script path>' had <n> more errors that Output did not show: Output shows the first 10 errors of a script file in 5 seconds and counts the rest. An error in Update, a callback or a handler ends that call only, and Update runs again on the next tick.
  • '<script path>' disabled after 5 consecutive runs over its instruction or memory budget: the engine stops the script's Update, PhysicsUpdate and system callbacks. Fix and save the script to reload it.

Service property writes

  • <Service>.<Property> is read-only, <Service> can only be written from the server and <Service> can only be written from a client script: the property takes no writes, or none from this side.
  • attempt to modify a readonly table: a script assigned a field of a constant table such as Input.Key.

Entity property writes

  • Entity: property '<Property>' is read-only: the property takes no writes.
  • '<Property>' is runtime state; only a server script writes it and '<Property>' is client-only; only client scripts may write it: the other side owns the property.
  • '<name>' is a server-owned entity: <Member> needs ownership; ask the server: a client script called Destroy, Add or another method that needs ownership, or wrote Parent. Send a Net.ToServer message so the server makes the change.
  • '<name>' is a server-owned entity: writing <Member> changes only this client and does not replicate; ask the server: Output warns once when a client script writes a collision property of a server-owned entity; see authority.
  • '<Property>' takes <min> to <max>, not <value>: the number is outside the range of an integer property.
  • '<Name>' has no value named '<label>'; use <A>, <B> or <C>: the string is not one of the listed labels. Matching ignores case and spaces.
  • '<Property>' takes a decimal asset id string: the string is neither an asset id nor a project file path.
  • Entity.<Property>: the entity has no <Component>; call Add(Component.<Component>) first: a property write requires that component on the entity; see components. Call Add first, or spawn the entity with that component.
  • Entity.<Property>: entity must have a world transform; cannot have a user interface layout and Entity.<Property>: entity must have a user interface layout; cannot have a world transform: a script used a 3D property on an interface element, or an interface property such as Text on a part.

Destroyed entities

  • Entity: cannot index a destroyed Entity, Entity: cannot modify a destroyed Entity, Entity: cannot call method on a destroyed Entity and attempt to use a destroyed Entity: the entity was destroyed.

On a destroyed entity, Parent returns nil, IsDescendantOf and IsAlive return false, and Destroy does nothing.

Signal warnings

Output warns the first time a script connects to a signal that never fires on its side:

  • Entity.<Signal>: signal cannot fire in a server script; <reason>, connect from a client script: pointer and interface signals, such as Hovered, Pressed or Clicked, fire only on the player's client.