OpenTTD

Tasklist

FS#5460 - Vehicles: access the user-defined bits of a specific vehicle only (in a train consist)

Attached to Project: OpenTTD
Opened by Jacopo (Snail_) - Monday, 04 February 2013, 00:08 GMT
Last edited by andythenorth (andythenorth) - Monday, 04 September 2017, 07:05 GMT
Type Feature Request
Category Vehicles
Status New
Assigned To No-one
Operating System All
Severity Medium
Priority Normal
Reported Version trunk
Due in Version Undecided
Due Date Undecided
Percent Complete 0%
Votes 0
Private No

Details

Hi all!

I would like to request a new way to access the user-defined bits of a vehicle inside of a train consist.
So far we have a function that allows us to do "ORing" across the userbits of a certain vehicle + all the vehicles in the consist after that one.
How about a function that only allows us to check a certain vehicle's userbit pattern, ignoring the bits of the following vehicles?

It would be very useful to check for info about a specific vehicle in the consist, without having it "blurred" by the other wagons' info.

Of course, this shouldn't replace the current way we go through userbits (at least for compatibility's sake), but it could be a very useful added feature.

Thanks in advance!
This task depends upon

Comment by andythenorth (andythenorth) - Thursday, 31 August 2017, 20:51 GMT
Hi Snail, it would be useful to discuss this in irc to find out (a) what the intended use is (b) if it's still valid 4 years later.

Flyspray is being cleaned, so I'd like to close any feature requests which are no longer useful, or not likely to be implemented :) In some newgrf cases, an alternative way has been found since the original feature request was opened.
Comment by Jacopo (Snail_) - Friday, 01 September 2017, 02:02 GMT
Yes it's still needed. I tried a few workarounds, but they didn't really work.
It's needed mostly for my push-pull implementation. Although some people might think push-pull is a BAD FEATURE altogether, it's a core part of my set; being able to access a specific vehicle's userbit pattern (without ORing) will be able to add new functionality, and also to make my code cleaner.
I'll try to get on irc in the next few weeks if you need to talk more about this

Loading...