[Patch] Leave station if new Vehicle arrives

Forum for technical discussions regarding development. If you have a general suggestion, problem or comment, please use one of the other forums.

Moderator: OpenTTD Developers

Post Reply

how do you like the new stop loading types?

Poll ended at 24 Sep 2010 14:16

It dosent work!
0
No votes
Timetable dose the same job.
0
No votes
unusefull, don't know what i have from it.
0
No votes
It's ok but i don't missed it.
0
No votes
I like it.
3
100%
 
Total votes: 3

doener
Engineer
Engineer
Posts: 11
Joined: 31 Aug 2010 12:49

[Patch] Leave station if new Vehicle arrives

Post by doener »

[Description]
I know this scenario, i have A LOT of planes and i dont want that empty plains flying around, so i select full load. Now i have landing planes wich are full but cant be unloaded because the airport is full with loading planes. I get not much money because the people are sitting along time in the plane while it is loading. and i pay for not moving planes. also the rating of the airport is not good because the traveltime is long.

The same also happens with trains, busses/trucks, ships.
with this patch you can select that the vehicle can also leave the station if another vehicle with same shared order arrives.
the vehicle is not full but you get money because the goods inside didn't stay so long int the vehicle.

because it dosent make sens on each station (loading goods) its selectable per order and per vehicle.

With patch version 0.3a
Now i included 6 options in the drop down box for the loading behaviour... also added some strings for german and english language
from this 6 options currently only 4 are working:

(full load any/all) leave if vehicle with same shared orders arrives
(full load any/all) leave if any vehicle arrives.

(full load any/all) leave if vehicle loading the same checks only the loading type of the first vehicle in chain. so currently not usefull for trains.

Actually the unload checks are commentet out, i changed the unload flags to use only 2 bit instead of 4 and used the new 2 bit to save the selected leave station option. so loading old savegames can make the orders wehre you used some unload types to change the unload/stop load type if ure using my patched binary.

I dont know what i broke all with it maybe some one can test it?


[DONE]
*if new Vehicle arrives and other vehicles are loading they get notified over the arrived Vehicle.
and previeus loading train leaves the station.
*notification dosent break the unloading prozess.
*if there is enough to load vehicle gehts full loaded before it leaves.
*now you can select over a drop down menu which stop loading option you want to use per order.
*option to only leave if vehicle with same shared orders arrives.
*option to leave if another vehicle arrives.

[TODO]
*nice to have options like leave only if arriving vehicle is loading the same the menu entry is there. but the check to look for each vehicle in chain what it is loading and compere the loading types is missing. but should work for airplanes, busses, trucks,
*make the check from shared order vehicles orders to same orders.



[PROBLEMS]
*now im using 2 bits of the unload type and changed the flags to use only 2 bits,
*i had to remove unload checks, to make it selectable.
*old and new savegames can make problems if ure using unload types. (i dont use them often)
*old save games can make the order to get a wrong unload oder leave station type...
*new save games can make the order to get a wrong unload type if ure playing it with a normal openttd without my patch.
*vehicle order gui string with stop positions [FRONT,MIDDLE,END] is now used to draw strings for "stop loading type" (if selected).
Attachments
OpenTTDleaveStation0.3a.7z
new win32 binary now with selectable options per order
(2.91 MiB) Downloaded 266 times
leaveStation0.3aa.patch
new patch version 0.3aa
same like 0.3a but patching should now work!
(20.14 KiB) Downloaded 277 times
Last edited by doener on 19 Sep 2010 00:37, edited 12 times in total.
Dante123
Chief Executive
Chief Executive
Posts: 671
Joined: 11 Aug 2009 16:10
Location: The Nederlands
Contact:

Re: [Patch] Leave station if new Vehicle arrives

Post by Dante123 »

very nice idea.

i think this: *nice to have option to only leave if vehicle with same shared orders arrives. should be the key.

i think of a steel plan or something where you have steel loading trains that leave when new coal arrives.
so i think be best thing is to make some option that you can set off/on maybe ? so that it will only work for trains with the same orders ?
doener
Engineer
Engineer
Posts: 11
Joined: 31 Aug 2010 12:49

Re: [Patch] Leave station if new Vehicle arrives

Post by doener »

Im currently testing my binary. I like it how it plays actually.
i think to make full load possible with shared orders i will make the patch only work for
"the same shared orders" and "full load any" in combination.
so you can select "full load all" and it will have the full load behaviour.
but if selecting "full load any" in a "shared order" it will stop waiting for goods an leave the station.
or what do you think?
Alberth
OpenTTD Developer
OpenTTD Developer
Posts: 4763
Joined: 09 Sep 2007 05:03
Location: home

Re: [Patch] Leave station if new Vehicle arrives

Post by Alberth »

doener wrote:i will make the patch only work for "the same shared orders" and "full load any" in combination.
I think 'full load any' means full load any. If you want different behaviour, add a menu item in the drop-down.
doener
Engineer
Engineer
Posts: 11
Joined: 31 Aug 2010 12:49

Re: [Patch] Leave station if new Vehicle arrives

Post by doener »

new version 0.3a with some improvements. happy testing...
Timmaexx
Transport Coordinator
Transport Coordinator
Posts: 301
Joined: 03 Jan 2009 17:55

Re: [Patch] Leave station if new Vehicle arrives

Post by Timmaexx »

This .patch remembers me on a attraction-setting in RollerCoasterTycoon! :D
I will try it, if my system is renewed...
Post Reply

Return to “OpenTTD Development”

Who is online

Users browsing this forum: No registered users and 13 guests