mirror of
https://github.com/OpenRCT2/OpenRCT2
synced 2026-01-26 16:24:35 +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:
@@ -11,7 +11,6 @@
|
||||
|
||||
#include "../core/IStream.hpp"
|
||||
#include "../core/Json.hpp"
|
||||
#include "../drawing/Image.h"
|
||||
|
||||
void FootpathRailingsObject::Load()
|
||||
{
|
||||
@@ -21,7 +20,7 @@ void FootpathRailingsObject::Load()
|
||||
auto numImages = GetImageTable().GetCount();
|
||||
if (numImages != 0)
|
||||
{
|
||||
PreviewImageId = GfxObjectAllocateImages(GetImageTable().GetImages(), GetImageTable().GetCount());
|
||||
PreviewImageId = LoadImages();
|
||||
BridgeImageId = PreviewImageId + 37;
|
||||
RailingsImageId = PreviewImageId + 1;
|
||||
}
|
||||
@@ -39,7 +38,7 @@ void FootpathRailingsObject::Load()
|
||||
void FootpathRailingsObject::Unload()
|
||||
{
|
||||
LanguageFreeObjectString(NameStringId);
|
||||
GfxObjectFreeImages(PreviewImageId, GetImageTable().GetCount());
|
||||
UnloadImages();
|
||||
|
||||
NameStringId = 0;
|
||||
PreviewImageId = 0;
|
||||
|
||||
Reference in New Issue
Block a user