Fix terraforming tool sizes bigger than 7 being written to the map window

This commit is contained in:
Michael Steenbeek 2015-03-11 11:11:19 +01:00
parent 9340c99a1e
commit 1f80802dbf
1 changed files with 2 additions and 1 deletions

View File

@ -571,7 +571,8 @@ static void window_map_paint()
window_draw_widgets(w, dpi);
// FEATURE larger land tool size support
if (RCT2_GLOBAL(RCT2_ADDRESS_LAND_TOOL_SIZE, sint16) > 7) {
if ((RCT2_GLOBAL(RCT2_ADDRESS_LAND_TOOL_SIZE, sint16) > 7) &&
(RCT2_GLOBAL(RCT2_ADDRESS_TOOL_WINDOWCLASS, uint8) == WC_MAP)) {
RCT2_GLOBAL(0x009BC677, char) = FORMAT_BLACK;
RCT2_GLOBAL(0x009BC678, char) = FORMAT_COMMA16;
RCT2_GLOBAL(0x009BC679, char) = 0;