in C sharp you can use this "FindGameObjectWithTag("Player")"
What is the JavaScript equivalent of this?
in C sharp you can use this "FindGameObjectWithTag("Player")"
What is the JavaScript equivalent of this?
All Unity functions are available in Javascript. They are the same, so there's no "equivalent".
(hit.gameObject.tag == "Naruto")
this will look for the player with the tag naruto :)