Difference between revisions of "Preliminaries"

From TTWiki
Jump to navigationJump to search
 
Line 1: Line 1:
   
 
'''''What you need to know and do when making new graphics'''''
 
'''''What you need to know and do when making new graphics'''''
  +
  +
'''NOTE TO AUTHORS''': Read the LocalStyleGuide, otherwise the page may be rolled back to the last well-commented edit. (This applies everywhere, not just on the pages that mention it.)
   
 
To write:
 
To write:
Line 16: Line 18:
 
As you probably already found out ttd can load new graphics files with help of the patch. These files have the extension .grf and are located in the newgrf folder.
 
As you probably already found out ttd can load new graphics files with help of the patch. These files have the extension .grf and are located in the newgrf folder.
   
These .grf files are made by [http://www.ttdpatch.net/tools.html#grfcodec|the GRFcodec], this program merges a [[DrawingSprites|.pcx]] file and a .nfo file. <span style='color:#808080'>(links to george his tut now, but I think on top of that page should be an explanation about pcx files and their palet )</span> In this tutorial we won't look at those 2 file types yet, at first we shall try to explain the basics.
+
These .grf files are made by [http://www.ttdpatch.net/tools.html#grfcodec|the GRFcodec], this program merges a [[DrawingSprites|.pcx]] file and a .nfo file. <span style='color:#808080'>(links to george his tut now, but I think on top of that page should be an explanation about pcx files and their pallete )</span> In this tutorial we won't look at those 2 file types yet, at first we shall try to explain the basics.
   
-= The GRFCodec and the GRFWizzard=-
+
-= The GRFCodec and the GRFWizard=-
   
Like said before a .grf file is a file made by the GRFCodec. The Codec is a package of 3 programs:
+
Like said before a .grf file is a file made by the GRFCodec. The codec is a package of 3 programs:
   
 
&nbsp; 1. GRFCodec: Convert a GRF into an editable PCX file and vice versa
 
&nbsp; 1. GRFCodec: Convert a GRF into an editable PCX file and vice versa
Line 30: Line 32:
 
In this tutorial we will only use the first program, if you want more info about the other programs look [http://www.ttdpatch.net/grfcodec/grfcodec.html|here].
 
In this tutorial we will only use the first program, if you want more info about the other programs look [http://www.ttdpatch.net/grfcodec/grfcodec.html|here].
   
The GRFCodec is a commandline program. This means it's option are only been set in the comand line, there is no nice user interface. For the nice interfase you can download the [http://www.divxland.org/ttd/ttdsolutions.htm|GRFWizzard] This program is realy helpfull. Be warned though for the GRFWizzard to work you need the GRFCodec too.
+
The GRFCodec is a command line program. This means it's option are only been set in the command line, there is no nice user interface. For the nice interface you can download the [http://www.divxland.org/ttd/ttdsolutions.htm|GRFWizard] This program is really helpful. Be warned though for the GRFWizard to work you need the GRFCodec too.
   
When you run the GRFWizzard for the first time you have to point it to the Codec, when you have done this everything is realy straight forward, you can encode your homemade sprites (sprites are the little drawwings that represend one side of a building/vehicle) or you can decode a grf from someone else.
+
When you run the GRFWizard for the first time you have to point it to the codec, when you have done this everything is really straight forward, you can encode your homemade sprites (sprites are the little drawings that represent one side of a building/vehicle) or you can decode a grf from someone else.
   
When you want to encode graphics you have to point the wizard wich grf file you want to encode the 2nd step is to tell it in wich you placed the NFO and PCX. All these file should have the same name.
+
When you want to encode graphics you have to point the wizard which grf file you want to encode the 2nd step is to tell it in which you placed the NFO and PCX. All these file should have the same name.
   
If you want to encode totaly new graphics you have to make a &quot;fake&quot; grf. Just make a new txt file and rename it to the grf you want to encode.
+
If you want to encode totally new graphics you have to make a &quot;fake&quot; grf. Just make a new txt file and rename it to the grf you want to encode.
   
 
If you choose to decode a grf, the nfo and pcx will be extracted to a map called sprites in the in the folder where you placed the grfcodec in.
 
If you choose to decode a grf, the nfo and pcx will be extracted to a map called sprites in the in the folder where you placed the grfcodec in.
Line 44: Line 46:
 
<span style='color:#808080'> some sort of text here to explain why you need to understand hex?</span>
 
<span style='color:#808080'> some sort of text here to explain why you need to understand hex?</span>
   
HEX is a way of counting. You normaly count from 1 till 9 and then go to 10,11 etc. In HEX it works a bit diferend: you count from 0 till 9 but then you go one with A, B,C,D,E,F. So 1 till 9 is just 1 till 9, but then it gets funky A=10, B=11, C=12 and so one till F= 15. when you reach F you just do like you would do normaly, you start at 0 again but now with a 1 in front thus 10 (gee thats almost like normal counting! :P) so 10=16 If you want a better understandable explanation visit [http://people.ee.ethz.ch/~oetiker/webtools/rrdtool/tutorial/bin_dec_hex.html|this] link.
+
HEX is a way of counting. You normally count from 1 till 9 and then go to 10,11 etc. In HEX it works a bit differently: you count from 0 till 9 but then you go one with A, B,C,D,E,F. So 1 till 9 is just 1 till 9, but then it gets funky A=10, B=11, C=12 and so one till F= 15. when you reach F you just do like you would do normally, you start at 0 again but now with a 1 in front thus 10 (gee thats almost like normal counting! :P) so 10=16 If you want a better understandable explanation visit [http://people.ee.ethz.ch/~oetiker/webtools/rrdtool/tutorial/bin_dec_hex.html|this] link.
   
 
Now it would be rather uneasy if you have to count it all by yourself (or at least for me being of the lazy generation) so you can use the windows calculator for that.
 
Now it would be rather uneasy if you have to count it all by yourself (or at least for me being of the lazy generation) so you can use the windows calculator for that.
   
If you open it &nbsp;it take any hex, so you have to go to scientific. Just open view and klick on scientific mode.
+
If you open it &nbsp;it take any hex, so you have to go to scientific. Just open view and click on scientific mode.
   
If you did it corect it will look like this:
+
If you did it correctly it will look like this:
   
(sory I had to eat, I will see this page later on again)
+
(sorry I had to eat, I will see this page later on again)

Revision as of 23:31, 24 October 2005

What you need to know and do when making new graphics

NOTE TO AUTHORS: Read the LocalStyleGuide, otherwise the page may be rolled back to the last well-commented edit. (This applies everywhere, not just on the pages that mention it.)

To write:

- explain GRFCodec / GRFWizard

- explain hex codes: specific examples using Windows calculator, ideally with screenshots

- maybe: explain DOS/Windows version and how to convert between them

- other things?

-=What's a .GRF file?=-

As you probably already found out ttd can load new graphics files with help of the patch. These files have the extension .grf and are located in the newgrf folder.

These .grf files are made by GRFcodec, this program merges a .pcx file and a .nfo file. (links to george his tut now, but I think on top of that page should be an explanation about pcx files and their pallete ) In this tutorial we won't look at those 2 file types yet, at first we shall try to explain the basics.

-= The GRFCodec and the GRFWizard=-

Like said before a .grf file is a file made by the GRFCodec. The codec is a package of 3 programs:

  1. GRFCodec: Convert a GRF into an editable PCX file and vice versa

  2. GRFDiff: Compare two GRF files for differences, and write only the differences to a GRD file

  3. GRFMerge: Take a GRD file and merge it back into the GRF file

In this tutorial we will only use the first program, if you want more info about the other programs look [1].

The GRFCodec is a command line program. This means it's option are only been set in the command line, there is no nice user interface. For the nice interface you can download the [2] This program is really helpful. Be warned though for the GRFWizard to work you need the GRFCodec too.

When you run the GRFWizard for the first time you have to point it to the codec, when you have done this everything is really straight forward, you can encode your homemade sprites (sprites are the little drawings that represent one side of a building/vehicle) or you can decode a grf from someone else.

When you want to encode graphics you have to point the wizard which grf file you want to encode the 2nd step is to tell it in which you placed the NFO and PCX. All these file should have the same name.

If you want to encode totally new graphics you have to make a "fake" grf. Just make a new txt file and rename it to the grf you want to encode.

If you choose to decode a grf, the nfo and pcx will be extracted to a map called sprites in the in the folder where you placed the grfcodec in.

-=Hex=-

some sort of text here to explain why you need to understand hex?

HEX is a way of counting. You normally count from 1 till 9 and then go to 10,11 etc. In HEX it works a bit differently: you count from 0 till 9 but then you go one with A, B,C,D,E,F. So 1 till 9 is just 1 till 9, but then it gets funky A=10, B=11, C=12 and so one till F= 15. when you reach F you just do like you would do normally, you start at 0 again but now with a 1 in front thus 10 (gee thats almost like normal counting! :P) so 10=16 If you want a better understandable explanation visit [3] link.

Now it would be rather uneasy if you have to count it all by yourself (or at least for me being of the lazy generation) so you can use the windows calculator for that.

If you open it  it take any hex, so you have to go to scientific. Just open view and click on scientific mode.

If you did it correctly it will look like this:

(sorry I had to eat, I will see this page later on again)