- Fixed #baselevelup adding instead of substracting status points when used with negative levels. Also made it reset your stats if there wasn't enough to substract from.

git-svn-id: https://svn.code.sf.net/p/rathena/svn/trunk@8861 54d463be-8e91-2dee-dedb-b68131a5f0ec
This commit is contained in:
skotlex
2006-09-25 15:17:12 +00:00
parent 2653525969
commit 7025584abe
2 changed files with 6 additions and 1 deletions

View File

@@ -1320,7 +1320,9 @@ int charcommand_baselevel(
level = pl_sd->status.base_level -1;
if (pl_sd->status.status_point > 0) {
for (i = 0; i > -level; i--)
status_point -= (pl_sd->status.base_level +i + 14) / 5;
status_point += (pl_sd->status.base_level +i + 14) / 5;
if (pl_sd->status.status_point < status_point)
pc_resetstate(sd);
if (pl_sd->status.status_point < status_point)
pl_sd->status.status_point = 0;
else