RoCode

The developer tool Roblox has been missing.

Native Luau editing. Live Studio sync. An AI assistant trained on the Roblox API.

Free to download. See pricing →

obby/src/Lobby.luau
studio connected
Workspace
ReplicatedStorage
ServerScriptService
GameLoop.server.luau
Lobby.luau
PartSpawner.server.luau
StarterGui
HUD.client.luau
Lobby.luau×
1-- Lobby.luau
2local Players = game:GetService("Players")
3local Lobby = {}
4
5function Lobby:onPlayerJoin(player: Player)
6 local pad = workspace.LobbyPad:Clone()
7 pad.Parent = workspace
8+ player.Character.HumanoidRootPart.CFrame = pad.CFrame
9end
10
11return Lobby
Spawn the player at the lobby pad when they join.
I’ll add a character spawn line inside onPlayerJoin.
roco-edit-fileLobby.luau+1 -0
Done. The new player will land on workspace.LobbyPad as soon as their character loads.
Tell the agent what to do…
AgentSonnet 4.6Personal
luau-lsp · ok·sync · live·agent · sonnet 4.6$ 12.40 credits