MCPcopy Create free account
hub / github.com/OpenStarbound/OpenStarbound / forEachTileAt

Method forEachTileAt

source/game/StarDungeonTMXPart.cpp:93–105  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

91 }
92
93 bool TMXMap::forEachTileAt(Vec2I pos, TileCallback const& callback) const {
94 for (auto const& layer : tileLayers()) {
95 if (layer->forEachTileAt(pos, this, callback))
96 return true;
97 }
98
99 for (auto const& group : objectGroups()) {
100 if (group->forEachTileAt(pos, this, callback))
101 return true;
102 }
103
104 return false;
105 }
106
107 bool TMXTileLayer::forEachTileAt(Vec2I pos, TMXMap const* map, TileCallback const& callback) const {
108 Vec2I tilePos(pos.x(), map->height() - 1 - pos.y());

Callers 1

tileUsesPlacesMethod · 0.45

Calls 6

xMethod · 0.80
yMethod · 0.80
heightMethod · 0.45
containsMethod · 0.45
centerMethod · 0.45
minMethod · 0.45

Tested by

no test coverage detected