Josef Scroggins
Member
I'm making a battle system similar to Final Fantasies. At the end of the battle, I want it to display what you gained from the battle. For example. Let's say I have 20 gold I win a battle I want it to show how much gold I gained in a draw GUI event that would look similar to this. (Better Example)
Essence: 25 +6
Cash: 40 +4
I'm not sure how to store a number and then use it later to show what the player has gained. Any idea or examples on how to do this would be greatly appreciated!
Essence: 25 +6
Cash: 40 +4
Code:
//Enemy Step Event if objCallList.turn = false
{
objCallList.hp -= 1;
objCallList.turn = true;
}
if objCallList.ehp == 0 && scanned = 0
{
instance_create_layer(500,380,"Instances",objStatGain)
objCallList.money += moneyGain;
objCallList.xp += xpGain;
scanned = 1;
}
//Stat Gain Draw GUI
if moneyIncreased = true
{
draw_text(x,y,"Money: " + string(objCallList.moneyBefore) + " +" + string(objChocoBattle0.moneyGain))
show_debug_message("Printed!")
}