src/aircraft_gui.cpp
changeset 7010 6f0d9f03180d
parent 7002 1bf6a62b0fcb
child 7049 0ebe47348074
equal deleted inserted replaced
7009:9992ccf17e58 7010:6f0d9f03180d
   123 			DrawString(13, 115, _patches.servint_ispercent?STR_SERVICING_INTERVAL_PERCENT:STR_883C_SERVICING_INTERVAL_DAYS, 0);
   123 			DrawString(13, 115, _patches.servint_ispercent?STR_SERVICING_INTERVAL_PERCENT:STR_883C_SERVICING_INTERVAL_DAYS, 0);
   124 		}
   124 		}
   125 
   125 
   126 		/* Draw Transfer credits text */
   126 		/* Draw Transfer credits text */
   127 		{
   127 		{
   128 			SetDParam(0, v->cargo_feeder_share);
   128 			SetDParam(0, v->cargo.FeederShare());
   129 			DrawString(60, 101, STR_FEEDER_CARGO_VALUE, 0);
   129 			DrawString(60, 101, STR_FEEDER_CARGO_VALUE, 0);
   130 		}
   130 		}
   131 
   131 
   132 		DrawAircraftImage(v, 3, 57, INVALID_VEHICLE);
   132 		DrawAircraftImage(v, 3, 57, INVALID_VEHICLE);
   133 
   133 
   150 					SetDParam(3, u->cargo_cap);
   150 					SetDParam(3, u->cargo_cap);
   151 					DrawString(60, y, (u->cargo_cap != 0) ? STR_A019_CAPACITY : STR_A01A_CAPACITY, 0);
   151 					DrawString(60, y, (u->cargo_cap != 0) ? STR_A019_CAPACITY : STR_A01A_CAPACITY, 0);
   152 					y += 14;
   152 					y += 14;
   153 				}
   153 				}
   154 
   154 
   155 				if (v->cargo_count != 0) {
   155 				uint cargo_count = v->cargo.Count();
       
   156 				if (cargo_count != 0) {
   156 
   157 
   157 					/* Cargo names (fix pluralness) */
   158 					/* Cargo names (fix pluralness) */
   158 					SetDParam(0, v->cargo_type);
   159 					SetDParam(0, v->cargo_type);
   159 					SetDParam(1, v->cargo_count);
   160 					SetDParam(1, cargo_count);
   160 					SetDParam(2, v->cargo_source);
   161 					SetDParam(2, v->cargo.Source());
   161 					DrawString(60, y, STR_8813_FROM, 0);
   162 					DrawString(60, y, STR_8813_FROM, 0);
   162 
   163 
   163 					y += 10;
   164 					y += 10;
   164 				}
   165 				}
   165 			} while ( (v=v->next) != NULL);
   166 			} while ( (v=v->next) != NULL);