Guides
Roblox scripting guides
Complete, working Luau for the systems Roblox developers build most, with where each script goes, why it is written that way and the errors you are likely to hit. Every guide works by hand. Popular first systems: a kill brick, coins to collect, a pet that follows you and daily rewards. New: how to make 26 kinds of game, from an obby and a horror game to tower defense, battlegrounds and an RNG game, plus a Steal a Brainrot style game, an admin panel and a drivable car. The building blocks most tutorials skip: key presses with UserInputService, press E prompts, TweenService, raycasting, debounce and cooldowns and developer products done safely. New to scripting? Start with how to script in Roblox Studio, then make your first game. RoCode, our Studio AI agent, is there if you would rather describe the system and have it built in your place. Just want the code? Roblox Studio scripts collects the main scripts from the guides, sorted by what they build, and the free tools include a game idea generator, a DevEx calculator, a Robux tax calculator, a thumbnail size checker and a Luau playground.
Using AI in Roblox Studio
What AI can and cannot do for a Roblox project today, and how to get useful Luau out of it.
How to make each kind of game
Obby, tycoon, horror, tower defense, battlegrounds, RNG and more: what makes each genre work, the systems it needs and a build plan. All 26 in one place: Roblox game genres. Which ones creators ask an AI to build most: our 2026 build data.
Scripting foundations
Where scripts run, how the client and server talk, and how to organise code so it stays readable.
Player data and leaderboards
Stats on the player list, and saving progress so it survives the next session.
Game systems
Complete, working systems you can drop into a place and extend.
Gameplay mechanics
Kill bricks, pads, platforms, pets, teams, combat and the day and night cycle: the pieces players touch every minute.
Rewards, pets and trading
Coins, eggs, codes, daily rewards, fishing and trades, with the server deciding every number.
Menus, HUD and sound
Health bars, minimaps, settings, music and menu animations, built in code you can restyle.
Debugging
Reading the Output window, understanding error messages and fixing them for good. Looking up one message? See Roblox Studio error messages.
Questions
Where should I start if I have never scripted in Roblox?
With how to script in Roblox Studio: where scripts go, your first script, events and reading the Output window. Then make your first game, and learn how the two sides of a game talk in client and server scripts and RemoteEvents.
What language are Roblox scripts written in?
Luau, the language Roblox made from Lua 5.1. It adds optional types and a few extras, so most Lua 5.1 code still runs. Every guide here is in Luau, and you can try short snippets in the Luau playground without opening Studio.
Can I use the code from these guides in my game?
Yes. Copy any script without an account and change it to fit your game. The main script from most guides is also on Roblox Studio scripts, sorted by what it builds.
Is the code tested?
Every Luau block in these guides passes Luau's strict type checker, luau-lsp, against Roblox's API definitions. A type check catches misspelt APIs and wrong types, not game logic, so press Play and watch the Output window before you publish. Scripts that were also run in Studio say so, with the date.
My script shows an error. Where do I look it up?
Copy the red line from Output and find it in Roblox Studio error messages: each page gives the causes, the code that triggers each and the fix. For a routine that works on any error, read how to fix Roblox script errors.
RoCode in other languages. In Spanish: IA para Roblox Studio, Crear juegos de Roblox con IA. In Portuguese: IA para Roblox Studio, Criar jogos no Roblox com IA. In French: IA pour Roblox Studio, Créer un jeu Roblox avec l'IA. In German: KI für Roblox Studio, Roblox Spiel erstellen. In Indonesian: AI untuk Roblox Studio, Cara membuat game di Roblox. In Russian: ИИ для Roblox Studio, Как сделать игру в Roblox. In Turkish: Roblox Studio için yapay zeka, Roblox oyun yapma. In Italian: IA per Roblox Studio, Come fare un gioco su Roblox. In Polish: AI do Roblox Studio, Jak zrobić grę w Roblox. Every page in each language links the others from its footer.
Or let RoCode write it in your place.
Every guide here works by hand. RoCode is the shortcut: describe the system, and it writes the Luau and builds it in the place you have open.