|
Hi guys, I believe this is a very simplistic question, but I havent managed to find an answer to this one (at least one that I would understand). My code: After hitting an object I would like to get info (tag, or more prefferably name) of the object. My goal is very simple - three boxes in the scene, and I want something to happen when one of them is hit. After getting info it is probably just a simple "switch" but I can`t seem to understand how to get that info. Being a noob, it will help me even if you can at least point me in the right direction. :)
(comments are locked)
|
|
To do a raycast you can use Thank you! I didn`t know that, now it works like a charm! :) In case anyone else needs the same thing I just used this line: name = rch.collider.name; Debug.Log(name);
Mar 24 '12 at 03:47 PM
wolis
(comments are locked)
|
