Godot 4.3
i made a machine gun that rotates at my mouse cursor, however its allways aimed at right so when it rotate to left it look weird i wanna know how to make it once it rotate more than 180 or -90 Flip the sprite and also how to change sprite in same time
var a := fposmod(rotation_degrees, 360.0)
flip_v = a > 180 and a < 270
Not tested, but might give the right direction.
You’d want 90 degrees and 270 degrees instead, since the sector between 180 and 270 is only one quadrant.
1 Like
and also what about Changing the Sprite in sametime of flip?