summaryrefslogtreecommitdiff
path: root/src/map/pc.c
diff options
context:
space:
mode:
authorskotlex <skotlex@54d463be-8e91-2dee-dedb-b68131a5f0ec>2006-06-15 18:56:54 +0000
committerskotlex <skotlex@54d463be-8e91-2dee-dedb-b68131a5f0ec>2006-06-15 18:56:54 +0000
commit2f2066f741111325b2510c6526b41b22dea93370 (patch)
tree3d6685374e23b0c5eaa23104b147af5300e4cf21 /src/map/pc.c
parent98669fa21190be11fadfd165678812d660338873 (diff)
downloadhercules-2f2066f741111325b2510c6526b41b22dea93370.tar.gz
hercules-2f2066f741111325b2510c6526b41b22dea93370.tar.bz2
hercules-2f2066f741111325b2510c6526b41b22dea93370.tar.xz
hercules-2f2066f741111325b2510c6526b41b22dea93370.zip
- Altered a bit how status_set_viewdata behaves in regards to Wedding/Xmas options.
- Added back OPTION_XMAS, but the actual value is missing! - Corrected chrif_save so that the player is not set offline on map-change. - Added change-look support in pc_setoption when specifying OPTION_XMAS - Fixed clif_parse_RemoveOption removing all options instead of just Falcon/Cart/Peco git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@7183 54d463be-8e91-2dee-dedb-b68131a5f0ec
Diffstat (limited to 'src/map/pc.c')
-rw-r--r--src/map/pc.c22
1 files changed, 14 insertions, 8 deletions
diff --git a/src/map/pc.c b/src/map/pc.c
index 75fd227d1..b76856dcb 100644
--- a/src/map/pc.c
+++ b/src/map/pc.c
@@ -3175,7 +3175,7 @@ int pc_setpos(struct map_session_data *sd,unsigned short mapindex,int x,int y,in
unit_remove_map(&sd->pd->bl, clrtype);
intif_save_petdata(sd->status.account_id,&sd->pet);
}
- chrif_save(sd,1);
+ chrif_save(sd,2);
chrif_changemapserver(sd, mapindex, x, y, ip, (short)port);
return 0;
}
@@ -5498,15 +5498,21 @@ int pc_setoption(struct map_session_data *sd,int type)
clif_changelook(&sd->bl,LOOK_BASE,JOB_WEDDING);
else if (!(type&OPTION_WEDDING) && p_type&OPTION_WEDDING)
{
- if (sd->vd.class_ != sd->status.class_) {
- status_set_viewdata(&sd->bl, sd->status.class_);
- clif_changelook(&sd->bl,LOOK_BASE,sd->vd.class_);
- if(sd->status.clothes_color)
- clif_changelook(&sd->bl,LOOK_CLOTHES_COLOR,sd->status.clothes_color);
- }
+ status_set_viewdata(&sd->bl, sd->status.class_);
+ clif_changelook(&sd->bl,LOOK_BASE,sd->vd.class_);
+ if(sd->status.clothes_color)
+ clif_changelook(&sd->bl,LOOK_CLOTHES_COLOR,sd->status.clothes_color);
}
- clif_changeoption(&sd->bl);
+ if (type&OPTION_XMAS && !(p_type&OPTION_XMAS))
+ clif_changelook(&sd->bl,LOOK_BASE,JOB_XMAS);
+ else if (!(type&OPTION_XMAS) && p_type&OPTION_XMAS)
+ {
+ status_set_viewdata(&sd->bl, sd->status.class_);
+ clif_changelook(&sd->bl,LOOK_BASE,sd->vd.class_);
+ if(sd->status.clothes_color)
+ clif_changelook(&sd->bl,LOOK_CLOTHES_COLOR,sd->status.clothes_color);
+ }
return 0;
}