summaryrefslogtreecommitdiff
path: root/src/map/pc.c
diff options
context:
space:
mode:
authorskotlex <skotlex@54d463be-8e91-2dee-dedb-b68131a5f0ec>2006-02-13 16:06:32 +0000
committerskotlex <skotlex@54d463be-8e91-2dee-dedb-b68131a5f0ec>2006-02-13 16:06:32 +0000
commit996f20c134b0aa6de62b06b286b626b950527479 (patch)
treef0d7df0e3c89700987a2711f8f7d479b179dcf58 /src/map/pc.c
parent78748079288acbd6e5fc7513baa70cf5b0a9a330 (diff)
downloadhercules-996f20c134b0aa6de62b06b286b626b950527479.tar.gz
hercules-996f20c134b0aa6de62b06b286b626b950527479.tar.bz2
hercules-996f20c134b0aa6de62b06b286b626b950527479.tar.xz
hercules-996f20c134b0aa6de62b06b286b626b950527479.zip
- Fixed SG_FUSION costing SP to deactivate.
- Some cleaning up at pc_setpos to prevent calling pc_clean_skilltree - Added pc_clean_skilltree on pc_recv_reg - Enabled use of TF_HIDING while Cloaked. - pc_resetstate won't remove wedding skills now git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@5268 54d463be-8e91-2dee-dedb-b68131a5f0ec
Diffstat (limited to 'src/map/pc.c')
-rw-r--r--src/map/pc.c20
1 files changed, 12 insertions, 8 deletions
diff --git a/src/map/pc.c b/src/map/pc.c
index 3842aa16a..9e8467c33 100644
--- a/src/map/pc.c
+++ b/src/map/pc.c
@@ -925,6 +925,7 @@ int pc_reg_received(struct map_session_data *sd)
char feel_var[3][NAME_LENGTH] = {"PC_FEEL_SUN","PC_FEEL_MOON","PC_FEEL_STAR"};
char hate_var[3][NAME_LENGTH] = {"PC_HATE_MOB_SUN","PC_HATE_MOB_MOON","PC_HATE_MOB_STAR"};
+ pc_clean_skilltree(sd); //Clean skill tree before loading reg-based skills
sd->change_level = pc_readglobalreg(sd,"jobchange_level");
sd->die_counter = pc_readglobalreg(sd,"PC_DIE_COUNTER");
if (!sd->die_counter && (sd->class_&MAPID_UPPERMASK) == MAPID_SUPER_NOVICE)
@@ -3334,12 +3335,6 @@ int pc_setpos(struct map_session_data *sd,unsigned short mapindex,int x,int y,in
sd->petDB = NULL;
if(battle_config.pet_status_support)
status_calc_pc(sd,2);
- pc_clean_skilltree(sd);
-
- if (sd->state.storage_flag == 1)
- storage_storageclose(sd);
- else if (sd->state.storage_flag == 2)
- storage_guild_storageclose(sd);
}
else if(sd->pet.intimate > 0) {
pet_stopattack(sd->pd);
@@ -3348,6 +3343,11 @@ int pc_setpos(struct map_session_data *sd,unsigned short mapindex,int x,int y,in
map_delblock(&sd->pd->bl);
}
}
+ if (sd->state.storage_flag == 1)
+ storage_storageclose(sd);
+ else if (sd->state.storage_flag == 2)
+ storage_guild_storageclose(sd);
+
clif_changemap(sd,map[m].index,x,y); // [MouseJstr]
}
@@ -5065,8 +5065,12 @@ int pc_resetlvl(struct map_session_data* sd,int type)
nullpo_retr(0, sd);
- for(i=1;i<MAX_SKILL;i++){
- sd->status.skill[i].lv = 0;
+ if (type != 3) {
+ for(i=1;i<MAX_SKILL;i++){
+ if (sd->status.skill[i].lv &&
+ !skill_get_inf2(i)&INF2_WEDDING_SKILL) //Do not reset Wedding Skills. [Skotlex]
+ sd->status.skill[i].lv = 0;
+ }
}
if(type == 1){