Ver código fonte

Magical damage reflection now works against boss monsters and only on target skill(but EarthQuake with one target is an exception).(bugreport:3026, bugreport:2527)

git-svn-id: https://svn.code.sf.net/p/rathena/svn/trunk@13857 54d463be-8e91-2dee-dedb-b68131a5f0ec
Inkfish 16 anos atrás
pai
commit
db7a45d725
2 arquivos alterados com 4 adições e 2 exclusões
  1. 1 0
      Changelog-Trunk.txt
  2. 3 2
      src/map/skill.c

+ 1 - 0
Changelog-Trunk.txt

@@ -4,6 +4,7 @@ AS OF SVN REV. 5091, WE ARE NOW USING TRUNK.  ALL UNTESTED BUGFIXES/FEATURES GO
 IF YOU HAVE A WORKING AND TESTED BUGFIX PUT IT INTO STABLE AS WELL AS TRUNK.
 
 09/06/07
+	* Magical damage reflection now works against boss monsters and only on target skill(but EarthQuake with one target is an exception). [Inkfish]
 	* Changed hardcoded "5" to MAX_ARROW_RESOURCE in skill_arrow_create preventing proper usage. (bugreport:3025) [Paradox924X]
 	* Implemented "cooking exp" that increases the success chance of cooking by 0.05% per try and the max bonus is 20%. [Inkfish]
 09/06/05

+ 3 - 2
src/map/skill.c

@@ -1630,8 +1630,9 @@ int skill_attack (int attack_type, struct block_list* src, struct block_list *ds
 		}
 	}
 
-	if (dmg.flag&BF_MAGIC) {
-		if( !(sstatus->mode&MD_BOSS) && (dmg.damage || dmg.damage2) && skill_magic_reflect(src, bl, src==dsrc) )
+	if( dmg.flag&BF_MAGIC && ( skillid != NPC_EARTHQUAKE || (flag&0xFFF) == 1 ) )
+	{ // Earthquake on multiple targets is not counted as a target skill. [Inkfish]
+		if( (dmg.damage || dmg.damage2) && skill_magic_reflect(src, bl, src==dsrc) )
 		{	//Magic reflection, switch caster/target
 			struct block_list *tbl = bl;
 			bl = src;