summaryrefslogtreecommitdiff
path: root/src/map/pc.c
diff options
context:
space:
mode:
authorskotlex <skotlex@54d463be-8e91-2dee-dedb-b68131a5f0ec>2006-12-22 14:19:39 +0000
committerskotlex <skotlex@54d463be-8e91-2dee-dedb-b68131a5f0ec>2006-12-22 14:19:39 +0000
commita65e4681cd29db1d0936523cc8ff5646dc7dca5b (patch)
tree11f6e3b19a7a829252caa983e62a2ad4c19baf02 /src/map/pc.c
parent34f200c644ba8598448e20f4aa69a504e55d3c8f (diff)
downloadhercules-a65e4681cd29db1d0936523cc8ff5646dc7dca5b.tar.gz
hercules-a65e4681cd29db1d0936523cc8ff5646dc7dca5b.tar.bz2
hercules-a65e4681cd29db1d0936523cc8ff5646dc7dca5b.tar.xz
hercules-a65e4681cd29db1d0936523cc8ff5646dc7dca5b.zip
- Added support for the new "make new char" packet that has the rename button data. Thanks to Sara-chan for the format change update.
- Fixed itemdb.c sql compilation - Now when you specify a max level beyond what the exp table has, the last entry of the exp table will be duplicated to fill in the remaining levels. git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@9558 54d463be-8e91-2dee-dedb-b68131a5f0ec
Diffstat (limited to 'src/map/pc.c')
-rw-r--r--src/map/pc.c7
1 files changed, 6 insertions, 1 deletions
diff --git a/src/map/pc.c b/src/map/pc.c
index 5fdb19378..9aefa3f08 100644
--- a/src/map/pc.c
+++ b/src/map/pc.c
@@ -7314,7 +7314,12 @@ int pc_readdb(void)
max_level[job][type]--;
if (max_level[job][type] < max) {
ShowWarning("pc_readdb: Specified max %d for job %d, but that job's exp table only goes up to level %d.\n", max, job, max_level[job][type]);
- ShowNotice("(You may still reach lv %d through scripts/gm-commands)\n", max);
+ ShowInfo("Filling the missing values with the last exp entry.\n");
+ //Fill the requested values with the last entry.
+ i = max_level[job][type]-2;
+ if (i < 0) i = 0;
+ for (; i < max-2; i++)
+ exp_table[job][type][i] = exp_table[job][type][i-1];
max_level[job][type] = max;
}
// ShowDebug("%s - Class %d: %d\n", type?"Job":"Base", job, max_level[job][type]);