OpenTTD

Tasklist

FS#5960 - Wrong capacity of the default cargo for planes (first livery)

Attached to Project: OpenTTD
Opened by George (George) - Monday, 31 March 2014, 18:48 GMT
Type Bug
Category Vehicles
Status New
Assigned To No-one
Operating System All
Severity High
Priority Normal
Reported Version trunk
Due in Version Undecided
Due Date Undecided
Percent Complete 0%
Votes 0
Private No

Details

R26438

test in a Arctic game, default cargoes
Default cargo is gold, capacity is 30 for the first livery, 118 (correct) for the second.

[22:23:17] <George> http://dev.openttdcoop.org/projects/worldairlinersset/repository/revisions/6c25b335b49e/entry/src/gfx/Airbus/A300/A300-600F/A300-600F.pnml
[22:23:41] <George> I cant make cargo plane to have correct capacity for default cargo
[22:24:15] <George> In my test game (arctic, default industries and cargoes) default cargo is GOLD
[22:24:20] <planetmaker> do you consider cargo size in your calculation?
[22:24:45] <George> it has 30 bags capacity for the first livery and 118 for the others
[22:25:27] <George> as you can see in the code above, I specify it regardles livery
[22:26:06] <George> But the first livery of the first cargo is default capacity divided by 4
[22:26:25] <George> But it should be a CB result instead
[22:28:13] <planetmaker> sounds like an issue with misc flag 5: http://newgrf-specs.tt-wiki.net/wiki/VehicleRefitting
[22:28:27] <planetmaker> and as to what is default cargo (which is passengers?)
[22:29:40] <George> what passengers if it is a cargo plane?
[22:30:26] <planetmaker> not sure such thing can exist
[22:31:47] <George> And what should I do?
[22:32:10] <George> Do you mean I need to set AIRCRAFT_FLAG_AUTOREFIT flag? But why?
[22:34:55] <planetmaker> I don't know yet what is going on and why
[22:36:03] <planetmaker> I've hardly ever looked at how aircraft work
[22:36:13] <George> As a test I've added PASS as default cargo while mail capacity is set to 0
[22:36:24] <George> and a bug remains
[22:37:24] <George> (default cargo is still gold)
[22:38:05] <planetmaker> not passengers?
[22:39:39] <George> yes
[22:39:47] <George> not passengers
[22:40:02] <George> GOLD is the first cargo in the translation table
[22:40:29] <George> and i suppose because of that is taken as default
[22:40:48] <planetmaker> might be the case
[22:40:55] <George> and default_cargo_type is not specified for planes
[22:41:09] <George> BTW why not?
This task depends upon

Comment by George (George) - Tuesday, 01 April 2014, 06:24 GMT
Note.
Changing CTT to have PASS the first cargo fixes the issue, but that is only a way to overcome a bug.
Comment by George (George) - Tuesday, 01 April 2014, 06:53 GMT
How to reproduce:
Download WAS push 44 (https://jenkins.openttdcoop.org/job/worldairlinersset/44/)
start a new game in arctic
Set current year to 2000
Build A300-600F (for cargo)
Look at gold capacity on both the liveries. Should be 118, but first one is 30 (=122/4)

Loading...