NML: 16-cargo industry support
Moderator: Graphics Moderators
- andythenorth
- Tycoon
- Posts: 5705
- Joined: 31 Mar 2007 14:23
- Location: Lost in Music
NML: 16-cargo industry support
Planetmaker merged the PR for NML 16-cargo industry support https://github.com/OpenTTD/nml/pull/15
1. There are no docs for this feature. Someone needs to write them, per the pull request.
2. This feature breaks backwards compatibility in NML.
3. The feature is relatively untested.
NML remains unmaintained, if you use it, and you want to see it continue to be developed, you need to help. Find us in #openttd irc https://wiki.openttd.org/Irc
cheers,
Andy
1. There are no docs for this feature. Someone needs to write them, per the pull request.
2. This feature breaks backwards compatibility in NML.
3. The feature is relatively untested.
NML remains unmaintained, if you use it, and you want to see it continue to be developed, you need to help. Find us in #openttd irc https://wiki.openttd.org/Irc
cheers,
Andy
FIRS Industry Replacement Set (released) | HEQS Heavy Equipment Set (trucks, industrial trams and more) (finished)
Unsinkable Sam (ships) (preview released) | CHIPS Has Improved Players' Stations (finished)
Iron Horse ((trains) (released) | Termite (tracks for Iron Horse) (released) | Busy Bee (game script) (released)
Road Hog (road vehicles and trams) (released)
Unsinkable Sam (ships) (preview released) | CHIPS Has Improved Players' Stations (finished)
Iron Horse ((trains) (released) | Termite (tracks for Iron Horse) (released) | Busy Bee (game script) (released)
Road Hog (road vehicles and trams) (released)
Re: NML: 16-cargo industry support
Hi all,
In the NML update dated April 10, tried to follow the sample for the Industry to try add extra cargos to my Industries, but unfortunately have trouble understanding it and also some of the code it comes up with some error messages.
For instance when I add this:
Get a message
So I made up a AuzIndTest with just one Industry to test with.
The Industry is called "Commercials" I extracted it from my main AuzInd files.
I've zipped up all the files associated with AuzIndTest for anyone who would like to play around with it and see if they can add extra cargos to it.
The nml file I zipped up has 6332 lines. The first 2038 is all references to 56 different cargo types and some Parameter settings.
Majority of my coding is extracted from FIRS 1.4.3.
Hoping those who understand coding better than me might be able to work with this one Industry and get it to work with many cargos.
Hope it will help other coders too.
Cheers all
In the NML update dated April 10, tried to follow the sample for the Industry to try add extra cargos to my Industries, but unfortunately have trouble understanding it and also some of the code it comes up with some error messages.
For instance when I add this:
Code: Select all
cargo_types: [
produce_cargo("LVST", 8),
produce_cargo("GRAI", 12),
produce_cargo("WOOD", 4),
];
I added other files from the sample trying to work out why it keep giving me that error message, but I was unsuccessful.Unknown property name: cargo types
So I made up a AuzIndTest with just one Industry to test with.
The Industry is called "Commercials" I extracted it from my main AuzInd files.
I've zipped up all the files associated with AuzIndTest for anyone who would like to play around with it and see if they can add extra cargos to it.
The nml file I zipped up has 6332 lines. The first 2038 is all references to 56 different cargo types and some Parameter settings.
Majority of my coding is extracted from FIRS 1.4.3.
Hoping those who understand coding better than me might be able to work with this one Industry and get it to work with many cargos.
Hope it will help other coders too.
Cheers all
- Attachments
-
- AuzIndTest.rar
- (239.49 KiB) Downloaded 260 times
Soot Happens
Screenshot Of The Month Winner March 2020
All my projects are GPLv2 License unless stated.
Auz Road Sets: viewtopic.php?f=29&t=87335
Auz Project Releases: viewtopic.php?f=67&t=84725
Auz Trains: http://www.tt-forums.net/viewtopic.php?f=26&t=74193
Auz Industry Sets: http://www.tt-forums.net/viewtopic.php?f=26&t=74471
Auz Objects: viewtopic.php?f=26&t=75657
Auz Bridges: viewtopic.php?f=26&t=75248
Auz Stations: viewtopic.php?f=26&t=76390
Auz Tracks: viewtopic.php?f=26&t=82691
Auz Subway Stations: viewtopic.php?f=26&t=85335
Auz Eyecandy TramTracks: viewtopic.php?t=89908
Videos and Images of Trains: viewtopic.php?t=90763
Screenshot Of The Month Winner March 2020
All my projects are GPLv2 License unless stated.
Auz Road Sets: viewtopic.php?f=29&t=87335
Auz Project Releases: viewtopic.php?f=67&t=84725
Auz Trains: http://www.tt-forums.net/viewtopic.php?f=26&t=74193
Auz Industry Sets: http://www.tt-forums.net/viewtopic.php?f=26&t=74471
Auz Objects: viewtopic.php?f=26&t=75657
Auz Bridges: viewtopic.php?f=26&t=75248
Auz Stations: viewtopic.php?f=26&t=76390
Auz Tracks: viewtopic.php?f=26&t=82691
Auz Subway Stations: viewtopic.php?f=26&t=85335
Auz Eyecandy TramTracks: viewtopic.php?t=89908
Videos and Images of Trains: viewtopic.php?t=90763
- andythenorth
- Tycoon
- Posts: 5705
- Joined: 31 Mar 2007 14:23
- Location: Lost in Music
Re: NML: 16-cargo industry support
Nielsm wrote an example for new production callback format here: https://0x0.st/zHBc.txt
I've attached a couple of files from FIRS v4 development.
Hope this helps.
I've attached a couple of files from FIRS v4 development.
Hope this helps.
- Attachments
-
- quarry.nml
- (216.52 KiB) Downloaded 248 times
-
- factory.nml
- (58.62 KiB) Downloaded 243 times
FIRS Industry Replacement Set (released) | HEQS Heavy Equipment Set (trucks, industrial trams and more) (finished)
Unsinkable Sam (ships) (preview released) | CHIPS Has Improved Players' Stations (finished)
Iron Horse ((trains) (released) | Termite (tracks for Iron Horse) (released) | Busy Bee (game script) (released)
Road Hog (road vehicles and trams) (released)
Unsinkable Sam (ships) (preview released) | CHIPS Has Improved Players' Stations (finished)
Iron Horse ((trains) (released) | Termite (tracks for Iron Horse) (released) | Busy Bee (game script) (released)
Road Hog (road vehicles and trams) (released)
Re: NML: 16-cargo industry support
Thanks kindly for the examples.
Will experiment with those and see what I can do.
Cheers
Will experiment with those and see what I can do.
Cheers
Soot Happens
Screenshot Of The Month Winner March 2020
All my projects are GPLv2 License unless stated.
Auz Road Sets: viewtopic.php?f=29&t=87335
Auz Project Releases: viewtopic.php?f=67&t=84725
Auz Trains: http://www.tt-forums.net/viewtopic.php?f=26&t=74193
Auz Industry Sets: http://www.tt-forums.net/viewtopic.php?f=26&t=74471
Auz Objects: viewtopic.php?f=26&t=75657
Auz Bridges: viewtopic.php?f=26&t=75248
Auz Stations: viewtopic.php?f=26&t=76390
Auz Tracks: viewtopic.php?f=26&t=82691
Auz Subway Stations: viewtopic.php?f=26&t=85335
Auz Eyecandy TramTracks: viewtopic.php?t=89908
Videos and Images of Trains: viewtopic.php?t=90763
Screenshot Of The Month Winner March 2020
All my projects are GPLv2 License unless stated.
Auz Road Sets: viewtopic.php?f=29&t=87335
Auz Project Releases: viewtopic.php?f=67&t=84725
Auz Trains: http://www.tt-forums.net/viewtopic.php?f=26&t=74193
Auz Industry Sets: http://www.tt-forums.net/viewtopic.php?f=26&t=74471
Auz Objects: viewtopic.php?f=26&t=75657
Auz Bridges: viewtopic.php?f=26&t=75248
Auz Stations: viewtopic.php?f=26&t=76390
Auz Tracks: viewtopic.php?f=26&t=82691
Auz Subway Stations: viewtopic.php?f=26&t=85335
Auz Eyecandy TramTracks: viewtopic.php?t=89908
Videos and Images of Trains: viewtopic.php?t=90763
Re: NML: 16-cargo industry support
First I like to thank and congratulate the ones who managed to change the coding in NML so Industries can accept all the extra cargoes. Well done.
The problem now is me trying to understanding it all
A few things in the coding of those samples I like to get a bit more information on and if I on the right track.
It shows that the Factory accepts the GLAS, PLAS, STAL and POWR and produces VPTS? Does the VPTS represent the MNSP and GOOD mentioned earlier in the code?
You have " produce (factory_produce_0 to produce (factory_produce_5 ". Are all 5 necessary and what the reason for them.
Also notice with some of the Cargo coding " current_date " .. will we be able to set a date for some cargos to become available?
That should do for starters.
Cheers
The problem now is me trying to understanding it all

A few things in the coding of those samples I like to get a bit more information on and if I on the right track.
Code: Select all
cargo_types: [accept_cargo("GLAS"),accept_cargo("PLAS"),accept_cargo("STAL"),accept_cargo("POWR"),produce_cargo("VPTS",0)];
Code: Select all
produce (factory_produce_0,
[
MNSP: incoming_cargo_waiting("MNSP");
],
[
GOOD: (LOAD_PERM(2) * 8) / 8;
],
0)
switch (FEAT_INDUSTRIES, SELF, factory_produce_calculation_0,
[
STORE_PERM(0, 1),
STORE_PERM(0, 2),
STORE_PERM(
max(LOAD_PERM(3), (incoming_cargo_waiting("MNSP") > 0) * current_date),
3
),
STORE_PERM(
LOAD_PERM(1)
+ (
(current_date - LOAD_PERM(3)) <= 90
? 8 : 0
),
1
),
STORE_PERM(
LOAD_PERM(2)
+ ((incoming_cargo_waiting("MNSP") * LOAD_PERM(1)) / 8),
2
),
STORE_PERM(
(LOAD_PERM(2) == 0)
? LOAD_PERM(0) : 0,
0
),
]) {
factory_produce_0;
}
Also notice with some of the Cargo coding " current_date " .. will we be able to set a date for some cargos to become available?
That should do for starters.
Cheers
Soot Happens
Screenshot Of The Month Winner March 2020
All my projects are GPLv2 License unless stated.
Auz Road Sets: viewtopic.php?f=29&t=87335
Auz Project Releases: viewtopic.php?f=67&t=84725
Auz Trains: http://www.tt-forums.net/viewtopic.php?f=26&t=74193
Auz Industry Sets: http://www.tt-forums.net/viewtopic.php?f=26&t=74471
Auz Objects: viewtopic.php?f=26&t=75657
Auz Bridges: viewtopic.php?f=26&t=75248
Auz Stations: viewtopic.php?f=26&t=76390
Auz Tracks: viewtopic.php?f=26&t=82691
Auz Subway Stations: viewtopic.php?f=26&t=85335
Auz Eyecandy TramTracks: viewtopic.php?t=89908
Videos and Images of Trains: viewtopic.php?t=90763
Screenshot Of The Month Winner March 2020
All my projects are GPLv2 License unless stated.
Auz Road Sets: viewtopic.php?f=29&t=87335
Auz Project Releases: viewtopic.php?f=67&t=84725
Auz Trains: http://www.tt-forums.net/viewtopic.php?f=26&t=74193
Auz Industry Sets: http://www.tt-forums.net/viewtopic.php?f=26&t=74471
Auz Objects: viewtopic.php?f=26&t=75657
Auz Bridges: viewtopic.php?f=26&t=75248
Auz Stations: viewtopic.php?f=26&t=76390
Auz Tracks: viewtopic.php?f=26&t=82691
Auz Subway Stations: viewtopic.php?f=26&t=85335
Auz Eyecandy TramTracks: viewtopic.php?t=89908
Videos and Images of Trains: viewtopic.php?t=90763
Re: NML: 16-cargo industry support
The six different factory_produce_(calculation_) seem to be selected by the economy variable, i.e. which FIRS economy is selected. For an industry set with just a single economy configuration you could probably make do with a single of them.
I think the current_date things are the check for when the relevant "supplies" cargo was last delivered. The day of last supplies delivery gets stored in one of the permanent slots in the industry.
Also notice that the FEAT_INDUSTRIES item itself is protected by if (economy == 5), and only the "mode 5" produce callback touches the cargo types mentioned in the cargo_types list.
I think the current_date things are the check for when the relevant "supplies" cargo was last delivered. The day of last supplies delivery gets stored in one of the permanent slots in the industry.
Also notice that the FEAT_INDUSTRIES item itself is protected by if (economy == 5), and only the "mode 5" produce callback touches the cargo types mentioned in the cargo_types list.
Code: Select all
produce (factory_produce_5,
[
GLAS: incoming_cargo_waiting("GLAS");
PLAS: incoming_cargo_waiting("PLAS");
STAL: incoming_cargo_waiting("STAL");
POWR: incoming_cargo_waiting("POWR");
],
[
VPTS: (LOAD_PERM(2) * 8) / 8;
],
0)
switch (FEAT_INDUSTRIES, SELF, factory_produce_calculation_5,
[
STORE_PERM(0, 1),
STORE_PERM(0, 2),
STORE_PERM(
max(LOAD_PERM(3), (incoming_cargo_waiting("GLAS") > 0) * current_date),
3
),
STORE_PERM(
LOAD_PERM(1)
+ (
(current_date - LOAD_PERM(3)) <= 90
? 2 : 0
),
1
),
STORE_PERM(
max(LOAD_PERM(4), (incoming_cargo_waiting("PLAS") > 0) * current_date),
4
),
STORE_PERM(
LOAD_PERM(1)
+ (
(current_date - LOAD_PERM(4)) <= 90
? 2 : 0
),
1
),
STORE_PERM(
max(LOAD_PERM(5), (incoming_cargo_waiting("STAL") > 0) * current_date),
5
),
STORE_PERM(
LOAD_PERM(1)
+ (
(current_date - LOAD_PERM(5)) <= 90
? 2 : 0
),
1
),
STORE_PERM(
max(LOAD_PERM(6), (incoming_cargo_waiting("POWR") > 0) * current_date),
6
),
STORE_PERM(
LOAD_PERM(1)
+ (
(current_date - LOAD_PERM(6)) <= 90
? 2 : 0
),
1
),
STORE_PERM(
LOAD_PERM(2)
+ ((incoming_cargo_waiting("GLAS") * LOAD_PERM(1)) / 8),
2
),
STORE_PERM(
LOAD_PERM(2)
+ ((incoming_cargo_waiting("PLAS") * LOAD_PERM(1)) / 8),
2
),
STORE_PERM(
LOAD_PERM(2)
+ ((incoming_cargo_waiting("STAL") * LOAD_PERM(1)) / 8),
2
),
STORE_PERM(
LOAD_PERM(2)
+ ((incoming_cargo_waiting("POWR") * LOAD_PERM(1)) / 8),
2
),
STORE_PERM(
(LOAD_PERM(2) == 0)
? LOAD_PERM(0) : 0,
0
),
]) {
factory_produce_5;
}
Re: NML: 16-cargo industry support
Probable all I need to use is the produce (factory_produce_0, for cargoes produced and produce (factory_produce_05, for cargoes accepted.
And
cargo_types: [accept_cargo("GLAS"),accept_cargo("PLAS"),accept_cargo("STAL"),accept_cargo("POWR"),produce_cargo("MNSP",0),produce_cargo("GOOD",0)];
Unfortunately it be several days before I get chance to experiment properly with these.
I hoping with the sample of my test file is to add as many cargos as I can to that one Industry to test it and when all working well remove what cargos I don't really need with that one and start adding more Industries.
And
cargo_types: [accept_cargo("GLAS"),accept_cargo("PLAS"),accept_cargo("STAL"),accept_cargo("POWR"),produce_cargo("MNSP",0),produce_cargo("GOOD",0)];
Unfortunately it be several days before I get chance to experiment properly with these.
I hoping with the sample of my test file is to add as many cargos as I can to that one Industry to test it and when all working well remove what cargos I don't really need with that one and start adding more Industries.
Soot Happens
Screenshot Of The Month Winner March 2020
All my projects are GPLv2 License unless stated.
Auz Road Sets: viewtopic.php?f=29&t=87335
Auz Project Releases: viewtopic.php?f=67&t=84725
Auz Trains: http://www.tt-forums.net/viewtopic.php?f=26&t=74193
Auz Industry Sets: http://www.tt-forums.net/viewtopic.php?f=26&t=74471
Auz Objects: viewtopic.php?f=26&t=75657
Auz Bridges: viewtopic.php?f=26&t=75248
Auz Stations: viewtopic.php?f=26&t=76390
Auz Tracks: viewtopic.php?f=26&t=82691
Auz Subway Stations: viewtopic.php?f=26&t=85335
Auz Eyecandy TramTracks: viewtopic.php?t=89908
Videos and Images of Trains: viewtopic.php?t=90763
Screenshot Of The Month Winner March 2020
All my projects are GPLv2 License unless stated.
Auz Road Sets: viewtopic.php?f=29&t=87335
Auz Project Releases: viewtopic.php?f=67&t=84725
Auz Trains: http://www.tt-forums.net/viewtopic.php?f=26&t=74193
Auz Industry Sets: http://www.tt-forums.net/viewtopic.php?f=26&t=74471
Auz Objects: viewtopic.php?f=26&t=75657
Auz Bridges: viewtopic.php?f=26&t=75248
Auz Stations: viewtopic.php?f=26&t=76390
Auz Tracks: viewtopic.php?f=26&t=82691
Auz Subway Stations: viewtopic.php?f=26&t=85335
Auz Eyecandy TramTracks: viewtopic.php?t=89908
Videos and Images of Trains: viewtopic.php?t=90763
Re: NML: 16-cargo industry support
Just had a try making cargo changes to my test set ..
not matter how I try to change it keep getting a Syntax error, unexpected token ":"
It is the ":" after ENSP
No matter if I try bring codes over to my test set from Quarry.nml, Factory.nml or from "Nielsm wrote an example for new production callback format here"
Just wondering if some one can look at my test file AuzIndTest (up above) and maybe change what coding is needed just for the cargoes I have in the test. That just might help me see where I going wrong.
Plenty time to check as be busy for a few days or more with home life. Cheers
not matter how I try to change it keep getting a Syntax error, unexpected token ":"
Code: Select all
produce (Commercials_clear_incoming_cargo_waiting_0,
[
ENSP: incoming_cargo_waiting("ENSP");
],
[],
0)
No matter if I try bring codes over to my test set from Quarry.nml, Factory.nml or from "Nielsm wrote an example for new production callback format here"
Just wondering if some one can look at my test file AuzIndTest (up above) and maybe change what coding is needed just for the cargoes I have in the test. That just might help me see where I going wrong.
Plenty time to check as be busy for a few days or more with home life. Cheers
Soot Happens
Screenshot Of The Month Winner March 2020
All my projects are GPLv2 License unless stated.
Auz Road Sets: viewtopic.php?f=29&t=87335
Auz Project Releases: viewtopic.php?f=67&t=84725
Auz Trains: http://www.tt-forums.net/viewtopic.php?f=26&t=74193
Auz Industry Sets: http://www.tt-forums.net/viewtopic.php?f=26&t=74471
Auz Objects: viewtopic.php?f=26&t=75657
Auz Bridges: viewtopic.php?f=26&t=75248
Auz Stations: viewtopic.php?f=26&t=76390
Auz Tracks: viewtopic.php?f=26&t=82691
Auz Subway Stations: viewtopic.php?f=26&t=85335
Auz Eyecandy TramTracks: viewtopic.php?t=89908
Videos and Images of Trains: viewtopic.php?t=90763
Screenshot Of The Month Winner March 2020
All my projects are GPLv2 License unless stated.
Auz Road Sets: viewtopic.php?f=29&t=87335
Auz Project Releases: viewtopic.php?f=67&t=84725
Auz Trains: http://www.tt-forums.net/viewtopic.php?f=26&t=74193
Auz Industry Sets: http://www.tt-forums.net/viewtopic.php?f=26&t=74471
Auz Objects: viewtopic.php?f=26&t=75657
Auz Bridges: viewtopic.php?f=26&t=75248
Auz Stations: viewtopic.php?f=26&t=76390
Auz Tracks: viewtopic.php?f=26&t=82691
Auz Subway Stations: viewtopic.php?f=26&t=85335
Auz Eyecandy TramTracks: viewtopic.php?t=89908
Videos and Images of Trains: viewtopic.php?t=90763
Re: NML: 16-cargo industry support
Just to be sure, you are running the updated NML version with the new syntax, right?
Re: NML: 16-cargo industry support
I have the nlmc.exe version dated 21st March 2019
Soot Happens
Screenshot Of The Month Winner March 2020
All my projects are GPLv2 License unless stated.
Auz Road Sets: viewtopic.php?f=29&t=87335
Auz Project Releases: viewtopic.php?f=67&t=84725
Auz Trains: http://www.tt-forums.net/viewtopic.php?f=26&t=74193
Auz Industry Sets: http://www.tt-forums.net/viewtopic.php?f=26&t=74471
Auz Objects: viewtopic.php?f=26&t=75657
Auz Bridges: viewtopic.php?f=26&t=75248
Auz Stations: viewtopic.php?f=26&t=76390
Auz Tracks: viewtopic.php?f=26&t=82691
Auz Subway Stations: viewtopic.php?f=26&t=85335
Auz Eyecandy TramTracks: viewtopic.php?t=89908
Videos and Images of Trains: viewtopic.php?t=90763
Screenshot Of The Month Winner March 2020
All my projects are GPLv2 License unless stated.
Auz Road Sets: viewtopic.php?f=29&t=87335
Auz Project Releases: viewtopic.php?f=67&t=84725
Auz Trains: http://www.tt-forums.net/viewtopic.php?f=26&t=74193
Auz Industry Sets: http://www.tt-forums.net/viewtopic.php?f=26&t=74471
Auz Objects: viewtopic.php?f=26&t=75657
Auz Bridges: viewtopic.php?f=26&t=75248
Auz Stations: viewtopic.php?f=26&t=76390
Auz Tracks: viewtopic.php?f=26&t=82691
Auz Subway Stations: viewtopic.php?f=26&t=85335
Auz Eyecandy TramTracks: viewtopic.php?t=89908
Videos and Images of Trains: viewtopic.php?t=90763
Re: NML: 16-cargo industry support
Just to let you know I been unsuccessful it coding extra cargos to my Industry .. even got that error message with the Industry sample that comes with NML updates.
Not been able to find the reason why as not been well past few weeks and not able to concentrate on any of my coding work. Could be out of action for a while.
Cheers all
Not been able to find the reason why as not been well past few weeks and not able to concentrate on any of my coding work. Could be out of action for a while.
Cheers all
Soot Happens
Screenshot Of The Month Winner March 2020
All my projects are GPLv2 License unless stated.
Auz Road Sets: viewtopic.php?f=29&t=87335
Auz Project Releases: viewtopic.php?f=67&t=84725
Auz Trains: http://www.tt-forums.net/viewtopic.php?f=26&t=74193
Auz Industry Sets: http://www.tt-forums.net/viewtopic.php?f=26&t=74471
Auz Objects: viewtopic.php?f=26&t=75657
Auz Bridges: viewtopic.php?f=26&t=75248
Auz Stations: viewtopic.php?f=26&t=76390
Auz Tracks: viewtopic.php?f=26&t=82691
Auz Subway Stations: viewtopic.php?f=26&t=85335
Auz Eyecandy TramTracks: viewtopic.php?t=89908
Videos and Images of Trains: viewtopic.php?t=90763
Screenshot Of The Month Winner March 2020
All my projects are GPLv2 License unless stated.
Auz Road Sets: viewtopic.php?f=29&t=87335
Auz Project Releases: viewtopic.php?f=67&t=84725
Auz Trains: http://www.tt-forums.net/viewtopic.php?f=26&t=74193
Auz Industry Sets: http://www.tt-forums.net/viewtopic.php?f=26&t=74471
Auz Objects: viewtopic.php?f=26&t=75657
Auz Bridges: viewtopic.php?f=26&t=75248
Auz Stations: viewtopic.php?f=26&t=76390
Auz Tracks: viewtopic.php?f=26&t=82691
Auz Subway Stations: viewtopic.php?f=26&t=85335
Auz Eyecandy TramTracks: viewtopic.php?t=89908
Videos and Images of Trains: viewtopic.php?t=90763
- andythenorth
- Tycoon
- Posts: 5705
- Joined: 31 Mar 2007 14:23
- Location: Lost in Music
Re: NML: 16-cargo industry support
Just to report, the nml docs were updated a little while ago for 16-cargo industry support 
https://newgrf-specs.tt-wiki.net/wiki/NML:Industries
https://newgrf-specs.tt-wiki.net/wiki/NML:Produce

https://newgrf-specs.tt-wiki.net/wiki/NML:Industries
https://newgrf-specs.tt-wiki.net/wiki/NML:Produce
FIRS Industry Replacement Set (released) | HEQS Heavy Equipment Set (trucks, industrial trams and more) (finished)
Unsinkable Sam (ships) (preview released) | CHIPS Has Improved Players' Stations (finished)
Iron Horse ((trains) (released) | Termite (tracks for Iron Horse) (released) | Busy Bee (game script) (released)
Road Hog (road vehicles and trams) (released)
Unsinkable Sam (ships) (preview released) | CHIPS Has Improved Players' Stations (finished)
Iron Horse ((trains) (released) | Termite (tracks for Iron Horse) (released) | Busy Bee (game script) (released)
Road Hog (road vehicles and trams) (released)
Re: NML: 16-cargo industry support
Has anyone had any success in coding for 16 cargos? I'm getting nowhere fast and would appreciate a small bit of working code to use as a starter.
Re: NML: 16-cargo industry support
There are some examples out, also on the NewGRF wiki for NML. They should work.3iff wrote: 21 Jan 2020 10:31 Has anyone had any success in coding for 16 cargos? I'm getting nowhere fast and would appreciate a small bit of working code to use as a starter.
If they don't, which errors do you get?
- andythenorth
- Tycoon
- Posts: 5705
- Joined: 31 Mar 2007 14:23
- Location: Lost in Music
Re: NML: 16-cargo industry support
FIRS v4 uses quite a lot of the spec, you'll find most of the cargo handling in src/templates: https://github.com/andythenorth/firs/tr ... ease-track3iff wrote: 21 Jan 2020 10:31 Has anyone had any success in coding for 16 cargos? I'm getting nowhere fast and would appreciate a small bit of working code to use as a starter.
I'm not sure how useful the whole FIRS nml is, but here you go anyway

- Attachments
-
- firs.nml
- (10.16 MiB) Downloaded 265 times
FIRS Industry Replacement Set (released) | HEQS Heavy Equipment Set (trucks, industrial trams and more) (finished)
Unsinkable Sam (ships) (preview released) | CHIPS Has Improved Players' Stations (finished)
Iron Horse ((trains) (released) | Termite (tracks for Iron Horse) (released) | Busy Bee (game script) (released)
Road Hog (road vehicles and trams) (released)
Unsinkable Sam (ships) (preview released) | CHIPS Has Improved Players' Stations (finished)
Iron Horse ((trains) (released) | Termite (tracks for Iron Horse) (released) | Busy Bee (game script) (released)
Road Hog (road vehicles and trams) (released)
Re: NML: 16-cargo industry support
Very useful indeed, for all us who don't understand templates and python.andythenorth wrote: 21 Jan 2020 19:20 I'm not sure how useful the whole FIRS nml is, but here you go anyway![]()
Truly thankful for sharing it with us.
Re: NML: 16-cargo industry support
I concur. I'm very sure it'll be very useful.
Thank you. Hopefully some results soon...(and probably a lot of frustration along the way...)
Thank you. Hopefully some results soon...(and probably a lot of frustration along the way...)
- andythenorth
- Tycoon
- Posts: 5705
- Joined: 31 Mar 2007 14:23
- Location: Lost in Music
Re: NML: 16-cargo industry support
The nml docs for 16-cargo industry are now entirely complete
https://newgrf-specs.tt-wiki.net/wiki/NML:Industries
Thanks to all those who helped
Note that NML 0.5 will remove support for some deprecated industry properties. That's noted in the NML docs.
16-cargo house support is also now done (will be in NML 0.5) and documented
https://newgrf-specs.tt-wiki.net/wiki/NML:Houses
NML 0.5 is not yet released, progress on that can be tracked here https://github.com/OpenTTD/nml/issues/43
Generally there has been a lot of change in the NewGRF spec as some big features have been added. That has required a lot of work in the tools and docs, which fortunately is now nearly complete
Keep track here: https://wiki.openttd.org/NewGRF_Specification_Status

Thanks to all those who helped

Note that NML 0.5 will remove support for some deprecated industry properties. That's noted in the NML docs.
16-cargo house support is also now done (will be in NML 0.5) and documented

NML 0.5 is not yet released, progress on that can be tracked here https://github.com/OpenTTD/nml/issues/43
Generally there has been a lot of change in the NewGRF spec as some big features have been added. That has required a lot of work in the tools and docs, which fortunately is now nearly complete

FIRS Industry Replacement Set (released) | HEQS Heavy Equipment Set (trucks, industrial trams and more) (finished)
Unsinkable Sam (ships) (preview released) | CHIPS Has Improved Players' Stations (finished)
Iron Horse ((trains) (released) | Termite (tracks for Iron Horse) (released) | Busy Bee (game script) (released)
Road Hog (road vehicles and trams) (released)
Unsinkable Sam (ships) (preview released) | CHIPS Has Improved Players' Stations (finished)
Iron Horse ((trains) (released) | Termite (tracks for Iron Horse) (released) | Busy Bee (game script) (released)
Road Hog (road vehicles and trams) (released)
Re: NML: 16-cargo industry support
Great news .. well done to those involved with this project.
I'll wait for it to be released before I start working on my Industries again.
Cheers all
Soot Happens
Screenshot Of The Month Winner March 2020
All my projects are GPLv2 License unless stated.
Auz Road Sets: viewtopic.php?f=29&t=87335
Auz Project Releases: viewtopic.php?f=67&t=84725
Auz Trains: http://www.tt-forums.net/viewtopic.php?f=26&t=74193
Auz Industry Sets: http://www.tt-forums.net/viewtopic.php?f=26&t=74471
Auz Objects: viewtopic.php?f=26&t=75657
Auz Bridges: viewtopic.php?f=26&t=75248
Auz Stations: viewtopic.php?f=26&t=76390
Auz Tracks: viewtopic.php?f=26&t=82691
Auz Subway Stations: viewtopic.php?f=26&t=85335
Auz Eyecandy TramTracks: viewtopic.php?t=89908
Videos and Images of Trains: viewtopic.php?t=90763
Screenshot Of The Month Winner March 2020
All my projects are GPLv2 License unless stated.
Auz Road Sets: viewtopic.php?f=29&t=87335
Auz Project Releases: viewtopic.php?f=67&t=84725
Auz Trains: http://www.tt-forums.net/viewtopic.php?f=26&t=74193
Auz Industry Sets: http://www.tt-forums.net/viewtopic.php?f=26&t=74471
Auz Objects: viewtopic.php?f=26&t=75657
Auz Bridges: viewtopic.php?f=26&t=75248
Auz Stations: viewtopic.php?f=26&t=76390
Auz Tracks: viewtopic.php?f=26&t=82691
Auz Subway Stations: viewtopic.php?f=26&t=85335
Auz Eyecandy TramTracks: viewtopic.php?t=89908
Videos and Images of Trains: viewtopic.php?t=90763
- planetmaker
- OpenTTD Developer
- Posts: 9432
- Joined: 07 Nov 2007 22:44
- Location: Sol d
Re: NML: 16-cargo industry support
Thanks a lot, andy!
GarryG wrote: 20 Feb 2020 12:02 I'll wait for it to be released before I start working on my Industries again.
Cheers all
There's nothing wrong with using the current development version to get going

OpenTTD: manual | online content | translations | Wanted contributions and patches
#openttdcoop: blog | wiki | public server | DevZone | NewGRF web translator
DevZone - home of the free NewGRFs: OpenSFX | OpenMSX | OpenGFX | Swedish Rails | OpenGFX+ Trains|RV|Industries|Airports|Landscape | NML
Who is online
Users browsing this forum: No registered users and 8 guests