src/newgrf.cpp
changeset 6126 40a18030c3aa
parent 6119 b47985557d1e
child 6140 22c9279c3bbd
equal deleted inserted replaced
6125:492a1c0440af 6126:40a18030c3aa
   325 					if (rvi[i].railveh_type == RAILVEH_MULTIHEAD) {
   325 					if (rvi[i].railveh_type == RAILVEH_MULTIHEAD) {
   326 						// adjust power and running cost if needed
   326 						// adjust power and running cost if needed
   327 						rvi[i].power *= 2;
   327 						rvi[i].power *= 2;
   328 						rvi[i].running_cost_base *= 2;
   328 						rvi[i].running_cost_base *= 2;
   329 					}
   329 					}
   330 					rvi[i].railveh_type = RAILVEH_SINGLEHEAD;
   330 					rvi[i].railveh_type = rvi[i].power == 0 ?
       
   331 						RAILVEH_WAGON : RAILVEH_SINGLEHEAD;
   331 				}
   332 				}
   332 			}
   333 			}
   333 			break;
   334 			break;
   334 
   335 
   335 		case 0x14: /* Cargo capacity */
   336 		case 0x14: /* Cargo capacity */