equal
deleted
inserted
replaced
425 |
425 |
426 SetClearUnderBridge(tile); |
426 SetClearUnderBridge(tile); |
427 break; |
427 break; |
428 |
428 |
429 case MP_STREET: { |
429 case MP_STREET: { |
430 uint town; |
|
431 if (!IsLevelCrossing(tile)) return CMD_ERROR; |
430 if (!IsLevelCrossing(tile)) return CMD_ERROR; |
432 |
431 |
433 /* This is a crossing, let's check if the direction is correct */ |
432 /* This is a crossing, let's check if the direction is correct */ |
434 if (GetCrossingRailBits(tile) != trackbit) return CMD_ERROR; |
433 if (GetCrossingRailBits(tile) != trackbit) return CMD_ERROR; |
435 |
434 |
436 if (!(flags & DC_EXEC)) |
435 if (!(flags & DC_EXEC)) |
437 return _price.remove_rail; |
436 return _price.remove_rail; |
438 |
437 |
439 town = (_m[tile].m3 == OWNER_TOWN) ? _m[tile].m2 : 0; |
438 MakeRoadNormal(tile, _m[tile].m3, GetCrossingRoadBits(tile), _m[tile].m2); |
440 MakeRoadNormal(tile, _m[tile].m3, GetCrossingRoadBits(tile), town); |
|
441 break; |
439 break; |
442 } |
440 } |
443 |
441 |
444 case MP_RAILWAY: |
442 case MP_RAILWAY: |
445 if (!IsPlainRailTile(tile)) |
443 if (!IsPlainRailTile(tile)) |