Requesting GRF: cargosetw.grf

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
dicepart
Engineer
Engineer
Posts: 6
Joined: 22 Jun 2009 03:37

Requesting GRF: cargosetw.grf

Post by dicepart »

I have the file cargosetw.grf (modified July 2003) but some of the sprites have an error (there is a white line underneath the bottle truck (Goss model) going NE or NW when full or empty). I have searched for this file on ttdpatch.net but there is only the same version that I have.

I learned that there is a new one from
http://osdir.com/ml/games.ttdpatch.gene ... 00106.html
in which M. Blunck responds that the file with this error is the old version. He directs the poster to his website.
However, his website is down, and I can't find the file any where else.

Does anyone have a copy of cargosetw.grf with a date after 2003 July?
Attachments
Attempted screenshot of the "white line" beneath Goss bottle truck.
Attempted screenshot of the "white line" beneath Goss bottle truck.
TingTong Transport, 10th Apr 2014.png (11.52 KiB) Viewed 4432 times
User avatar
Ammler
President
President
Posts: 953
Joined: 18 Jun 2006 18:18
Location: Switzerland
Contact:

Re: Requesting GRF: cargosetw.grf

Post by Ammler »

If you read further on that mail thread, you should see, that the bug remains in the latest update. The same version is also on the ttdpatch version of the coop pack.
Eddi
Tycoon
Tycoon
Posts: 8289
Joined: 17 Jan 2007 00:14

Re: Requesting GRF: cargosetw.grf

Post by Eddi »

note that the cargoset is generally considered outdated, so don't expect any kind of update to it
User avatar
FooBar
Tycoon
Tycoon
Posts: 6553
Joined: 21 May 2007 11:47
Location: The Netherlands
Contact:

Re: Requesting GRF: cargosetw.grf

Post by FooBar »

With a little help of grfcodec that's an easy fix though.
dicepart
Engineer
Engineer
Posts: 6
Joined: 22 Jun 2009 03:37

Re: Requesting GRF: cargosetw.grf

Post by dicepart »

FooBar wrote:With a little help of grfcodec that's an easy fix though.
Dear FooBar,

I downloaded the grfcodec and attempted to fix the problem with the grf file.
I thought that the definition of the sprite was one too deep (tall), so I wanted to make that sprite line "invisible" to OpenTTD by making it blue.

Using a pcx editor, I looked at the pcx generated by the program, and located the Goss-brand container trucks (sprites 201-272). I then added a blue line (1 pixel deep; color copied from other sprites) at the bottom of each NW or NE traveling Goss truck. I recompiled the grf and loaded it, but the white line is still present, as if I had done nothing. Yes, the new grf has a date of 2009.

Was wondering what I did wrong? Which steps should I take to correct the problem?
Attachments
Before (left) and after (right) of what was done with each Goss-brand truck.<br />(Black guidelines added for this posting only, to clarify what was done.)
Before (left) and after (right) of what was done with each Goss-brand truck.
(Black guidelines added for this posting only, to clarify what was done.)
Goss-edit.jpg (2.78 KiB) Viewed 4188 times
User avatar
FooBar
Tycoon
Tycoon
Posts: 6553
Joined: 21 May 2007 11:47
Location: The Netherlands
Contact:

Re: Requesting GRF: cargosetw.grf

Post by FooBar »

What you did sounds to me like a correct way to do it (the other way being to change the nfo reducing the height of the sprite).

Are you certain that the game is actually using the correct file?

EDIT: Attached you can find a diff to correct the decoded nfo.
Attachments
cargoset.diff
Diff to fix white line in some Goss Container truck sprites.
(5.09 KiB) Downloaded 101 times
dicepart
Engineer
Engineer
Posts: 6
Joined: 22 Jun 2009 03:37

Re: Requesting GRF: cargosetw.grf

Post by dicepart »

Dear FooBar,

Thank you for your prompt reply.
After I wrote my last reply to you, I started adjusting the height parameters of the effected sprites. I recompiled, pasted the file into my OpenTTD data folder, and noticed no difference in my game. I removed and re-added the grf in game, etc but there was no change.

I noticed that I can edit a grf file with notepad. However I haven't noticed any in-game changes when doing so. Can you confirm? That is, the nfo must be edited, then compiled with an associated pcx. Editing the grf directly (which has same data-structure as nfo) does not change the effect of that grf on the game.

Thank you for attaching the .diff file, I will go and again attempt these changes.
User avatar
FooBar
Tycoon
Tycoon
Posts: 6553
Joined: 21 May 2007 11:47
Location: The Netherlands
Contact:

Re: Requesting GRF: cargosetw.grf

Post by FooBar »

Adding some blue to the pcx should work just as well, really. Even (hex)editing the grf directly should work...

Only thing I can think of is that you don't have the newly adjusted grf in the correct position, or are having the old one still in place with the new under a different name.

The diff changes exactly what you started changing manually. So if for some reason the aforementioned options don't work, I don't expect this to work either...
dicepart
Engineer
Engineer
Posts: 6
Joined: 22 Jun 2009 03:37

Re: Requesting GRF: cargosetw.grf

Post by dicepart »

FooBar wrote:What you did sounds to me like a correct way to do it (the other way being to change the nfo reducing the height of the sprite).

Are you certain that the game is actually using the correct file?
I have found my error!

Here is what happened: I renamed the old cargosetw.grf as _cargosetw.grf and left it in the /data directory. I then pasted the new cargosetw.grf into the /data directory.
Upon game loading, the game looked at the ID (hash, or checksum, or something) of the file that it was using, and redirected itself to the _cargosetw.grf. I reapplied the .grf, and it again reloaded the _cargoset.grf instead of the cargosetw.grf with the new ID.

So yes, you were right, the game was not using the correct file. I should have removed the old grf from the /data directory completely.

But the good news is the white lines are gone! Well, except for in the Goss-brand plywood trucks. I can edit those myself.
User avatar
FooBar
Tycoon
Tycoon
Posts: 6553
Joined: 21 May 2007 11:47
Location: The Netherlands
Contact:

Re: Requesting GRF: cargosetw.grf

Post by FooBar »

Well there you go :wink: Good that you have it figured out now!

Also my compliments on you hands-on approach! You wouldn't be the first one to sit still until someone else fixed it for you. People who actually attempt to fix it themselves after one single hint on where to start are a welcome change around here! :P
Eddi
Tycoon
Tycoon
Posts: 8289
Joined: 17 Jan 2007 00:14

Re: Requesting GRF: cargosetw.grf

Post by Eddi »

dicepart wrote:I then added a blue line (1 pixel deep; color copied from other sprites) at the bottom of each NW or NE traveling Goss truck.
technically, just flood-filling all the white should do the trick as well, the areas outside of the sprites are ignored by grfcodec
User avatar
Benny
Tycoon
Tycoon
Posts: 2185
Joined: 25 Aug 2007 17:03
Location: ~/

Re: Requesting GRF: cargosetw.grf

Post by Benny »

Eddi wrote:
dicepart wrote:I then added a blue line (1 pixel deep; color copied from other sprites) at the bottom of each NW or NE traveling Goss truck.
technically, just flood-filling all the white should do the trick as well, the areas outside of the sprites are ignored by grfcodec
That makes the .grf a bit bigger in size too, doesn't it?
Image
Yexo
Tycoon
Tycoon
Posts: 3663
Joined: 20 Dec 2007 12:49

Re: Requesting GRF: cargosetw.grf

Post by Yexo »

Bennythen00b wrote:
Eddi wrote:
dicepart wrote:I then added a blue line (1 pixel deep; color copied from other sprites) at the bottom of each NW or NE traveling Goss truck.
technically, just flood-filling all the white should do the trick as well, the areas outside of the sprites are ignored by grfcodec
That makes the .grf a bit bigger in size too, doesn't it?
Please explain why ignoring blue pixels would make the grf bigger as opposed to ignoring some white pixels.
User avatar
Benny
Tycoon
Tycoon
Posts: 2185
Joined: 25 Aug 2007 17:03
Location: ~/

Re: Requesting GRF: cargosetw.grf

Post by Benny »

My bad. I read "OpenTTD", and not "GRFcodec". :oops:
Image
dicepart
Engineer
Engineer
Posts: 6
Joined: 22 Jun 2009 03:37

Re: Requesting GRF: cargosetw.grf

Post by dicepart »

FooBar wrote:Well there you go :wink: Good that you have it figured out now!
Attached is the grf file which I requested at the beginning of this topic. (Technically speaking, it isn't. This is an unofficial version.) I have attached it in case anyone else is looking for it. This file is heavily based off of work by Michael Blunck.

Thanks to FooBar, who assisted me with technical issues.

The changes in this grf are undocumented; perhaps later I will release one with documentation of exactly what I did[n't] do. Technically speaking, there was a better way to fix the file. Regardless, enjoy the absence of the white lines beneath your (newer) Goss trucks!

In order to get this file to work, you will need to go to your GRF options (once the game has started), then manually remove the use of your old cargosetw.grf file and add the file ncargosetw.grf. Then press apply.
Attachments
ncargosetw.grf
(321.58 KiB) Downloaded 197 times
User avatar
Benny
Tycoon
Tycoon
Posts: 2185
Joined: 25 Aug 2007 17:03
Location: ~/

Re: Requesting GRF: cargosetw.grf

Post by Benny »

Which license is the original grf file licensed under? I've had some license problems myself.
Image
User avatar
Ammler
President
President
Posts: 953
Joined: 18 Jun 2006 18:18
Location: Switzerland
Contact:

Re: Requesting GRF: cargosetw.grf

Post by Ammler »

AFAIK, all grfs from MB are licensed like CC-ND, so you aren't allowed to modify them, and for sure you aren't allowed to publish them without his permission. Please, ask on his thread, if he can give you permission and delete the GRF until you have.
http://www.tt-forums.net/viewtopic.php?p=681507

Greets
Ammler
User avatar
FooBar
Tycoon
Tycoon
Posts: 6553
Joined: 21 May 2007 11:47
Location: The Netherlands
Contact:

Re: Requesting GRF: cargosetw.grf

Post by FooBar »

This one happens to be GPL. That still means that you have to pack the grf appropriately with readme and more importantly a copy of the license.

If you download the faulty version from ttdpatch.net, extract that, replace the grf with your new version and update the readme to reflect what changes and when you made them. Then repack it again and it's fine for distribution.

EDIT: Let me set this straight before misunderstandings occur: The cargoset file you can get from http://www.ttdpatch.net/newgrf.html#20 is GPL licensed. The one in the OpenTTDCoop grf pack is not. Modifications versions of the file from the OpenTTDCoop grf pack therefore cannot be distributed.
User avatar
Ammler
President
President
Posts: 953
Joined: 18 Jun 2006 18:18
Location: Switzerland
Contact:

Re: Requesting GRF: cargosetw.grf

Post by Ammler »

FooBar wrote: Modifications versions of the file from the OpenTTDCoop grf pack therefore cannot be distributed.
cargoset.grf isn't in the pack, so it can't be used, the Link to the readme is from the "private" ttdpatch version, which was never published. I have downloaded that version from ttdpatch.de, which is currently offline.

This wonders me, are all newgrfs from MB on the ttdpatch.net site GPL'd? checking... (Edit: No, cargoset seems the only one.)

Greets
Ammler
User avatar
FooBar
Tycoon
Tycoon
Posts: 6553
Joined: 21 May 2007 11:47
Location: The Netherlands
Contact:

Re: Requesting GRF: cargosetw.grf

Post by FooBar »

It isn't? Then that link you've sent me must've confused me. Either way: always check the license before distributing something that you've modified ;)
Post Reply

Return to “Graphics Development”

Who is online

Users browsing this forum: Bing [Bot], Majestic-12 [Bot] and 10 guests