GRF encoder tool: GRFMaker [under development]

Discussions about the technical aspects of graphics development, including NewGRF tools and utilities.

Moderator: Graphics Moderators

User avatar
gl2
Engineer
Engineer
Posts: 21
Joined: 21 Jun 2004 08:20
Location: Budapest, Hungary

Post by gl2 »

Darkmast49 wrote:right.. now I need the basic files for TTDLX... Cuz when I start my version, it saids error reading registry.. and I don't even have an .exe files called transport tycoon deluxe.exe or something.. only ttconfig.exe
Hello Darkmast49!

Szappy sad:

The problem is, that GRFM is looking for a dir called 'newgrf' under the TTD directory. You can solve this problem by creating this directory in the openttd dir, then, after creating the grf file, you can move it to the proper openttd dir.
Also please note, that GRFM was not designed for OpenTTD, so not all of the functions in GRFM will work under OTTD.
User avatar
Samwise
Tycoon
Tycoon
Posts: 2459
Joined: 09 Apr 2006 18:50
Location: Oss, Netherlands, At home
Contact:

Post by Samwise »

aah thanks for that! Lets try it out..

EDIT: Same problem.. I think it's the OpenTTD being problem..
Image
DaleStan
TTDPatch Developer
TTDPatch Developer
Posts: 10285
Joined: 18 Feb 2004 03:06
Contact:

Post by DaleStan »

GRFMaker can generate Open-compatible GRFs, but I strongly encourage you not to try that; Open's newgrf support is documented exactly nowhere, so you'll never quite know whether your code or Open's support is broken.
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
Samwise
Tycoon
Tycoon
Posts: 2459
Joined: 09 Apr 2006 18:50
Location: Oss, Netherlands, At home
Contact:

Post by Samwise »

Ok, gonna try and find a PROPER download of TTDLX and TTDPatch, as now it gives an error reading registry.. But do you now how to solve the problem I have with GRFMaker, error (invalid filename)?
Image
User avatar
krtaylor
Tycoon
Tycoon
Posts: 11784
Joined: 07 Feb 2003 01:58
Location: Texas, USA
Contact:

Post by krtaylor »

If all you have is a registry error, you may be installed OK except for the registry. You can fix it easily with the registry tool, I think it's on the Patch website under tools.
Development Projects Site:
http://www.as-st.com/ttd
Japan, American Transition, Planeset, and Project Generic Stations available there
Patchman
Tycoon
Tycoon
Posts: 7575
Joined: 02 Oct 2002 18:57
Location: Ithaca, New York
Contact:

Post by Patchman »

If you get a registry error, you're trying to run TTD directly instead of the patch. So run the patch instead. The latest versions need no registry entries.
Josef Drexler

TTDPatch main | alpha/beta | nightly | manual | FAQ | tracker
No private messages please, you'll only get the answering machine there. Send email instead.
User avatar
Samwise
Tycoon
Tycoon
Posts: 2459
Joined: 09 Apr 2006 18:50
Location: Oss, Netherlands, At home
Contact:

Post by Samwise »

Thanks for the tips guys :)

EDIT: Now I have other problems.. TTDLOADW.OVL not found
GAMEGFX.exe: No such file or directory.. Gonna try and find them right now..

EDIT: GAMEGFX.exe found, and it works, TTDLOADW.OVL found as well, but it gives an error of ongeldige segmentlengte? (find a dictionary for dutch ;) cuz I can't translate this to english..
Image
Patchman
Tycoon
Tycoon
Posts: 7575
Joined: 02 Oct 2002 18:57
Location: Ithaca, New York
Contact:

Post by Patchman »

Most likely the gamegfx.exe is not the TTD/Win gamegfx.exe but some other random file. You have to get the gamegfx.exe that comes with TTD.
Josef Drexler

TTDPatch main | alpha/beta | nightly | manual | FAQ | tracker
No private messages please, you'll only get the answering machine there. Send email instead.
User avatar
Samwise
Tycoon
Tycoon
Posts: 2459
Joined: 09 Apr 2006 18:50
Location: Oss, Netherlands, At home
Contact:

Post by Samwise »

Ok Patchman.. where to download that? (I wish I still had the harddisk of my old pc, it was on there... :( )
Image
User avatar
lws1984
President
President
Posts: 945
Joined: 03 May 2004 11:34
Location: Spaceship Heart of Gold
Contact:

Post by lws1984 »

I was trying to figure something out, and the Wiki isn't helping due to the diffrences in terms, but I've been trying to figure out how to set up a livery refit (where you can change the livery by using the Refit window). I have callback 19 on, but after that I'm hopelessely lost. Could one of you please help?
It's not me in my avatar, it's a time lord!

Time is an illusion. Lunchtime, doubly so.
-Douglas Adams
DaleStan
TTDPatch Developer
TTDPatch Developer
Posts: 10285
Joined: 18 Feb 2004 03:06
Contact:

Post by DaleStan »

In the CB19 section of the action 2 chain, check (byte) variable F2. For each value starting at 00, return the xx of one D0xx text that you want attached to the cargo type. Once you have returned all desired texts, return and FF for all other values of F2.

In the graphics section of the action 2 chain, check variable F2, and return the graphics that correspond to the D0xx text that is returned by callback 19 for the same value of F2.
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
jonty-comp
Tycoon
Tycoon
Posts: 2542
Joined: 22 Oct 2005 16:05
Location: Chesterfield, England
Contact:

Post by jonty-comp »

Hey, would someone please mind giving me an idiot's guide to making steam engines with tenders? I downloaded the guide file but I can't understand it without instructions explaining it. :( I know it uses some kind of variational graphics, but I can't figure out how you make it attach to the rest of the engine when you buy it. Help would be greatly appreciated! :]
User avatar
krtaylor
Tycoon
Tycoon
Posts: 11784
Joined: 07 Feb 2003 01:58
Location: Texas, USA
Contact:

Post by krtaylor »

Another budding coder? Great news!
Development Projects Site:
http://www.as-st.com/ttd
Japan, American Transition, Planeset, and Project Generic Stations available there
User avatar
lws1984
President
President
Posts: 945
Joined: 03 May 2004 11:34
Location: Spaceship Heart of Gold
Contact:

Post by lws1984 »

ERm.... thanks DaleStan, but there appears to not be a CB19 section of an Action 2 chain, nor is there a place for variables in the graphics section.
It's not me in my avatar, it's a time lord!

Time is an illusion. Lunchtime, doubly so.
-Douglas Adams
User avatar
Samwise
Tycoon
Tycoon
Posts: 2459
Joined: 09 Apr 2006 18:50
Location: Oss, Netherlands, At home
Contact:

Post by Samwise »

At last I have TTDPatch.. but yet another problem.. Which buttons I have to input to change a trains graphic to my creation? And it still gives the problem of invalid filename..
Image
DaleStan
TTDPatch Developer
TTDPatch Developer
Posts: 10285
Joined: 18 Feb 2004 03:06
Contact:

Post by DaleStan »

jonty-comp wrote:Hey, would someone please mind giving me an idiot's guide to making steam engines with tenders?
... I can't figure out how you make it attach to the rest of the engine when you buy it.
Callback 16
lws1984 wrote:ERm.... thanks DaleStan, but there appears to not be a CB19 section of an Action 2 chain, nor is there a place for variables in the graphics section.
"CB19" is my lazy way of referring to callback 19. Do something like:

Code: Select all

1*0 04 00 9F 02 00 D0 " first livery" 00 " second livery" 00
2*0 01 00 02 08
//sprites for first livery
//sprites for second livery
3*0 02 00 00 01 01 00 00 00 00
4*0 02 00 01 01 01 01 00 01 00
5*0 02 00 02 81 F2 00 FF 01 00 00 00 00 01 00 // Select graphics (first livery if F2==00, second livery else (if F2==01)) 
6*0 02 00 03 81 F2 00 FF 02 00 FF 00 00 01 FF 01 01 FF FF // return texts for CB19 ((D0)00 for F2==00, (D0)01 for F2==01, FF else)
7*0 02 00 04 81 0C 00 FF 01 03 00 19 19 02 00 // Check for CB19
8*0 03 00 01 XX 00 04 00
As I've mentioned, I don't use GRFMaker, but that's the NFO for doing two liveries.
To add a third livery, add a third string to sprite 1, a third set of sprites after sprite 2, a third copy of sprite 3/4, and an additional option to sprites 5 and 6.
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
lws1984
President
President
Posts: 945
Joined: 03 May 2004 11:34
Location: Spaceship Heart of Gold
Contact:

Post by lws1984 »

Just a suggestion after coding some trams:

Perhaps you should update the "position" window with a road for RV's so that you don't have to approximate on the train tracks.
It's not me in my avatar, it's a time lord!

Time is an illusion. Lunchtime, doubly so.
-Douglas Adams
User avatar
jvassie
Tycoon
Tycoon
Posts: 3421
Joined: 18 Dec 2002 18:00
Location: High Wycombe, England
Contact:

Post by jvassie »

Szappy, i seem to get an error everytime i try to make a .grf file thorugh GRFMaker, it says 'Invalid filename' whilst trying to create it.

Got any ideas?

James
(British) Modular Stations Set - Thread: | Website:
Swiss Set - Thread: | Website:
Route Map Creator
My Screenshot Thread
DaleStan
TTDPatch Developer
TTDPatch Developer
Posts: 10285
Joined: 18 Feb 2004 03:06
Contact:

Post by DaleStan »

WhiteHand wrote:Note: I coded these to be compatible with the nightlies. They might work with the betas.
DaleStan wrote:I'm probably just anal-retentive, but I'm of the opinion that any GRF released should have version-checking code, and that the specified minimum version should, in fact, be the first version that supports all the features that the GRF uses.
WhiteHand wrote:Ofcourse, something that advanced is out of my coding grasp :p
DaleStan wrote:You use GRFMaker, right? Maybe it's time for a feature request: "Automatic version checking code"?
It'd take a quite a bit of work, but the introduction date of most newgrf features is pretty well documented, IIRC.

Of course, an override would be necessary so people who insert literal NFO could change the minimum version correctly.
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
uzusan
Engineer
Engineer
Posts: 74
Joined: 12 Apr 2005 22:17
Location: Scotland
Contact:

Post by uzusan »

Is this project still being worked on?
Reality is that which, when you stop believing in it, doesn't go away. - PKD
Post Reply

Return to “NewGRF Technical Discussions”

Who is online

Users browsing this forum: No registered users and 11 guests