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
Assert when opening industry directory #7631
Comments
|
[7:33pm] andythenorth: should I inspect any frames? |
Can confirm that this is an issue from #6867 - FIRS has a "Bulk Terminal" that produces 5 cargoes, which blows through the 20 parameter limit in Previously, the maximum number of parameters from this function would've been 9, for 2 produced cargoes A horribly quick and dirty fix would be to replace lengthof(i->produced_cargo) in both for loops, but the actual solution might require some more thought... |
i think the real issue is that i haven't looked at what the resulting string should look like, but it probably needs to be rewritten to not all be packed in one string (like cargo list or something) |
Would it be feasible to allow up to 255 parameters in a single string? If the parameter limit was 255, then that would solve many problems with current industry strings caused by having 16 cargoes I/O of a single industry. Also, that would allow Game Scripts such as Simpleton's City Builder to display full town requirements to grow (via option), instead of just the first few cargoes. |
Maybe we can fix it using something like master...glx22:fix_7631_alt then open a new issue about the current limitation |
Another option is on master...glx22:industry_directory removing the produced/transported strings and replacing them with cargo sprites |
Version of OpenTTD
commit a83b80bacfa4aa5da2a6043136749b164ac2b191 (HEAD -> 7380)
Using dev version of FIRS (attached), economy parameter set to "Steeltown".
Expected result
OpenTTD doesn't assert when opening industry directory window.
Actual result
OpenTTD asserts when opening industry directory window.
Steps to reproduce
Add attached FIRS, set economy to "Steeltown".
Start a game.
Open industry directory window.
OpenTTD will assert.
firs-1.tar.zip
The text was updated successfully, but these errors were encountered: