Quantcast
Channel: Answers for "Firing at mouse position, 2d game"
Browsing latest articles
Browse All 4 View Live

Answer by LyanApps

Are you moving the camera position as well? You can use Input.mousePosition to get the location of your mouse on each frame....

View Article


Answer by BDP1

Thank YOU! This code works perfectly!! function Update () { var mousePos = Input.mousePosition; mousePos.z = 32; //The distance from the camera to the player object var lookPos : Vector3 =...

View Article

Browsing latest articles
Browse All 4 View Live


<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>