Java-Gaming.org Hi !
Featured games (83)
games approved by the League of Dukes
Games in Showcase (522)
Games in Android Showcase (127)
games submitted by our members
Games in WIP (589)
games currently in development
News: Read the Java Gaming Resources, or peek at the official Java tutorials
 
    Home     Help   Search   Login   Register   
Pages: [1]
  ignore  |  Print  
  Program for spritesheet?  (Read 869 times)
0 Members and 1 Guest are viewing this topic.
Offline SauronWatchesYou
« Posted 2014-04-22 14:54:58 »

I'm looking for a good program (free) to use to create a sprite sheet. I want to use it with Slick2D and create some nice animations for my golden coins as they fall down the screen. I've never done sprite sheets or animation before so any tips/techniques would be appreciated Smiley
Offline Rayvolution

« JGO Spiffy Duke »


Medals: 219
Projects: 2
Exp: 1 year


Resident Crazyman


« Reply #1 - Posted 2014-04-22 15:03:38 »

GIMP or Aseprite are good options. GIMP is a highly recommended free alternative to Photoshop.

Really, pixel art doesn't need much in the way of tools (since you should be drawing everything with a pencil tool anyway), but having a program like Photoshop or GIMP can still help you tons. Once you get really deep into complicated pixel art, it's nice to have layers, selection tools, action scripts and other advanced tools.

- Raymond "Rayvolution" Doerr.
Retro-Pixel Castles - Survival Sim/Builder/Roguelike!
LIVE-STREAMING DEVELOPMENT: http://www.twitch.tv/SG_Rayvolution
Offline SauronWatchesYou
« Reply #2 - Posted 2014-04-22 15:05:45 »

Exactly what I'm looking for, thanks a bunch! Smiley
Games published by our own members! Check 'em out!
Legends of Yore - The Casual Retro Roguelike
Offline BurntPizza

« JGO Bitwise Duke »


Medals: 271
Exp: 5 years



« Reply #3 - Posted 2014-04-22 15:06:14 »

Paint.NET if you're on Windows and don't have PS.

Much simpler than GIMP, but you have to be on Windows.
Offline SauronWatchesYou
« Reply #4 - Posted 2014-04-22 15:10:17 »

Can I get square brushes for paint.net? Smiley pixel art stuff. Not bothered if I have to download them etc
Offline BurntPizza

« JGO Bitwise Duke »


Medals: 271
Exp: 5 years



« Reply #5 - Posted 2014-04-22 15:13:30 »

Can I get square brushes for paint.net? Smiley pixel art stuff. Not bothered if I have to download them etc

Well usually pixel art is drawn pixel by pixel, so the "pencil" tool (1-wide brush) is a square brush.
Otherwise I don't think it does. (not at home to check, sorry)

But if GIMP is too intimidating, give PDN a try.
Offline SauronWatchesYou
« Reply #6 - Posted 2014-04-22 15:15:51 »

Fair point Smiley I usually like nice big squares but I will sure give paint.net a try as well Smiley
Offline BurntPizza

« JGO Bitwise Duke »


Medals: 271
Exp: 5 years



« Reply #7 - Posted 2014-04-22 15:18:03 »

Tip for pixel art: use the Grid to easily see the pixels.
Offline SauronWatchesYou
« Reply #8 - Posted 2014-04-22 15:25:58 »

Thanks Smiley that's really useful (I downloaded PDN)
Offline SauronWatchesYou
« Reply #9 - Posted 2014-04-22 17:56:25 »

Strange.. My animation displays all the images in a line rather than just one at a time on the screen. I watched a video about the animation and spritesheet classes and I followed everything the guy did but I got different results. Do I have to use a method to manually separate the sprites?

Below you can see my sheet. The images are not perfect yet, I just wanted to test it out before spending ages making images.

Games published by our own members! Check 'em out!
Legends of Yore - The Casual Retro Roguelike
Offline trollwarrior1
« Reply #10 - Posted 2014-04-22 18:07:49 »

What are you talking about? Are you just slapping whole texture onto the quad?
Offline SauronWatchesYou
« Reply #11 - Posted 2014-04-22 18:11:54 »

In the video the guy used an image very similar to mine that had 4 different images on and first called the sprite sheet method in the init and then the animation method as well. When he ran the game, they were displayed one at a time on the screen. He somehow split the images up from his sprite sheet. I've linked the video at the part where he did so.

<a href="http://www.youtube.com/v/4c7QeQDSY9s?version=3&amp;hl=en_US&amp;start=" target="_blank">http://www.youtube.com/v/4c7QeQDSY9s?version=3&amp;hl=en_US&amp;start=</a> it's at 4:02
Offline trollwarrior1
« Reply #12 - Posted 2014-04-22 18:15:58 »

Maybe you entered image width, height in new SpriteSheet(.., int spritewidth, int spriteheight) instead of individual sprite coordinates?
Offline SauronWatchesYou
« Reply #13 - Posted 2014-04-22 18:37:53 »

Ahh I think I understand. I need to specifically go through the sheet and grab the images I want to use? That's really weird because the guy didn't seem to do that in the video
Offline BurntPizza

« JGO Bitwise Duke »


Medals: 271
Exp: 5 years



« Reply #14 - Posted 2014-04-22 18:41:56 »

No, you need to tell SpriteSheet() how large the sprite you're animating is, so it can "cut out" the individual "slide" for you.
The spritesheet is like a slideshow, the image contains multiple slides (which are scrolled through), but it can't figure out by itself how large a slide is.
Offline SauronWatchesYou
« Reply #15 - Posted 2014-04-22 18:45:25 »

Oh, I did that with 32, 32 as that is the size of my coins I made in the sheet. I think one of them is a different size.. does that make a difference? Shocked
Offline BurntPizza

« JGO Bitwise Duke »


Medals: 271
Exp: 5 years



« Reply #16 - Posted 2014-04-22 18:51:25 »

They all have to be the same size.

Edit: the regions have to be the same size. The contained sprite images don't have to fill each region, just make sure that they don't overlap region boundaries.
Offline SauronWatchesYou
« Reply #17 - Posted 2014-04-22 18:52:51 »

Ah right, one of them is very slightly smaller, I will re size it and see what that does
Offline SauronWatchesYou
« Reply #18 - Posted 2014-04-22 19:07:06 »

Thanks guys ^_^ I got it working. Sorry for the noob questions, I only started learning game programming this week but I've learned alot.. and now about animation and sprite sheets Cheesy. I have one final question.

My coins sprite sheet means that my coins rotate as they fall, how would I go about a walking animation such as key presses and jumping etc?
Offline ctomni231

JGO Wizard


Medals: 99
Projects: 1
Exp: 7 years


Not a glitch. Just have a lil' pixelexia...


« Reply #19 - Posted 2014-04-23 02:04:18 »

You would go about it the same way. Create a spritesheet or expand the current sheet to have a different animation for each type. Then use states to choose which animation to use while certain actions are done.

Pages: [1]
  ignore  |  Print  
 
 
You cannot reply to this message, because it is very, very old.

 

Add your game by posting it in the WIP section,
or publish it in Showcase.

The first screenshot will be displayed as a thumbnail.

trollwarrior1 (24 views)
2014-11-22 12:13:56

xFryIx (69 views)
2014-11-13 12:34:49

digdugdiggy (48 views)
2014-11-12 21:11:50

digdugdiggy (42 views)
2014-11-12 21:10:15

digdugdiggy (36 views)
2014-11-12 21:09:33

kovacsa (60 views)
2014-11-07 19:57:14

TehJavaDev (64 views)
2014-11-03 22:04:50

BurntPizza (62 views)
2014-11-03 18:54:52

moogie (77 views)
2014-11-03 06:22:04

CopyableCougar4 (77 views)
2014-11-01 23:36:41
Understanding relations between setOrigin, setScale and setPosition in libGdx
by mbabuskov
2014-10-09 22:35:00

Definite guide to supporting multiple device resolutions on Android (2014)
by mbabuskov
2014-10-02 22:36:02

List of Learning Resources
by Longor1996
2014-08-16 10:40:00

List of Learning Resources
by SilverTiger
2014-08-05 19:33:27

Resources for WIP games
by CogWheelz
2014-08-01 16:20:17

Resources for WIP games
by CogWheelz
2014-08-01 16:19:50

List of Learning Resources
by SilverTiger
2014-07-31 16:29:50

List of Learning Resources
by SilverTiger
2014-07-31 16:26:06
java-gaming.org is not responsible for the content posted by its members, including references to external websites, and other references that may or may not have a relation with our primarily gaming and game production oriented community. inquiries and complaints can be sent via email to the info‑account of the company managing the website of java‑gaming.org
Powered by MySQL Powered by PHP Powered by SMF 1.1.18 | SMF © 2013, Simple Machines | Managed by Enhanced Four Valid XHTML 1.0! Valid CSS!