Sign in to follow this  
Yamero

Slick2D and Tiled Map Editor - Sprite Shadows

Recommended Posts

Just started learning Java a few weeks ago and got into Slick2D to get me started on creating some games.

I started using some free sprites from this site and loaded then into Tiled Map Editor. everything worked correctly expect for the shadows.

At the moment they look like this

spriteshadows.PNG

 

Tiled Map Editor allows me to remove the blue background to make it transparent but I don't know how to remove the pink.

On the site the author talks a bit about the shadows but I didn't understand much.

They are supposed to look like this when used correctly

treeShadows.PNG

 

I tired looking through the slick2d javadoc and even googled the problem for about 2 hours and couldn't find a thing.

Please help.

 

Share this post


Link to post
Share on other sites

That image appears to be using multiple colour keys for transparency.

 

Generally, that pink is used as a transparency colour key and while I'm sure it's possible, I'm not immediately aware of how to do colour key based partial transparency.

If your library supports alpha transparency, I'd suggest going that route instead.

 

Should be pretty simple to replace the blue/pink with transparent, the gray-pink with semi-transparent black and just use that.

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

Sign in to follow this