Im having a problem with this text code, first I have the load code (that I didn’t make)
function loadGame(){
myLSO = SharedObject.getLocal("uniqueName");
if(myLSO.data.myObj == undefined){ // No object exists
trace("No Saved Game");
}
else{
trace("Loaded Game");
hp = myLSO.data.myObj.objArray[0];
mp = myLSO.data.myObj.objArray[1];
maxhp = myLSO.data.myObj.objArray[2];
atk = myLSO.data.myObj.objArray[3];
money = myLSO.data.myObj.objArray[4];
lv = myLSO.data.myObj.objArray[5];
expirence = myLSO.data.myObj.objArray[6];
expirencemax = myLSO.data.myObj.objArray[7];
maxmp = myLSO.data.myObj.objArray[8];
}
What I want it to do is instead of doing trace, I want it to add text to a dynamic text with the variable info. So if there is no data to load it will say “no saves found” or something and if there is a file to load it will say “game loaded”. This is some code that someone gave me,
_root.fight.text = _root.fight += "<font color=\"#003399\"><B>- You use a potion - You gain <font color=\"#FF0000\">" + heal + " HP<font color=\"#003399\"><B>!\r</font></B>";
_root.fight.scroll +=1;
but I can’t figure out where I can change it to do what I want.
Thanks