how to make vehicles and trains for open ttd?

Discuss, get help with, or post new graphics for TTDPatch and OpenTTD, using the NewGRF system, here. Graphics for plain TTD also acceptable here.

Moderator: Graphics Moderators

Post Reply
Facu-Noguera
Engineer
Engineer
Posts: 2
Joined: 02 Sep 2021 04:12

how to make vehicles and trains for open ttd?

Post by Facu-Noguera »

Hi, I'm new to the forum, my name is Facundo and I'm from Argentina. I registered because I wanted to know if someone could tell me how to create / design vehicles, trains and others for the game, I want to know this because I want to make the vehicles and trains of my country for openttd. I want to know how to do it and if it is possible to do it in android (if it is something simple that does not require any pc program I suppose it is possible to do it) I hope someone can help me.👋
User avatar
kamnet
Moderator
Moderator
Posts: 8548
Joined: 28 Sep 2009 17:15
Location: Eastern KY
Contact:

Re: how to make vehicles and trains for open ttd?

Post by kamnet »

There's plenty of posts here to help, and for the most part things have not changed in years. Search through the forums, see the pinned links at the top.

NewGRFs are comprised of two parts, graphics and code. Graphics can be created on any program that can save as .png. There is a limitation, though. For traditional 8bpp graphics you will need to use a special palette of 256 colors, including a blue color used for transparency and special colors used in animations. If your graphics program can save in this kind of format, that's easy. You have another option of creating 32bpp graphics, but you'll lose the ability to use special company color (1cc or 2cc) unless you create special masks. But if you don't need company colors or color-animated pixels, then you can crank these out all day and night.

The preferred language for most sets these days is NML, but there are other languages as well that you can try later if you choose to be more ambitious. There's no special program required, you can use any plain text editor to create your files.

The tools required to compile your graphics and code into a working NewGRF file will require a computer or device running Windows, MacOS or Linux. As far as I know nobody has ported the tools to Android. You should be able to do it with a low-cost Raspberry Pi or other SBC running a Linux variant, and use a terminal program on your Android device to connect to it. Any low-end piece of junk computer can run the compiler, though.
User avatar
DemianWSE
Engineer
Engineer
Posts: 116
Joined: 21 Jul 2020 03:52
Location: Argentina

Re: how to make vehicles and trains for open ttd?

Post by DemianWSE »

[SPANISH] (English translation below)

Hola! Como dijo kamnet, no creo que exista una forma de hacer un NewGRF en android. Creo que lo mínimo que necesitás es un programa para hacer gráficos (puede ser Paint, pero es mejor usar Photoshop o GIMP), un editor de texto (podés usar el Block de notas) y después los programas para compilar tu NewGRF, que va a depender de qué lenguaje elijas para programar el set (hay tres opciones, hasta donde se: NFO, NML o m4nfo).

Acá están los manuales de esos tres lenguajes:
NFO: http://www.ttdpatch.de/grfspecs/nfogrfTechRef.html
NML: https://www.tt-wiki.net/wiki/NMLTutorial
m4nfo: http://www.ttdpatch.de/grfspecs/m4nfoManual/index.html

NFO es el menos amigable de los tres. Creo que la mejor forma de empezar es encontrar algún NewGRF simple para entender como funciona el código, y reemplazar los gráficos por los que vos hagas. Acá hay un tutorial hecho por Purno para hacer los gráficos que puede ser útil: http://users.tt-forums.net/purno/PDT/index.html

Suerte!
---------------------------------------------------------------------------------------------------------------------------------------------------
[ENGLISH]

Hi! As kamnet said, I don't think there is a way to make a NewGRF on android. I think the least you need is a program to make graphics (you can use MS Paint, but it's better to use Photoshop or GIMP), a text editor (you can use the Notepad) and the programs needed to compile your NewGRF, which depends on what language you choose to code the set (as far as I know there are three options: NFO, NML or m4nfo).

Here are the manuals for those languages:
NFO: http://www.ttdpatch.de/grfspecs/nfogrfTechRef.html
NML: https://www.tt-wiki.net/wiki/NMLTutorial
m4nfo: http://www.ttdpatch.de/grfspecs/m4nfoManual/index.html

NFO is the least friendly out of the three. I think the best way to start is to find a simple NewGRF to understand how the code works, and then replace its graphics with the ones you make. Here there is a tutorial by Purno on how to draw graphics that can be useful: http://users.tt-forums.net/purno/PDT/index.html

Good luck!
DemianWSE
Facu-Noguera
Engineer
Engineer
Posts: 2
Joined: 02 Sep 2021 04:12

Re: how to make vehicles and trains for open ttd?

Post by Facu-Noguera »

DemianWSE wrote: 03 Sep 2021 17:41 [SPANISH] (English translation below)

Hola! Como dijo kamnet, no creo que exista una forma de hacer un NewGRF en android. Creo que lo mínimo que necesitás es un programa para hacer gráficos (puede ser Paint, pero es mejor usar Photoshop o GIMP), un editor de texto (podés usar el Block de notas) y después los programas para compilar tu NewGRF, que va a depender de qué lenguaje elijas para programar el set (hay tres opciones, hasta donde se: NFO, NML o m4nfo).

Acá están los manuales de esos tres lenguajes:
NFO: http://www.ttdpatch.de/grfspecs/nfogrfTechRef.html
NML: https://www.tt-wiki.net/wiki/NMLTutorial
m4nfo: http://www.ttdpatch.de/grfspecs/m4nfoManual/index.html

NFO es el menos amigable de los tres. Creo que la mejor forma de empezar es encontrar algún NewGRF simple para entender como funciona el código, y reemplazar los gráficos por los que vos hagas. Acá hay un tutorial hecho por Purno para hacer los gráficos que puede ser útil: http://users.tt-forums.net/purno/PDT/index.html

Suerte!
---------------------------------------------------------------------------------------------------------------------------------------------------
[ENGLISH]

Hi! As kamnet said, I don't think there is a way to make a NewGRF on android. I think the least you need is a program to make graphics (you can use MS Paint, but it's better to use Photoshop or GIMP), a text editor (you can use the Notepad) and the programs needed to compile your NewGRF, which depends on what language you choose to code the set (as far as I know there are three options: NFO, NML or m4nfo).

Here are the manuals for those languages:
NFO: http://www.ttdpatch.de/grfspecs/nfogrfTechRef.html
NML: https://www.tt-wiki.net/wiki/NMLTutorial
m4nfo: http://www.ttdpatch.de/grfspecs/m4nfoManual/index.html

NFO is the least friendly out of the three. I think the best way to start is to find a simple NewGRF to understand how the code works, and then replace its graphics with the ones you make. Here there is a tutorial by Purno on how to draw graphics that can be useful: http://users.tt-forums.net/purno/PDT/index.html

Good luck!
Gracias Demian por los enlaces de los tutoriales!!Los voy a leer con atención y veré que puedo hacer 👍
Post Reply

Return to “Graphics Development”

Who is online

Users browsing this forum: No registered users and 15 guests