79 t.
m2() = index.base();
82 t.
m5() = index.base() >> 16;
constexpr T SB(T &x, const uint8_t s, const uint8_t n, const U d)
Set n bits in x starting at bit s to d.
Wrapper class to abstract away the way the tiles are stored.
uint8_t & m5()
General purpose.
uint8_t & m4()
General purpose.
uint8_t & m6()
General purpose.
uint8_t & m7()
Primarily used for newgrf support.
uint8_t & m3()
General purpose.
uint16_t & m8()
General purpose.
uint16_t & m2()
Primarily used for indices to towns, industries and stations.
void MakeObject(Tile t, Owner o, ObjectID index, WaterClass wc, uint8_t random)
Make an Object tile.
bool IsObjectTypeTile(Tile t, ObjectType type)
Check whether a tile is a object tile of a specific type.
uint8_t GetObjectRandomBits(Tile t)
Get the random bits of this tile.
ObjectType GetObjectType(Tile t)
Gets the ObjectType of the given object tile.
bool IsObjectType(Tile t, ObjectType type)
Check whether the object on a tile is of a specific type.
ObjectID GetObjectIndex(Tile t)
Get the index of which object this tile is attached to.
Types related to object tiles.
uint16_t ObjectType
Types of objects.
PoolID< uint32_t, struct ObjectIDTag, 0xFF0000, 0xFFFFFFFF > ObjectID
Unique identifier for an object.
Templated helper to make a PoolID a single POD value.
static bool IsTileType(Tile tile, TileType type)
Checks if a tile is a given tiletype.
void SetTileType(Tile tile, TileType type)
Set the type of a tile.
void SetTileOwner(Tile tile, Owner owner)
Sets the owner of a tile.
@ MP_OBJECT
Contains objects such as transmitters and owned land.
Map accessors for water tiles.
void SetWaterClass(Tile t, WaterClass wc)
Set the water class at a tile.
WaterClass
classes of water (for WaterTileType::Clear water tile type).