return function(mod) local blocks = {} for i = 1, 30 do blocks[i] = 10 end blocks[8], blocks[9] = 11, 11 -- the two grass blocks local pallet = mod.content.maps:get("PALLET_TOWN") local palletBlocks = {} for i, block in ipairs(pallet.blocks) do palletBlocks[i] = block end palletBlocks[7 * pallet.width] = 10 -- block (9, 6), lower-right exit mod.content.maps:register("TUTORIAL_ROUTE", { id = "TUTORIAL_ROUTE", label = "TutorialRoute", index = 1000, tileset = "OVERWORLD", width = 6, height = 5, blocks = blocks, borderBlock = 10, connections = { west = { map = "PALLET_TOWN", offset = -2 } }, }) mod.content.maps:patch("PALLET_TOWN", { connections = { east = { map = "TUTORIAL_ROUTE", offset = 2 } }, blocks = palletBlocks, objects = { __append = { { index = 90, x = 8, y = 7, sprite = "SPRITE_BEAUTY", movement = "STAY", range = "NONE", text = "TEXT_TUTORIAL_WORLD", name = "TUTORIAL_WORLD_NPC", }, } }, }) mod.content.map_scripts:register("PALLET_TOWN", { talk = { TEXT_TUTORIAL_WORLD = { { "face_player" }, { "show_text", "Welcome to the\nTutorial World!" }, } }, }) mod.content.encounters:register("TUTORIAL_ROUTE", { grass = { rate = 25, slots = { { species = "PIDGEY", level = 3 }, { species = "RATTATA", level = 3 }, { species = "PIDGEY", level = 4 }, { species = "RATTATA", level = 4 }, { species = "PIDGEY", level = 5 }, { species = "RATTATA", level = 5 }, { species = "PIDGEY", level = 3 }, { species = "RATTATA", level = 3 }, { species = "PIDGEY", level = 6 }, { species = "RATTATA", level = 6 }, } }, }) end