3 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

Getting this text to scroll and crop should have been super easy but I couldn't get it to work with sin(), so I had to use an extra variable to reverse the movement at the end point. But it DOES work. so *shrug*

What am I missing, this quest no work!?

CHONK-Y-CHU!

CHONK-Y-CHU!

CHONK-Y-CHU!

Doki Doki Literature Club is celebrating Monika's birthday and the 8th anniversary of DDLC with exclusive stickers, avatar frames and backgrounds on Game Jolt! 

Head over to the shop to collect yours 👉 https://gamejolt.com/#shop

Happy Trans Day of Visibility!

Please remember, you are valid and you matter .

Please look after yourselves and stay safe out there. Keep being awesome!

Mae Borowski is the main character of Night in the Woods! It's an adventure game that tells the story of her return to her hometown of Possum Springs. She was confirmed as canonically pan in a social media post by the game's creator Scott Benson.

Oh actually, one more 10 pull because the daily check in gave me enough to do it!😅

Oh thank frick for that! I thought I missed a day because of daylight savings time

The Knightling launches on August 28! Wishlist it now so you don't miss out: https://bit.ly/KnightlingSteam

To celebrate the game's impending release, we've added The Knightling Pack and The Knightling Community Pack back to the Shop!

HAPPY April first Mimikyu day!

Or is it?