The International Simutrans Forum

 

Author Topic: [FIX] Bridges over runways  (Read 5697 times)

0 Members and 1 Guest are viewing this topic.

Offline eipi

  • *
  • Posts: 67
  • Languages: DE EN FR ES C++ LaTeX
[FIX] Bridges over runways
« on: July 01, 2012, 07:42:18 AM »
I found it is possible to build bridges over runways.
Disabling this is trivial, just add this piece of code to ./bauer/fabrikbauer.cc (line ~295 or so):

Code: [Select]
if(!ribi  &&  gr2->get_grund_hang()==hang_typ(zv)) {
// end on slope, way (or ribi) is missing
// check if another way is blocking us
if(wegtyp!=powerline_wt && (!gr2->hat_wege() || gr2->hat_weg(wegtyp))) {
return pos;
}
if (wegtyp == powerline_wt && (!gr2->hat_wege() || gr2->find<leitung_t>())) {
return pos;
}
}
}
}
//change here
if (gr2->hat_weg(air_wt)){ // no bridge crossing
break;
}
//end change
} while(  !gr1  &&  // no bridge is crossing
(!gr2 || (gr2->get_grund_hang()==hang_t::flach  &&  gr2->get_weg_hang()==hang_t::flach)  ||  gr2->get_hoehe()<pos.z )  &&  // ground stays below bridge
(!ai_bridge || length <= welt->get_settings().way_max_bridge_len) // not too long in case of AI
);

I tried to enable bridges over taxiways that are not adjacent to a runway but I had no luck.
If I think about it, disabling bridges over runways and taxiways entirely is not a constraint, especially when playing in the 1980s or later when the airplanes are so big that they don't fit under a bridge. :)

Offline prissi

  • Developer
  • Administrator
  • *
  • Posts: 9585
  • Languages: De,EN,JP
Re: [FIX] Bridges over runways
« Reply #1 on: July 01, 2012, 09:07:20 AM »
sytem_type==1 is runway. But you need also to check for lower tiles, crossing a runways is never ever allowed ...

Offline AP

  • Devotee
  • *
  • Posts: 1202
  • Languages: EN
Re: [FIX] Bridges over runways
« Reply #2 on: July 01, 2012, 04:50:51 PM »
Hmm. There are a number of airports with level crossings on runways, either road or rail, so that should not be precluded. And obviously running things in tunnels underneath is rather important too.

Because such things are interesting, some photos:

Sydney Airport (formerly, but I liked the sign. Info about a crash that occurred there...)


Gisborne airport, NZ


Gibraltar airport (twice)





Wynyard Airport, Tasmania
Wynyard Tasmania Airport

Manakara Airport, Madagascar
Manakara, Madagascar Airport

There's also:
Peshawar International Airport, Pakistan (still)
Bari Palese airport ,Italy (formerly)
Le Touquet, France (formerly)
Tomahawk Airport, Wisconsin (formerly)

Also on military runways at a number of places worldwide, notably when jet engines needed longer runways and the railway or road was in the way.
« Last Edit: July 01, 2012, 05:01:38 PM by AP »

Offline Ters

  • Coder/patcher
  • Devotee
  • *
  • Posts: 5558
  • Languages: EN, NO
Re: [FIX] Bridges over runways
« Reply #3 on: July 01, 2012, 05:42:08 PM »
Strange, the picture illustrating Gisborne airport on Wikipedia has the same train, at the same spot, with the same smoke, but without colors and airplane.

Offline AP

  • Devotee
  • *
  • Posts: 1202
  • Languages: EN
Re: [FIX] Bridges over runways
« Reply #4 on: July 01, 2012, 06:17:19 PM »
Hmm, odd. I suppose though it's possible the same locomotives/rolling stock worked the route for quite some time. (Or maybe photoshop has been employed... thought it would be odd to go to the effort of colourising an image when adding a plane in)

Offline Ters

  • Coder/patcher
  • Devotee
  • *
  • Posts: 5558
  • Languages: EN, NO
Re: [FIX] Bridges over runways
« Reply #5 on: July 01, 2012, 07:01:02 PM »
A non-photoshoped solution would take a coincidence beyond belief. Not only was the same train on the exact same spot, but the airflow and piston strokes were also identical in order to produce exactly the same smoke distribution.

Offline MagnusA

  • *
  • Posts: 35
  • Languages: SV, EN
Re: [FIX] Bridges over runways
« Reply #6 on: July 03, 2012, 07:10:24 AM »
According to the "metadata" of the Wikipedia picture of Gisborne airport Photoshop has been used. http://commons.wikimedia.org/wiki/File:DCIM_2019.jpg Maybe the plane has been removed?

Offline prissi

  • Developer
  • Administrator
  • *
  • Posts: 9585
  • Languages: De,EN,JP
Re: [FIX] Bridges over runways
« Reply #7 on: July 03, 2012, 08:36:23 AM »
Togethers with the stripes on the runway ... it lookslike that. On wikipedia also the top is cropped.

Maybe the original is copyrighted and the guy wanted to make some CC from it?