summaryrefslogtreecommitdiff
path: root/src/map/pc.c
diff options
context:
space:
mode:
authorai4rei <ai4rei@54d463be-8e91-2dee-dedb-b68131a5f0ec>2011-04-16 20:15:20 +0000
committerai4rei <ai4rei@54d463be-8e91-2dee-dedb-b68131a5f0ec>2011-04-16 20:15:20 +0000
commit432ec6db58f1c10a4c1050d5af6ebe329c03cf91 (patch)
tree3eb41aeb402cda096bcf61190dd02d501482837e /src/map/pc.c
parent15a067108a3cf465a4eaddd655770e96ff5c5092 (diff)
downloadhercules-432ec6db58f1c10a4c1050d5af6ebe329c03cf91.tar.gz
hercules-432ec6db58f1c10a4c1050d5af6ebe329c03cf91.tar.bz2
hercules-432ec6db58f1c10a4c1050d5af6ebe329c03cf91.tar.xz
hercules-432ec6db58f1c10a4c1050d5af6ebe329c03cf91.zip
* Added support for visible garments/robes.
- For SQL apply upgrade_svn14797.sql to upgrade table `char`; for TXT no action is necessary, as it upgrades itself. - This also fixes NPCs not being visible with clients 2011-01-11aRagexeRE+ (bugreport:4865). git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@14797 54d463be-8e91-2dee-dedb-b68131a5f0ec
Diffstat (limited to 'src/map/pc.c')
-rw-r--r--src/map/pc.c14
1 files changed, 14 insertions, 0 deletions
diff --git a/src/map/pc.c b/src/map/pc.c
index 4cfec2de8..e1ecc171e 100644
--- a/src/map/pc.c
+++ b/src/map/pc.c
@@ -6398,6 +6398,7 @@ int pc_equiplookall(struct map_session_data *sd)
clif_changelook(&sd->bl,LOOK_HEAD_BOTTOM,sd->status.head_bottom);
clif_changelook(&sd->bl,LOOK_HEAD_TOP,sd->status.head_top);
clif_changelook(&sd->bl,LOOK_HEAD_MID,sd->status.head_mid);
+ clif_changelook(&sd->bl, LOOK_ROBE, sd->status.robe);
return 0;
}
@@ -6454,6 +6455,9 @@ int pc_changelook(struct map_session_data *sd,int type,int val)
break;
case LOOK_SHOES:
break;
+ case LOOK_ROBE:
+ sd->status.robe = val;
+ break;
}
clif_changelook(&sd->bl,type,val);
return 0;
@@ -7184,6 +7188,11 @@ int pc_equipitem(struct map_session_data *sd,int n,int req_pos)
}
if(pos & EQP_SHOES)
clif_changelook(&sd->bl,LOOK_SHOES,0);
+ if( pos&EQP_GARMENT )
+ {
+ sd->status.robe = id ? id->look : 0;
+ clif_changelook(&sd->bl, LOOK_ROBE, sd->status.robe);
+ }
pc_checkallowskill(sd); //Check if status changes should be halted.
@@ -7274,6 +7283,11 @@ int pc_unequipitem(struct map_session_data *sd,int n,int flag)
}
if(sd->status.inventory[n].equip & EQP_SHOES)
clif_changelook(&sd->bl,LOOK_SHOES,0);
+ if( sd->status.inventory[n].equip&EQP_GARMENT )
+ {
+ sd->status.robe = 0;
+ clif_changelook(&sd->bl, LOOK_ROBE, 0);
+ }
clif_unequipitemack(sd,n,sd->status.inventory[n].equip,1);