Browse Source

- Fixed item group 35 (lottobox) in item_misc.txt
- Item group reading will now complain when a line doesn't has enough fields.


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

skotlex 18 years ago
parent
commit
fc0f3b45bf
4 changed files with 17 additions and 11 deletions
  1. 2 0
      Changelog-Trunk.txt
  2. 1 0
      db/Changelog.txt
  3. 10 10
      db/item_misc.txt
  4. 4 1
      src/map/itemdb.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.
 IF YOU HAVE A WORKING AND TESTED BUGFIX PUT IT INTO STABLE AS WELL AS TRUNK.
 
 
 2006/09/25
 2006/09/25
+	* Item group reading will now complain when a line doesn't has enough
+	  fields. [Skotlex]
 	* Fixed #baselevelup adding instead of substracting status points when used
 	* Fixed #baselevelup adding instead of substracting status points when used
 	  with negative levels. Also made it reset your stats if there wasn't enough
 	  with negative levels. Also made it reset your stats if there wasn't enough
 	  to substract from. [Skotlex]
 	  to substract from. [Skotlex]

+ 1 - 0
db/Changelog.txt

@@ -20,6 +20,7 @@
 
 
 =========================
 =========================
 09/25
 09/25
+	* Fixed item group 35 (lottobox) in item_misc.txt [Skotlex]
 	* Added Ninja/Gunslinger job exp as separate exp chart [Playtester]
 	* Added Ninja/Gunslinger job exp as separate exp chart [Playtester]
 	* Immaterial Sword now has a 3% chance of reducing target's sp by 30% [Playtester]
 	* Immaterial Sword now has a 3% chance of reducing target's sp by 30% [Playtester]
 09/23
 09/23

+ 10 - 10
db/item_misc.txt

@@ -610,13 +610,13 @@
 33,5042,5	//Bao Bao
 33,5042,5	//Bao Bao
 33,5066,1	//Succubus Horn
 33,5066,1	//Succubus Horn
 // Lotto Box
 // Lotto Box
-35,7391
-35,7392
-35,7393
-35,7394
-35,7395
-35,7396
-35,7397
-35,7398
-35,7540
-35,7541
+35,7391,1
+35,7392,1
+35,7393,1
+35,7394,1
+35,7395,1
+35,7396,1
+35,7397,1
+35,7398,1
+35,7540,1
+35,7541,1

+ 4 - 1
src/map/itemdb.c

@@ -493,8 +493,11 @@ static void itemdb_read_itemgroup_sub(const char* filename)
 		}
 		}
 		if(str[0]==NULL)
 		if(str[0]==NULL)
 			continue;
 			continue;
-		if (j<3)
+		if (j<3) {
+			if (j>1) //Or else it barks on blank lines...
+				ShowWarning("itemdb_read_itemgroup: Insufficient fields for entry at %s:%d\n", filename, ln);
 			continue;
 			continue;
+		}
 		groupid = atoi(str[0]);
 		groupid = atoi(str[0]);
 		if (groupid < 0 || groupid >= MAX_ITEMGROUP) {
 		if (groupid < 0 || groupid >= MAX_ITEMGROUP) {
 			ShowWarning("itemdb_read_itemgroup: Invalid group %d in %s:%d\n", groupid, filename, ln);
 			ShowWarning("itemdb_read_itemgroup: Invalid group %d in %s:%d\n", groupid, filename, ln);