Get Score distance! Help!
Hi, I need a script to get the distance traveled by "X" object and add the score. Example, I have this script that I put under to increase the score every time I collide with a "Coin"
static var Counter : int = 0;
function Update () {
GetComponent.<TextMesh>().text = "" + Counter; }
I attach this script to my 3D Text for the coin collection.
Now, if I create another static var and another script to get the player's distance, which script should it be?
I hope you can help me please.
Greetings
Comment
Your answer
Follow this Question
Related Questions
Movement distance per frame providing choppy values 1 Answer
Move player set distance forward overtime. 0 Answers
Spawn a number of prefabs an equal distance apart 2 Answers
How to use RaycastHit ? 0 Answers
Pixel to z-Distance in Unity 0 Answers