Bay 12 Games Forum

Please login or register.

Login with username, password and session length
Advanced search  
Pages: 1 [2]

Author Topic: Specific wants from a tileset/graphics pack.  (Read 1497 times)

WormSlayer

  • Bay Watcher
    • View Profile
    • WormSlayer.com
Re: Specific wants from a tileset/graphics pack.
« Reply #15 on: August 15, 2010, 03:59:53 pm »

Personally I use photoshop which is handy for DF tile editing because it automatically converts the alpha channel to its own layer transparency, then back to alpha when you load and save PNG files.

Not sure how gimp handles png's but I know other people edit their tilesheets with it.

Most things in DF have a foreground and background colour. Anything in the RGB channels of the image is tinted with the foreground colour and the alpha channel is used, not for transparency, but to display the background colour.

For an example, check out the trees I made for the Ironhand set - The white leaves are tinted green, then the alpha channel bleeds through the brown background of the trunk.

You also may want to check out:
Tile Magic
Raw Tile Selector
« Last Edit: August 15, 2010, 04:07:19 pm by WormSlayer »
Logged

gramks2k

  • Bay Watcher
    • View Profile
Re: Specific wants from a tileset/graphics pack.
« Reply #16 on: August 15, 2010, 04:24:17 pm »

Installed and using Gimp, it seems to be working really well. Though I am involuntarily taking a crash course in transparencies along the way and I haven't quite figured some of it out yet...

Basically I noticed that the Phoebus 'staircase up' and 'staircase down' tiles do not match, and the 'staircase up' tile has steps that are far too large for Dwarfs. So I set about coming up with a new tile in MS Paint and came up with a decent tile, then I tried it out and it messed everything up since it doesn't save transparencies in MS Paint. Then I installed Gimp and I have had some success with it, but this is by my using copy and paste and not creating original transparency all on my own. Once I can figure out how to make the kinds of transparency that I need to, and get a better understanding of how the different rock hues are used I'll be on the fast track to making the custom tile set that I've wanted from the get-go.

tl;dr
Using Gimp, good times. Transparencies are a hurtle.
Logged

gramks2k

  • Bay Watcher
    • View Profile
Re: Specific wants from a tileset/graphics pack.
« Reply #17 on: August 15, 2010, 04:51:25 pm »

I guess my end goal is to be able to copy a tile out of the full-custom-tileset.png and open it in Gimp in a new file and edit it as I please, then paste it back in to the full file. I've already had a large amount of success with this, except for the editing it as I please. After a fair amount of messing around I can safely say that I could use some guidance with the transparencies, and how tiles work in general.

From what I gather...
The raw files assign the tile to be used for an object in game, and certain objects have hard-coded colors while others also have colors assigned in the raw files.
For what I'm concerned with (stairs, walls, rocks) gray scale tiles will take on the color of the material used to build the object (example; stairs dug out of bauxite will be red) and the gray scale will be used to hue the pixels to darker or lighter shades of red.
Anything drawn in the full tile-set file in color will remain that color in game no matter what.
Tile-magic summed up; There are two colors available to be assigned to a tile, foreground and background. Black used as background frees up the settable background color to be used basically as foreground color 2.

So, what I need cleared up is how to make the transparencies, and also how to determine what will be assigned foreground and background colors. And how to make the black so that it won't accidentally get colored...
Logged

WormSlayer

  • Bay Watcher
    • View Profile
    • WormSlayer.com
Re: Specific wants from a tileset/graphics pack.
« Reply #18 on: August 15, 2010, 06:00:12 pm »

> The raw files assign the tile to be used for an object in game, and certain objects have hard-coded colors while others also have colors assigned in the raw files.

Yup.

> For what I'm concerned with (stairs, walls, rocks) gray scale tiles will take on the color of the material used to build the object (example; stairs dug out of bauxite will be red) and the gray scale will be used to hue the pixels to darker or lighter shades of red.

Yeah but there are various exceptions and ways of overriding color.
http://df.magmawiki.com/index.php/DF2010:Color

> Anything drawn in the full tile-set file in color will remain that color in game no matter what.

Only if the game draws that tile with white as the foreground colour.  See below.

> Tile-magic summed up; There are two colors available to be assigned to a tile, foreground and background. Black used as background frees up the settable background color to be used basically as foreground color 2.

Not quite. The foreground tints everything, which you can play with (see this post) while alpha transparency allows the background colour to show through - doesnt matter what the colour is, which again you can play with.

> So, what I need cleared up is how to make the transparencies, and also how to determine what will be assigned foreground and background colors. And how to make the black so that it won't accidentally get colored...

Cant help with the how-to of working with alpha channels in gimp, but they are the key.
Logged

gramks2k

  • Bay Watcher
    • View Profile
Re: Specific wants from a tileset/graphics pack.
« Reply #19 on: August 15, 2010, 06:40:12 pm »

Those answers helped a bit, and I've been looking at google stuff and have figured out a bit about alpha layers. Basically if you have a layer and add an Alpha Mask to it and color the alpha mask in gray scale it will let that much of the layer show through on to the overall image (white = everything through, black = everything blocked).

Considering that I probably won't be using tile magic too much, what would be the purpose of using the alpha layers at all? I can think of one thing, but I would need confirmation... That's how the engravings in Phoebus' package works. I'm guessing that he drew a gray scale wall and then put some pixels around the perimeter of the wall using the alpha layer and kept the background color set to black. Then whenever the tile becomes engraved it sets the background color to white, which makes this odd engraved perimeter show up around his wall.

I guess I'm going to recreate this in the style of walls that I make for the custom tileset by doing the same thing, but the walls are going to be straight (no diagonals, just angles) and will look to be made out of bricks (like the Gold Plated tileset). Hopefully they turn out looking as good as they do in my mind.

If I ever do a massive amount of work on tiles I think I'll be able to figure out tile magic, but until then I'll probably just use it in little bits, like making engraving show up on walls.
Logged

WormSlayer

  • Bay Watcher
    • View Profile
    • WormSlayer.com
Re: Specific wants from a tileset/graphics pack.
« Reply #20 on: August 15, 2010, 07:52:33 pm »

Yah you seem to have the essentials. As you have noticed some things, like the smoothed/engraved walls, are hard-coded to use background colours, but with most its optional. It is a good way of maximising the variation possible from the limited number of tiles and colours though.

It's worth mentioning that Baughn is hard at work making a new tile format and rendering system, so in the not too distant future you may be able to make tiles in a totally different way.
Logged
Pages: 1 [2]