From 2f2066f741111325b2510c6526b41b22dea93370 Mon Sep 17 00:00:00 2001 From: skotlex Date: Thu, 15 Jun 2006 18:56:54 +0000 Subject: - 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 --- src/map/status.c | 16 ++++++++++++---- 1 file changed, 12 insertions(+), 4 deletions(-) (limited to 'src/map/status.c') diff --git a/src/map/status.c b/src/map/status.c index 7fc090dd1..7e7cadfb6 100644 --- a/src/map/status.c +++ b/src/map/status.c @@ -3712,6 +3712,12 @@ void status_set_viewdata(struct block_list *bl, int class_) { TBL_PC* sd = (TBL_PC*)bl; if (pcdb_checkid(class_)) { + if (sd->sc.option&OPTION_WEDDING) + class_ = JOB_WEDDING; + else + if (sd->sc.option&OPTION_XMAS) + class_ = JOB_XMAS; + else if (sd->sc.option&OPTION_RIDING) switch (class_) { //Adapt class to a Mounted one. @@ -3734,10 +3740,6 @@ void status_set_viewdata(struct block_list *bl, int class_) class_ = JOB_BABY_CRUSADER2; break; } - if (class_ == JOB_WEDDING) - sd->sc.option|=OPTION_WEDDING; - else if (sd->sc.option&OPTION_WEDDING) - sd->sc.option&=~OPTION_WEDDING; //If not going to display it, then remove the option. sd->vd.class_ = class_; clif_get_weapon_view(sd, &sd->vd.weapon, &sd->vd.shield); sd->vd.head_top = sd->status.head_top; @@ -5264,6 +5266,9 @@ int status_change_start(struct block_list *bl,int type,int rate,int val1,int val case SC_WEDDING: sc->option |= OPTION_WEDDING; break; + case SC_XMAS: + sc->option |= OPTION_XMAS; + break; case SC_ORCISH: sc->option |= OPTION_ORCISH; break; @@ -5661,6 +5666,9 @@ int status_change_end( struct block_list* bl , int type,int tid ) case SC_WEDDING: sc->option &= ~OPTION_WEDDING; break; + case SC_XMAS: + sc->option &= ~OPTION_XMAS; + break; case SC_ORCISH: sc->option &= ~OPTION_ORCISH; break; -- cgit v1.2.3-70-g09d2