Browse Source

Fixes Marionette Control versus Curse/Quagmire (#6183)

* Fixes #5908.
* Marionette Control will no longer cast onto targets that are either Cursed or in Quagmire.
Thanks to @Tydus1!
Aleos 3 years ago
parent
commit
d8d6d74fc9
1 changed files with 4 additions and 4 deletions
  1. 4 4
      src/map/skill.cpp

+ 4 - 4
src/map/skill.cpp

@@ -6827,15 +6827,15 @@ int skill_castend_nodamage_id (struct block_list *src, struct block_list *bl, ui
 
 	case CG_MARIONETTE:
 		{
-			struct status_change* sc = status_get_sc(src);
-
-			if( sd && dstsd && (dstsd->class_&MAPID_UPPERMASK) == MAPID_BARDDANCER && dstsd->status.sex == sd->status.sex )
-			{// Cannot cast on another bard/dancer-type class of the same gender as caster
+			if( (sd && dstsd && (dstsd->class_&MAPID_UPPERMASK) == MAPID_BARDDANCER && dstsd->status.sex == sd->status.sex) || (tsc && (tsc->data[SC_CURSE] || tsc->data[SC_QUAGMIRE])) )
+			{// Cannot cast on another bard/dancer-type class of the same gender as caster, or targets under Curse/Quagmire
 				clif_skill_fail(sd,skill_id,USESKILL_FAIL_LEVEL,0);
 				map_freeblock_unlock();
 				return 1;
 			}
 
+			status_change* sc = status_get_sc(src);
+
 			if( sc && tsc )
 			{
 				if( !sc->data[SC_MARIONETTE] && !tsc->data[SC_MARIONETTE2] )