Bug #3930
Error when adding wagon
| Status: | Closed | Start date: | 2012-04-22 | |
|---|---|---|---|---|
| Priority: | Normal | Due date: | ||
| Assignee: | Hirundo | % Done: | 100% |
|
| Category: | - | |||
| Target version: | - |
Description
I am getting a nmlc error when compiling.
This happened when I added the wagon item_railflatbed3.
If I replace the item_railflatbed3 with some other item name like item_railhopper3, then comment railhopper3 out to disable it, then compile, it works.
I also tried to completely ignore railflatbed3 and define a new item - item_testwagon but the same error occured.
I tried to add an engine item. That works without any problems.
I attach the whole folder with my newgrf stuff so I hope it will be enough. I am sorry for the huge amount of data and long code :z
I tried to make it a bit easier to navigate by adding two "TEST_NAVIGATION_POINT" things in the code so you could quickly find the thing.
Here goes:
http://dl.dropbox.com/u/20419525/nuts-newgrf%20%E2%80%93%20bug.zip
Thank you,
V453000
Associated revisions
Fix #3930: Provide a proper error message when running out of action2 IDs. Also make use of ID 255.
Fix #3930: Provide a proper error message when running out of action2 IDs. Also make use of ID 255.
History
#2 Updated by V453000 about 1 year ago
I have just commented the previous problema causers out and continued with making something else.
This time I added random switches for railtanker2_random_cola, railtanker2_random_plastic, and railtanker2_random_beer.
I also added FZDR refittability to item_railtanker1, item_railtanker2, item_monotanker and item_maglevtanker. Followed by that I also added FZDR spritegroups/random switches to the railuniversal2_wagon_switch, railuniversal1_wagon_switch, monouniversal_wagon_switch, maglevuniversal_wagon_switch, railtanker_wagon_switch, railtanker2_wagon_switch, monotanker_wagon_switch and maglevtanker_wagon_switch.
Then I reach the same error message again. :(
#3 Updated by Hirundo 11 months ago
- Assignee set to Hirundo
Looking into it now.
Just reproducing the bug was quite a hassle, as the attached bundle doesn't build on a linux VM.
Please use only forward slashes ("/", not "\") in path names and keep capitalization of file names (Foo.png vs foo.png) consistent.
#5 Updated by Hirundo 11 months ago
- Status changed from New to Closed
- % Done changed from 0 to 100
Applied in changeset 8df0da1e50cf.
#6 Updated by Hirundo 11 months ago
I have fixed the problem, NML no longer errors internally but provides a proper error message.
The root cause of the problem is, though, that there are only 255 reusable IDs available for sprite groups, switch blocks and such. This limit is built into the nfo format, there's no way around it.* It may help, though, to define sprite sets/groups, switches etc. as shortly as possible before they are used.
- NML could take steps to reduce the impact of the problem by reordering code, but that's quite hard to do properly.