summaryrefslogtreecommitdiff
path: root/src/map/pc.c
diff options
context:
space:
mode:
authorcookiecrumbs <cookiecrumbs@54d463be-8e91-2dee-dedb-b68131a5f0ec>2012-07-22 01:26:48 +0000
committercookiecrumbs <cookiecrumbs@54d463be-8e91-2dee-dedb-b68131a5f0ec>2012-07-22 01:26:48 +0000
commit04ce57ecc743ec95e79fedab7e00bc650e386d23 (patch)
treeb9a0abcfed19b711b343ef32f37e2f84bea2512e /src/map/pc.c
parent48ae82a0d0bd24c8ba9ee622930f4d74009843e9 (diff)
downloadhercules-04ce57ecc743ec95e79fedab7e00bc650e386d23.tar.gz
hercules-04ce57ecc743ec95e79fedab7e00bc650e386d23.tar.bz2
hercules-04ce57ecc743ec95e79fedab7e00bc650e386d23.tar.xz
hercules-04ce57ecc743ec95e79fedab7e00bc650e386d23.zip
Added a new configuration option to allow either weapon switching to cancel SC_DANCING or not.
Fixed an issue where movement is frozen (caster) with Longing for Freedom (walking outside of the cast). Added checks related to dancing/ensemble skills to prevent frozen characters. git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@16470 54d463be-8e91-2dee-dedb-b68131a5f0ec
Diffstat (limited to 'src/map/pc.c')
-rw-r--r--src/map/pc.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/src/map/pc.c b/src/map/pc.c
index 459f6ef99..f918ce9ca 100644
--- a/src/map/pc.c
+++ b/src/map/pc.c
@@ -4805,6 +4805,8 @@ int pc_checkallowskill(struct map_session_data *sd)
for (i = 0; i < ARRAYLENGTH(scw_list); i++)
{ // Skills requiring specific weapon types
+ if( scw_list[i] == SC_DANCING && !battle_config.dancing_weaponswitch_fix )
+ continue;
if(sd->sc.data[scw_list[i]] &&
!pc_check_weapontype(sd,skill_get_weapontype(status_sc2skill(scw_list[i]))))
status_change_end(&sd->bl, scw_list[i], INVALID_TIMER);
@@ -8085,6 +8087,8 @@ int pc_unequipitem(struct map_session_data *sd,int n,int flag)
sd->status.weapon = sd->weapontype2;
pc_calcweapontype(sd);
clif_changelook(&sd->bl,LOOK_WEAPON,sd->status.weapon);
+ if( !battle_config.dancing_weaponswitch_fix )
+ status_change_end(&sd->bl, SC_DANCING, INVALID_TIMER); // Unequipping => stop dancing.
}
if(sd->status.inventory[n].equip & EQP_HAND_L) {
sd->status.shield = sd->weapontype2 = 0;