Hello guys,
I need to instantiate object to be looking at current theTouch.deltaPosition + theTouch,position.
I am working in 2D so I need to change just z rotation.
Instantiate (prefab, hit.point ,I dont know what here);
Thanks
Hello guys,
I need to instantiate object to be looking at current theTouch.deltaPosition + theTouch,position.
I am working in 2D so I need to change just z rotation.
Instantiate (prefab, hit.point ,I dont know what here);
Thanks
Read: LookAt 2D Equivalent
Both the code snippet from two answers (by daivd.ramz and robertbu) provide the rotation that you can use to instantiate your object.