The International Simutrans Forum

Simutrans Extended => Simutrans-Extended development => Topic started by: Junna on April 30, 2013, 10:05:35 PM

Title: Reservation loading errors seem to remain
Post by: Junna on April 30, 2013, 10:05:35 PM
This is most well examplified by aeroports.

Test map: http://www.mediafire.com/?oah7j4ocbn5h5o3

Three airport, two lines converging on one; upon loading (should be present in the save), the planes will become stuck due to incorrect reservations.

I believe this might be connected to the persistent bugs with chose signals, which do not work properly and often have one train running into the other upon loading. This also seems to occur on random other stations, most notable being where several different lines reverse at or run through the same platform at a station (without chose signals) after loading a save game, suggesting that the reservations are not properly saved.
Title: Re: Reservation loading errors seem to remain
Post by: jamespetts on April 30, 2013, 10:18:14 PM
Hmm - looking at this save, the only problem that I can find is that two aircraft seem to get stuck on the taxiway in the middle of the left to right runway (18/36 rather than 09/27) because they are both trying to go in opposite directions on the same part. This does not seem to be a reservation issue, but a design issue: use one way arrows to prevent this.

Generally, this airport design is inefficient: it has two runways, but only one can be used at once because they cross. There is no designation of a departure and arrival runway (this can be done by using one way signs, which may not be available in 0.8.4, but will be available in 0.9.0), which also reduces the efficiency of this airport.
Title: Re: Reservation loading errors seem to remain
Post by: Junna on April 30, 2013, 10:23:09 PM
Quote from: jamespetts on April 30, 2013, 10:18:14 PM
Hmm - looking at this save, the only problem that I can find is that two aircraft seem to get stuck on the taxiway in the middle of the left to right runway (18/36 rather than 09/27) because they are both trying to go in opposite directions on the same part. This does not seem to be a reservation issue, but a design issue: use one way arrows to prevent this.

Generally, this airport design is inefficient: it has two runways, but only one can be used at once because they cross. There is no designation of a departure and arrival runway (this can be done by using one way signs, which may not be available in 0.8.4, but will be available in 0.9.0), which also reduces the efficiency of this airport.

Well, it was just testing it... if it isn't related to the reservation issue, are you at least aware of that even more pressing problem? It's very troublesome because it is very tedious to replicate, and will occur only occasionally even when it is possible to replicate it.
Title: Re: Reservation loading errors seem to remain
Post by: jamespetts on April 30, 2013, 10:37:18 PM
Hmm - I didn't write the relevant part of the code, but the issue appears to be here:


if(route_index<takeoff  &&  route_index>1  &&  takeoff<last_index) {
// check, if tile occupied by a plane on ground
for(  uint8 i = 1;  i<gr->get_top();  i++  ) {
ding_t *d = gr->obj_bei(i);
if(  d->get_typ()==ding_t::aircraft  &&  ((aircraft_t *)d)->is_on_ground()  ) {
restart_speed = 0;
return false;
}


Both aircraft detect that the relevant tile is occupied by another aircraft on the ground. The program appears to be working as intended - the problem is that this airport does not separate by direction, so this (two aircraft heading in opposite directions on the same piece of taxiway) is apt to occur. Using one way arrows should solve this.
Title: Re: Reservation loading errors seem to remain
Post by: Junna on May 02, 2013, 02:40:28 AM
http://www.mediafire.com/?d5ov4ynx33xilir

Should example the reservation error at the goods station centred upon at loading. A train is erroneously trying to enter an occupied platform.
Title: Re: Reservation loading errors seem to remain
Post by: jamespetts on May 04, 2013, 05:14:26 PM
Hmm - this doesn't show the problem occurring - this shows the consequences of the problem having occurred. Can you give me steps so that I can reproduce the problem actually occurring?

Edit: Also, I cannot change anything, as the players are all password protected, and some vehicles/buildings are missing (including the locomotive on the train that appears to have gone the wrong way) as I do not have the latest version of your version of the pakset.
Title: Re: Reservation loading errors seem to remain
Post by: Junna on May 05, 2013, 11:49:10 AM
Ah, sorry.

http://www.mediafire.com/?27c39cn0zh7twy6

Pak.

http://www.mediafire.com/?08wyaxe7qh89xml

New save.
Now, go down to Syuri East station, it is just eastwards to where it loads; there, after the train in the platform presently departs, another will enter, and the one following it will ignore its presence and enter anyway, and they will become stuck.
Title: Re: Reservation loading errors seem to remain
Post by: jamespetts on May 05, 2013, 01:42:53 PM
Preliminary tests seem to show that the problem is related to having signals on junctions. In fact, the game won't let you build signals on junctions, but it is possible to build junctions on existing signals, which is how this seems to have arisen. I will have to look into this.

Edit: Further testing reveals this to be a bug in Standard. Reporting on the Standard forum...

Edit 2: Looking more closely, the signals are not placed on junctions at all. The issue with being able to bypass the prohibition on building signals on junctions by building junctions on signals appears to be a real issue (reported here (http://forum.simutrans.com/index.php?topic=11864.0)), but not related to this. Investigating further...

Edit 3: Have found and fixed the problem, which was related to the presence of waypoints on the route. Thank you for the report.