Skip to main content

On Sale: GamesAssetsToolsTabletopComics
Indie game storeFree gamesFun gamesHorror games
Game developmentAssetsComics
SalesBundles
Jobs
TagsGame Engines

NEXXT studio 3

Featureful NES assets studio based off the classic "NES Screen Tool". It's the "famitracker" of NES graphics. · By FrankenGraphics

Suggestion: Append project name and palette group to array name when exporting palette to C

A topic by Matt Hughson (NES Dev) created Dec 03, 2022 Views: 160 Replies: 1
Viewing posts 1 to 2
(1 edit)

When using Palettes -> Put to clipboard as -> C Data we get something like:

const unsigned char palette[16]={ 0x0f,0x28,0x1a,0x2a,0x0f,0x28,0x18,0x38,0x0f,0x1c,0x0c,0x2c,0x0f,0x28,0x00,0x30 };

Most games will have more than one palette, and this requires us to edit the palette name after the fact. It would be nice if some unique ID were embedded in the variable name itself (similar to meta sprites). 

I suggest:

"palette_" {project_name} "_" {palette_sub_set_id}

So, for example this Palette:


This would output:

const unsigned char palette_overworld_b[16]={ 0x0f,0x28,0x1a,0x2a,0x0f,0x28,0x18,0x38,0x0f,0x1c,0x0c,0x2c,0x0f,0x28,0x00,0x30 };
Developer(+1)

That makes sense, and should be a minute. I'll add it to the next version! Thanks for the idea.