OpenTTD

Tasklist

FS#5456 - New misc_flag to disable vehicle intro date randomization

Attached to Project: OpenTTD
Opened by Supercheese (Supercheese) - Tuesday, 29 January 2013, 09:19 GMT
Last edited by andythenorth (andythenorth) - Saturday, 19 August 2017, 19:30 GMT
Type Patch
Category Vehicles
Status Closed
Assigned To No-one
Operating System All
Severity Medium
Priority Normal
Reported Version trunk
Due in Version Undecided
Due Date Undecided
Percent Complete 100%
Votes 1
Private No

Details

Attached is a patch against r24948 that defines a new misc_flag for vehicles, EF_NO_RANDOM_INTRO_DATE, that if set will prevent the vehicle's introduction date from being randomized.

This is useful for introducing historically important vehicles (such as the first Montgolfier hot air balloon or the Wright Flyer) at the proper date, and useful for other purposes too (see: http://bugs.openttd.org/task/5086)


A few comments:

I'm not 100% sure when parentheses are needed and when they aren't, so I took the "add more" route, I hope that's not too big of an issue.

It seems that bit 7 is the last available bit for misc_flags...
This task depends upon

Closed by  andythenorth (andythenorth)
Saturday, 19 August 2017, 19:30 GMT
Reason for closing:  Won't implement
Additional comments about closing:  Disabling randomisation isn't a current goal :) OpenTTD simulates a highly realistic quantum universe, and vehicle intro dates are probabilistic accordingly ;)

Flyspray clean up, so closing.
Comment by Supercheese (Supercheese) - Tuesday, 29 January 2013, 09:27 GMT
Here's an example grf with the flag set, a modified version of the Hot Air Balloon grf available from Bananas with the appropriate flag set. Intro date is date(1960,1,1) in NML.
Comment by frosch (frosch) - Tuesday, 29 January 2013, 17:34 GMT
As discussed in  FS#5086 , I don't think this is the right way to go at all.
You are heading for introducing stuff at the same time. Disabling randomisation is a really really stupid hack for that.
Comment by Supercheese (Supercheese) - Tuesday, 29 January 2013, 18:30 GMT
My interest is not so much for introducing a set of vehicles at the same time, but for introducing the historical vehicles mentioned above at the appropriate date. For instance, the first Wright Flyer flew on December 17, 1903, but by 1904 the Wright brothers had already built a second Flyer, and by 1905 a third with different specifications. If a grf wanted to have the Wright Flyer introduced as close to December 17, 1903 as possible, with the randomization it could end up being introduced in OTTD as late as May 1905, far too late for the first or even second model Flyers.
Comment by Alberth (Alberth) - Tuesday, 29 January 2013, 19:25 GMT
Currently it is far too easy to confuse this idea with a hack to work around a proper solution for  FS#5086 .

Loading...