diff options
author | skotlex <skotlex@54d463be-8e91-2dee-dedb-b68131a5f0ec> | 2006-04-09 22:52:06 +0000 |
---|---|---|
committer | skotlex <skotlex@54d463be-8e91-2dee-dedb-b68131a5f0ec> | 2006-04-09 22:52:06 +0000 |
commit | 532ebd7e97e1948f6fe7ad8b823faa1f101896be (patch) | |
tree | 42df864d100c972cb09c38527df4a12fd98a5680 | |
parent | 5972e1349abc1d4343b970c28faf263218635eb5 (diff) | |
download | hercules-532ebd7e97e1948f6fe7ad8b823faa1f101896be.tar.gz hercules-532ebd7e97e1948f6fe7ad8b823faa1f101896be.tar.bz2 hercules-532ebd7e97e1948f6fe7ad8b823faa1f101896be.tar.xz hercules-532ebd7e97e1948f6fe7ad8b823faa1f101896be.zip |
- Changed use of strtol to strtoll as strtol's result is just a signed int, and we need to parse values above 0x7FFFFFFF
- Corrected Knives being usable by Gunslinger. SQL users use upgrade_svn5972.sql to ugprade that.
git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@5972 54d463be-8e91-2dee-dedb-b68131a5f0ec
-rw-r--r-- | Changelog-Trunk.txt | 5 | ||||
-rw-r--r-- | db/item_db.txt | 40 | ||||
-rw-r--r-- | sql-files/upgrade_svn5972.sql | 1 | ||||
-rw-r--r-- | src/map/itemdb.c | 4 |
4 files changed, 28 insertions, 22 deletions
diff --git a/Changelog-Trunk.txt b/Changelog-Trunk.txt index dd121ae33..1e9645f4f 100644 --- a/Changelog-Trunk.txt +++ b/Changelog-Trunk.txt @@ -4,6 +4,11 @@ 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/04/09
+ * Changed use of strtol to strtoll when reading the equip_jobs as strtol's
+ result is just a signed int, fixes reading of equippable jobs for certain
+ items. [Skotlex]
+ * Corrected Knives being usable by Gunslinger. SQL users use
+ upgrade_svn5972.sql to ugprade that. [Skotlex]
* Modified @warp/@rura to prevent causing pc_setpos position error
messages. [Skotlex]
* Fixed the mob's last_thinktime not being updated on mob_spawn, causing
diff --git a/db/item_db.txt b/db/item_db.txt index 5bec8f7fd..00fb7d34f 100644 --- a/db/item_db.txt +++ b/db/item_db.txt @@ -516,24 +516,24 @@ 1169,Executioner,Executioner,4,,10,2200,155,,1,0,0x00004082,7,2,34,4,48,1,3,{ bonus bIgnoreDefRace,RC_DemiHuman; bonus2 bAddRace,RC_DemiHuman,20; bonus2 bSubRace,RC_DemiHuman,-10; bonus bAtkEle,Ele_Dark; } 1170,Katzbalger,Katzbalger,4,,10,2000,175,,1,0,0x00004082,7,2,34,4,48,1,3,{ bonus bVit,5; bonus bDef,10; } // Daggers -1201,Knife,Knife,4,50,,400,17,,1,3,0xEFFF7EEF,7,2,2,1,1,1,1,{} -1202,Knife_,Knife,4,50,,400,17,,1,4,0xEFFF7EEF,7,2,2,1,1,1,1,{} -1203,Knife__,Knife,4,50,,400,17,,1,0,0xEFFF7EEF,7,2,2,1,1,1,1,{} -1204,Cutter,Cutter,4,1250,,500,30,,1,3,0xEFFF7EEF,7,2,2,1,1,1,1,{} -1205,Cutter_,Cutter,4,1250,,500,30,,1,4,0xEFFF7EEF,7,2,2,1,1,1,1,{} -1206,Cutter__,Cutter,4,1250,,500,30,,1,0,0xEFFF7EEF,7,2,2,1,1,1,1,{} -1207,Main_Gauche,Main Gauche,4,2400,,600,43,,1,3,0xEFFF7EEF,7,2,2,1,1,1,1,{} -1208,Main_Gauche_,Main Gauche,4,2400,,600,43,,1,4,0xEFFF7EEF,7,2,2,1,1,1,1,{} -1209,Main_Gauche__,Main Gauche,4,2400,,600,43,,1,0,0xEFFF7EEF,7,2,2,1,1,1,1,{} -1210,Dirk,Dirk,4,8500,,500,59,,1,2,0xEFFF7EEF,7,2,2,2,12,1,1,{} -1211,Dirk_,Dirk,4,8500,,500,59,,1,3,0xEFFF7EEF,7,2,2,2,12,1,1,{} -1212,Dirk__,Dirk,4,8500,,500,59,,1,0,0xEFFF7EEF,7,2,2,2,12,1,1,{} -1213,Dagger,Dagger,4,14000,,600,73,,1,2,0xEFFF7EEF,7,2,2,2,12,1,1,{} -1214,Dagger_,Dagger,4,14000,,600,73,,1,3,0xEFFF7EEF,7,2,2,2,12,1,1,{} -1215,Dagger__,Dagger,4,14000,,600,73,,1,0,0xEFFF7EEF,7,2,2,2,12,1,1,{} -1216,Stiletto,Stiletto,4,19500,,700,87,,1,2,0xEFFF7EEF,7,2,2,2,12,1,1,{} -1217,Stiletto_,Stiletto,4,19500,,700,87,,1,3,0xEFFF7EEF,7,2,2,2,12,1,1,{} -1218,Stiletto__,Stiletto,4,19500,,700,87,,1,0,0xEFFF7EEF,7,2,2,2,12,1,1,{} +1201,Knife,Knife,4,50,,400,17,,1,3,0xFEFF7EEF,7,2,2,1,1,1,1,{} +1202,Knife_,Knife,4,50,,400,17,,1,4,0xFEFF7EEF,7,2,2,1,1,1,1,{} +1203,Knife__,Knife,4,50,,400,17,,1,0,0xFEFF7EEF,7,2,2,1,1,1,1,{} +1204,Cutter,Cutter,4,1250,,500,30,,1,3,0xFEFF7EEF,7,2,2,1,1,1,1,{} +1205,Cutter_,Cutter,4,1250,,500,30,,1,4,0xFEFF7EEF,7,2,2,1,1,1,1,{} +1206,Cutter__,Cutter,4,1250,,500,30,,1,0,0xFEFF7EEF,7,2,2,1,1,1,1,{} +1207,Main_Gauche,Main Gauche,4,2400,,600,43,,1,3,0xFEFF7EEF,7,2,2,1,1,1,1,{} +1208,Main_Gauche_,Main Gauche,4,2400,,600,43,,1,4,0xFEFF7EEF,7,2,2,1,1,1,1,{} +1209,Main_Gauche__,Main Gauche,4,2400,,600,43,,1,0,0xFEFF7EEF,7,2,2,1,1,1,1,{} +1210,Dirk,Dirk,4,8500,,500,59,,1,2,0xFEFF7EEF,7,2,2,2,12,1,1,{} +1211,Dirk_,Dirk,4,8500,,500,59,,1,3,0xFEFF7EEF,7,2,2,2,12,1,1,{} +1212,Dirk__,Dirk,4,8500,,500,59,,1,0,0xFEFF7EEF,7,2,2,2,12,1,1,{} +1213,Dagger,Dagger,4,14000,,600,73,,1,2,0xFEFF7EEF,7,2,2,2,12,1,1,{} +1214,Dagger_,Dagger,4,14000,,600,73,,1,3,0xFEFF7EEF,7,2,2,2,12,1,1,{} +1215,Dagger__,Dagger,4,14000,,600,73,,1,0,0xFEFF7EEF,7,2,2,2,12,1,1,{} +1216,Stiletto,Stiletto,4,19500,,700,87,,1,2,0xFEFF7EEF,7,2,2,2,12,1,1,{} +1217,Stiletto_,Stiletto,4,19500,,700,87,,1,3,0xFEFF7EEF,7,2,2,2,12,1,1,{} +1218,Stiletto__,Stiletto,4,19500,,700,87,,1,0,0xFEFF7EEF,7,2,2,2,12,1,1,{} 1219,Gladius,Gladius,4,43000,,700,105,,1,2,0x028F5EEE,7,2,2,3,24,1,1,{} 1220,Gladius_,Gladius,4,43000,,700,105,,1,3,0x028F5EEE,7,2,2,3,24,1,1,{} 1221,Gladius__,Gladius,4,43000,,700,105,,1,0,0x028F5EEE,7,2,2,3,24,1,1,{} @@ -2386,8 +2386,8 @@ 13000,Jujube_Dagger,Dagger with Jujube hilt,4,,5000,600,39,,1,0,0x008F5EEF,7,2,2,1,0,1,1,{ bonus bAtkEle,Ele_Wind; } 13001,Dragon_Killer,Dragon Killer,4,,10,900,110,,1,0,0x008F5EEF,7,2,2,4,60,1,1,{ bonus bIgnoreDefRace,RC_Dragon; bonus2 bExpAddRace,RC_Dragon,10; } 13002,Ginnungagap,Ginnungagap,4,,10,700,120,,1,0,0x008F5EEF,7,2,2,4,70,1,1,{ bonus bAtkEle,Ele_Dark; bonus2 bAddEff,Eff_Blind,500; bonus2 bAddEff2,Eff_Blind,50; } -13003,Cowardice_Blade,Cowardice Blade,4,52000,,700,80,,1,1,0xEFFF7EEF,7,2,2,3,55,1,1,{ bonus bDef,5; } -13004,Cowardice_Blade_,Cowardice Blade,4,52000,,700,80,,1,2,0xEFFF7EEF,7,2,2,3,55,1,1,{ bonus bDef,5; } +13003,Cowardice_Blade,Cowardice Blade,4,52000,,700,80,,1,1,0xFEFF7EEF,7,2,2,3,55,1,1,{ bonus bDef,5; } +13004,Cowardice_Blade_,Cowardice Blade,4,52000,,700,80,,1,2,0xFEFF7EEF,7,2,2,3,55,1,1,{ bonus bDef,5; } 13005,Angelic_Wing_Dagger,Angelic Wing Dagger,4,,10,10,0,,1,1,0x00000000,0,2,0,0,0,0,0,{} // Ninja Weapons 13006,Gokurin,Gokurin,4,240000,,600,150,,1,0,0x02000000,7,2,2,3,65,1,1,{ bonus bAtkEle,Ele_Dark; bonus2 bAddEff,Eff_Curse,500; } diff --git a/sql-files/upgrade_svn5972.sql b/sql-files/upgrade_svn5972.sql new file mode 100644 index 000000000..eec3ecc30 --- /dev/null +++ b/sql-files/upgrade_svn5972.sql @@ -0,0 +1 @@ +UPDATE item_db SET equip_jobs = 0xFEFF7EEF WHERE equip_jobs = 0xEFFF7EEF; diff --git a/src/map/itemdb.c b/src/map/itemdb.c index 9b48efec9..5771ec66d 100644 --- a/src/map/itemdb.c +++ b/src/map/itemdb.c @@ -914,7 +914,7 @@ static int itemdb_read_sqldb(void) ShowWarning("itemdb_read_sqldb: Item %d (%s) specifies %d slots, but the server only supports up to %d\n", nameid, id->jname, id->slot, MAX_SLOTS);
id->slot = MAX_SLOTS;
}
- itemdb_jobid2mapid(id->class_base, (sql_row[11] != NULL) ? (unsigned int)strtol(sql_row[11], NULL, 0) : 0);
+ itemdb_jobid2mapid(id->class_base, (sql_row[11] != NULL) ? (unsigned int)strtoll(sql_row[11], NULL, 0) : 0);
id->class_upper= (sql_row[12] != NULL) ? atoi(sql_row[12]) : 0;
id->sex = (sql_row[13] != NULL) ? atoi(sql_row[13]) : 0;
id->equip = (sql_row[14] != NULL) ? atoi(sql_row[14]) : 0;
@@ -1057,7 +1057,7 @@ static int itemdb_readdb(void) ShowWarning("itemdb_readdb: Item %d (%s) specifies %d slots, but the server only supports up to %d\n", nameid, id->jname, id->slot, MAX_SLOTS);
id->slot = MAX_SLOTS;
}
- itemdb_jobid2mapid(id->class_base, (unsigned int)strtol(str[11],NULL,0));
+ itemdb_jobid2mapid(id->class_base, (unsigned int)strtoll(str[11],NULL,0));
id->class_upper = atoi(str[12]);
id->sex = atoi(str[13]);
if(id->equip != atoi(str[14])){
|