id need to compare the horizontal and vertical axis
Hi,
no no, both axis can be treated independently. I see no reason to compare them, this make no sense both from a user perspective ( he can move where every he wants withint he joystick bounds), and from a development perspective ( it's perfectly acceptable to isolate the x and y axis on the same joystick , which is actually how it's done in the joystick script, x and y are computed separatly).
but really, (I mean, unless you want to do this for the fun, which is completely welcome of course,) Simply use the joystick prefab and get the x and y using "get property" action and retrieve the "position" and store it in a Fsm vector2 variable, and inject it anywhere else you want ( back to other controllers for example).
Also from your attempt, I don't see anything that jumps to my eyes, so it must be something very simple, like a wrong redirection or a wrong action order or something. Are you able to constraint one axe only? so that you can perfectly replicate the game sample Fsm, then add the other axis, but start simple first.
Bye
Jean