2 years ago

Fixed a bug with Animals; I changed their draw code to clip off the bottom of the sprite when In water, but this changed where the origin point is. All good now!
(please ignore how hats float, they need a new sprite)

Fix in the article

#gameDev #goblins


The Fix:

Add a couple temp variables
var _xO = (-sprite_width/2); ///Puts us back to the middle)
var _xSq = ((1-xSc)*(sprite_width/2)); ///Adjusts the offset based on how much the sprite has been squashed. When not squished this is 0, as it squashes this increases and keeps the sprite centre.

Then for the draw x position in draw_sprite_general use: x+_xO+xSq



2 comments

Loading...

Next up

Oh gosh! Shiny Charmander card!?

Make a post celebrating a Creator with the tag #WorldCreativityDay ?

Hmm, how about @Victoree !

She is an incredibly talented artist, a pillar of the GameJolt community and a genuinely nice person who's kindness knows no bounds.

Send her some love!

Yay! I took way too long to make these, especially with knowing how long it usually takes Game Jolt to approve Premium stickers.

But they're here now!

I hope they can bring some joy to people.

I'll do more if people want them.

@TofuPixel is a Jolter to Watch and a pixel artist from England who works on indie games. She likes horror, nature, and funny animals! Follow @TofuPixel before the quest ends on April 15 and you'll get Coins!

OH OF COURSE I see this Quest after just doing a huge number of likes >:| FINE! I'll like even MORE posts! That'll show em'!

Happy #WIPWednesday! Are you working on a game? Making some art? Practicing a song? Something else? Tell us in the comments!

Since I added a fade in/out on death I've also added it to moving between floors!

Didn't add it to the Teleporter though...maybe that should have a white/blue fade instead?

Smol

We've updated the trending section of the Game Jolt Shop! http://gamejolt.com/#shop

Snag a new avatar frame and a sticker pack or two!

Remember, every purchase supports our creators and our community!

Support creators, shop on Game Jolt! #broadcast

WOop!