Add more levels

This commit is contained in:
Jakub Sztuba 2023-01-07 21:02:30 +01:00
parent 5a5fa8a04a
commit 556c396959

View File

@ -148,6 +148,62 @@ public class Player : MonoBehaviour
lvlUp = true; lvlUp = true;
maxExp = 200; maxExp = 200;
// Add points and refresh view (if opened)
SkillsPointsManger.Instance.AddFreePoints(2);
SkillsPointsManger.Instance.UpdatePanelView();
}
}
else if (lvl == 4)
{
maxExp = 200;
if (exp >= maxExp)
{
lvl = 5;
lvlUp = true;
maxExp = 300;
// Add points and refresh view (if opened)
SkillsPointsManger.Instance.AddFreePoints(2);
SkillsPointsManger.Instance.UpdatePanelView();
}
}
else if (lvl == 5)
{
maxExp = 300;
if (exp >= maxExp)
{
lvl = 6;
lvlUp = true;
maxExp = 450;
// Add points and refresh view (if opened)
SkillsPointsManger.Instance.AddFreePoints(2);
SkillsPointsManger.Instance.UpdatePanelView();
}
}
else if (lvl == 6)
{
maxExp = 450;
if (exp >= maxExp)
{
lvl = 7;
lvlUp = true;
maxExp = 550;
// Add points and refresh view (if opened)
SkillsPointsManger.Instance.AddFreePoints(2);
SkillsPointsManger.Instance.UpdatePanelView();
}
}
else if (lvl == 7)
{
maxExp = 550;
if (exp >= maxExp)
{
lvl = 8;
lvlUp = true;
maxExp = 700;
// Add points and refresh view (if opened) // Add points and refresh view (if opened)
SkillsPointsManger.Instance.AddFreePoints(2); SkillsPointsManger.Instance.AddFreePoints(2);
SkillsPointsManger.Instance.UpdatePanelView(); SkillsPointsManger.Instance.UpdatePanelView();