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

Ooo pretty!

#GJAsks I thought it would have been Tennis for the Atari 400 which my dad had, but I can't find evidence of the cartridge, so I'm gonna say Joust which I still have from back then!

https://www.youtube.com/watch?v=Rc_mV9bbTpY

Adding a key system for Gates and stuff (on top of the existing Button system which is now over-rided by keys) I can also have other conditions like a specific number of enemies need to be killed before they open.

Need to fix the collision detection.

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

Nothing I make will ever be better than the tiny birbs

Opera GX's #GXNailArt competition has arrived on Game Jolt!

You might have missed Worlds, but you can still be a winner. Take part in the #GXNailArt contest to have a chance to win Riot Points!

Get started by completing our #GXNailArt quests!

Mob locks work! Activating the Beacon locks the gate and spawns mobs, killing them all grants a reward and unlocks it letting you out again!

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.

WOOP!