Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

var F2 value lost on autoreplace #5070

Closed
DorpsGek opened this issue Feb 18, 2012 · 8 comments
Closed

var F2 value lost on autoreplace #5070

DorpsGek opened this issue Feb 18, 2012 · 8 comments
Labels
flyspray This issue is imported from FlySpray (https://bugs.openttd.org/)

Comments

@DorpsGek
Copy link
Member

George opened the ticket and wrote:

R23961

Var F2 is used to store cargo subtype (for example, beer as subtype for food).
But when the vehicle is autoreplaced, it forgets the value and gets value 0 instead. This makes non beer vehicle to transport beer (In fact this is all food and it was for food and becomes food vehicle, but from sub type POV a beer transporting vehicle becomes non beer transporting vehicle still transporting beer, that is a mistake)

Reported version: trunk
Operating system: All


This issue was imported from FlySpray: https://bugs.openttd.org/task/5070
@DorpsGek
Copy link
Member Author

frosch wrote:

Autoreplace will pick the subtype which returns the same text. If the vehicle does not offer a matching subtype, it will pick type 0.

So, make sure you are using the exact same text ID for the subtypes of both vehicles.

Note that this might also fail, if the available subtypes depend on other vehicles in the consist.


This comment was imported from FlySpray: https://bugs.openttd.org/task/5070#comment10905

@DorpsGek
Copy link
Member Author

akasoft wrote:

I think George in this case keep in mind autorenew instead autoreplace.


This comment was imported from FlySpray: https://bugs.openttd.org/task/5070#comment10906

@DorpsGek
Copy link
Member Author

frosch wrote:

Autorenew uses the same method. So unless certain subtypes become unavailable later on, it should work.
Please attach a savegame (plus NewGRFs, unless they are no bananas) showing the effect.


This comment was imported from FlySpray: https://bugs.openttd.org/task/5070#comment10907

@DorpsGek
Copy link
Member Author

George wrote:

Correct. I mean autorenew. So the subtypes list is the same


This comment was imported from FlySpray: https://bugs.openttd.org/task/5070#comment10913

@DorpsGek
Copy link
Member Author

George wrote:

Have a look on depot novgorod # 11. the group "sand CHS7" is send for service. As you can see, when being renewed, all the liveries become # 0.
The possible reason may be changed to 0 capacity, but there is no other way to provide a list for a loco.

Attachments


This comment was imported from FlySpray: https://bugs.openttd.org/task/5070#comment10914

@DorpsGek
Copy link
Member Author

Rubidium wrote:

I'm missing all ECS NewGRFs and the version of NewShips used in that savegame. Furthermore I can't find them on Bananas, so there are mostly missing cargos, so only "invalid cargo" is shown.


This comment was imported from FlySpray: https://bugs.openttd.org/task/5070#comment10915

@DorpsGek
Copy link
Member Author

George wrote:

ECS can be found at http://george.zernebok.net/temp/ECS1.2/
New ships are attached

Attachments


This comment was imported from FlySpray: https://bugs.openttd.org/task/5070#comment10916

@DorpsGek
Copy link
Member Author

frosch closed the ticket.

Reason for closing: Fixed

in r23965


This comment was imported from FlySpray: https://bugs.openttd.org/task/5070

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
flyspray This issue is imported from FlySpray (https://bugs.openttd.org/)
Projects
None yet
Development

No branches or pull requests

1 participant