From 354058341b8500cbb0075c0c568ec12063e84fe7 Mon Sep 17 00:00:00 2001 From: celestar Date: Tue, 21 Jun 2005 16:28:17 +0000 Subject: (svn r2468) -Codechange: Got rid of DEREF_PLAYER and replaced it by GetPlayer --- main_gui.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'main_gui.c') diff --git a/main_gui.c b/main_gui.c index df618e865..760f8f943 100644 --- a/main_gui.c +++ b/main_gui.c @@ -84,7 +84,7 @@ void HandleOnEditText(WindowEvent *e) NetworkServer_HandleChat(NETWORK_ACTION_CHAT + (id & 0xFF), id & 0xFF, (id >> 8) & 0xFF, e->edittext.str, NETWORK_SERVER_INDEX); break; case 3: { /* Give money, you can only give money in excess of loan */ - const Player *p = DEREF_PLAYER(_current_player); + const Player *p = GetPlayer(_current_player); int32 money = min(p->money64 - p->current_loan, atoi(e->edittext.str) / GetCurrentCurrencyRate()); char msg[20]; @@ -329,7 +329,7 @@ static void MenuClickShowAir(int index) static void MenuClickBuildRail(int index) { - Player *p = DEREF_PLAYER(_local_player); + Player *p = GetPlayer(_local_player); _last_built_railtype = min(index, p->max_railtype-1); ShowBuildRailToolbar(_last_built_railtype, -1); } @@ -941,7 +941,7 @@ static void ToolbarZoomOutClick(Window *w) static void ToolbarBuildRailClick(Window *w) { - Player *p = DEREF_PLAYER(_local_player); + Player *p = GetPlayer(_local_player); Window *w2; w2 = PopupMainToolbMenu(w, 457, 19, STR_1015_RAILROAD_CONSTRUCTION, p->max_railtype); WP(w2,menu_d).sel_index = _last_built_railtype; @@ -2211,7 +2211,7 @@ static void StatusBarWndProc(Window *w, WindowEvent *e) { switch (e->event) { case WE_PAINT: { - const Player *p = (_local_player == OWNER_SPECTATOR) ? NULL : DEREF_PLAYER(_local_player); + const Player *p = (_local_player == OWNER_SPECTATOR) ? NULL : GetPlayer(_local_player); DrawWindowWidgets(w); SetDParam(0, _date); -- cgit v1.2.3-54-g00ecf