/* pop_bg_atlas.h — раскладка атласов статического фона PoP. * Сгенерировано toolchain/pop_pack_bg.py — НЕ править вручную. * * Прямая адресация (ноль remap-таблиц в W2): * ENV фон id N -> atlas env_bg[N>>4], idx N&15 * WALL id N -> atlas wall, idx N * FORE id N -> atlas fore, idx N * * ДВА ТАЙЛСЕТА (порт tbl_envir_ki[tbl_level_type], seg000:1108): * 0 = подземелье (pop_*), 1 = дворец (pal_*). Набор id и раскладка * у них ОДНИ И ТЕ ЖЕ — меняются только файлы и 32 записи палитры * (env 0x50..0x5F, wall 0x60..0x6F), см. *tile.pal. */ #ifndef POP_BG_ATLAS_H #define POP_BG_ATLAS_H #define POP_ENV_SHIFT 4 #define POP_ENV_MASK 15 #define POP_ENV_PAGES 10 #define POP_TILESETS 2 /* Палитра: env-слоты, wall-слоты (спрайт-пиксель i -> база+i). */ #define POP_PAL_ENV 0x50 #define POP_PAL_WALL 0x60 /* Имена файлов атласов по тайлсету (грузятся atlas_load). Таблицы * видны только тому, кто попросил POP_BG_ATLAS_NAMES: иначе копия * строк уедет в каждый включивший заголовок модуль. */ #ifdef POP_BG_ATLAS_NAMES static const char *const pop_env_atl[POP_TILESETS][POP_ENV_PAGES] = { { "pop_env0.atl", "pop_env1.atl", "pop_env2.atl", "pop_env3.atl", "pop_env4.atl", "pop_env5.atl", "pop_env6.atl", "pop_env7.atl", "pop_env8.atl", "pop_env9.atl" }, { "pal_env0.atl", "pal_env1.atl", "pal_env2.atl", "pal_env3.atl", "pal_env4.atl", "pal_env5.atl", "pal_env6.atl", "pal_env7.atl", "pal_env8.atl", "pal_env9.atl" }, }; static const char *const pop_wall_atl[POP_TILESETS] = { "pop_wall.atl", "pal_wall.atl" }; static const char *const pop_fore_atl[POP_TILESETS] = { "pop_fore.atl", "pal_fore.atl" }; static const char *const pop_tile_pal[POP_TILESETS] = { "pop_tile.pal", "pal_tile.pal" }; #endif /* POP_BG_ATLAS_NAMES */ #define POP_POT_ATL "pop_pot.atl" /* chtab_1: зелья, от набора не зависит */ #define POP_PAL_POT 0x40 /* Пузырёк зелья: красный набор = id 16..22 (кадры оригинала), зелёный (перо/переворот) и синий (вред/открыть) = те же кадры под id 30..36 и 40..46 (draw_tile_anim, seg008:652). */ #define POP_POT_BUBB_GREEN 30 #define POP_POT_BUBB_BLUE 40 #define POP_BG_PAL "pop_bg.pal" #endif