Selaa lähdekoodia

- Overlapping song/dances will now cause dissonance/ugly-dance level 1 instead of retaining the level of their song/dance.
- Fixed the misleading description of what item_avail does.
- Fixed wrong check in @petrename, thanks to The Ultra Mage.


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

skotlex 18 vuotta sitten
vanhempi
commit
17f4afab04
6 muutettua tiedostoa jossa 14 lisäystä ja 5 poistoa
  1. 4 0
      Changelog-Trunk.txt
  2. 1 0
      db/Changelog.txt
  3. 2 1
      db/item_avail.txt
  4. 1 1
      src/map/atcommand.c
  5. 1 2
      src/map/clif.c
  6. 5 1
      src/map/skill.c

+ 4 - 0
Changelog-Trunk.txt

@@ -3,6 +3,10 @@ Date	Added
 AS OF SVN REV. 5091, WE ARE NOW USING TRUNK.  ALL UNTESTED BUGFIXES/FEATURES GO INTO TRUNK.
 IF YOU HAVE A WORKING AND TESTED BUGFIX PUT IT INTO STABLE AS WELL AS TRUNK.
 
+2006/11/16
+	* Overlapping song/dances will now cause dissonance/ugly-dance level 1
+	  instead of retaining the level of their song/dance. [Skotlex]
+	* Fixed wrong check in @petrename, thanks to The Ultra Mage.[Skotlex]
 2006/11/14
 	* Early Christmas present. 3 new "features" which were very easy to code,
 	  and should help scripters tremendously. Eapp is quite a way from being

+ 1 - 0
db/Changelog.txt

@@ -20,6 +20,7 @@
 
 ========================
 11/16
+	* Fixed the misleading description of what item_avail does. [Skotlex]
 	* Updated X.3 mob stats [Playtester]
 	* Updated Kiel dungeon mob stats [Playtester]
 	* Changed type of unimplemented cards to "Card" [Playtester]

+ 2 - 1
db/item_avail.txt

@@ -1,5 +1,6 @@
 // item id,sprite id
-// Client will use sprite ID to display particular item.
+// Replaces an item client-side while keeping them separate server-side.
+// Think of it as a way to disguise items.
 // If 0 is used then item will be disabled.
 2240,2241 //Beard - Grampa Beard
 

+ 1 - 1
src/map/atcommand.c

@@ -4337,7 +4337,7 @@ int atcommand_petrename(
 		return -1;
 	}
 	pd = sd->pd;
-	if (pd->pet.rename_flag) {
+	if (!pd->pet.rename_flag) {
 		clif_displaymessage(fd, msg_txt(188)); // You can already rename your pet.
 		return -1;
 	}

+ 1 - 2
src/map/clif.c

@@ -8356,7 +8356,6 @@ void clif_parse_LoadEndAck(int fd,struct map_session_data *sd)
 
 	if(sd->state.connect_new) {
 		int lv;
-	
 		sd->state.connect_new = 0;
 		clif_skillinfoblock(sd);
 		clif_updatestatus(sd,SP_NEXTBASEEXP);
@@ -9124,7 +9123,7 @@ void clif_parse_Wis(int fd, struct map_session_data *sd) { // S 0096 <len>.w <ni
 			{
 				sprintf(whisper_tmp, "@whispervar%d$", i);
 				set_var(sd,whisper_tmp,(char *) split_data[i]);        
-			}//You don't need to zero them, iust reset them [Kevin]
+			}//You don't need to zero them, just reset them [Kevin]
 			
 			aFree(whisper_tmp);
 			whisper_tmp=(char *)aMallocA((strlen(npc->name)+18)*sizeof(char));

+ 5 - 1
src/map/skill.c

@@ -6435,6 +6435,7 @@ static int skill_dance_switch_sub(struct skill_unit *unit, struct skill_unit_gro
 		memset(&uglydance, 0, sizeof(uglydance));
 		group2 = &dissonance;
 		group2->skill_id = BA_DISSONANCE;
+		group2->skill_lv = 1;
 		group2->unit_id = skill_get_unit_id(group2->skill_id,0);
 		group2->target_flag = skill_get_unit_target(group2->skill_id);
 		group2->bl_flag= skill_get_unit_bl_target(group2->skill_id);
@@ -6442,6 +6443,7 @@ static int skill_dance_switch_sub(struct skill_unit *unit, struct skill_unit_gro
 
 		group2 = &uglydance;
 		group2->skill_id = DC_UGLYDANCE;
+		group2->skill_lv = 1;
 		group2->unit_id = skill_get_unit_id(group2->skill_id,0);
 		group2->target_flag = skill_get_unit_target(group2->skill_id);
 		group2->bl_flag= skill_get_unit_bl_target(group2->skill_id);
@@ -6454,12 +6456,14 @@ static int skill_dance_switch_sub(struct skill_unit *unit, struct skill_unit_gro
 		memcpy(&original, group, sizeof(struct skill_unit_group)); //Backup
 		group2 = unit->val2&UF_SONG?&dissonance:&uglydance;
 		group->skill_id = group2->skill_id;
+		group->skill_lv = group2->skill_lv;
 		group->unit_id = group2->unit_id;
 		group->target_flag = group2->target_flag;
 		group->bl_flag= group2->bl_flag;
 		group->interval = group2->interval;
 	} else { //Restore only relevant values (should the backup be 5 ints rather than the whole structure?)
 		group->skill_id = original.skill_id;
+		group->skill_lv = original.skill_lv;
 		group->unit_id = original.unit_id;
 		group->target_flag = original.target_flag;
 		group->bl_flag = original.bl_flag;
@@ -9325,7 +9329,7 @@ int skill_cell_overlap(struct block_list *bl, va_list ap)
 			}
 			//Delete the rest of types.
 		case HW_GANBANTEIN:
-			if(!skill_get_inf2(unit->group->skill_id)&(INF2_SONG_DANCE|INF2_TRAP))
+			if(!(skill_get_inf2(unit->group->skill_id)&(INF2_SONG_DANCE|INF2_TRAP)))
 			{	//It deletes everything except songs/dances
 				skill_delunit(unit, 1);
 				return 1;