1
0
mirror of https://github.com/OpenRCT2/OpenRCT2 synced 2026-01-24 15:24:30 +01:00

Expose obj image offset and num images to plugins (#17567)

Co-authored-by: Duncan <duncans_pumpkin@hotmail.co.uk>
This commit is contained in:
Nikolas Parshook
2023-04-13 15:09:15 -04:00
committed by GitHub
parent d0c7d0f6fb
commit ef35dfa40a
22 changed files with 106 additions and 52 deletions

View File

@@ -12,7 +12,6 @@
#include "../core/IStream.hpp"
#include "../core/Json.hpp"
#include "../drawing/Drawing.h"
#include "../drawing/Image.h"
#include "../localisation/Language.h"
#include "../object/Object.h"
#include "../object/ObjectRepository.h"
@@ -62,13 +61,13 @@ void BannerObject::Load()
{
GetStringTable().Sort();
_legacyType.name = LanguageAllocateObjectString(GetName());
_legacyType.image = GfxObjectAllocateImages(GetImageTable().GetImages(), GetImageTable().GetCount());
_legacyType.image = LoadImages();
}
void BannerObject::Unload()
{
LanguageFreeObjectString(_legacyType.name);
GfxObjectFreeImages(_legacyType.image, GetImageTable().GetCount());
UnloadImages();
_legacyType.name = 0;
_legacyType.image = 0;