Skip to content

Commit

Permalink
walls: Adjust wall orientation next to new hardpoints.
Browse files Browse the repository at this point in the history
Wall orientation should no longer depend on whether the wall or the hardpoint was built first.
  • Loading branch information
Cyp committed Nov 17, 2011
1 parent 42f57b6 commit 312b4a2
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions src/structure.cpp
Expand Up @@ -1423,10 +1423,10 @@ STRUCTURE* buildStructureDir(STRUCTURE_STATS *pStructureType, UDWORD x, UDWORD y
return NULL;
}

if (!FromSave && (pStructureType->type == REF_WALL || pStructureType->type == REF_GATE))
if (!FromSave && isWallCombiningStructureType(pStructureType))
{
wallType = structChooseWallType(player, map_coord(x), map_coord(y));
if (wallType == WALL_CORNER && pStructureType->type != REF_GATE)
wallType = structChooseWallType(player, map_coord(x), map_coord(y)); // This makes neighbouring walls match us, even if we're a hardpoint, not a wall.
if (wallType == WALL_CORNER && pStructureType->type == REF_WALL)
{
if (pStructureType->asFuncList[0]->type == WALL_TYPE)
{
Expand Down

0 comments on commit 312b4a2

Please sign in to comment.