Hi Jean,
Great!
I would prefer a basic action not a complete joystick script. So its universal usefull. Im not very good at math so i cant tell you which approach ist better.
Maybe you have also a look at this custom action which is going in a similar direction:
http://hutonggames.com/playmakerforum/index.php?topic=2795.0I would call the action something like:
Restrict Vector3 to Radius position
With public vars:
- Input: Vector3
- Radius (or min / max magnitude, that would make it possible to create a ring. could be of use....)
- axis xz, xy, zx
- Store result: vector 3
- every frame (dont know if NOT every frame is usefull. but its nice to have the option :-))
Thats what coming to my mind. This Action in combination with Mouse/Touch Actions should be sufficient to create virtual Joysticks, but is also good for placing something around an object (golf, poolbillard etc).
I just discovered that Mouse Pick Actions work fine on touch devices too, so thats oppening a whole lot new oportunities for me!