Player Looking Direction System?

Hello, I would like to know if it is possible to make a system that indicates where the player is looking

example:

LOOKING DOWN
1685894428596.png


LOOKING UP
1685894459103.png


LOOKING LEFT
1685894486370.png


LOOKING RIGHT
1685894511677.png
Your Looking Down and Looking Right look exactly the same. Since you have an 8 directional sprite you need to define which direction each diagonal counts as.

This script will return the gameplayer's facing direction
$gamePlayer.direction()
Your Looking Down and Looking Right look exactly the same. Since you have an 8 directional sprite you need to define which direction each diagonal counts as.

This script will return the gameplayer's facing direction
$gamePlayer.direction()
I managed to make the system.

thanks!!
2023-06-04-14-04-27.gif

Original thread: https://forums.rpgmakerweb.com/threads/player-looking-direction-system.158053/