[nostalgia/core/gba] Add hardware target types for loading tile maps and palettes
This commit is contained in:
@@ -35,6 +35,13 @@ struct NostalgiaGraphic {
|
||||
ox::Vector<uint8_t> tiles;
|
||||
};
|
||||
|
||||
template<typename T>
|
||||
ox::Error model(T *io, NostalgiaPalette *pal) {
|
||||
io->setTypeInfo("nostalgia::core::NostalgiaPalette", NostalgiaPalette::Fields);
|
||||
oxReturnError(io->field("colors", &pal->colors));
|
||||
return OxError(0);
|
||||
}
|
||||
|
||||
template<typename T>
|
||||
ox::Error model(T *io, NostalgiaGraphic *ng) {
|
||||
io->setTypeInfo("nostalgia::core::NostalgiaGraphic", NostalgiaGraphic::Fields);
|
||||
@@ -45,13 +52,6 @@ ox::Error model(T *io, NostalgiaGraphic *ng) {
|
||||
return OxError(0);
|
||||
}
|
||||
|
||||
template<typename T>
|
||||
ox::Error model(T *io, NostalgiaPalette *pal) {
|
||||
io->setTypeInfo("nostalgia::core::NostalgiaPalette", NostalgiaPalette::Fields);
|
||||
oxReturnError(io->field("colors", &pal->colors));
|
||||
return OxError(0);
|
||||
}
|
||||
|
||||
[[nodiscard]] ox::Error initGfx(Context *ctx);
|
||||
|
||||
[[nodiscard]] ox::Error shutdownGfx();
|
||||
|
||||
Reference in New Issue
Block a user