(svn r23075) -Codechange: Add GetGRF() and GetGRFID() methods to Engine and Vehicle to simplify code.
This commit is contained in:
@@ -192,7 +192,7 @@ Money Ship::GetRunningCost() const
|
||||
{
|
||||
const Engine *e = this->GetEngine();
|
||||
uint cost_factor = GetVehicleProperty(this, PROP_SHIP_RUNNING_COST_FACTOR, e->u.ship.running_cost);
|
||||
return GetPrice(PR_RUNNING_SHIP, cost_factor, e->grf_prop.grffile);
|
||||
return GetPrice(PR_RUNNING_SHIP, cost_factor, e->GetGRF());
|
||||
}
|
||||
|
||||
void Ship::OnNewDay()
|
||||
|
Reference in New Issue
Block a user