Using blend space 2d for sprite rotation with mouse.

:information_source: Attention Topic was automatically imported from the old Question2Answer platform.
:bust_in_silhouette: Asked By sand32848

Hi, I’m trying to create a top-down shooter game and I want to know how to rotate my sprite in 8 directions using blend space 2d with mouse. For example like this:

enter image description here

The game is Enter the gungeon by the way. From the gif the character face the direction the mouse cursor is pointing at and I want to do exactly that. Also, if blend space is not possible I would like to know alternative way to perform this.
Thank in advance!