mirror of
https://github.com/OpenRCT2/OpenRCT2
synced 2026-01-25 15:54:31 +01:00
Use object_entry_get_type() throughout
This commit is contained in:
@@ -26,6 +26,8 @@
|
||||
#include "FootpathObject.h"
|
||||
#include "LargeSceneryObject.h"
|
||||
#include "Object.h"
|
||||
#include "ObjectLimits.h"
|
||||
#include "ObjectList.h"
|
||||
#include "ObjectFactory.h"
|
||||
#include "RideObject.h"
|
||||
#include "SceneryGroupObject.h"
|
||||
@@ -34,9 +36,6 @@
|
||||
#include "WallObject.h"
|
||||
#include "WaterObject.h"
|
||||
|
||||
#include "../object/Object.h"
|
||||
#include "ObjectLimits.h"
|
||||
|
||||
class ReadObjectContext : public IReadObjectContext
|
||||
{
|
||||
private:
|
||||
@@ -164,7 +163,7 @@ namespace ObjectFactory
|
||||
Object * CreateObject(const rct_object_entry &entry)
|
||||
{
|
||||
Object * result;
|
||||
uint8 objectType = entry.flags & 0x0F;
|
||||
uint8 objectType = object_entry_get_type(&entry);
|
||||
switch (objectType) {
|
||||
case OBJECT_TYPE_RIDE:
|
||||
result = new RideObject(entry);
|
||||
|
||||
Reference in New Issue
Block a user