Просмотр исходного кода

- Fixed inverted check which was preventing you from buying more than 1 from any stackable item....

git-svn-id: https://svn.code.sf.net/p/rathena/svn/trunk@7627 54d463be-8e91-2dee-dedb-b68131a5f0ec
skotlex 19 лет назад
Родитель
Сommit
a2b96bc621
2 измененных файлов с 3 добавлено и 1 удалено
  1. 2 0
      Changelog-Trunk.txt
  2. 1 1
      src/map/npc.c

+ 2 - 0
Changelog-Trunk.txt

@@ -4,6 +4,8 @@ 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/11
+	* Fixed inverted check which was preventing you from buying more than 1
+	  from any stackable item.... [Skotlex]
 	* Should have fixed the crash in intif gm message... [Skotlex]
 	* Fixed GTB card only working while you had a status-change active.
 	  [Skotlex]

+ 1 - 1
src/map/npc.c

@@ -1198,7 +1198,7 @@ int npc_buylist(struct map_session_data *sd,int n,unsigned short *item_list)
 		if (nd->u.shop_item[j].nameid==0)
 			return 3;
 		
-		if (itemdb_isstackable(nd->u.shop_item[j].nameid) && item_list[i*2] > 1)
+		if (!itemdb_isstackable(nd->u.shop_item[j].nameid) && item_list[i*2] > 1)
 		{	//Exploit? You can't buy more than 1 of equipment types o.O
 			ShowWarning("Player %s (%d:%d) sent a hexed packet trying to buy %d of nonstackable item %d!\n",
 				sd->status.name, sd->status.account_id, sd->status.char_id, item_list[i*2], nd->u.shop_item[j].nameid);