@@ -159,52 +159,51 @@ void DrawPlayerFace(uint32 face, int col
if (val < 3) {
DrawSprite((flag&2 ? 0x3D1 : 0x37F) + val, x, y);
}
/* draw the glasses */
{
uint val = GB(face, 28, 3);
if (!(flag&2)) {
if (val<=1) {
DrawSprite(0x347 + val, x, y);
} else {
DrawSprite(0x3AE + val, x, y);
void InvalidatePlayerWindows(Player *p)
uint pid = p->index;
if ( (byte)pid == _local_player)
InvalidateWindow(WC_STATUS_BAR, 0);
PlayerID pid = p->index;
if (pid == _local_player) InvalidateWindow(WC_STATUS_BAR, 0);
InvalidateWindow(WC_FINANCES, pid);
bool CheckPlayerHasMoney(int32 cost)
if (cost > 0) {
uint pid = _current_player;
if (pid < MAX_PLAYERS && cost > GetPlayer(pid)->player_money) {
SetDParam(0, cost);
_error_message = STR_0003_NOT_ENOUGH_CASH_REQUIRES;
return false;
return true;
static void SubtractMoneyFromAnyPlayer(Player *p, int32 cost)
p->money64 -= cost;
UpdatePlayerMoney32(p);
p->yearly_expenses[0][_yearly_expenses_type] += cost;
if ( ( 1 << _yearly_expenses_type ) & (1<<7|1<<8|1<<9|1<<10))