MCPcopy Create free account
hub / github.com/OpenDUNE/OpenDUNE / Tile_AddTileDiff

Function Tile_AddTileDiff

src/tile.c:55–63  ·  view source on GitHub ↗

* Adds two tiles together. * * @param from The origin. * @param diff The difference. * @return The new coordinates. */

Source from the content-addressed store, hash-verified

53 * @return The new coordinates.
54 */
55tile32 Tile_AddTileDiff(tile32 from, tile32 diff)
56{
57 tile32 result;
58
59 result.x = from.x + diff.x;
60 result.y = from.y + diff.y;
61
62 return result;
63}
64
65/**
66 * Centers the offset of the tile.

Callers 3

Structure_DamageFunction · 0.85
Map_UpdateAroundFunction · 0.85
Tools_Index_GetTileFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected