1
0
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:
Michael Steenbeek
2018-02-13 15:20:55 +01:00
parent 3ea6a3ea2f
commit a408747c4c
5 changed files with 23 additions and 19 deletions

View File

@@ -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);