File diff r15959:4236f491bc28 → r15960:9a2091bc3647
src/object_base.h
Show inline comments
 
@@ -17,24 +17,25 @@
 
#include "tilearea_type.h"
 
#include "town_type.h"
 
#include "date_type.h"
 

	
 
typedef Pool<Object, ObjectID, 64, 64000> ObjectPool;
 
extern ObjectPool _object_pool;
 

	
 
/** An object, such as transmitter, on the map. */
 
struct Object : ObjectPool::PoolItem<&_object_pool> {
 
	Town *town;        ///< Town the object is built in
 
	TileArea location; ///< Location of the object
 
	Date build_date;   ///< Date of construction
 
	byte colour;        ///< Colour of the object, for display purpose
 

	
 
	/** Make sure the object isn't zeroed. */
 
	Object() {}
 
	/** Make sure the right destructor is called as well! */
 
	~Object() {}
 

	
 
	/**
 
	 * Get the object associated with a tile.
 
	 * @param tile The tile to fetch the object for.
 
	 * @return The object.
 
	 */
 
	static Object *GetByTile(TileIndex tile);