Experimental

An early preview: docs, the API and the dashboard may change or break.

Report a problem

Get started

Glowstone games are called experiences. You write them in Luau, a typed version of Lua, and they run on Glowstone's Minecraft servers.

You build them in Glowstone Studio, our desktop editor. It knows the whole scripting API, so it can autocomplete, type-check and format your code as you write.

1. Install Glowstone Studio

Download Glowstone Studio for macOS or Windows, then open it and sign in. For now, Studio is only for Glowstone partners: you need to be in a partner organisation to download and use it.

2. Create an experience

On the welcome screen, choose New experience… and pick a template:

  • Coin Rush is a complete, small game. Players race to collect gold coins, and the first to three wins. Start here if you want to see how a real game fits together.
  • Blank gives you an empty starting point: one world, a script, a module, some example content and two textures. There's no game logic or map yet.

Your experience is saved as a normal folder, in Documents/Glowstone unless you choose somewhere else. You can also open it in VS Code with the luau-lsp extension. Glowstone Studio writes the type files and .luaurc that luau-lsp needs.

3. Look around the folder

An experience can contain several games, called worlds. Each world has its own folder under worlds/. Coin Rush has one world, called match:

experience.toml            settings for the whole experience
content.luau               custom blocks, items, mobs and recipes
assets/                    models and textures for your custom content
worlds/
  match/
    world.toml             settings for this world
    main.luau              the script that runs the game
    maps/coinrush.embermap the map it's played on

content.luau and assets/ are shared by every world in the experience.

When players join a world, Glowstone starts a server for it: one running copy of the world, with its own copy of your scripts. Scripts call this the instance. When the game ends, the server shuts down and nothing in it is kept, apart from data you save on purpose.

4. Make your first change

Open worlds/match/main.luau. Add this to say hello to every player who joins:

local players = require("@ember/players")

players.joined:connect(function(player)
	player:send("<yellow>Welcome to my game!")
end)

Text uses MiniMessage tags, so <yellow> makes the message yellow.

Hover over any name in Glowstone Studio to see its documentation. The API reference has everything too. @ember/players and Player are good places to start, and scripting basics explains how scripts work.

5. Put it on Glowstone

  1. Go to the dashboard and sign in with the Microsoft account you use for Minecraft.
  2. Choose New experience and give it a name. This also sets its address (like @you/coin-rush) and its content namespace. You can change the address later, but not the namespace.
  3. Add a world for each game in the experience. One is enough to start.

New experiences are private, so only you can see them. When yours is ready for players, request to make it public.

Settings reference

experience.toml

Coin Rush's experience.toml:

namespace = "coinrush"
name = "Coin Rush"
uses = ["minecraft"]
KeyWhat it does
namespaceRequired. The prefix for your custom content. Coin Rush's coin item becomes coinrush:coin. It can't be changed after the experience is created.
nameRequired. The name players see.
startThe key of the world players join first. You can leave it out if there's only one world.
usesContent packs to include. Add "minecraft" to use vanilla blocks and items; without it, there are none. See vanilla blocks and items.

world.toml

Each world folder has one. Coin Rush's worlds/match/world.toml:

name = "Coin Rush"
maxPlayers = 8
countdownSeconds = 5
map = "coinrush"
entry = "main.luau"

[config]
coinsToWin = 3
roundSeconds = 60
KeyWhat it doesDefault
nameRequired. The world's name.
minPlayersHow many players must be waiting before the countdown starts.1
maxPlayersThe most players one server can hold.16
countdownSecondsHow long the countdown lasts before the game starts.10
mapThe map to play on, from the world's maps/ folder. You can leave off .embermap.maps/map.embermap
mapsUse this instead of map to rotate between several, like maps = "crossroads,octave".
modesVariants of the game, like modes = "solo,duos". Each server picks one at random.
entryThe script that runs the game, in the same folder as world.toml.main.luau
combatnone, modern or legacy.none
hungerSet to false to turn hunger off.true
damageSet to false so players take no damage, falls included.true

The [config] section goes at the end of world.toml. You choose its keys, and your scripts read them from instance.config. This is a good place for numbers you might want to tweak, like round length.

Both files are simple key = value lines. Values can be quoted strings, whole numbers, true or false, or a list of quoted strings. Unknown or repeated keys are errors.

Next

Learn the terms Glowstone uses in experiences, worlds and builds, or jump into scripting basics.