(svn r1568) made an enum of train subtypes to make the code more readable

This commit is contained in:
bjarni
2005-01-19 19:15:03 +00:00
parent e4a3d284b2
commit 2fd3553d78
12 changed files with 73 additions and 68 deletions

View File

@@ -271,9 +271,9 @@ static bool HandleOrderVehClick(Vehicle *v, Vehicle *u, Window *w)
if (u->type != v->type)
return false;
if (u->type == VEH_Train && u->subtype != 0) {
if (u->type == VEH_Train && u->subtype != TS_Front_Engine) {
u = GetFirstVehicleInChain(u);
if (u->subtype != 0)
if (u->subtype != TS_Front_Engine)
return false;
}