Quote:
|
Originally Posted by Naxix
Quote:
|
Originally Posted by Hiddos
Well, if you've set 'levelexp' to 4, it'll output 4. If it's like: Level 1: 4 xp - Level 2: 8xp - Level 3: 12xp
Then try this:
pawn Код:
format(string,sizeof(string),"LVL: %d~n~Respect: %d/%d",PlayerInfo[i][pLevel],PlayerInfo[i][pExp],levelexp*(PlayerInfo[i][pLevel]+1)); // Gets the player's level, counts +1 (Next level) and multiplies it by 4 (XP required for one next level)
|
Wouldn't that output level 1: 5xp 2: 10 xp and so on, as if levelexp is 4 and you times it with the level +1 you wont get 4,8,12 and so on.
|
levelexp*(PlayerInfo[i][pLevel]+1)
Code between () will be calculated before it calculates with something else.
Wrong would be:
levelexp*(PlayerInfo[i][pLevel])+1