Browse Source

* Reverting a change on deleting any skill units when we're logging off
* Added check whether an item is allowed to be dropped

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

celest 20 years ago
parent
commit
d3003849b8
4 changed files with 9 additions and 9 deletions
  1. 4 0
      Changelog.txt
  2. 0 1
      src/map/clif.c
  3. 2 2
      src/map/map.c
  4. 3 6
      src/map/pc.c

+ 4 - 0
Changelog.txt

@@ -1,6 +1,10 @@
 Date	Added
 
 12/20
+        * Experimental: Reverting a change on deleting any skill units when we're 
+          logging off - might reduce the 'delete_timer' errors [celest]
+        * Added check whether an item is allowed to be dropped, for example wedding
+          rings [celest]
         * Updated Acid Terror - should never miss [celest]
         * updated Sword Reject - should display reflected damage properly now [celest]
         * Updated Double Strafe - should only work with bows [celest]

+ 0 - 1
src/map/clif.c

@@ -9092,7 +9092,6 @@ void clif_parse_MoveToKafra(int fd, struct map_session_data *sd) {
 		return;
 
 	if(itemdb_isdropable(sd->status.inventory[item_index].nameid) == 0)
-
 		return;
 
 	if (sd->state.storage_flag)

+ 2 - 2
src/map/map.c

@@ -995,7 +995,7 @@ int map_quit(struct map_session_data *sd) {
 		sd->status.hp = 100;
 
 	skill_status_change_clear(&sd->bl,1);	// ステ?タス異常を解除する
-//	skill_clear_unitgroup(&sd->bl);	// スキルユニットグル?プの削除
+	skill_clear_unitgroup(&sd->bl);	// スキルユニットグル?プの削除
 	skill_cleartimerskill(&sd->bl);
 	pc_stop_walking(sd,0);
 	pc_stopattack(sd);
@@ -1004,7 +1004,7 @@ int map_quit(struct map_session_data *sd) {
 	skill_gangsterparadise(sd,0);
 
 	pc_calcstatus(sd,4);
-	skill_clear_unitgroup(&sd->bl);	// [Sara-chan]
+//	skill_clear_unitgroup(&sd->bl);	// [Sara-chan]
 
 	clif_clearchar_area(&sd->bl,2);
 

+ 3 - 6
src/map/pc.c

@@ -1475,7 +1475,7 @@ int pc_calcstatus(struct map_session_data* sd,int first)
 	}
 
 	// New guild skills - Celest
-	if (sd->status.guild_id > 0) {
+	if (sd->status.guild_id > 0 && !(first&4)) {
 		struct guild *g;
 		if ((g = guild_search(sd->status.guild_id)) && strcmp(sd->status.name,g->master)==0) {
 			if (!sd->state.leadership_flag && guild_checkskill(g, GD_LEADERSHIP)>0) {
@@ -3174,19 +3174,16 @@ int pc_dropitem(struct map_session_data *sd,int n,int amount)
 	nullpo_retr(1, sd);
 
 	if(n < 0 || n >= MAX_INVENTORY)
-
 		return 1;
 
-
 	if(amount <= 0)
-
 		return 1;
 
-
 	if (sd->status.inventory[n].nameid <= 0 ||
 	    sd->status.inventory[n].amount < amount ||
 	    sd->trade_partner != 0 || sd->vender_id != 0 ||
-	    sd->status.inventory[n].amount <= 0)
+	    sd->status.inventory[n].amount <= 0 ||
+		itemdb_isdropable(sd->status.inventory[n].nameid) == 0) // Celest
 		return 1;
 	map_addflooritem(&sd->status.inventory[n], amount, sd->bl.m, sd->bl.x, sd->bl.y, NULL, NULL, NULL, 0);
 	pc_delitem(sd, n, amount, 0);