MCPcopy Create free account
hub / github.com/OpenApoc/OpenApoc / checkItemCollision

Method checkItemCollision

game/state/battle/battleitem.cpp:143–151  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

141}
142
143Collision BattleItem::checkItemCollision(Vec3<float> previousPosition, Vec3<float> nextPosition)
144{
145 if (collisionIgnoredTicks > 0)
146 return {};
147 Collision c = tileObject->map.findCollision(
148 previousPosition, nextPosition, {},
149 ownerInvulnerableTicks > 0 ? item->ownerUnit->tileObject : nullptr);
150 return c;
151}
152
153void BattleItem::updateTB(GameState &state) { item->updateTB(state); }
154

Callers

nothing calls this directly

Calls 1

findCollisionMethod · 0.80

Tested by

no test coverage detected