Nifflas' Support Forum

Level Editing Support => Knytt Stories Level Editing Support => Knytt Stories - Custom Content => Topic started by: minmay on September 13, 2009, 21:04:45

Title: How to Draw Simple Tilesets - So You Don't Have An Excuse Anymore
Post by: minmay on September 13, 2009, 21:04:45
Too long have we suffered from really, really bad tilesets.  Too long have we suffered from questions about transparency.  It is time to take action.

What?
This is a tutorial for drawing Knytt Stories tilesets in the style of those present in, for example, The Machine and A Strange Dream.  And the original Knytt, for that matter.  It is also a tutorial for how to make a tileset work in the editor in the first place.

Why?
I'm bored and I want to see more and better custom tilesets, though the impact of this post may not be as significant as I hope for it to be.

When?
Right now.

Where?
Okay, this isn't clever anymore.  We'll go on with it, then.





First of all, you will want to obtain a good image editing program.  If you decide to ignore this and use MS Paint, I hate you.  Sorry.  This tutorial will use GIMP, but none of it is specific to GIMP.

-The GIMP (http://www.gimp.org) is very powerful, and cross-platform.  Its interface may take some time to get used to, however, and it is not suitable for extremely low-end computers.
-Paint.NET (http://www.getpaint.net) seems to be preferred by the majority of Nifforumers.  While not the most versatile or powerful of programs available, it is simple to use.
-Photoshop and Paint Shop Pro are perfectly suitable, but neither one is free, and most of their features will be useless in tileset creation.



Now, I'll explain how to use custom tilesets in the first place.
Every KS level has its own directory.  Inside your Knytt Stories directory is a directory named Worlds.
The Worlds directory contains another directory for each level.  A level's directory will be named [author's name] - [level name].
If a level has custom tilesets, then its directory will contain a directory named Tilesets.
Inside this directory will be one or more tilesets, labeled with Tileset[number].png.
The number determines the tileset's ID in the editor, hence Tileset43.png will appear in slot 43 in the editor, Tileset214.png in slot 214, and so on.  You can use slot 0, and there is no particular reason not to.



Now, the conditions that the tileset itself must satisfy:
-It must be a valid PNG image.
-It must be 384 pixels wide and 202 pixels tall.
-It must have no completely transparent tiles except for the one in the top left.  (Regardless of the content of the top left tile, the game will treat it as transparent, hence it is pointless to put anything in the top left tile.)

The ten pixels at the bottom are used for an info bar, which is generally used for the tileset title and author name.  It is up to you what you put in that 384x10 space if anything.



And now, the part four or five people have been waiting for: how to draw a tileset.

First of all, start up your image editor.
Then open [your KS directory]/Data/Tilesets/Tileset0.png.  This is the tileset "template"; it meets all the game's tileset requirements and has all the tiles neatly marked out for you.  For reference, it's this:
(http://imgur.com/kO2Fy.png)

Then save it to [your KS directory]/Worlds/[your level's directory]/Tilesets/Tileset[number].png.  This will ensure that you don't accidentally save your own tileset over the Tileset0 in the Data folder (although if you do, it should be a trivial matter to correct).

You may want to turn on the grid function of your image editor; make sure it's set to 24x24 with no offset and no spacing.

Now it's finally time to start drawing - yay.
The first thing any KS tileset needs is its basic ground tiles.  Normally, this will be a box three tiles wide and three tiles tall, filled with some sort of texture.  Generally, the box will have a black outline that is one pixel thick, like this:
(http://imgur.com/gd851.png)

A simple ground texture will generally be a 4x4, 6x6, or 8x8 pattern of two colors.  It is generally preferable for the colors to not differ too strongly, and usually the result of this is that the second color is simply a different shade than the first color.  The best way to find an appealing texture is to experiment!
In any case, once you've drawn your texture, go ahead and copy-paste it to fill those nine tiles, then draw the box around it.  You'll end up with something like this:
(http://imgur.com/kJG8M.png)

Often, your ground tiles will look better if you put a slight layer of white or black "gloss" on their extremes.  Generally, you would do this by drawing over the desired pixels with Opacity set to 10% or so.  The effect is slight, but often very appealing.
(http://imgur.com/6wg6B.png)

A very common feature of tilesets is grass.  It is simple enough to draw; just draw a bunch of straight, dark green lines next to each other, constantly varying their height.  Generally, you'll want three or four grass tiles, and possibly "end" tiles:
(http://imgur.com/VxKxW.png)
(Here I've made two of the three tiles suitable for use as "end" tiles.  Also, the grass I've drawn here is rather taller than normal.  Of course, some tilesets won't have any place for grass at all.)

Another staple is background tiles, which can usually be done satisfactorily simply by altering the saturation, contrast, and especially brightness of the foreground tiles.  You may want to make multiple "flavors" of these.  Generally, they have 45-degree slopes instead of edges, for some reason.  It just looks better that way.  The tiles shown here would be used for, say, a cave:
(http://imgur.com/jBM0H.png)



And that's it!

No, really!  Drawing a simple tileset is, well, simple.  It takes a few minutes.  From there, you can simply add whatever you think suits the set.  I'm just going to add some rocks:
(http://imgur.com/rUq5o.png)

And make an example screen:
(http://imgur.com/6wAva.png)



Really, you can hardly expect me to write a complete pixel art tutorial.  There are thousands of things you can draw in a tileset, and many of them I can't even properly draw myself, let alone tell someone else how to.  This is intended as sort of a quickstart guide, nothing else.

Oh, and y'all are free to use/edit/steal that tileset as you wish.  It isn't like it's very good or anything.



If this whole thing seems a bit bare-bones, it's because, well, it is.  I assume that you already know what Knytt Stories is, for example.
Title: Re: How to Draw Simple Tilesets - So You Don't Have An Excuse Anymore
Post by: Dataflashsabot on September 13, 2009, 21:33:17
Nice tutorial. :)
Title: Re: How to Draw Simple Tilesets - So You Don't Have An Excuse Anymore
Post by: Pick Yer Poison on September 13, 2009, 22:22:08
Thanks for making this; it's about time someone did. We've had way too many "how do I make a tileset" threads started recently.
Title: Re: How to Draw Simple Tilesets - So You Don't Have An Excuse Anymore
Post by: LPChip on September 13, 2009, 22:25:06
Nice topic.

Topic awarded with a sticky ;)
Title: Re: How to Draw Simple Tilesets - So You Don't Have An Excuse Anymore
Post by: Evil on September 13, 2009, 23:37:11
*steals tileset*
Title: Re: How to Draw Simple Tilesets - So You Don't Have An Excuse Anymore
Post by: googoogjoob on September 14, 2009, 01:09:57
I applaud this tutorial.

Hopefully it will have its intended effect.
Title: Re: How to Draw Simple Tilesets - So You Don't Have An Excuse Anymore
Post by: StaticRomantic on September 14, 2009, 07:09:57
very nice. well put together.
hopefully this'll put an end to bad tilesets and spark more creativity in forummers :O
(although i have no room to speak)
Title: Re: How to Draw Simple Tilesets - So You Don't Have An Excuse Anymore
Post by: Razzorman on September 14, 2009, 08:34:33
hopefully this'll put an end to bad tilesets and spark more creativity in forummers :O
(although i have no room to speak)
Probably not that much. People who are bad at pixel art will still be bad at pixel art, even if they know where they are supposed to draw. :P

A general tip for up and coming tileset makers: If you do not know how to draw something that you want in your tileset, look at other tilesets. Open them in your image editor and zoom in to see how everything is done.
Title: Re: How to Draw Simple Tilesets - So You Don't Have An Excuse Anymore
Post by: Londeea on September 21, 2009, 09:17:03
Woot, this is a GREAT tutorial. Unfortunately I cannot see the pictures...
Title: Re: How to Draw Simple Tilesets - So You Don't Have An Excuse Anymore
Post by: googoogjoob on September 21, 2009, 09:22:09
Woot, this is a GREAT tutorial. Unfortunately I cannot see the pictures...

Yeah Vulomedia (which was hosting the images) appears to have crashed.
Title: Re: How to Draw Simple Tilesets - So You Don't Have An Excuse Anymore
Post by: Londeea on September 21, 2009, 10:07:35
And, Paint is a very easy program to function... the only problem I now have is finding the color that Knytt Stories accepts as a transparency.. but you can also use Irfranview for saving transparent pictures.
Title: Re: How to Draw Simple Tilesets - So You Don't Have An Excuse Anymore
Post by: AClockworkLemon on September 21, 2009, 10:54:01
if you mean msPaint, I've never been able to get magic pink (r=255,g=0,b=255,g=0) to work in that program. personally i have something against anyone who uses msPaint to make tilesets etc. blahblahblah....

If you are using msPaint, you should SERIOUSLY download Paint.net (http://www.getpaint.net/) It is like a free version of photoshop, and is ver handy. It can handle transparency no problems. like ACTUAL transparencey, not just magic pink.

so I repeat:
if you are using msPaint GET PAINT.NET (http://www.getpaint.net/)!
Title: Re: How to Draw Simple Tilesets - So You Don't Have An Excuse Anymore
Post by: Purple Pineapple on September 22, 2009, 02:22:58
if you mean msPaint, I've never been able to get magic pink (r=255,g=0,b=255,g=0) to work in that program.
Maybe that's because you've added two values for green. :P

Seriously, though. Will everyone please shut up about MS paint. If it ain't broke don't fix it. I thought tilesets were supposed to be about pixel art, not fancy effects, anyway.
Title: Re: How to Draw Simple Tilesets - So You Don't Have An Excuse Anymore
Post by: Pick Yer Poison on September 22, 2009, 03:07:03
Seriously, though. Will everyone please shut up about MS paint. If it ain't broke don't fix it. I thought tilesets were supposed to be about pixel art, not fancy effects, anyway.
Fancy pixel art doesn't count for squat if it doesn't show right.
Title: Re: How to Draw Simple Tilesets - So You Don't Have An Excuse Anymore
Post by: AClockworkLemon on September 22, 2009, 10:14:57
/\ I agree. Its all very well if your PixelArt is "DaBestInDaWordl!!!!!", but it's no use to you if you cant get it to work properly. If you can get magic pink to work in msPaint, good for you, but Paint.net (http://www.getpaint.net) is still a better tool as it has more functionality.

Anyway, could we get back on topic? minmay, Great tutorial!
Title: Re: How to Draw Simple Tilesets - So You Don't Have An Excuse Anymore
Post by: minmay on September 22, 2009, 19:16:23
While most drawing tools in editing programs will be useless for tilesets, having layers and more than three undos will be extremely useful.

One thing you will NEVER be able to do with MS Paint is alpha transparency - you know those gradients present in, say, the Desert tileset?  Can't make those.
Title: Re: How to Draw Simple Tilesets - So You Don't Have An Excuse Anymore
Post by: Londeea on September 26, 2009, 10:51:48
OK. Few things (really a couple):
1. You can make transparency with MS Paint, but not the mist-like effects Minmay (you mind MM? I love abbreviations) spoke of, but normal transparency - just use that magenta/pink/whatever for transparency.

2. This is a problem with me - my tileset ain't showing up. I'll post a pic of it soon... the name is Tileset11.png.
Title: Re: How to Draw Simple Tilesets - So You Don't Have An Excuse Anymore
Post by: Purple Pineapple on September 26, 2009, 19:10:26
Seriously, guys there's like 10 posts of mspaint ranting.
Title: Re: How to Draw Simple Tilesets - So You Don't Have An Excuse Anymore
Post by: minmay on September 26, 2009, 19:20:30
I didn't cover fudging transparency with magenta, because I don't want people to do it!  This tutorial assumes you have an image editor that can do transparency and you know how to use it.  It only covers what KS requires of tilesets - it doesn't cover how to meet those requirements with, say, MS Paint or Paint.NET or Photoshop or whatever you have.  Because, frankly, that would just be silly!  It's about tilesets, and nothing else.

This tutorial is about how to draw a tileset and what KS requires of the image.  It is not about how to "do" transparency.  If you don't know how to add transparency to an image (and you're using a program that can do so in the first place), your problem is one with your program, not with KS, and frankly doesn't really belong in the Knytt Stories Level Editing Support subforum.
Title: Re: How to Draw Simple Tilesets - So You Don't Have An Excuse Anymore
Post by: Razzorman on September 26, 2009, 20:42:17
Lets break this whole thing down before we shush everyone.

Basic pixel art
Ms paint: Easy enough, but you only get three undos, so making mistakes is incredibly annoying.
Any other program: Easy

Transparency
Ms paint: Can't do it, but you can use magenta if you want to. Semi-transparency and blurring is impossible.
Any other program: Can do it.

Brush sizes
Ms paint: A few presets.
Any other program: Allows you to scale brushes freely.

Selection tool
Ms paint: Annoying and limited.
Any other program: Useful.

Color selector
Ms paint: Good enough once you learn it, but you have to delete one of your preset colors to use it.
Any other program: Simple and easy to use.

Zooming
Ms paint: Has a few presets.
Any other program: Allows you to zoom freely.

Layers
Ms paint: Nope.
Most other programs: Yes.

Grids
Ms paint: Nope.
Most other programs: Yes.

Final verdict
Anyone still using paint is just being stubborn. Its useable, but not nearly as good as, well, anything.
If you want to use it, then go ahead, but I highly recommend that you get something else, like Paint.net (http://www.getpaint.net/index.html) or GIMP (http://www.gimp.org/).

Now lets not get any further off topic. :)
Title: Re: How to Draw Simple Tilesets - So You Don't Have An Excuse Anymore
Post by: Pick Yer Poison on September 26, 2009, 21:05:56
Grids
Ms paint: Nope.
Most other programs: Yes.
Actually, it does have a grid, and it works fairly well, but the rest of the post is still 100% correct.
Title: Re: How to Draw Simple Tilesets - So You Don't Have An Excuse Anymore
Post by: minmay on October 06, 2009, 04:03:01
I've moved the images since it turns out Vulo is gone for good.
Title: Re: How to Draw Simple Tilesets - So You Don't Have An Excuse Anymore
Post by: Shawnachu on October 06, 2009, 04:56:22
If you look down at this tileset by me (shameless advertising), this is how I like to lay out the general shape of my tiles. Ground is two 3x3 squares on the left. This leaves room for the 4x4+1 background tiles on top. Then you have a huge space on the right for anything you want, with nearly no size limitations.

I do recommend you make your first few tiles like this, it saves alot of room and makes the tileset easy to use.

EDIT: Oh, and MS Paint does have a grid, but unless you want to blind yourself with dotted gray lines and where one square=one pixel then I say no.
Title: Re: How to Draw Simple Tilesets - So You Don't Have An Excuse Anymore
Post by: Salmoneous on October 06, 2009, 07:29:46
Hey! Have anyone seen the new ms paint for the new windows OS? Apparently it will be more advanced.
Title: Re: How to Draw Simple Tilesets - So You Don't Have An Excuse Anymore
Post by: LPChip on October 06, 2009, 12:55:26
Hey! Have anyone seen the new ms paint for the new windows OS? Apparently it will be more advanced.

Although it is completelly offtopic, yes, I've already used it. Its better than the normal MS Paint, but doesn't beat say... Paint.net or gimp or any other known draw tool.
Title: Re: How to Draw Simple Tilesets - So You Don't Have An Excuse Anymore
Post by: minmay on October 06, 2009, 17:39:22
shawnachu: I have not covered, and will not cover, tile layout.  It is a matter of personal preference.  If you're making a tileset for other people to use, then you should worry about tile layout - but who makes KS tilesets specifically for public use?
Title: Re: How to Draw Simple Tilesets - So You Don't Have An Excuse Anymore
Post by: Razzorman on October 06, 2009, 19:17:05
but who makes KS tilesets specifically for public use?
I do. :|
Title: Re: How to Draw Simple Tilesets - So You Don't Have An Excuse Anymore
Post by: Gorfinhofin on October 07, 2009, 03:21:40
Lots of people did back when we had a tilesets board...
Title: Re: How to Draw Simple Tilesets - So You Don't Have An Excuse Anymore
Post by: Evil on October 07, 2009, 04:04:49
Lots of people did back when we had a tilesets board...

which is now th development showcase

post those tilesets! 
Title: Re: How to Draw Simple Tilesets - So You Don't Have An Excuse Anymore
Post by: Londeea on October 07, 2009, 09:13:17
You know, I wonder why the object 11 of bank 11 doesn't work.
Title: Re: How to Draw Simple Tilesets - So You Don't Have An Excuse Anymore
Post by: googoogjoob on October 07, 2009, 14:48:13
You know, I wonder why the object 11 of bank 11 doesn't work.

This was posted on the old forum and stuff: it doesn't work because the object isn't actually in the game, but its icon got left in the object bank. Or something.
Title: Re: How to Draw Simple Tilesets - So You Don't Have An Excuse Anymore
Post by: Londeea on October 09, 2009, 07:41:28
...OK...
Title: Re: How to Draw Simple Tilesets - So You Don't Have An Excuse Anymore
Post by: syeager on October 10, 2009, 07:39:55
Woo hoo hoo hoo. C)p Thanks for that. Now I can make my own tilesets.
Title: Re: How to Draw Simple Tilesets - So You Don't Have An Excuse Anymore
Post by: Meow Tse Tongue on December 23, 2009, 20:01:30
As for magic pink, it's apparently not a "real color".   Interesting link.
http://www.null-hypothesis.co.uk/science/strange-but-true/profs-probings/colour_spectrum_magenta_complimentary_bizarre
Title: Re: How to Draw Simple Tilesets - So You Don't Have An Excuse Anymore
Post by: Comhon on January 13, 2010, 14:14:06
Really good
Title: Re: How to Draw Simple Tilesets - So You Don't Have An Excuse Anymore
Post by: TheDarkOne on July 22, 2010, 03:21:29
Problem: how to copy/paste in Paint.NET without blowing your wrist up?
Title: Re: How to Draw Simple Tilesets - So You Don't Have An Excuse Anymore
Post by: Pumpkinbot on July 22, 2010, 10:05:28
Problem: how to copy/paste in Paint.NET without blowing your wrist up?
ctrl-x to cut, ctrl-c to copy, ctrl-v to paste.
Title: Re: How to Draw Simple Tilesets - So You Don't Have An Excuse Anymore
Post by: Mr. Macduggan on August 06, 2010, 19:10:05
This tutorial has really helped me and put me on track to make custom content! >) also pixel art in general.
Title: Re: How to Draw Simple Tilesets - So You Don't Have An Excuse Anymore
Post by: Enavesca on September 09, 2010, 13:35:48
Just found this really nice tutorial ! Thanks, it really learn lots of interesting things about pixel art and making custom content and it's also very easy to understand  :) !
Title: Re: How to Draw Simple Tilesets - So You Don't Have An Excuse Anymore
Post by: troels on September 14, 2010, 13:32:12
Hi there
 
I am trying to follow this tutorial, but I have to trouble getting the transparency right in Gimp.
I have several layers in my Gimp project that I am combining into on png image. But somehow, when I try to apply my "art" in KS, what happens is that the transparent pixels in the tiles cover the background!

What am I doing wrong?
How should I make transparent pixels in Gimp, that also work in the KS editor?

Best,
troels
Title: Re: How to Draw Simple Tilesets - So You Don't Have An Excuse Anymore
Post by: minmay on September 14, 2010, 18:13:16
It sounds like you're saving the image without an alpha channel.  However, I'm confused by that since as far as I know GIMP will always save an image with an alpha channel as an image with an alpha channel, provided the format supports it (and PNG does, and if a format doesn't then it will tell you).

I guess another possibility is that you're merging layers with alpha channels into a layer with no alpha channel and not noticing.  Make sure all the layers have an alpha channel.
Title: Re: How to Draw Simple Tilesets - So You Don't Have An Excuse Anymore
Post by: Comhon on September 17, 2010, 12:50:35
There is default empty tileset for Gimp users.
To see, what I changed without using Gimp, look in the preview.png
tileset.png file: I changed xcf to png, cause I can't upload xcf files. You can open it in the Gimp only
Title: Re: How to Draw Simple Tilesets - So You Don't Have An Excuse Anymore
Post by: KnyttAdventures on November 04, 2012, 00:46:58
Wow! Thanks! That's a great tutorial.
Title: Re: How to Draw Simple Tilesets - So You Don't Have An Excuse Anymore
Post by: Sisdog on July 31, 2013, 02:16:14
Alright, now how do I upload it? I have made my tileset, and finally saved it as one of the preexisting tilesets, my question is, How do I upload a tileset without replacing the other tilesets?
Title: Re: How to Draw Simple Tilesets - So You Don't Have An Excuse Anymore
Post by: Firecat on July 31, 2013, 02:55:29
and finally saved it as one of the preexisting tilesets
I sure hope you have a backup of that, as it may alter the look and or gameplay of other levels you play.
Anyways:
Quote from: Most KS level INI files
inside the folder for your level, create sub-folders for the custom art and music content and put them in there.
Knytt Stories\Worlds\Your Level\Tilesets\TilesetX.png
Knytt Stories\Worlds\Your Level\Music\SongX.ogg
Knytt Stories\Worlds\Your Level\Ambiance\AmbiX.ogg
...Where "Your Level" is the name of the autor of the level followed by a dash and the name of the level. And X is a number beteween 1 and 255.
Title: Re: How to Draw Simple Tilesets - So You Don't Have An Excuse Anymore
Post by: juhj on September 29, 2013, 10:34:15
When I make grass, I did exactly what you did, but then the original color I draw over is still there and when I make use of the tileset it ends up like this.
How do I fix it? I tried to make it white and I tried to make it black but still with no success. I also tried to take away the color using Rectangle select and then Move Selected Pixels, but it didn't work. (I use Paint.NET)
Title: Re: How to Draw Simple Tilesets - So You Don't Have An Excuse Anymore
Post by: Tablecat on September 29, 2013, 11:01:36
You have a problem as I see.
Who can fix it? Me!
To fix the transparency of its,
Make the bit depth 32 bits.
Then make your grass and trees!

(http://i329.photobucket.com/albums/l397/Bass_Net/ImageDepth_zpsd93cc9ff.png)
Title: Re: How to Draw Simple Tilesets - So You Don't Have An Excuse Anymore
Post by: juhj on September 29, 2013, 12:19:35
Thank you! Gives a :hiddenstar:
Title: Re: How to Draw Simple Tilesets - So You Don't Have An Excuse Anymore
Post by: SC on August 03, 2015, 01:09:22
Another program I'd recommend for tileset creation is Aseprite. (http://www.aseprite.org/) The current version (at time of posting) is $10, but you can grab version 0.9.5 for free and it works just as well as the paid version (give or take a few features).