Skip to content

game

Registry lookups and translations: the data that does not change while the game runs.

Live objects live on player and world. game answers what stays put.

Function Returns
game.item(id) Item handle for that id’s default stack
game.translate(key, ...) The key translated through the client language; extra args fill %s slots
game.has_translation(key) Whether the client language knows the key
game.language() Language code, e.g. "en_us"
print(game.translate("block.minecraft.stone"))   -- "Stone", or the localized name

local apple = game.item("minecraft:golden_apple")
print(apple:name(), apple:food().nutrition)
Navigation

Type to search…

↑↓ navigate↵ selectEsc close