Переглянути джерело

- Close confine won't get the bonus range on cast as other skills do due to exploits.
- Fixed a bug in setnpctimer checking out the wrong variable.


git-svn-id: https://svn.code.sf.net/p/rathena/svn/trunk@5347 54d463be-8e91-2dee-dedb-b68131a5f0ec

skotlex 19 роки тому
батько
коміт
3dbf70680c
3 змінених файлів з 6 додано та 2 видалено
  1. 3 0
      Changelog-Trunk.txt
  2. 1 1
      src/map/npc.c
  3. 2 1
      src/map/skill.c

+ 3 - 0
Changelog-Trunk.txt

@@ -5,6 +5,9 @@ IF YOU HAVE A WORKING AND TESTED BUGFIX PUT IT INTO STABLE AS WELL AS TRUNK.  EV
 GOES INTO TRUNK AND WILL BE MERGED INTO STABLE BY VALARIS AND WIZPUTER. -- VALARIS
 
 2006/02/20
+	* Close confine won't get the bonus range on cast as other skills do due to
+	  exploits. [Skotlex]
+	* Fixed a bug in setnpctimer. [Skotlex]
 	* Menu-based skills now use their own variables separetly from the normal
 	  skill variables. This should enable them to work even when you keep doing
 	  other stuff between the menu invocation and selection. Also gives a better

+ 1 - 1
src/map/npc.c

@@ -769,7 +769,7 @@ int npc_settimerevent_tick(struct npc_data *nd,int newtimer)
 		}
 		flag= sd->npc_timer_id != -1 ;
 	} else
-		flag= nd->u.scr.timer != -1 ;
+		flag= nd->u.scr.timerid != -1 ;
 	if(flag)
 		npc_timerevent_stop(nd);
 	nd->u.scr.timer=newtimer;

+ 2 - 1
src/map/skill.c

@@ -8489,7 +8489,8 @@ int skill_use_id (struct map_session_data *sd, int target_id, int skill_num, int
 	if (!skill_check_condition(sd,0)) return 0;	
 
 	if(sd->bl.id != target_id){ // Don't check range for self skills, this is useless...
-		if(!battle_check_range(&sd->bl,bl,skill_get_range2(&sd->bl, skill_num,skill_lv)+1))
+		if(!battle_check_range(&sd->bl,bl,skill_get_range2(&sd->bl, skill_num,skill_lv)
+		+(skill_num==RG_CLOSECONFINE)?0:1)) //Close confine is expoitable thanks to this extra range "feature" of the client. [Skotlex]
 			return 0;
 	}