Beispiel #1
0
    public void PlayerGameEnd()
    {
        //Add all player values to the save file
        GameManager.SP.playerData.damageDone  += matchDamageDealth;
        GameManager.SP.playerData.playerXP    += matchXP;
        GameManager.SP.playerData.totalDeaths += matchDeaths;
        GameManager.SP.playerData.totalKills  += matchKills;

        //Calculate gold
        GameManager.SP.playerData.gold += GameUtils.CalculateEarnedGold(playerScore, matchXP);

        GameManager.SP.SaveGame();
    }