# HG changeset patch # User glx # Date 1199980294 0 # Node ID 2114c740d1dd4dd068ea9b2e6dd4913aae93dd1d # Parent 4648f777da552bdf7e8fb35c39f1a301fc99be51 (svn r11806) -Fix (r11793) [FS#1638]: sign inversion when updating income and expenses diff --git a/src/players.cpp b/src/players.cpp --- a/src/players.cpp +++ b/src/players.cpp @@ -204,14 +204,14 @@ 1 << EXPENSES_ROADVEH_INC | 1 << EXPENSES_AIRCRAFT_INC | 1 << EXPENSES_SHIP_INC, cost.GetExpensesType())) { - p->cur_economy.income += cost.GetCost(); + p->cur_economy.income -= cost.GetCost(); } else if (HasBit(1 << EXPENSES_TRAIN_RUN | 1 << EXPENSES_ROADVEH_RUN | 1 << EXPENSES_AIRCRAFT_RUN | 1 << EXPENSES_SHIP_RUN | 1 << EXPENSES_PROPERTY | 1 << EXPENSES_LOAN_INT, cost.GetExpensesType())) { - p->cur_economy.expenses += cost.GetCost(); + p->cur_economy.expenses -= cost.GetCost(); } InvalidatePlayerWindows(p);