Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- public void addExperience(int par1)
- {
- score += par1;
- int i = 0x7fffffff - experienceTotal;
- if (par1 > i)
- {
- par1 = i;
- }
- experience += (float)par1 / (float)xpBarCap();
- experienceTotal += par1;
- for (; experience >= 1.0F; experience = experience / (float)xpBarCap())
- {
- experience = (experience - 1.0F) * (float)xpBarCap();
- increaseLevel();
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment