فهرست منبع

* Fixed searchstores not removing character data when logging off. (bugreport:8080) (Merged from Hercules:58e2d27)

aleos89 11 سال پیش
والد
کامیت
3887ffd832
2فایلهای تغییر یافته به همراه4 افزوده شده و 1 حذف شده
  1. 3 0
      src/map/map.c
  2. 1 1
      src/map/vending.c

+ 3 - 0
src/map/map.c

@@ -1727,6 +1727,9 @@ int map_quit(struct map_session_data *sd) {
 		}
 	}
 
+	if (sd->state.vending)
+		idb_remove(vending_db, sd->status.char_id);
+
 	pc_damage_log_clear(sd,0);
 	party_booking_delete(sd); // Party Booking [Spiria]
 	pc_makesavestatus(sd);

+ 1 - 1
src/map/vending.c

@@ -294,7 +294,7 @@ void vending_openvending(struct map_session_data* sd, const char* message, const
 	clif_openvending(sd,sd->bl.id,sd->vending);
 	clif_showvendingboard(&sd->bl,message,0);
 
-	idb_put(vending_db, sd->vender_id, sd);
+	idb_put(vending_db, sd->status.char_id, sd);
 }