summaryrefslogtreecommitdiff
path: root/src/map/skill.c
diff options
context:
space:
mode:
authorskotlex <skotlex@54d463be-8e91-2dee-dedb-b68131a5f0ec>2006-07-03 14:39:15 +0000
committerskotlex <skotlex@54d463be-8e91-2dee-dedb-b68131a5f0ec>2006-07-03 14:39:15 +0000
commit8c01ccc448ce7ba067ece0e0dbc524671754494a (patch)
treef853883aca2709e637104aecbcc298cc2d8a51f2 /src/map/skill.c
parentb5febfe0a8d95d69ba8de291994993fabc5d718a (diff)
downloadhercules-8c01ccc448ce7ba067ece0e0dbc524671754494a.tar.gz
hercules-8c01ccc448ce7ba067ece0e0dbc524671754494a.tar.bz2
hercules-8c01ccc448ce7ba067ece0e0dbc524671754494a.tar.xz
hercules-8c01ccc448ce7ba067ece0e0dbc524671754494a.zip
- Fixed a compile warning in login sql/txt
- Fixed pc_makesavestatus not setting your logout position. - Fixed the UF * flags of Songs/Dances in skill_unit_db. - Fixed two dances becoming BA_DISSONANCE instead of DC_UGLYDANCE. - Added the missing +100% damage modifier of Enchant Deadly Poison. - Fixed SkillStatusChangeTable not working correctly for Homun/Guild skills. git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@7454 54d463be-8e91-2dee-dedb-b68131a5f0ec
Diffstat (limited to 'src/map/skill.c')
-rw-r--r--src/map/skill.c23
1 files changed, 16 insertions, 7 deletions
diff --git a/src/map/skill.c b/src/map/skill.c
index 250ef1d3c..fd7dc61d9 100644
--- a/src/map/skill.c
+++ b/src/map/skill.c
@@ -6166,7 +6166,7 @@ static int skill_dance_overlap_sub(struct block_list *bl, va_list ap)
if (!(target->val2 & src->val2 & ~UF_ENSEMBLE)) //They don't match (song + dance) is valid.
return 0;
if (flag) { //Set dissonance
- target->val1 = src->val1 = BA_DISSONANCE;
+ target->val1 = src->val1 = target->val2&UF_SONG?BA_DISSONANCE:DC_UGLYDANCE;
target->val2 |= UF_ENSEMBLE; //Add ensemble to signal this unit is overlapping.
} else { //Remove dissonance
target->val1 = target->group->skill_id; //Restore skill id
@@ -6665,11 +6665,16 @@ int skill_unit_onplace_timer (struct skill_unit *src, struct block_list *bl, uns
type = SkillStatusChangeTable(sg->skill_id);
skillid = sg->skill_id;
if (sg->state.song_dance && src->val2&UF_ENSEMBLE)
- { //Treat this group as if it were BA_DISSONANCE.
+ { //Treat this group as if it were BA_DISSONANCE/DC_UGLYDANCE.
//Values will be restored on proper switch case.
src->val1 = sg->unit_id;
- sg->unit_id = UNT_DISSONANCE;
- sg->skill_id = BA_DISSONANCE;
+ if (src->val2&UF_SONG) {
+ sg->unit_id = UNT_DISSONANCE;
+ sg->skill_id = BA_DISSONANCE;
+ } else {
+ sg->unit_id = UNT_UGLYDANCE;
+ sg->skill_id = DC_UGLYDANCE;
+ }
}
if (sg->interval == -1) {
@@ -6872,10 +6877,14 @@ int skill_unit_onplace_timer (struct skill_unit *src, struct block_list *bl, uns
break;
case UNT_UGLYDANCE: //Ugly Dance [Skotlex]
- if (ss->id == bl->id)
- break;
- if (bl->type == BL_PC)
+ if (ss->id != bl->id && bl->type == BL_PC)
skill_additional_effect(ss, bl, sg->skill_id, sg->skill_lv, BF_LONG|BF_SKILL|BF_MISC, tick);
+ if (sg->state.song_dance && src->val2&UF_ENSEMBLE)
+ { //Restore values.
+ sg->skill_id = skillid;
+ sg->unit_id = src->val1;
+ src->val1 = DC_UGLYDANCE;
+ }
break;
case UNT_DISSONANCE: