-
Notifications
You must be signed in to change notification settings - Fork 2
Cookbook Tweaks
Content changes to things that already exist. Mechanism:
Concepts: Registries. All code goes in main.lua
inside return function(mod) ... end unless noted.
Ship a recipe, not pixels: declare "assets_transforms": "transforms.lua"
in the manifest and write the transform.
-- transforms.lua
return function(ctx)
local front = ctx.readImage("battle/front/mew.png")
ctx.writeImage(ctx.recolor(front, {
{ 255, 255, 255 }, { 255, 170, 200 }, { 180, 60, 120 }, { 40, 0, 20 },
}), "battle/front/mew.png")
endThe derived file shadows the cache path everywhere it is drawn. Checkpoint: Mew renders recolored in the dex and in battle. Full walkthrough: Tutorial 01.
mod.content.text:override("_PalletTownSignText", "MODDED SIGN.")Checkpoint: reading the Pallet Town sign shows the new text. Find label
names in the merged registry: mod.content.text:each().
mod.content.moves:patch("TACKLE", { power = 50 })Checkpoint: Tackle deals more damage; every unnamed field stays vanilla.
mod.content.pokemon:patch("PIDGEY", { baseStats = { speed = 71 } })Checkpoint: the baseStats sub-table merges — only speed changes.
base_stats is the classic typo; api = 2 rejects it with a suggestion.
mod.content.encounters:patch("ROUTE_1", {
grass = {
rate = 30,
slots = { __prepend = { { species = "EKANS", level = 5 } } },
},
})Checkpoint: Route 1 rolls Ekans in its most common slot; rate (of 255)
governs how often grass rolls at all. Ten slots weight front-to-back per
constants.encounterBuckets.
mod.content.trainers:patch("OPP_BROCK", {
parties = { { { species = "ONIX", level = 14 },
{ species = "GEODUDE", level = 12 } } },
})Checkpoint: Brock leads Onix 14. parties is an array of parties —
arrays replace wholesale, so state the full party list.
Engine 1.0.0 · mod API 2 · repository · Discord
This project ships no ROM data. All game content is decoded on the player's machine from their own verified Pokemon Red ROM; mods ship recipes and original assets, never extracted content.
Start here
Concepts
Tutorials
- The ladder
- 01 Sprite and Text Tweak
- 02 Balance Patch
- 03 New Species
- 04 New Item and Ball
- 05 New Move
- 06 NPC and Dialogue
- 07 New Map
- 08 Quest
- 09 Custom Music
- 10 New Mechanic
- 11 Custom UI Screen
- 12 Mini Total Conversion
Reference
Guides
Playing