---
title: "Glorpia Luau"
description: "Functions, datatypes and object APIs exposed to Glorpia creator scripts."
canonical: "https://docs.glorpia.com/scripting"
markdown: "https://docs.glorpia.com/scripting.md"
---
# Glorpia Luau

Functions, datatypes and object APIs exposed to Glorpia creator scripts.

**Category:** Scripting

## Public scripting

Glorpia executes creator-authored `ServerScript`s on the authoritative server and creator-authored `LocalScript`s on each client. RemoteEvent and RemoteFunction connect the two public scripting contexts while keeping client-only and server-only APIs separated.

- [Public Scripts](https://docs.glorpia.com/scripting/public-scripts.md) — ServerScript and LocalScript execution and permission boundaries.
- [ServerScript](https://docs.glorpia.com/instances/serverscript.md) — Authoritative server-side creator code.
- [LocalScript](https://docs.glorpia.com/instances/localscript.md) — Client-side creator code.
- [RemoteEvent](https://docs.glorpia.com/instances/remoteevent.md) — One-way client/server communication.
- [RemoteFunction](https://docs.glorpia.com/instances/remotefunction.md) — Request/response client/server communication.
- [BasicSound](https://docs.glorpia.com/instances/basicsound.md) — Control global or spatial audio from Luau.

> **Note:** `CoreScript` and `CoreLocalScript` remain privileged engine-owned classes. Public ServerScripts and LocalScripts use restricted side-specific creator permissions.

## Script editor

ServerScripts and LocalScripts open as editable tabs beside the place tab. The public editor uses the same Glorpia Luau syntax colours and layout as the read-only CoreScript viewer.

The editor autocomplete includes globals, services, properties, methods, signals, enums and known hierarchy children. Callable completions show and insert parentheses. String-first calls such as `game:GetService()`, `FindFirstChild()`, `FindFirstChildOfClass()`, `FindFirstChildWhichIsA()`, `WaitForChild()` and `IsA()` insert `("")` and place the caret between the quotes. Typing a raw `(` also inserts the matching `)` with the caret left inside the pair.

![Glorpia Studio script editor showing Luau source with syntax highlighting](https://docs.glorpia.com/images/studio/script-editor.png)

*The Studio script editor uses the same syntax-colour design for public and core scripts.*

## Runtime information

The global `Glorpia` table exposes engine identity, client/server state, Offline Mode state, memory information and current player FPS reports.

```luau
print(Glorpia.EngineName)
print(Glorpia.EngineVersion)
print(Glorpia.IsServer)
print(Glorpia.IsClient)
print(Glorpia.IsOfflineMode)
print(Glorpia.EngineMemoryUsage)

for player, fps in pairs(Glorpia.GetFramesPerSecond()) do
    print(player.Name, player.Platform, fps)
end
```

- [Glorpia Runtime](https://docs.glorpia.com/scripting/glorpia.md) — Runtime flags, memory usage, GetEngineMemory() and player FPS reporting.

## A first script

This example creates a Part, changes some of its BasePart properties, and parents it into Workspace so it appears in the world.

```luau
local part = Instance.new("Part")
part.Name = "ExamplePart"
part.Size = Vector3.new(4, 1, 4)
part.Shape = Enum.PartShape.Cylinder
part.Bevel = 0.35
part.Colour3 = Colour3.fromRGB(88, 255, 106)
part.Parent = workspace
```

## Common functions and methods

- [Instance.new()](https://docs.glorpia.com/scripting/functions/instance-new.md) — Create supported runtime instances including scripts, remotes, Humanoid, Parts and containers.
- [RemoteEvent](https://docs.glorpia.com/instances/remoteevent.md) — Send one-way messages across the client/server boundary.
- [RemoteFunction](https://docs.glorpia.com/instances/remotefunction.md) — Invoke the opposite side and receive return values.
- [game:GetService()](https://docs.glorpia.com/scripting/functions/get-service.md) — Access Workspace, Lighting, RunService, Players, TweenService and other documented services.
- [Math & Task Utilities](https://docs.glorpia.com/scripting/utilities.md) — Use math.random(), math.noise() and task.wait().
- [FindFirstChild()](https://docs.glorpia.com/scripting/functions/find-first-child.md) — Safely find a child by name, optionally recursively.
- [WaitForChild()](https://docs.glorpia.com/scripting/functions/wait-for-child.md) — Yield until a named direct child exists.
- [FindFirstChildWhichIsA()](https://docs.glorpia.com/scripting/functions/find-first-child-which-is-a.md) — Find a child by class or supported base class.
- [Clone()](https://docs.glorpia.com/scripting/functions/clone.md) — Deep-copy an Instance tree before parenting the clone.
- [Humanoid:TakeDamage()](https://docs.glorpia.com/scripting/functions/take-damage.md) — Reduce authoritative Humanoid health.
- [Humanoid:MoveTo()](https://docs.glorpia.com/scripting/functions/move-to.md) — Walk an authored NPC Humanoid toward a world position.
- [Humanoid:FollowPlayer()](https://docs.glorpia.com/scripting/functions/follow-player.md) — Continuously follow a Player with an authored NPC Humanoid.
- [FindFirstChildOfClass()](https://docs.glorpia.com/scripting/functions/find-first-child-of-class.md) — Find the first direct child with an exact ClassName.
- [workspace:Raycast()](https://docs.glorpia.com/scripting/functions/raycast.md) — Cast through the physics world and inspect the first hit.
- [PivotTo()](https://docs.glorpia.com/scripting/functions/pivot-to.md) — Move and rotate BaseParts or Models around their pivot.
- [Signals & Connect()](https://docs.glorpia.com/scripting/functions/signals.md) — Connect and disconnect runtime signals.
- [BasePart.Touched](https://docs.glorpia.com/scripting/events/touched.md) — React to authoritative BasePart contact events.

## Instance access

Normal instances support hierarchy methods such as `FindFirstChild()`, `WaitForChild()`, `FindFirstChildOfClass()`, `FindFirstChildWhichIsA()`, `Clone()`, `GetChildren()` and `GetDescendants()`. Direct child-name indexing is also supported, so `character.Humanoid` can resolve a direct child named Humanoid.

BasePart colour accepts `Color`, `Colour`, `Color3` and `Colour3` as equivalent read/write aliases. Vector and colour constructors accept numeric variables in their component arguments.

## Where to go next

- [Instances](https://docs.glorpia.com/instances.md) — Learn what objects exist and which properties each class exposes.
- [Services](https://docs.glorpia.com/services.md) — Learn how engine-wide systems and hierarchy storage services are exposed to scripts.
- [Datatypes](https://docs.glorpia.com/scripting/datatypes.md) — Vector2, Vector3, CFrame and Color3 / Colour3.
- [Enums & Input](https://docs.glorpia.com/scripting/enums.md) — PartShape, KeyCode, UserInputType, UserInputState and MouseBehavior.
