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

Method findConnectablePart

source/game/StarDungeonGenerator.cpp:1584–1595  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1582}
1583
1584List<Dungeon::ConnectorConstPtr> DungeonGenerator::findConnectablePart(Dungeon::ConnectorConstPtr connector) const {
1585 List<Dungeon::ConnectorConstPtr> result;
1586 for (auto const& partPair : m_def->parts()) {
1587 if (partPair.second->doesNotConnectTo(connector->part()))
1588 continue;
1589 for (auto const& connection : partPair.second->connections()) {
1590 if (connection->connectsTo(connector))
1591 result.append(connection);
1592 }
1593 }
1594 return result;
1595}
1596
1597DungeonDefinitionConstPtr DungeonGenerator::definition() const {
1598 return m_def;

Callers

nothing calls this directly

Calls 4

doesNotConnectToMethod · 0.80
partMethod · 0.80
connectsToMethod · 0.80
appendMethod · 0.45

Tested by

no test coverage detected