Forráskód Böngészése

- Fixed the new addeff structure not working well with SC_STONE (because SC_STONE is 0, which was by default not handled as a valid value).
- Added back the TF_MISS walking speed bonus to assassin type classes (how did that got lost?)


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

skotlex 19 éve
szülő
commit
598e005ed4
4 módosított fájl, 11 hozzáadás és 5 törlés
  1. 5 0
      Changelog-Trunk.txt
  2. 2 3
      src/map/pc.c
  3. 2 2
      src/map/skill.c
  4. 2 0
      src/map/status.c

+ 5 - 0
Changelog-Trunk.txt

@@ -4,6 +4,11 @@ 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.
 
 2006/07/08
+	* Fixed the new addeff structure not working well with SC_STONE (because
+	  SC_STONE is 0, which was by default not handled as a valid value).
+	  [Skotlex]
+	* Added back the TF_MISS walking speed bonus to assassin type classes (how
+	  did that got lost?) [Skotlex]
 	* Fixed mobinfo displaying exp as signed ints rather than unsigned.
 	  [Skotlex]
 	* Added status_check_visibility to check if an object is within range of

+ 2 - 3
src/map/pc.c

@@ -1173,12 +1173,11 @@ static int pc_bonus_autospell(struct s_autospell *spell, int max, short id, shor
 
 static int pc_bonus_addeff(struct s_addeffect *effect, int max, short id, short rate, short arrow_rate, unsigned char flag) {
 	int i;
-
-	for (i = 0; i < max && effect[i].id; i++) {
+	for (i = 0; i < max && effect[i].flag; i++) {
 		if (effect[i].id == id && effect[i].flag == flag)
 		{
 			effect[i].rate += rate;
-			effect[i].arrow_rate += rate;
+			effect[i].arrow_rate += arrow_rate;
 			return 1;
 		}
 	}

+ 2 - 2
src/map/skill.c

@@ -1339,7 +1339,7 @@ int skill_additional_effect (struct block_list* src, struct block_list *bl, int
 		skillid != CR_REFLECTSHIELD
 	){	//Trigger status effects
 		int i, type;
-		for(i=0; i < MAX_PC_BONUS && sd->addeff[i].id; i++)
+		for(i=0; i < MAX_PC_BONUS && sd->addeff[i].flag; i++)
 		{
 			rate = sd->addeff[i].rate;
 			type = sd->state.arrow_atk; //Ranged?
@@ -1478,7 +1478,7 @@ int skill_counter_additional_effect (struct block_list* src, struct block_list *
 	if(dstsd && attack_type&BF_WEAPON)
 	{	//Counter effects.
 		int i, type, time;
-		for(i=0; i < MAX_PC_BONUS && dstsd->addeff2[i].id; i++)
+		for(i=0; i < MAX_PC_BONUS && dstsd->addeff2[i].flag; i++)
 		{
 			rate = dstsd->addeff2[i].rate;
 			type = (sd && sd->state.arrow_atk) || (status_get_range(src)>2);

+ 2 - 0
src/map/status.c

@@ -2011,6 +2011,8 @@ int status_calc_pc(struct map_session_data* sd,int first)
 // ----- WALKING SPEED CALCULATION -----
 
 	// Relative modifiers from passive skills
+	if((sd->class_&MAPID_UPPERMASK) == MAPID_ASSASSIN && (skill=pc_checkskill(sd,TF_MISS))>0)
+		status->speed -= status->speed * skill/100;
 	if(pc_isriding(sd) && pc_checkskill(sd,KN_RIDING)>0)
 		status->speed -= status->speed * 25/100;
 	if(pc_iscarton(sd) && (skill=pc_checkskill(sd,MC_PUSHCART))>0)