Sfoglia il codice sorgente

- Corrected the firewall/kaensin knockback code to how it is supposed to be done (the element/race check was originally in battle.c, and it was moved to skill.c because of the firewall hits on undead setting, now that it is not needed the code can be changed to how it was back then).

git-svn-id: https://svn.code.sf.net/p/rathena/svn/trunk@11594 54d463be-8e91-2dee-dedb-b68131a5f0ec
skotlex 17 anni fa
parent
commit
88e0444634
2 ha cambiato i file con 2 aggiunte e 3 eliminazioni
  1. 1 1
      src/map/battle.c
  2. 1 2
      src/map/skill.c

+ 1 - 1
src/map/battle.c

@@ -2157,7 +2157,7 @@ struct Damage battle_calc_magic_attack(struct block_list *src,struct block_list
 		case MG_FIREWALL:
 		case NJ_KAENSIN:
 			ad.dmotion = 0; //No flinch animation.
-			if(mflag) //mflag has a value when it was checked against an undead in skill.c [Skotlex]
+			if ( tstatus->def_ele == ELE_FIRE || battle_check_undead(tstatus->race, tstatus->def_ele) )
 				ad.blewcount = 0; //No knockback
 			break;
 		case PR_SANCTUARY:

+ 1 - 2
src/map/skill.c

@@ -7325,11 +7325,10 @@ int skill_unit_onplace_timer (struct skill_unit *src, struct block_list *bl, uns
 		{
 			int count=0;
 			const int x = bl->x, y = bl->y;
-			const bool noknockback = ( tstatus->def_ele == ELE_FIRE || battle_check_undead(tstatus->race, tstatus->def_ele) );
 
 			//Take into account these hit more times than the timer interval can handle.
 			do
-				skill_attack(BF_MAGIC,ss,&src->bl,bl,sg->skill_id,sg->skill_lv,tick+count*sg->interval,noknockback);
+				skill_attack(BF_MAGIC,ss,&src->bl,bl,sg->skill_id,sg->skill_lv,tick+count*sg->interval,0);
 			while(--src->val2 && x == bl->x && y == bl->y &&
 				++count < SKILLUNITTIMER_INTERVAL/sg->interval && !status_isdead(bl));