object_base.h File Reference

Base for all objects. More...

#include "core/pool_type.hpp"
#include "object_type.h"
#include "tilearea_type.h"
#include "town_type.h"
#include "date_type.h"
#include "core/smallvec_type.hpp"

Go to the source code of this file.

Data Structures

struct  Object
 An object, such as transmitter, on the map. More...
struct  ClearedObjectArea
 Keeps track of removed objects during execution/testruns of commands. More...

Defines

#define FOR_ALL_OBJECTS_FROM(var, start)   FOR_ALL_ITEMS_FROM(Object, object_index, var, start)
#define FOR_ALL_OBJECTS(var)   FOR_ALL_OBJECTS_FROM(var, 0)

Typedefs

typedef Pool< Object, ObjectID, 64, 64000 > ObjectPool

Functions

ClearedObjectAreaFindClearedObject (TileIndex tile)
 Find the entry in _cleared_object_areas which occupies a certain tile.

Variables

ObjectPool _object_pool
SmallVector< ClearedObjectArea, 4 > _cleared_object_areas

Detailed Description

Base for all objects.

Definition in file object_base.h.


Function Documentation

ClearedObjectArea* FindClearedObject ( TileIndex  tile  ) 

Find the entry in _cleared_object_areas which occupies a certain tile.

Parameters:
tile Tile of interest
Returns:
Occupying entry, or NULL if none

Definition at line 402 of file object_cmd.cpp.

References SmallVector< T, S >::Begin(), and SmallVector< T, S >::End().

Referenced by CmdBuildTunnel(), CmdLandscapeClear(), and CmdTerraformLand().


Generated on Mon May 9 05:19:10 2011 for OpenTTD by  doxygen 1.6.1