- Home /
Experience System
i wanted to ask the people of unityAnswers if they could answer my question... i wanted to make a gui text where when it get to a certain number other numbers change it... (i know not that descriptive...) basically i wanted them to start out there experience like this... 1/1000 | 1 after you got to 1000 it would change to this 1000/2000 | 2 i hope you understand where im getting at (1 is current experience 1000 is the goal and | 1 is the level...) Please consider in helping me...
EDIT:
i just need help with this last thing....
i dont know much about javascript but someone help me with this
var yourGUITextVariable; var accumulatedExperiencePoints; var levelExpRequirements; var currentLevel;
function Update () { yourGUITextVariable.text = accumulatedExperiencePoints + "/" + levelExpRequirements[currentLevel+1]; }
Answer by matyicsapo · Aug 17, 2010 at 02:58 PM
pseudo-code:
yourGUITextVariable.text = accumulatedExperiencePoints + "/" + levelExpRequirements[currentLevel+1]; // change the last part to the way you get the nex level's exp requirement(currentLevel*1000 for another example)
thanks but i need some help... im trying to use that code and i know its just an example but when i try it how do i make it show on the screen... i have some variable set up. and im new to js and all and i dont know if there right please help im gunna edit my post..
GUIText are only visible in the game view, positioned in screen coords - bottom left(0, 0) top right(1, 1)