News:

Simutrans Forum Archive
A complete record of the old Simutrans Forum.

passengers dont take reassigned classes

Started by Ves, September 23, 2017, 12:51:28 PM

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

Ves

I think there are some bugs when reassigning classes. Look at this savegame:
http://simutrans-germany.com/files/upload/classes_GUI_vehicle_tests_4.sve

In order to easily see what classes the passengers belong to, you should use this branch where this information stands clear in the halt info window:
https://github.com/VictorErik/Simutrans-Experimental-Ves/tree/gui-classes

Here you will find a line with two white busses on the "(26) Line" going between "Bishop's Kesmere Town Hall Stop" and "Petwater Ponds Town Hall Railway Station".
Both of the busses have their classes reassigned from p_class[ 0 ] to p_class[ 1 ]. When the savegame was captured, I had just rearranged the classes on the two busses.
To make this easier to follow, I have written it in steps:
* passengers wont take the reassigned vehicle and dissappears: As you can see initially, there are plenty of passengers on both stations that want to take the bus. Mostly it is p_class[ 0 ] passengers, which rightly now have no way to get to their destination and they appears also to disapear from the stop, but there are also higher classes, which should still board the bus, however, it appears not to.
Slowly, all passengers wanting to go to the other station evaporates and no one wants to go, as if the line did not even exist.

* Resetting a reassigned vehicle doesnt help: Now open the class manager of the two vehicles, and set the classes back to p_class[ 0 ]. This doesnt make any difference. You would at least expect that approximately the same amount of passengers would start to show up, but none will be showing up at the stop.

The only solution I could come up with to make the passengers take the busses again, was to sell them and buy new ones. Then passengers (of all classes) started to turn up again, riding the busses.
So it appears that, the change of the classes also dont trigger the same "rerouting mechanism" as buying new vehicles does.

jamespetts

I think that I have now managed to fix this on the passenger-and-mail-classes branch. I have not yet incorporated your latest GUI code, as I wanted to leave that until after fixing this, but this now appears to work.

Would you be able to re-test to confirm? I should be most grateful.
Download Simutrans-Extended.

Want to help with development? See here for things to do for coding, and here for information on how to make graphics/objects.

Follow Simutrans-Extended on Facebook.

Ves

Hmm, I get a crash now.

How to reproduce:

* Open the same savegame as before (classes_GUI_vehicle_tests_4.sve).
* Delete the two white busses on the "(26) Line"
* Build two new identical busses and send out from depot
* When the busses are on the street and have started on their route, open their info window and reassign their classes to p_class[1]. Do this for both busses.
* Now just fast forward some time and the game will crash.

jamespetts

Thank you for testing that. I think that I have managed to fix this now - would you be able to re-test? I should be most grateful.
Download Simutrans-Extended.

Want to help with development? See here for things to do for coding, and here for information on how to make graphics/objects.

Follow Simutrans-Extended on Facebook.