I'm trying to do a health system via GUItext heres the code I have for the GUIText its in java script but here
and heres the code I have for when the zombie collides with the player
but the text isnt updateing when the zombie hits the player the gui text is named GUIhealth but it isnt working:/ what am I doing wrong?
You are doing twice the job: first in the GUIText script - where you do it the wrong way, since its score variable is never modified by the player's health - and in the player's script, where it should work. Delete the Update function from the GUI script (or the entire script, if there's nothing else in it).
answered Jun 27 '11 at 03:55 AM