Skip to content

Commit

Permalink
Use overmapbuffer.place_special in debug special placement
Browse files Browse the repository at this point in the history
This brings debug placement more in line with the placement done during
map generation, e.g. it will make connections, record placement into the
data structure tying overmap terrains to the special that placed them,
and so on.
  • Loading branch information
ralreegorganon committed Dec 17, 2018
1 parent 2240120 commit 44e1c4a
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions src/overmap_ui.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1151,10 +1151,9 @@ tripoint display( const tripoint &orig, const draw_data_t &data = draw_data_t()
overmap_buffer.ter( curs ) = uistate.place_terrain->id.id();
overmap_buffer.set_seen( curs.x, curs.y, curs.z, true );
} else {
overmap_buffer.place_special( *uistate.place_special, curs, uistate.omedit_rotation, false, true );
for( const auto &s_ter : uistate.place_special->terrains ) {
const tripoint pos = curs + om_direction::rotate( s_ter.p, uistate.omedit_rotation );

overmap_buffer.ter( pos ) = s_ter.terrain->get_rotated( uistate.omedit_rotation );
overmap_buffer.set_seen( pos.x, pos.y, pos.z, true );
}
}
Expand Down

0 comments on commit 44e1c4a

Please sign in to comment.