Go to the documentation of this file.
1 /* $Id: object_type.h 25844 2013-10-12 16:35:50Z frosch $ */
3 /*
4  * This file is part of OpenTTD.
5  * OpenTTD is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, version 2.
6  * OpenTTD is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
7  * See the GNU General Public License for more details. You should have received a copy of the GNU General Public License along with OpenTTD. If not, see <>.
8  */
12 #ifndef OBJECT_TYPE_H
13 #define OBJECT_TYPE_H
16 typedef uint16 ObjectType;
18 static const ObjectType OBJECT_TRANSMITTER = 0;
19 static const ObjectType OBJECT_LIGHTHOUSE = 1;
20 static const ObjectType OBJECT_STATUE = 2;
21 static const ObjectType OBJECT_OWNED_LAND = 3;
22 static const ObjectType OBJECT_HQ = 4;
24 static const ObjectType NUM_OBJECTS_PER_GRF = 255;
26 static const ObjectType NEW_OBJECT_OFFSET = 5;
27 static const ObjectType NUM_OBJECTS = 64000;
28 static const ObjectType INVALID_OBJECT_TYPE = 0xFFFF;
31 typedef uint32 ObjectID;
33 struct Object;
34 struct ObjectSpec;
36 static const ObjectID INVALID_OBJECT = 0xFFFFFFFF;
38 #endif /* OBJECT_TYPE_H */
static const ObjectType NUM_OBJECTS
Number of supported objects overall.
Definition: object_type.h:27
static const ObjectType OBJECT_TRANSMITTER
The large antenna.
Definition: object_type.h:18
static const ObjectType OBJECT_STATUE
Statue in towns.
Definition: object_type.h:20
Allow incrementing of ObjectClassID variables.
Definition: newgrf_object.h:60
static const ObjectID INVALID_OBJECT
An invalid object.
Definition: object_type.h:36
static const ObjectType NUM_OBJECTS_PER_GRF
Number of supported objects per NewGRF; limited to 255 to allow extending Action3 with an extended by...
Definition: object_type.h:24
An object, such as transmitter, on the map.
Definition: object_base.h:25
static const ObjectType NEW_OBJECT_OFFSET
Offset for new objects.
Definition: object_type.h:26
static const ObjectType OBJECT_OWNED_LAND
Owned land &#39;flag&#39;.
Definition: object_type.h:21
uint16 ObjectType
Types of objects.
Definition: object_type.h:16
uint32 ObjectID
Unique identifier for an object.
Definition: object_type.h:31
static const ObjectType INVALID_OBJECT_TYPE
An invalid object.
Definition: object_type.h:28
static const ObjectType OBJECT_HQ
HeadQuarter of a player.
Definition: object_type.h:22
static const ObjectType OBJECT_LIGHTHOUSE
The nice lighthouse.
Definition: object_type.h:19