show ports
This commit is contained in:
@@ -173,7 +173,7 @@ EntityId BuildingSystem::place(BuildingType type, QPoint anchor,
|
||||
{
|
||||
m_belts.placeBelt(anchor, rotation);
|
||||
m_tileOccupancy[{anchor.x(), anchor.y()}] = id;
|
||||
m_beltEntities[id] = BeltEntry{anchor, BuildingType::Belt};
|
||||
m_beltEntities[id] = BeltEntry{anchor, BuildingType::Belt, rotation, rotation};
|
||||
return id;
|
||||
}
|
||||
|
||||
@@ -187,7 +187,7 @@ EntityId BuildingSystem::place(BuildingType type, QPoint anchor,
|
||||
const Rotation outB = mask.outputPorts[1].direction;
|
||||
m_belts.placeSplitter(anchor, outA, outB);
|
||||
m_tileOccupancy[{anchor.x(), anchor.y()}] = id;
|
||||
m_beltEntities[id] = BeltEntry{anchor, BuildingType::Splitter};
|
||||
m_beltEntities[id] = BeltEntry{anchor, BuildingType::Splitter, outA, outB};
|
||||
return id;
|
||||
}
|
||||
|
||||
@@ -663,9 +663,11 @@ std::vector<BuildingSystem::BeltTileInfo> BuildingSystem::allBeltTiles() const
|
||||
for (const std::map<EntityId, BeltEntry>::value_type& kv : m_beltEntities)
|
||||
{
|
||||
BeltTileInfo info;
|
||||
info.id = kv.first;
|
||||
info.tile = kv.second.tile;
|
||||
info.type = kv.second.type;
|
||||
info.id = kv.first;
|
||||
info.tile = kv.second.tile;
|
||||
info.type = kv.second.type;
|
||||
info.directionA = kv.second.directionA;
|
||||
info.directionB = kv.second.directionB;
|
||||
result.push_back(info);
|
||||
}
|
||||
return result;
|
||||
|
||||
Reference in New Issue
Block a user