From 0c099f4f700d15704c5ad919dcfcb4ef2a5a28a2 Mon Sep 17 00:00:00 2001 From: Celtic Minstrel Date: Tue, 14 Apr 2009 17:30:55 +0000 Subject: [PATCH] Name of town or outdoor section now displayed while editing terrain git-svn-id: http://openexile.googlecode.com/svn/trunk@15 4ebdad44-0ea0-11de-aab3-ff745001d230 --- osx/Scenario Editor/buttonmg.c | 2 +- osx/Scenario Editor/global.h | 2 +- osx/Scenario Editor/tactions.c | 28 ++++++++++++++++------------ 3 files changed, 18 insertions(+), 14 deletions(-) diff --git a/osx/Scenario Editor/buttonmg.c b/osx/Scenario Editor/buttonmg.c index c18e1202..2d948ea7 100644 --- a/osx/Scenario Editor/buttonmg.c +++ b/osx/Scenario Editor/buttonmg.c @@ -74,7 +74,7 @@ void set_lb(short slot, short mode, char *label, short do_draw) } left_button_status[slot] = mode; //sprintf((char *)data_store->strings_ls[slot], "%-39.39s", label); - sprintf((char *)data_store->strings_ls[slot], "%-39.39s", label); + sprintf((char *)data_store->strings_ls[slot], "%-50.50s", label); data_store->strings_ls[slot][39] = 0; if (do_draw > 0) draw_lb_slot(slot,0); diff --git a/osx/Scenario Editor/global.h b/osx/Scenario Editor/global.h index a2f0e866..902e6c21 100644 --- a/osx/Scenario Editor/global.h +++ b/osx/Scenario Editor/global.h @@ -25,7 +25,7 @@ #define RIGHT_AREA_HEIGHT 400 #define TER_RECT_UL_X 6 -#define TER_RECT_UL_Y 25 +#define TER_RECT_UL_Y 19 // Formerly 25 #define CDGT cd_retrieve_text_edit_str #define CDGN cd_retrieve_text_edit_num diff --git a/osx/Scenario Editor/tactions.c b/osx/Scenario Editor/tactions.c index 8d0505b4..9c4e5b31 100644 --- a/osx/Scenario Editor/tactions.c +++ b/osx/Scenario Editor/tactions.c @@ -3209,12 +3209,14 @@ void set_up_main_screen() void start_town_edit() { short i,j; - + char message[50]; small_any_drawn = FALSE; cen_x = max_dim[town_type] / 2; cen_y = max_dim[town_type] / 2; reset_lb(); - set_lb(0,2,"Editing town",0); - set_lb(NLS - 2,1,"Click border to scroll view.",0); + sprintf(message,"Editing Town %d",cur_town); + set_lb(0,2,message,0); + set_lb(NLS - 3,1,data_store->town_strs[0],0); + set_lb(NLS - 2,1,"(Click border to scroll view.)",0); set_lb(NLS - 1,11,"Back to Main Menu",0); overall_mode = 0; editing_town = TRUE; @@ -3238,12 +3240,14 @@ void start_town_edit() void start_out_edit() { short i,j; - + char message[50]; small_any_drawn = FALSE; cen_x = 24; cen_y = 24; reset_lb(); - set_lb(0,2,"Editing outdoors",0); - set_lb(NLS - 2,1,"Click border to scroll view.",0); + sprintf(message,"Editing outdoors (%d,%d)",cur_out.x,cur_out.y); + set_lb(0,2,message,0); + set_lb(NLS - 3,1,data_store->out_strs[0],0); + set_lb(NLS - 2,1,"(Click border to scroll view.)",0); set_lb(NLS - 1,11,"Back to Main Menu",0); overall_mode = 0; editing_town = FALSE; @@ -3256,12 +3260,12 @@ void start_out_edit() set_string("Drawing mode",""); place_location(); copied_spec = -1; - for (i = 0; i < 48; i++) - for (j = 0; j < 48; j++) - if (current_terrain.terrain[i][j] == 0) - current_ground = 0; - else if (current_terrain.terrain[i][j] == 2) - current_ground = 2; + for (i = 0; i < 48; i++) + for (j = 0; j < 48; j++) + if (current_terrain.terrain[i][j] == 0) + current_ground = 0; + else if (current_terrain.terrain[i][j] == 2) + current_ground = 2; } // mode 0 - initial shut down, 1 - no town, 2 - no out, 3 - no town or out 4 - all menus on