[ImenuDef_t] itemDefData is now functional for most item types.

multiDef_s is todo.
This commit is contained in:
RektInator 2017-02-26 11:36:58 +01:00
parent 5e9e7e630d
commit edd906170b

View File

@ -347,6 +347,10 @@ namespace Assets
void save_itemDefData_t(Game::itemDefData_t* asset, int type, Game::itemDef_t* dest, Components::ZoneBuilder::Zone* builder) void save_itemDefData_t(Game::itemDefData_t* asset, int type, Game::itemDef_t* dest, Components::ZoneBuilder::Zone* builder)
{ {
AssertSize(Game::newsTickerDef_s, 28);
AssertSize(Game::listBoxDef_s, 324);
AssertSize(Game::editFieldDef_s, 32);
Utils::Stream* buffer = builder->getBuffer(); Utils::Stream* buffer = builder->getBuffer();
// feeder // feeder
@ -406,7 +410,7 @@ namespace Assets
else else
{ {
buffer->align(Utils::Stream::ALIGN_4); buffer->align(Utils::Stream::ALIGN_4);
buffer->save(asset->multiDef); buffer->save(asset->editField);
} }
Utils::Stream::ClearPointer(&dest->typeData.data); Utils::Stream::ClearPointer(&dest->typeData.data);
@ -482,8 +486,7 @@ namespace Assets
// itemDefData // itemDefData
if (asset->typeData.data) if (asset->typeData.data)
{ {
// save_itemDefData_t(&asset->typeData, asset->type, dest, builder); save_itemDefData_t(&asset->typeData, asset->type, dest, builder);
dest->typeData.data = nullptr;
} }
// floatExpressions // floatExpressions