139 } |
140 } |
140 |
141 |
141 FOR_ALL_VEHICLES(v) { |
142 FOR_ALL_VEHICLES(v) { |
142 /* Code ripped from CmdStartStopTrain. Can't call it, because of |
143 /* Code ripped from CmdStartStopTrain. Can't call it, because of |
143 * ownership problems, so we'll duplicate some code, for now */ |
144 * ownership problems, so we'll duplicate some code, for now */ |
144 if (v->type == VEH_TRAIN) |
|
145 v->u.rail.days_since_order_progr = 0; |
|
146 v->vehstatus |= VS_STOPPED; |
145 v->vehstatus |= VS_STOPPED; |
147 InvalidateWindowWidget(WC_VEHICLE_VIEW, v->index, STATUS_BAR); |
146 InvalidateWindowWidget(WC_VEHICLE_VIEW, v->index, STATUS_BAR); |
148 InvalidateWindow(WC_VEHICLE_DEPOT, v->tile); |
147 InvalidateWindow(WC_VEHICLE_DEPOT, v->tile); |
149 } |
148 } |
150 return true; |
149 return true; |
1231 FOR_ALL_PLAYERS(p) { |
1230 FOR_ALL_PLAYERS(p) { |
1232 char buffer[512]; |
1231 char buffer[512]; |
1233 |
1232 |
1234 if (!p->is_active) continue; |
1233 if (!p->is_active) continue; |
1235 |
1234 |
|
1235 const NetworkPlayerInfo *npi = &_network_player_info[p->index]; |
|
1236 |
1236 GetString(buffer, STR_00D1_DARK_BLUE + _player_colors[p->index], lastof(buffer)); |
1237 GetString(buffer, STR_00D1_DARK_BLUE + _player_colors[p->index], lastof(buffer)); |
1237 IConsolePrintF(8, "#:%d(%s) Company Name: '%s' Year Founded: %d Money: %d Loan: %d Value: %" OTTD_PRINTF64 "d (T:%d, R:%d, P:%d, S:%d)", |
1238 IConsolePrintF(8, "#:%d(%s) Company Name: '%s' Year Founded: %d Money: %d Loan: %d Value: %" OTTD_PRINTF64 "d (T:%d, R:%d, P:%d, S:%d) %sprotected", |
1238 p->index + 1, buffer, _network_player_info[p->index].company_name, p->inaugurated_year, p->player_money, p->current_loan, CalculateCompanyValue(p), |
1239 p->index + 1, buffer, npi->company_name, p->inaugurated_year, p->player_money, p->current_loan, CalculateCompanyValue(p), |
1239 /* trains */ _network_player_info[p->index].num_vehicle[0], |
1240 /* trains */ npi->num_vehicle[0], |
1240 /* lorry + bus */ _network_player_info[p->index].num_vehicle[1] + _network_player_info[p->index].num_vehicle[2], |
1241 /* lorry + bus */ npi->num_vehicle[1] + npi->num_vehicle[2], |
1241 /* planes */ _network_player_info[p->index].num_vehicle[3], |
1242 /* planes */ npi->num_vehicle[3], |
1242 /* ships */ _network_player_info[p->index].num_vehicle[4]); |
1243 /* ships */ npi->num_vehicle[4], |
|
1244 /* protected */ StrEmpty(npi->password) ? "un" : ""); |
1243 } |
1245 } |
1244 |
1246 |
1245 return true; |
1247 return true; |
1246 } |
1248 } |
1247 |
1249 |
1495 IConsoleCmdRegister("ls", ConListFiles); |
1510 IConsoleCmdRegister("ls", ConListFiles); |
1496 IConsoleCmdRegister("cd", ConChangeDirectory); |
1511 IConsoleCmdRegister("cd", ConChangeDirectory); |
1497 IConsoleCmdRegister("pwd", ConPrintWorkingDirectory); |
1512 IConsoleCmdRegister("pwd", ConPrintWorkingDirectory); |
1498 IConsoleCmdRegister("clear", ConClearBuffer); |
1513 IConsoleCmdRegister("clear", ConClearBuffer); |
1499 IConsoleCmdRegister("patch", ConPatch); |
1514 IConsoleCmdRegister("patch", ConPatch); |
|
1515 IConsoleCmdRegister("list_patches", ConListPatches); |
1500 |
1516 |
1501 IConsoleAliasRegister("dir", "ls"); |
1517 IConsoleAliasRegister("dir", "ls"); |
1502 IConsoleAliasRegister("del", "rm %+"); |
1518 IConsoleAliasRegister("del", "rm %+"); |
1503 IConsoleAliasRegister("newmap", "newgame"); |
1519 IConsoleAliasRegister("newmap", "newgame"); |
1504 IConsoleAliasRegister("new_map", "newgame"); |
1520 IConsoleAliasRegister("new_map", "newgame"); |