Hey guys, I have coin, level, health, hunger variable.I want to save them, I have a code something like that to save coin,
if(coin> PlayerPrefs.GetFloat("coin")){
PlayerPrefs.SetFloat("coin", coin);
}
coin = PlayerPrefs.GetFloat("coin");
but when I buy something, it doesn't decrease.
___
My hunger decreases by and by but when I exit the game, it starts with %100.
How can I fix them.Thanks in advance!
↧