Projectile Physics – Leighton Snyder

This one took a bit to get right, but I have something operational I think. Multiplying the bullet speed by delta gave me some weird effects when moving while shooting, but removing that seemed to fix it. I’m also still trying to find the best way to align the bullet and the gun. Currently I have a point on the gun barrel where it spawns, but that can create weird effects when the cursor gets close to the player.

Also just a note for others, if you are concerned with crosshair accuracy: make sure that when you change the cursor to your crosshair sprite in Godot, you change the “image hotpost” in settings to align with the center of your crosshair. It makes it the top left of your sprite by default, which makes your shots a bit less accurate. My cursor sprite was 17 x 17, so I set my hotspot x=9 and y=9 to align with the center of the crosshair.

Here’s my player exterminating a bunch of snakes:

Leave a comment