A futuristic plan for new graphics

Got an idea for OpenTTD? Post it here!

Moderator: OpenTTD Developers

Post Reply
LordAzamath
Tycoon
Tycoon
Posts: 1656
Joined: 08 Jun 2007 08:00

A futuristic plan for new graphics

Post by LordAzamath »

Hello everybody. The other day I was in wiki and an interesting thought came into my mind...

EDIT: I know it's a bit messy over here :D

I just was in wiki exhibition again and looked those pictures.. They are made by various artists, thereby different. In-example the http://wiki.openttd.org/index.php/Image:Red_Flats_E.png I think should be 2x2 tiles, not 1x1 as original, for scalings sake. Same goes for http://wiki.openttd.org/index.php/Image ... _-_001.PNG. It just doesn't look good, when compared to other 1x1 buildings. The football stadium ( http://wiki.openttd.org/index.php/Image:Tag-stadium.jpg ) should even be 4x4 or 3x3, not 2x2.

http://wiki.openttd.org/images/b/b1/Gor ... ffices.png should be 4x4 too, I think. there are lot of examples. So I want to know from devs or somebody, that will there be major changes in that direction, so they wouldn't be sprite replacements, but new houses, which replace old ones. The tar or whatever it is in future, should contain only few things

1. The sprite
2. The sprite, when the new zoom-in levels are introduced. -> sprite with more details etc.
3. A text file. (extension may be ottdg -> OpenTTDGraphic or ogrf...Many possibilities :D but it's not important )

If it would be possible to branch it, I would be glad, but if not, then I don't mind it either. I know it would be a hell lot of a work :D....Although I know some games, where you can do everything with simple text files and pngs. It's called The Battle for Wesnoth, which uses WML, it's own markup language. Actually a lot of things below are based on that :)
Enjoy reading, because it's long and messy text below :D

Lord

Anyway....the whole concept ->

All files are simple text files with extensions:
  • *.ottd - some general things..Yet not sure
    *.ottdh - various header files, used as templates for things like defining official grass tiles, pavement for graphics. Also usable for any other things etc
    *.ottdg - defines new graphics and their props
    *.ottdi - defines IDs for various things. In this example it's for buildings in town
    other *.ottd*'s for any use.
    *.png - good old 32bpp-sprites are pngs :)
The ottdh-file for defining things, that should not be changed, but are used frequently. Like for graphics the grass/pavement tile properties. It acts like a template so they can be changed when needed, but then have to be defined somewhere else. One can even create another template file for himself

Let's say there is a file, that defines the pavements for all town-centre houses. It would look like following..

template_house.ottdh - it's location is ../data/templates/template_house.ottdh

Code: Select all

//OpenTTD header file

#define ('general_pavement')
id=000001
layout=1
sprites {
1 [
url="pavement/1.png"
elevation=0
]
}
#enddef
//end of template

Now there is a list of house-ids so the engine knows what to replace

id_house.ottdi it's loacation is in ../data/id/

//OpenTTD ID defining file

#define_id (
Shops_and_offices_temperate=000002
Flats_tropical=000003
Houses_temperate=000004
)
#enddef

//end of file
Now we've got basic descriptions for some houses and pavement
Now we want to make a new house, which would replace Shops and Offices in temperate OpenTTD. Let's say there is some *.ottd file, which is *big* and defines all default buildings and other objects. The id_house.oddti is then just reference for new graphics makers.



myawesomehouse.ottdg - it's location is in the ../data/new_graphics/

Code: Select all

//OpenTTD New Graphic File
#include 
{
url="../templates/template_general.ottdh"
}
#define_props {
gfx_id=LordAzamath00 //Should be unique, like in "real" grfs
gfx_name="My awesome render"
author="LordAzamath","Azamath","Lord","LA"
type=house
name="Shops and offices"
accept=passengers(1/8),mail(1/5),goods(4/6)
generate=passengers(5/8),mail(1/10)
replace=000002
house_type=centre
intro_year=1965
del_year=1978
//Here they are just most common. It may come in other years too
layout=1/2, 3/2, 4/2, ; 5/2, 6/2, 7/2
}
#enddef
#define_sprites {
1 [
url="1.png"
elevation=100
]
2 [
('general_pavement')
]
}
3 [
url="3.png"
elevation=100
]
4 [
url="4.png"
elevation=100
]
5 [
url="5.png"
elevation=100
]
6 [
url="6.png"
elevation=100
]
7 [
url="7.png"
elevation=100
]}
#enddef

Include command should order the parser to include those template files.
template_house.ottdh is used for pavement (look at sprites, sprite nr2. It uses ('general_pavement') from template_house)
id_house.ottdi is used for "replace_id=000002"

Define_props will define the properties for the object
gfx_id is something like in action8 id in real grfs. It's a string
gfx_name is the one it shows in "Configure GRFs" right now
Author is author. Multiple authors are separated with commas. They're strings, so should be between quotation-marks
type is the object type, you'll going to define. In this case it's house
avilable types are house, industry, track, general, ground
name is the one it shows in-game
acceptance-produce is common for industries and houses, but it's not limited to them. So if one want's (s)he can make ie. rails produce pax. It's the same thing as it shows in-game right now.
replace is the id, defined in id_house.ottdh, of which it object it might replace. If the value is false, then there must follow "add=999999" or soemthing like that. add function does the same thing as #define_id, but it's inside #define_props
layout is the layout of the object. If one one tile there are multiple sprites, they're separated by slash (/). The beginning of next tile is defined by comma (,) and new row by semi-colon (;). If there is 0 between commas, then it means there is no part of object in-tile. This should make possible irregular houses like "layout=1/2, 0, 4/2, ; 5/2, 0, 7/2" it means, that there are two 1x2 buildings in one object, but they're parted by one 1x2 space, where could be whatever...roads, rail, stations...even other houses.

#define_sprites will define sprites
1 is the sprite number, used in layout.
url is the location of the sprite.
elevation, is again for layout. It describes what sprite should be in front and what should be in background. Also for tunnels, it defines the place where a vehicle should go behind tunnel entrance. There could be even a standard elevation for i.e roads - road vehicles can only drive on that type of object, what has proper elevation. That makes possible to make "over-road" buildings. One value for roads is 50. And the other 51. A bus can ride on both of these, but a on elevation 50 it looks on road, on 51 it looks behind road, or a building. The layout would be road/building, whereas the road has elevation of 50 and building in that specific sprite 51. It's like a custom tunnel. For steam/diesel trains it could be 52,53,58,59...maglev - 54,55 monorail - 56,57, electrified trains only 58,59 It allows to create custom rails and different roads. Elevation over 100 isn't anymore special and is just - the greater the nubmber, the more front the sprite is. Elevation 0 is special for pavement under various buildings If there are two sprites for let's say steam trains then the elevations are 52 and 52+1


Another example for a steamer.

now some things must be added for general template
//OpenTTD header file

Code: Select all

#define ('general_pavement')
id=000001
layout=1
sprites {
1 [
url="pavement/1.png"
elevation=0
]
}
#enddef
#define ('rail')
id=000005
layout=1/2
sprites {
1 [
url="rail/steam_diesel/1.png"
elevation=52+1
]
2 [
url="rail/1.png"
elevation=52
]
}
#enddef
//here the elevation defines it's a place, where trains can go. It's special elevation value.
//end of template
Now we want to make a new train, which wouldn't replace anything.

myawesometrain.ottdg - it's location is in the ../data/new_graphics/

Code: Select all

//OpenTTD New Graphic File
#include 
{
url="../templates/template_general.ottdh"
}
#define_props {
gfx_id=LordAzamath01 //Should be unique, like in "real" grfs
gfx_name="My awesome train"
author="LordAzamath","Azamath","Lord","LA"
type=train
name="ES 101 DMA"
add=012345
train_speed=120
//speed is mph
train_price=64 250
//price is in £
train_weight=80
//always in tonnes
train_tractive_effort=2400
//in kN
intro_year=1976
del_year=2002
vehicle_reliability=86
//in percents (%)
life=18
//in years
capacity=passengers(36)
//if no capacity the it's 'false'
layout=1
}
#enddef
#define_sprites {
1 [
url="1.png"
elevation=52,53,58,59
]
//again special values, so it can go on standard rail, under std rail, and same for electric rails.
#enddef

Sorry for the text being very messy. It originated from reply to a blender thread, and the my thoughts only evolved :D I have covered only basics here, cos I don't think it would be useful to think everything out and then find out that it won't be done ....ever :)

EDIT: I forgot to make some things like introduction years, weight and speed for trains and stuff. Now repaired :)

Lord
PS: And I stopped the propaganda to support Dave Worley since he got a nice new red hat now.[/color]
I know I have a BBCode error in my signature but I really cba to fix it.
User avatar
FooBar
Tycoon
Tycoon
Posts: 6553
Joined: 21 May 2007 11:47
Location: The Netherlands
Contact:

Re: A futuristic plan for new graphics

Post by FooBar »

Personally, I'd like to stick to GRF. It's just far too easy with that new system of yours! :P The current level of difficulty of the NFO language makes it fun to use it (for me, that is).
Consider this as a complement :D
User avatar
ostlandr
Chairman
Chairman
Posts: 882
Joined: 12 May 2007 01:09
Location: Northeastern USA

Re: A futuristic plan for new graphics

Post by ostlandr »

As far as 3x3 and 4x4 buildings are concerned, we need to be careful of scale (i.e. Locomotion, with steel mills larger than Mount Everest and farms larger than cities).
Who is John Galt?
LordAzamath
Tycoon
Tycoon
Posts: 1656
Joined: 08 Jun 2007 08:00

Re: A futuristic plan for new graphics

Post by LordAzamath »

FooBar wrote:Personally, I'd like to stick to GRF. It's just far too easy with that new system of yours! :P The current level of difficulty of the NFO language makes it fun to use it (for me, that is).
Consider this as a complement :D
Considered :D Actually, that was my point... to make it easier for nfo n00bs like me :D. The second thing is, that it could allow even some scripting finally. A la you create a scenario and set a year, when a subsidy is offered. I again refer to WesnothMarkupLanguage of which I'm little familiar.
ostlandr wrote:As far as 3x3 and 4x4 buildings are concerned, we need to be careful of scale (i.e. Locomotion, with steel mills larger than Mount Everest and farms larger than cities).
I hacve thought about that... What if the current 1x1 buildings in 32bpp would be 2x2. Then the vehicles, now seemed to be too big or long, would fit into one tile. The road tiles would again be 1x1, so no heliport should be the same size of a patch of ROAD! etc. It would make the cities again larger and so on. That would require again bigger maps for x-large play (4096x4096). But I said futuristic plan... When the 32bpp models are all ready and stuff. I think it would add some realism..It's not about making the buildings bigger, but adding different sizes...You cant currently have i.e 2/3 of tile building, so you can actually build onto that 1/3. but if you have 3x3 and 2x2 buildings next to eacjother, you can. In real life the builings aren't aligned so well either ...
PS: And I stopped the propaganda to support Dave Worley since he got a nice new red hat now.[/color]
I know I have a BBCode error in my signature but I really cba to fix it.
User avatar
CMircea
Chairman
Chairman
Posts: 887
Joined: 29 Dec 2006 14:05

Re: A futuristic plan for new graphics

Post by CMircea »

You know what I'd do? Make an INI based system and have a scripting section where to put the NFO script. This way old good artists won't have to learn everything again. I'll try to see what I could do.
LordAzamath
Tycoon
Tycoon
Posts: 1656
Joined: 08 Jun 2007 08:00

Re: A futuristic plan for new graphics

Post by LordAzamath »

what's an INI based sys?
PS: And I stopped the propaganda to support Dave Worley since he got a nice new red hat now.[/color]
I know I have a BBCode error in my signature but I really cba to fix it.
User avatar
CMircea
Chairman
Chairman
Posts: 887
Joined: 29 Dec 2006 14:05

Re: A futuristic plan for new graphics

Post by CMircea »

Have you EVER edited the OpenTTD config file? That's in an INI format, which was made by M$ and it pretty nice.
LordAzamath
Tycoon
Tycoon
Posts: 1656
Joined: 08 Jun 2007 08:00

Re: A futuristic plan for new graphics

Post by LordAzamath »

Hmm...Seems quite nice indeed :)..and clean. I didn't know that THAT was an ini format :)
And as an answer, yes I have...once :D

So I guess this...

Code: Select all

//OpenTTD New Graphic File
#include
{
url="../templates/template_general.ottdh"
}
#define_props {
gfx_id=LordAzamath01 //Should be unique, like in "real" grfs
gfx_name="My awesome train"
author="LordAzamath","Azamath","Lord","LA"
type=train
name="ES 101 DMA"
add=012345
train_speed=120
//speed is mph
train_price=64 250
//price is in £
train_weight=80
//always in tonnes
train_tractive_effort=2400
//in kN
intro_year=1976
del_year=2002
vehicle_reliability=86
//in percents (%)
life=18
//in years
capacity=passengers(36)
//if no capacity the it's 'false'
layout=1
}
#enddef
#define_sprites {
1 [
url="1.png"
elevation=52,53,58,59
]
//again special values, so it can go on standard rail, under std rail, and same for electric rails.
#enddef
..would change into this, when using ini.

Code: Select all

[external_files]
include=../templates/template_general.ottdh

[define_props]
gfx_id=LordAzamath01
gfx_name="My awesome train"
author="LordAzamath","Azamath","Lord","LA"
type=train
name="ES 101 DMA"
add=012345
train_speed=120
train_price=64 250
train_weight=80
train_tractive_effort=2400
intro_year=1976
del_year=2002
vehicle_reliability=86
life= 18
capacity= passengers:36
layout=1

[sprites]
1=1.png
1_elev=52, 53, 58, 59
That isn't so different at my first thought at all :) and it's pretty much better too (cleaner look)...And OpenTTD already knows how to deal with ini format. That's a good idea :)
If this idea would work, then two things would be needed -> work on the needed strings-expressions for the ini-file itself and adding support for those attributes in source. Ofcourse I don't want it to stay that way I just showed you ;), I want it to get some more suggestions (not that these are bad, just maybe anyone ha noticed even better ones;) )and then....god knows what will happen then when devs support this idea :)

I read somewhere that some dev (possibly Belugas, but not sure) said that Open is not yet ready for it's own grf-specs. If thay translate these as *new, their own* specs, then I'm afraid it won't come in very near future....But until that, let's hear more opinions :)
PS: And I stopped the propaganda to support Dave Worley since he got a nice new red hat now.[/color]
I know I have a BBCode error in my signature but I really cba to fix it.
User avatar
FooBar
Tycoon
Tycoon
Posts: 6553
Joined: 21 May 2007 11:47
Location: The Netherlands
Contact:

Re: A futuristic plan for new graphics

Post by FooBar »

Problem with ini is (as far as I understand the format) that you can't duplicate values. You need a seperate INI-file for each vehicle/object.

I'd suggest some kind of XML-style:

Code: Select all

<newgrf>
  <name>Set Name</name>
  <desc>Set Description</desc>
  <train>
    <vehid>0A</vehid>
    <name>My new train</name>
    <sprites>
      <src>newgrf/sprite.png</src>
    </sprites>
    <speed>120</speed>
    //...etc...//
  </train>
  <train>
    <vehid>0B</vehid>
    <name>My second train</name>
    <sprites>
      <src>newgrf/sprite2.png</src>
    </sprites>
    <speed>121</speed>
    //...etc...//
  </train>
</newgrf>
But how do you plan to incorporate callbacks and the like?
User avatar
belugas
OpenTTD Developer
OpenTTD Developer
Posts: 1507
Joined: 05 Apr 2005 01:48
Location: Deep down the deepest blue
Contact:

Re: A futuristic plan for new graphics

Post by belugas »

lordazamath wrote:should even be 4x4 or 3x3, not 2x2. ... This should make possible irregular houses like "layout=1/2, 0, 4/2, ; 5/2, 0, 7/2"
May I remind you that the code has to be changed as well, it is not just a matter of definition.
The code expect at the most a 2x2 house. Anything else is not available right now.

By the way, how are you going to handle callback declaration with your system?
And conditionnal loading of pseudo sprites?

And how would your system coexist with loaded grfs?
Although it might sound like a good idea (as other text based grf replacement we have seen emerging), the work of implementing them and refining the concept to a level that AT LEAST equals nfo is so enormous that i do not see it been done.
And to what advantage? Make changes more accessible because more readable? I think that a lot of wonderfull grf have been made already using the current method, i don't see why it should stop.
lordazamath wrote:I read somewhere that some dev (possibly Belugas, but not sure) said that Open is not yet ready for it's own grf-specs. If thay translate these as *new, their own* specs, then I'm afraid it won't come in very near future....But until that, let's hear more opinions
There is a big difference between writing its own specs and changing the overall format of the said specs. What you are refering to is what I said about OpenTTD not been ready to submit its own modifications of grf specs regarding the newindustries specs.
If you are not ready to work a bit for your ideas, it means they don't count much for you.
OpenTTD and Realism? Well... Here are a few thoughs on the matter.
He he he he
------------------------------------------------------------
Music from the Bloody Time Zones
LordAzamath
Tycoon
Tycoon
Posts: 1656
Joined: 08 Jun 2007 08:00

Re: A futuristic plan for new graphics

Post by LordAzamath »

never known anything about the callbacks :D
BUT...
specs say:
specs wrote:<Sprite-number> * <Length> 02 0A <set-id> <version> <subtract-in-1> <subtract-in-2> <subtract-in-3> <add-out-1> <add-out-2> <again>
so INI would be(I think)

Code: Select all

[industry_callback]
definition_id=xx
subtr_in1=xx
subtr_in2=xx
subtr_in3=xx
...

conditional pseudo..
<sprite-number> * <length> [07/09] <variable> <varsize> <condition-type> <value> <num-sprites>
[something here, which defines what it is]
ok, I give up the writing right now :), I'm not familiar with what HAS to be in and what doesn't have. Anyway I think it is possible
Those things CAN be done, although it wouldn't be much different of making grfs with TTDPatch Specs in other hand. And those things - subtr etc are just for getting to write something, these have to be something normal :)...And with what Belugas pointed out...I (being a very easily influenced person) am starting to think of learning how to do proper GRFs not how to make new system :( ):
Anyway, I think that the irregular houses should be made whatsoever...Lots of hard work, where I can't do anything -> oh I feel so dumb at the moment. I will not write more, or I'll say something worse than herebefore :D

Anyway, I still have one quote by Athanasios, what gived me all those nice ideas, what I haven't pt anywhere yet :) (It's so easy to start blaming Athanasios, for putting these thougths in my mind...so easy :D)
Athanasios wrote:Some things have to change one day...
..and I'm 100% with him...

Lord
PS: And I stopped the propaganda to support Dave Worley since he got a nice new red hat now.[/color]
I know I have a BBCode error in my signature but I really cba to fix it.
Rubidium
OpenTTD Developer
OpenTTD Developer
Posts: 3815
Joined: 09 Feb 2006 19:15

Re: A futuristic plan for new graphics

Post by Rubidium »

When can we see the first working prototype doing everything that NewGRF does?
User avatar
CMircea
Chairman
Chairman
Posts: 887
Joined: 29 Dec 2006 14:05

Re: A futuristic plan for new graphics

Post by CMircea »

I suggested using NFO to do the actions and so, but using XML or INI to define the properties. Then we could slowly add our own scripting language based on something modern and easy like Lua, PHP, Perl, etc. (no Python, please, it's so annoying that whitespace matters)
User avatar
belugas
OpenTTD Developer
OpenTTD Developer
Posts: 1507
Joined: 05 Apr 2005 01:48
Location: Deep down the deepest blue
Contact:

Re: A futuristic plan for new graphics

Post by belugas »

Desolator, can you write the parser for that? It must be such a pretty code...

and by the way :
Some things have to change one day...
Yes, they do, but things that DO work are FAR less required to be changed. And not for trivial reasons...
If you are not ready to work a bit for your ideas, it means they don't count much for you.
OpenTTD and Realism? Well... Here are a few thoughs on the matter.
He he he he
------------------------------------------------------------
Music from the Bloody Time Zones
LordAzamath
Tycoon
Tycoon
Posts: 1656
Joined: 08 Jun 2007 08:00

Re: A futuristic plan for new graphics

Post by LordAzamath »

belugas wrote:
Some things have to change one day...
Yes, they do, but things that DO work are FAR less required to be changed. And not for trivial reasons...
Still, the reason is not very trivial...When you want to add a building in the future, when the 32bpp is ready and original gfx are not required anymore, you still need to write nfo. I think I have added *Futuristic, Plan, New graphics* in the title for this thread...So when futurism isn't popular, that doesn't mean it's trivial ;)

I, for one, thought about what will be done in few years, not being done right now and for grfs. I thought by that time, such changes are possible. Inexample those irregular houses would be useful I think even w/o new graphics coding plan. And I'm pretty well conviced by the tempo of your current development (Bjarni, Darkwater, Ludde, Mihamix, orudge, peter1138, Belugas, blathijs, Celestar, glx, KUDr, rubidium, Tron, Maedhros, Richk -> GREAT WORK :bow: :bow: :bow: :bow: :bow: :bow: :bow: :bow: :bow: if anyone is out of list sorry :D), there will be a LOT of changes in a year or so... Who knows..

In this plan, I wanted to make something for easier PNG-coding, not for GRF-replacement. Anyway, I don't believe, that when all the models in 32bpp are released, you still use 8bpp grfs, but use 32bpp models.But then, the pcx-files again would not be needed. But that would lead to many changes and misunderstandings, errors etc. So I thought, that maybe it's a good idea to prevent all that mess, by starting to implement a wholly differnest solution, and do it early enough. I never intended to make it a standard for current "business :)"

Lord
PS: And I stopped the propaganda to support Dave Worley since he got a nice new red hat now.[/color]
I know I have a BBCode error in my signature but I really cba to fix it.
Rubidium
OpenTTD Developer
OpenTTD Developer
Posts: 3815
Joined: 09 Feb 2006 19:15

Re: A futuristic plan for new graphics

Post by Rubidium »

From the beginning of 32bpp the whole intention has been and will be that 8bpp graphics, including NewGRFs, are necessary to have a working 32bpp game. This so one can choose to play with 32bpp graphics in MP, but one is not forced to do so.

Therefore 32bpp is nothing more than loading 32bpp sprites and drawing them instead of drawing their respectable 8bpp sprites.

This approach makes everything very clear and will not cause OTTD to be split into two camps where one runs 32bpp and the other does not. It also allows much more freedom in the choice of 32bpp graphics when playing games. You can even load your nice 32bpp grass sprites when playing multiplayer on any of the nightlies.

So do not expect something remotely like NewGRF to be 32bpp exclusive. Furthermore don't expect that OpenTTD will support two distinct formats for graphics as that is only going to give trouble.

The only feasible place for your idea (IMO) seems to be an external application that takes your text file plus a bunch of PNGs and creates a NewGRF with 8bpp downscaled graphics and a tar with the properly encoded PNGs with correct names and offsets.
LordAzamath
Tycoon
Tycoon
Posts: 1656
Joined: 08 Jun 2007 08:00

Re: A futuristic plan for new graphics

Post by LordAzamath »

Ok, thanks for the explanation :). I'm afraid that from now on I can't really talk on that issue, because it would need to know atleast the basics of grffing and things. The way you described makes it now clear. So there will never be only 32bpp Open. Understood. Thanks again.

Lord
PS: And I stopped the propaganda to support Dave Worley since he got a nice new red hat now.[/color]
I know I have a BBCode error in my signature but I really cba to fix it.
DaleStan
TTDPatch Developer
TTDPatch Developer
Posts: 10285
Joined: 18 Feb 2004 03:06
Contact:

Re: A futuristic plan for new graphics

Post by DaleStan »

How many times? Just with a simple search:

http://www.tt-forums.net/viewtopic.php?f=36&t=22937
http://www.tt-forums.net/viewtopic.php?f=32&t=23478
http://www.tt-forums.net/viewtopic.php?f=33&t=23386
http://www.tt-forums.net/viewtopic.php?f=36&t=24310
http://www.tt-forums.net/viewtopic.php?f=29&t=29399

I expect there are more.

The eternally repeated theme in those threads:
Patchman wrote:It seems to me like there are really two options here:
  1. Write a program that takes your "plain text" spec file and converts it to NFO, then use the already-(mostly-)working NFO support in OTTD and be done. [1]
  2. Write a program that takes your "plain text" spec file and converts it to some other, yet-to-be-specified easily computer-readable format. Then start from scratch implementing this format (which for NFO took many, many months and won't be significantly faster no matter how nicely you design your new one), fixing bugs, redoing the specs because you find things you need to do that can't be done, restart coding yet again, fixing the limitations of specs. Deal with the headaches of supporting two incompatible formats internally (unless you want to drop support for all existing graphics). Repeat as necessary.
My point is, why not use a format that works, can do just about everything that needs to be done[2], that there are many people out there who know how it works, and that OTTD mostly supports already? Why bother making all the mistakes that TTDPatch made all over again in a new design?

I'm not saying NFO is perfect. It has warts, and some things aren't designed as cleverly or cleanly as they could've been (because it's a grown design that grew as artist's demands increased). However, it is very simple for doing simple things (you can make a new train with four or five lines of very simple "code". It can get very complex too, but only when complex things need to be done. You cannot remove the complexity without losing its power and sophistication. Any new design will need to be just as complex if it needs to be able to do what NFO can do[3].

If the hex-ness of NFO is the only thing that bothers you, then it's the only thing that needs fixing. This means either improving/fixing GRFMaker, or writing a "plain text"->NFO converter. A variation of the latter would need to be written even if you come up with your own format.

So why not NFO?

[1] Whether the graphics are 8bpp or 32bpp or 256bpp does not matter here. The way sprites are encoded in the file is irrelevant. NFO can work just as well no matter what type of sprites you have.
[2] And can relatively easily be extended to support new things.
[3] For example Locomotion has a very simple format. As a result it can only do simple things. No repainting of wagons after N years to show a new historical livery. No showing of dirt as vehicles get older. No random variations in colours. No seasonal cargo acceptance/production of industries. No sophisticated animation control. No sophisticated station designs. No simple support for trainsets, other than defining a new vehicle ID for each loco and each wagon in each train set. Etc...
To get a good answer, ask a Smart Question. Similarly, if you want a bug fixed, write a Useful Bug Report. No TTDPatch crashlog? Then follow directions.
Projects: NFORenum (download) | PlaneSet (Website) | grfcodec (download) | grfdebug.log parser
User avatar
CMircea
Chairman
Chairman
Posts: 887
Joined: 29 Dec 2006 14:05

Re: A futuristic plan for new graphics

Post by CMircea »

Hmm, I think I'll try to make something that converts a much readable format into NFO, but this won't happen soon since I don't have time right now. This way I can make everyone happy...well, almost everyone :P
Post Reply

Return to “OpenTTD Suggestions”

Who is online

Users browsing this forum: No registered users and 9 guests