Writing R6 & R15 Compatible Server ScriptsWrite once so your Luau runs in both classic R6 and modern R15 lobbies.
A script that looks for character.Torso crashes in R15 games, while UpperTorso crashes in R6 games. Two tiny habits make your server scripts work in both automatically.
Target HumanoidRootPart and Humanoid first
Both R6 and R15 avatars share HumanoidRootPart, Head, and Humanoid. When attaching effects, lights, or positioning props, reference HumanoidRootPart so your script never breaks when switching games.
local function getAnchor(character)
return character:FindFirstChild("HumanoidRootPart")
or character:FindFirstChild("Torso")
or character:FindFirstChild("UpperTorso")
endCommon questions
How can I check if a character is R6 or R15 in Luau?
Inspect humanoid.RigType == Enum.HumanoidRigType.R6 or Enum.HumanoidRigType.R15.
Keep reading
All scriptsServer-Replicated Character & Visual Effects
Attach Particles, Highlights, PointLights, and clean visual effects to Roblox characters on the server so every player in the lobby sees them live.
Read guideEnvironment & WorldSpawning Replicated Props Server-Side
Spawn anchored neon props, platforms, and decorative markers safely in Roblox workspace from the server with automatic Debris cleanup.
Read guideNova Script CloudBeginner Luau Server Snippets
Clean, readable 3-to-10-line Luau server snippets you can run right away in Nova's Script Console on the Free plan to see real server replication.
Read guideDiagnostics & UtilitiesServer Health & Diagnostics Scripts
Inspect live player count, server job uptime, and workspace stats cleanly with non-intrusive Luau diagnostic snippets.
Read guideDiagnostics & UtilitiesPolicy-Safe Scripts & Script Safety Guard
How to write and pick policy-safe server scripts on Nova, avoid warning triggers, and use Ultra's Script Safety Guard for reviewed pre-run checks.
Read guideFree PlanFree Roblox Serverside ($0 Plan)
Start free with 25 runs every 3 hours, Verified Scripts, and zero downloads.
Read guideTry Nova free right in your browser.
Create a free account, link your Roblox profile in about a minute, and run verified or custom Luau scripts with zero downloads. Upgrade to Basic, Enhanced, or Ultra anytime with one-time card checkout.