summaryrefslogtreecommitdiff
path: root/sql-files
diff options
context:
space:
mode:
authorultramage <ultramage@54d463be-8e91-2dee-dedb-b68131a5f0ec>2007-03-02 00:11:54 +0000
committerultramage <ultramage@54d463be-8e91-2dee-dedb-b68131a5f0ec>2007-03-02 00:11:54 +0000
commit572e2c0dcc4e124136f9ad4bc493184e917e8f63 (patch)
treef93861924f9b03e10feb005e21eb51672693e545 /sql-files
parentf9b1682603fee23ba36ff04fbdc303dd0b7cf0ef (diff)
downloadhercules-572e2c0dcc4e124136f9ad4bc493184e917e8f63.tar.gz
hercules-572e2c0dcc4e124136f9ad4bc493184e917e8f63.tar.bz2
hercules-572e2c0dcc4e124136f9ad4bc493184e917e8f63.tar.xz
hercules-572e2c0dcc4e124136f9ad4bc493184e917e8f63.zip
EOL-styled some more files
git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@9947 54d463be-8e91-2dee-dedb-b68131a5f0ec
Diffstat (limited to 'sql-files')
-rw-r--r--sql-files/convert_engine.sql44
-rw-r--r--sql-files/convert_passwords.sql6
-rwxr-xr-xsql-files/item_db2.sql84
-rw-r--r--sql-files/logs.sql224
-rw-r--r--sql-files/mail.sql24
-rw-r--r--sql-files/main.sql1156
-rw-r--r--sql-files/oA2eA-rc5.sql408
-rw-r--r--sql-files/update_logs.sql26
-rw-r--r--sql-files/upgrade_0.5.2_database.sql2
-rw-r--r--sql-files/upgrade_0.5.2_main.sql124
-rw-r--r--sql-files/upgrade_1.0.0-rc1_main.sql6
-rw-r--r--sql-files/upgrade_1.0.0-rc2_database.sql8
-rw-r--r--sql-files/upgrade_1.0.0-rc5_database.sql8
-rw-r--r--sql-files/upgrade_svn1759.sql36
-rw-r--r--sql-files/upgrade_svn1863.sql14
-rw-r--r--sql-files/upgrade_svn2068.sql6
-rw-r--r--sql-files/upgrade_svn2252.sql28
-rw-r--r--sql-files/upgrade_svn2331.sql6
-rw-r--r--sql-files/upgrade_svn2574.sql4
-rw-r--r--sql-files/upgrade_svn3273.sql24
-rw-r--r--sql-files/upgrade_svn3746.sql2
-rw-r--r--sql-files/upgrade_svn4367.sql18
-rw-r--r--sql-files/upgrade_svn4941.sql10
-rw-r--r--sql-files/upgrade_svn5311.sql2
-rw-r--r--sql-files/upgrade_svn5322.sql2
-rw-r--r--sql-files/upgrade_svn5455.sql4
-rw-r--r--sql-files/upgrade_svn5607.sql2
-rw-r--r--sql-files/upgrade_svn5834.sql2
-rw-r--r--sql-files/upgrade_svn5902.sql28
-rw-r--r--sql-files/upgrade_svn6533.sql4
-rw-r--r--sql-files/upgrade_svn6868.sql2
-rw-r--r--sql-files/upgrade_svn7146.sql2
-rw-r--r--sql-files/upgrade_svn7580.sql4
-rw-r--r--sql-files/upgrade_svn7706.sql72
-rw-r--r--sql-files/upgrade_svn7768.sql14
-rw-r--r--sql-files/upgrade_svn8630.sql2
-rw-r--r--sql-files/upgrade_svn8675.sql2
-rw-r--r--sql-files/upgrade_svn8728.sql8
-rw-r--r--sql-files/upgrade_svn9050.sql12
-rw-r--r--sql-files/upgrade_svn9135.sql2
40 files changed, 1216 insertions, 1216 deletions
diff --git a/sql-files/convert_engine.sql b/sql-files/convert_engine.sql
index 98bdec409..9db50748e 100644
--- a/sql-files/convert_engine.sql
+++ b/sql-files/convert_engine.sql
@@ -1,22 +1,22 @@
---
--- eAthena Database Converter ( InnoDB -> MyISAM ) by Jaguar
---
-
-ALTER TABLE `sc_data` DROP FOREIGN KEY `scdata_ibfk_1`, DROP FOREIGN KEY `scdata_ibfk_2`;
-ALTER TABLE `guild` DROP FOREIGN KEY `guild_ibfk_1`;
-ALTER TABLE `guild_alliance` DROP FOREIGN KEY `guild_alliance_ibfk_1`, DROP FOREIGN KEY `guild_alliance_ibfk_2`;
-ALTER TABLE `guild_expulsion` DROP FOREIGN KEY `guild_expulsion_ibfk_1`;
-ALTER TABLE `guild_member` DROP FOREIGN KEY `guild_member_ibfk_1`, DROP FOREIGN KEY `guild_member_ibfk_2`;
-ALTER TABLE `guild_position` DROP FOREIGN KEY `guild_position_ibfk_1`;
-ALTER TABLE `guild_skill` DROP FOREIGN KEY `guild_skill_ibfk_1`;
-ALTER TABLE `guild_storage` DROP FOREIGN KEY `guild_storage_ibfk_1`;
-ALTER TABLE `sc_data` TYPE = MYISAM;
-ALTER TABLE `login` TYPE = MYISAM;
-ALTER TABLE `char` TYPE = MYISAM;
-ALTER TABLE `guild` TYPE = MYISAM;
-ALTER TABLE `guild_alliance` TYPE = MYISAM;
-ALTER TABLE `guild_expulsion` TYPE = MYISAM;
-ALTER TABLE `guild_member` TYPE = MYISAM;
-ALTER TABLE `guild_position` TYPE = MYISAM;
-ALTER TABLE `guild_skill` TYPE = MYISAM;
-ALTER TABLE `guild_storage` TYPE = MYISAM;
+--
+-- eAthena Database Converter ( InnoDB -> MyISAM ) by Jaguar
+--
+
+ALTER TABLE `sc_data` DROP FOREIGN KEY `scdata_ibfk_1`, DROP FOREIGN KEY `scdata_ibfk_2`;
+ALTER TABLE `guild` DROP FOREIGN KEY `guild_ibfk_1`;
+ALTER TABLE `guild_alliance` DROP FOREIGN KEY `guild_alliance_ibfk_1`, DROP FOREIGN KEY `guild_alliance_ibfk_2`;
+ALTER TABLE `guild_expulsion` DROP FOREIGN KEY `guild_expulsion_ibfk_1`;
+ALTER TABLE `guild_member` DROP FOREIGN KEY `guild_member_ibfk_1`, DROP FOREIGN KEY `guild_member_ibfk_2`;
+ALTER TABLE `guild_position` DROP FOREIGN KEY `guild_position_ibfk_1`;
+ALTER TABLE `guild_skill` DROP FOREIGN KEY `guild_skill_ibfk_1`;
+ALTER TABLE `guild_storage` DROP FOREIGN KEY `guild_storage_ibfk_1`;
+ALTER TABLE `sc_data` TYPE = MYISAM;
+ALTER TABLE `login` TYPE = MYISAM;
+ALTER TABLE `char` TYPE = MYISAM;
+ALTER TABLE `guild` TYPE = MYISAM;
+ALTER TABLE `guild_alliance` TYPE = MYISAM;
+ALTER TABLE `guild_expulsion` TYPE = MYISAM;
+ALTER TABLE `guild_member` TYPE = MYISAM;
+ALTER TABLE `guild_position` TYPE = MYISAM;
+ALTER TABLE `guild_skill` TYPE = MYISAM;
+ALTER TABLE `guild_storage` TYPE = MYISAM;
diff --git a/sql-files/convert_passwords.sql b/sql-files/convert_passwords.sql
index 6d2521e56..86e4c5b08 100644
--- a/sql-files/convert_passwords.sql
+++ b/sql-files/convert_passwords.sql
@@ -1,3 +1,3 @@
-# Convert passwords to MD5 hashes
-
-UPDATE `login` SET `user_pass`=MD5(`user_pass`);
+# Convert passwords to MD5 hashes
+
+UPDATE `login` SET `user_pass`=MD5(`user_pass`);
diff --git a/sql-files/item_db2.sql b/sql-files/item_db2.sql
index 8496bf0da..c7a15306b 100755
--- a/sql-files/item_db2.sql
+++ b/sql-files/item_db2.sql
@@ -1,42 +1,42 @@
-#
-# Table structure for table `item_db2`
-#
-
-DROP TABLE IF EXISTS `item_db2`;
-CREATE TABLE `item_db2` (
- `id` smallint(5) unsigned NOT NULL default '0',
- `name_english` varchar(50) NOT NULL default '',
- `name_japanese` varchar(50) NOT NULL default '',
- `type` tinyint(2) unsigned NOT NULL default '0',
- `price_buy` mediumint(10) unsigned default NULL,
- `price_sell` mediumint(10) unsigned default NULL,
- `weight` smallint(5) unsigned NOT NULL default '0',
- `attack` smallint(3) unsigned default NULL,
- `defence` tinyint(3) unsigned default NULL,
- `range` tinyint(2) unsigned default NULL,
- `slots` tinyint(2) unsigned default NULL,
- `equip_jobs` int(12) unsigned default NULL,
- `equip_upper` tinyint(8) unsigned default NULL,
- `equip_genders` tinyint(2) unsigned default NULL,
- `equip_locations` smallint(4) unsigned default NULL,
- `weapon_level` tinyint(2) unsigned default NULL,
- `equip_level` tinyint(3) unsigned default NULL,
- `refineable` tinyint(1) unsigned default NULL,
- `view` smallint(3) unsigned default NULL,
- `script` text,
- `equip_script` text,
- `unequip_script` text,
- PRIMARY KEY (`id`)
-) TYPE=MyISAM;
-
-# // Items Additional Database - Custom Items go here
-# //
-# // Structure of Database:
-# // ID,Name,Name,Type,Price,Sell,Weight,ATK,DEF,Range,Slot,Job,Upper,Gender,Loc,wLV,eLV,Refineable,View,{ Script },{ OnEquip_Script },{ OnUnequip_Script }
-# //
-# // THQ Quest Items
-# //=============================================================
-# REPLACE INTO `item_db2` VALUES (7950,'THG_Membership','THG Membership',3,NULL,10,10,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL);
-# REPLACE INTO `item_db2` VALUES (7951,'Token_Bag','Token Bag',3,NULL,10,10,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL);
-# REPLACE INTO `item_db2` VALUES (1998,'Jeramiah\'s_Jur','Jeramiah\'s Jur',3,NULL,10,10,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL);
-# REPLACE INTO `item_db2` VALUES (1999,'Zed\'s_Staff','Zed\'s Staff',3,NULL,10,10,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL);
+#
+# Table structure for table `item_db2`
+#
+
+DROP TABLE IF EXISTS `item_db2`;
+CREATE TABLE `item_db2` (
+ `id` smallint(5) unsigned NOT NULL default '0',
+ `name_english` varchar(50) NOT NULL default '',
+ `name_japanese` varchar(50) NOT NULL default '',
+ `type` tinyint(2) unsigned NOT NULL default '0',
+ `price_buy` mediumint(10) unsigned default NULL,
+ `price_sell` mediumint(10) unsigned default NULL,
+ `weight` smallint(5) unsigned NOT NULL default '0',
+ `attack` smallint(3) unsigned default NULL,
+ `defence` tinyint(3) unsigned default NULL,
+ `range` tinyint(2) unsigned default NULL,
+ `slots` tinyint(2) unsigned default NULL,
+ `equip_jobs` int(12) unsigned default NULL,
+ `equip_upper` tinyint(8) unsigned default NULL,
+ `equip_genders` tinyint(2) unsigned default NULL,
+ `equip_locations` smallint(4) unsigned default NULL,
+ `weapon_level` tinyint(2) unsigned default NULL,
+ `equip_level` tinyint(3) unsigned default NULL,
+ `refineable` tinyint(1) unsigned default NULL,
+ `view` smallint(3) unsigned default NULL,
+ `script` text,
+ `equip_script` text,
+ `unequip_script` text,
+ PRIMARY KEY (`id`)
+) TYPE=MyISAM;
+
+# // Items Additional Database - Custom Items go here
+# //
+# // Structure of Database:
+# // ID,Name,Name,Type,Price,Sell,Weight,ATK,DEF,Range,Slot,Job,Upper,Gender,Loc,wLV,eLV,Refineable,View,{ Script },{ OnEquip_Script },{ OnUnequip_Script }
+# //
+# // THQ Quest Items
+# //=============================================================
+# REPLACE INTO `item_db2` VALUES (7950,'THG_Membership','THG Membership',3,NULL,10,10,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL);
+# REPLACE INTO `item_db2` VALUES (7951,'Token_Bag','Token Bag',3,NULL,10,10,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL);
+# REPLACE INTO `item_db2` VALUES (1998,'Jeramiah\'s_Jur','Jeramiah\'s Jur',3,NULL,10,10,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL);
+# REPLACE INTO `item_db2` VALUES (1999,'Zed\'s_Staff','Zed\'s Staff',3,NULL,10,10,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL);
diff --git a/sql-files/logs.sql b/sql-files/logs.sql
index 7a27f8a6a..597e9e0ed 100644
--- a/sql-files/logs.sql
+++ b/sql-files/logs.sql
@@ -1,112 +1,112 @@
-#Pick_Log types (M)onsters Drop, (P)layers Drop/Take, Mobs Drop (L)oot Drop/Take,
-# Players (T)rade Give/Take, Players (V)ending Sell/Take, (S)hop Sell/Take, (N)PC Give/Take,
-# (C)onsumable Items, (A)dministrators Create/Delete
-
-#Database: log
-#Table: picklog
-CREATE TABLE `picklog` (
- `id` int(11) NOT NULL auto_increment,
- `time` datetime NOT NULL default '0000-00-00 00:00:00',
- `char_id` int(11) NOT NULL default '0',
- `type` set('M','P','L','T','V','S','N','C','A') NOT NULL default 'P',
- `nameid` int(11) NOT NULL default '0',
- `amount` int(11) NOT NULL default '1',
- `refine` tinyint(3) unsigned NOT NULL default '0',
- `card0` int(11) NOT NULL default '0',
- `card1` int(11) NOT NULL default '0',
- `card2` int(11) NOT NULL default '0',
- `card3` int(11) NOT NULL default '0',
- `map` varchar(20) NOT NULL default 'prontera.gat',
- PRIMARY KEY (`id`),
- INDEX (`type`)
-) TYPE=MyISAM AUTO_INCREMENT=1 ;
-
-#ZenyLog types (M)onsters,(T)rade,(V)ending Sell/Buy,(S)hop Sell/Buy,(N)PC Change amount,(A)dministrators
-#Database: log
-#Table: zenylog
-CREATE TABLE `zenylog` (
- `id` int(11) NOT NULL auto_increment,
- `time` datetime NOT NULL default '0000-00-00 00:00:00',
- `char_id` int(11) NOT NULL default '0',
- `src_id` int(11) NOT NULL default '0',
- `type` set('M','T','V','S','N','A') NOT NULL default 'S',
- `amount` int(11) NOT NULL default '0',
- `map` varchar(20) NOT NULL default 'prontera.gat',
- PRIMARY KEY (`id`),
- INDEX (`type`)
-) TYPE=MyISAM AUTO_INCREMENT=1 ;
-
-#Database: log
-#Table: branchlog
-CREATE TABLE `branchlog` (
- `branch_id` mediumint(9) unsigned NOT NULL auto_increment,
- `branch_date` datetime NOT NULL default '0000-00-00 00:00:00',
- `account_id` int(11) NOT NULL default '0',
- `char_id` int(11) NOT NULL default '0',
- `char_name` varchar(30) NOT NULL default '',
- `map` varchar(20) NOT NULL default 'prontera.gat',
- PRIMARY KEY (`branch_id`),
- INDEX (`account_id`),
- INDEX (`char_id`)
-) TYPE=MyISAM AUTO_INCREMENT=1 ;
-
-#Database: log
-#Table: mvplog
-CREATE TABLE `mvplog` (
- `mvp_id` mediumint(9) unsigned NOT NULL auto_increment,
- `mvp_date` datetime NOT NULL default '0000-00-00 00:00:00',
- `kill_char_id` int(11) NOT NULL default '0',
- `monster_id` smallint(6) NOT NULL default '0',
- `prize` int(11) NOT NULL default '0',
- `mvpexp` mediumint(9) NOT NULL default '0',
- `map` varchar(20) NOT NULL default 'prontera.gat',
- PRIMARY KEY (`mvp_id`)
-) TYPE=MyISAM AUTO_INCREMENT=1 ;
-
-#Database: log
-#Table: atcommandlog
-CREATE TABLE `atcommandlog` (
- `atcommand_id` mediumint(9) unsigned NOT NULL auto_increment,
- `atcommand_date` datetime NOT NULL default '0000-00-00 00:00:00',
- `account_id` int(11) unsigned NOT NULL default '0',
- `char_id` int(11) unsigned NOT NULL default '0',
- `char_name` varchar(30) NOT NULL default '',
- `map` varchar(20) NOT NULL default 'prontera.gat',
- `command` varchar(50) NOT NULL default '',
- PRIMARY KEY (`atcommand_id`),
- INDEX (`account_id`),
- INDEX (`char_id`)
-) TYPE=MyISAM AUTO_INCREMENT=1 ;
-
-#Database: log
-#Table: npclog
-CREATE TABLE `npclog` (
- `npc_id` mediumint(9) unsigned NOT NULL auto_increment,
- `npc_date` datetime NOT NULL default '0000-00-00 00:00:00',
- `account_id` int(11) unsigned NOT NULL default '0',
- `char_id` int(11) unsigned NOT NULL default '0',
- `char_name` varchar(30) NOT NULL default '',
- `map` varchar(20) NOT NULL default 'prontera.gat',
- `mes` varchar(255) NOT NULL default '',
- PRIMARY KEY (`npc_id`),
- INDEX (`account_id`),
- INDEX (`char_id`)
-) TYPE=MyISAM AUTO_INCREMENT=1 ;
-
-#ChatLOG
-CREATE TABLE `chatlog` (
- `id` bigint(20) NOT NULL auto_increment,
- `time` datetime NOT NULL default '0000-00-00 00:00:00',
- `type` set('W','P','G') NOT NULL default 'W',
- `type_id` int(11) NOT NULL default '0',
- `src_charid` int(11) NOT NULL default '0',
- `src_accountid` int(11) NOT NULL default '0',
- `src_map` varchar(17) NOT NULL default 'prontera.gat',
- `src_map_x` smallint(4) NOT NULL default '0',
- `src_map_y` smallint(4) NOT NULL default '0',
- `dst_charname` varchar(25) NOT NULL default '',
- `message` varchar(150) NOT NULL default '',
- PRIMARY KEY (`id`),
- INDEX (`src_accountid`),
- INDEX (`src_charid`)
-) TYPE=MyISAM AUTO_INCREMENT=1 ;
+#Pick_Log types (M)onsters Drop, (P)layers Drop/Take, Mobs Drop (L)oot Drop/Take,
+# Players (T)rade Give/Take, Players (V)ending Sell/Take, (S)hop Sell/Take, (N)PC Give/Take,
+# (C)onsumable Items, (A)dministrators Create/Delete
+
+#Database: log
+#Table: picklog
+CREATE TABLE `picklog` (
+ `id` int(11) NOT NULL auto_increment,
+ `time` datetime NOT NULL default '0000-00-00 00:00:00',
+ `char_id` int(11) NOT NULL default '0',
+ `type` set('M','P','L','T','V','S','N','C','A') NOT NULL default 'P',
+ `nameid` int(11) NOT NULL default '0',
+ `amount` int(11) NOT NULL default '1',
+ `refine` tinyint(3) unsigned NOT NULL default '0',
+ `card0` int(11) NOT NULL default '0',
+ `card1` int(11) NOT NULL default '0',
+ `card2` int(11) NOT NULL default '0',
+ `card3` int(11) NOT NULL default '0',
+ `map` varchar(20) NOT NULL default 'prontera.gat',
+ PRIMARY KEY (`id`),
+ INDEX (`type`)
+) TYPE=MyISAM AUTO_INCREMENT=1 ;
+
+#ZenyLog types (M)onsters,(T)rade,(V)ending Sell/Buy,(S)hop Sell/Buy,(N)PC Change amount,(A)dministrators
+#Database: log
+#Table: zenylog
+CREATE TABLE `zenylog` (
+ `id` int(11) NOT NULL auto_increment,
+ `time` datetime NOT NULL default '0000-00-00 00:00:00',
+ `char_id` int(11) NOT NULL default '0',
+ `src_id` int(11) NOT NULL default '0',
+ `type` set('M','T','V','S','N','A') NOT NULL default 'S',
+ `amount` int(11) NOT NULL default '0',
+ `map` varchar(20) NOT NULL default 'prontera.gat',
+ PRIMARY KEY (`id`),
+ INDEX (`type`)
+) TYPE=MyISAM AUTO_INCREMENT=1 ;
+
+#Database: log
+#Table: branchlog
+CREATE TABLE `branchlog` (
+ `branch_id` mediumint(9) unsigned NOT NULL auto_increment,
+ `branch_date` datetime NOT NULL default '0000-00-00 00:00:00',
+ `account_id` int(11) NOT NULL default '0',
+ `char_id` int(11) NOT NULL default '0',
+ `char_name` varchar(30) NOT NULL default '',
+ `map` varchar(20) NOT NULL default 'prontera.gat',
+ PRIMARY KEY (`branch_id`),
+ INDEX (`account_id`),
+ INDEX (`char_id`)
+) TYPE=MyISAM AUTO_INCREMENT=1 ;
+
+#Database: log
+#Table: mvplog
+CREATE TABLE `mvplog` (
+ `mvp_id` mediumint(9) unsigned NOT NULL auto_increment,
+ `mvp_date` datetime NOT NULL default '0000-00-00 00:00:00',
+ `kill_char_id` int(11) NOT NULL default '0',
+ `monster_id` smallint(6) NOT NULL default '0',
+ `prize` int(11) NOT NULL default '0',
+ `mvpexp` mediumint(9) NOT NULL default '0',
+ `map` varchar(20) NOT NULL default 'prontera.gat',
+ PRIMARY KEY (`mvp_id`)
+) TYPE=MyISAM AUTO_INCREMENT=1 ;
+
+#Database: log
+#Table: atcommandlog
+CREATE TABLE `atcommandlog` (
+ `atcommand_id` mediumint(9) unsigned NOT NULL auto_increment,
+ `atcommand_date` datetime NOT NULL default '0000-00-00 00:00:00',
+ `account_id` int(11) unsigned NOT NULL default '0',
+ `char_id` int(11) unsigned NOT NULL default '0',
+ `char_name` varchar(30) NOT NULL default '',
+ `map` varchar(20) NOT NULL default 'prontera.gat',
+ `command` varchar(50) NOT NULL default '',
+ PRIMARY KEY (`atcommand_id`),
+ INDEX (`account_id`),
+ INDEX (`char_id`)
+) TYPE=MyISAM AUTO_INCREMENT=1 ;
+
+#Database: log
+#Table: npclog
+CREATE TABLE `npclog` (
+ `npc_id` mediumint(9) unsigned NOT NULL auto_increment,
+ `npc_date` datetime NOT NULL default '0000-00-00 00:00:00',
+ `account_id` int(11) unsigned NOT NULL default '0',
+ `char_id` int(11) unsigned NOT NULL default '0',
+ `char_name` varchar(30) NOT NULL default '',
+ `map` varchar(20) NOT NULL default 'prontera.gat',
+ `mes` varchar(255) NOT NULL default '',
+ PRIMARY KEY (`npc_id`),
+ INDEX (`account_id`),
+ INDEX (`char_id`)
+) TYPE=MyISAM AUTO_INCREMENT=1 ;
+
+#ChatLOG
+CREATE TABLE `chatlog` (
+ `id` bigint(20) NOT NULL auto_increment,
+ `time` datetime NOT NULL default '0000-00-00 00:00:00',
+ `type` set('W','P','G') NOT NULL default 'W',
+ `type_id` int(11) NOT NULL default '0',
+ `src_charid` int(11) NOT NULL default '0',
+ `src_accountid` int(11) NOT NULL default '0',
+ `src_map` varchar(17) NOT NULL default 'prontera.gat',
+ `src_map_x` smallint(4) NOT NULL default '0',
+ `src_map_y` smallint(4) NOT NULL default '0',
+ `dst_charname` varchar(25) NOT NULL default '',
+ `message` varchar(150) NOT NULL default '',
+ PRIMARY KEY (`id`),
+ INDEX (`src_accountid`),
+ INDEX (`src_charid`)
+) TYPE=MyISAM AUTO_INCREMENT=1 ;
diff --git a/sql-files/mail.sql b/sql-files/mail.sql
index 8ec74dcdd..62cc9d65d 100644
--- a/sql-files/mail.sql
+++ b/sql-files/mail.sql
@@ -1,12 +1,12 @@
-CREATE TABLE `mail` (
- `message_id` int(11) NOT NULL auto_increment,
- `to_account_id` int(11) NOT NULL default '0',
- `to_char_name` varchar(24) NOT NULL default '',
- `from_account_id` int(11) NOT NULL default '0',
- `from_char_name` varchar(24) NOT NULL default '',
- `message` varchar(80) NOT NULL default '',
- `read_flag` tinyint(1) NOT NULL default '0',
- `priority` tinyint(1) NOT NULL default '0',
- `check_flag` tinyint(1) NOT NULL default '0',
- PRIMARY KEY (`message_id`)
-) TYPE=MyISAM;
+CREATE TABLE `mail` (
+ `message_id` int(11) NOT NULL auto_increment,
+ `to_account_id` int(11) NOT NULL default '0',
+ `to_char_name` varchar(24) NOT NULL default '',
+ `from_account_id` int(11) NOT NULL default '0',
+ `from_char_name` varchar(24) NOT NULL default '',
+ `message` varchar(80) NOT NULL default '',
+ `read_flag` tinyint(1) NOT NULL default '0',
+ `priority` tinyint(1) NOT NULL default '0',
+ `check_flag` tinyint(1) NOT NULL default '0',
+ PRIMARY KEY (`message_id`)
+) TYPE=MyISAM;
diff --git a/sql-files/main.sql b/sql-files/main.sql
index 155542119..c7c45d3c5 100644
--- a/sql-files/main.sql
+++ b/sql-files/main.sql
@@ -1,578 +1,578 @@
--- MySQL dump 9.11
--- Server version 4.0.24
-
---
--- Table structure for table `cart_inventory`
---
-
-DROP TABLE IF EXISTS `cart_inventory`;
-CREATE TABLE `cart_inventory` (
- `id` int(11) NOT NULL auto_increment,
- `char_id` int(11) NOT NULL default '0',
- `nameid` int(11) NOT NULL default '0',
- `amount` int(11) NOT NULL default '0',
- `equip` mediumint(8) unsigned NOT NULL default '0',
- `identify` smallint(6) NOT NULL default '0',
- `refine` tinyint(3) unsigned NOT NULL default '0',
- `attribute` tinyint(4) NOT NULL default '0',
- `card0` int(11) NOT NULL default '0',
- `card1` int(11) NOT NULL default '0',
- `card2` int(11) NOT NULL default '0',
- `card3` int(11) NOT NULL default '0',
- PRIMARY KEY (`id`),
- KEY `char_id` (`char_id`)
-) TYPE=MyISAM;
-
---
--- Table structure for table `char`
---
-
-DROP TABLE IF EXISTS `char`;
-CREATE TABLE `char` (
- `char_id` int(11) unsigned NOT NULL auto_increment,
- `account_id` int(11) unsigned NOT NULL default '0',
- `char_num` tinyint(1) NOT NULL default '0',
- `name` varchar(30) NOT NULL default '',
- `class` smallint(6) unsigned NOT NULL default '0',
- `base_level` smallint(6) unsigned NOT NULL default '1',
- `job_level` smallint(6) unsigned NOT NULL default '1',
- `base_exp` bigint(20) unsigned NOT NULL default '0',
- `job_exp` bigint(20) unsigned NOT NULL default '0',
- `zeny` int(11) unsigned NOT NULL default '0',
- `str` smallint(4) unsigned NOT NULL default '0',
- `agi` smallint(4) unsigned NOT NULL default '0',
- `vit` smallint(4) unsigned NOT NULL default '0',
- `int` smallint(4) unsigned NOT NULL default '0',
- `dex` smallint(4) unsigned NOT NULL default '0',
- `luk` smallint(4) unsigned NOT NULL default '0',
- `max_hp` mediumint(8) unsigned NOT NULL default '0',
- `hp` mediumint(8) unsigned NOT NULL default '0',
- `max_sp` mediumint(6) unsigned NOT NULL default '0',
- `sp` mediumint(6) unsigned NOT NULL default '0',
- `status_point` smallint(4) unsigned NOT NULL default '0',
- `skill_point` smallint(4) unsigned NOT NULL default '0',
- `option` int(11) NOT NULL default '0',
- `karma` tinyint(3) NOT NULL default '0',
- `manner` tinyint(3) NOT NULL default '0',
- `party_id` int(11) unsigned NOT NULL default '0',
- `guild_id` int(11) unsigned NOT NULL default '0',
- `pet_id` int(11) unsigned NOT NULL default '0',
- `homun_id` int(11) unsigned NOT NULL default '0',
- `hair` tinyint(4) unsigned NOT NULL default '0',
- `hair_color` smallint(5) unsigned NOT NULL default '0',
- `clothes_color` smallint(5) unsigned NOT NULL default '0',
- `weapon` smallint(6) unsigned NOT NULL default '1',
- `shield` smallint(6) unsigned NOT NULL default '0',
- `head_top` smallint(6) unsigned NOT NULL default '0',
- `head_mid` smallint(6) unsigned NOT NULL default '0',
- `head_bottom` smallint(6) unsigned NOT NULL default '0',
- `last_map` varchar(20) NOT NULL default 'prontera.gat',
- `last_x` smallint(4) unsigned NOT NULL default '53',
- `last_y` smallint(4) unsigned NOT NULL default '111',
- `save_map` varchar(20) NOT NULL default 'prontera.gat',
- `save_x` smallint(4) unsigned NOT NULL default '53',
- `save_y` smallint(4) unsigned NOT NULL default '111',
- `partner_id` int(11) unsigned NOT NULL default '0',
- `online` tinyint(2) NOT NULL default '0',
- `father` int(11) unsigned NOT NULL default '0',
- `mother` int(11) unsigned NOT NULL default '0',
- `child` int(11) unsigned NOT NULL default '0',
- `fame` int(11) unsigned NOT NULL default '0',
- PRIMARY KEY (`char_id`),
- KEY `account_id` (`account_id`),
- KEY `party_id` (`party_id`),
- KEY `guild_id` (`guild_id`),
- KEY `name` (`name`),
- KEY `online` (`online`)
-) TYPE=MyISAM AUTO_INCREMENT=150000;
-
---
--- Table structure for table `charlog`
---
-
-DROP TABLE IF EXISTS `charlog`;
-CREATE TABLE `charlog` (
- `time` datetime NOT NULL default '0000-00-00 00:00:00',
- `char_msg` varchar(255) NOT NULL default 'char select',
- `account_id` int(11) NOT NULL default '0',
- `char_num` tinyint(4) NOT NULL default '0',
- `name` varchar(255) NOT NULL default '',
- `str` int(11) unsigned NOT NULL default '0',
- `agi` int(11) unsigned NOT NULL default '0',
- `vit` int(11) unsigned NOT NULL default '0',
- `int` int(11) unsigned NOT NULL default '0',
- `dex` int(11) unsigned NOT NULL default '0',
- `luk` int(11) unsigned NOT NULL default '0',
- `hair` tinyint(4) NOT NULL default '0',
- `hair_color` int(11) NOT NULL default '0'
-) TYPE=MyISAM;
-
---
--- Table structure for table `friends`
---
-
-DROP TABLE IF EXISTS `friends`;
-CREATE TABLE `friends` (
- `char_id` int(11) NOT NULL default '0',
- `friend_account` int(11) NOT NULL default '0',
- `friend_id` int(11) NOT NULL default '0',
- KEY `char_id` (`char_id`)
-) TYPE=MyISAM;
-
---
--- Table structure for table `global_reg_value`
---
-
-DROP TABLE IF EXISTS `global_reg_value`;
-CREATE TABLE `global_reg_value` (
- `char_id` int(11) unsigned NOT NULL default '0',
- `str` varchar(255) NOT NULL default '',
- `value` varchar(255) NOT NULL default '0',
- `type` int(11) NOT NULL default '3',
- `account_id` int(11) unsigned NOT NULL default '0',
- PRIMARY KEY (`char_id`,`str`,`account_id`),
- KEY `account_id` (`account_id`),
- KEY `char_id` (`char_id`)
-) TYPE=MyISAM;
-
---
--- Table structure for table `guild`
---
-
-DROP TABLE IF EXISTS `guild`;
-CREATE TABLE `guild` (
- `guild_id` int(11) unsigned NOT NULL auto_increment,
- `name` varchar(24) NOT NULL default '',
- `char_id` int(11) unsigned NOT NULL default '0',
- `master` varchar(24) NOT NULL default '',
- `guild_lv` tinyint(6) unsigned NOT NULL default '0',
- `connect_member` tinyint(6) unsigned NOT NULL default '0',
- `max_member` tinyint(6) unsigned NOT NULL default '0',
- `average_lv` smallint(6) unsigned NOT NULL default '1',
- `exp` int(11) unsigned NOT NULL default '0',
- `next_exp` int(11) unsigned NOT NULL default '0',
- `skill_point` tinyint(11) unsigned NOT NULL default '0',
- `mes1` varchar(60) NOT NULL default '',
- `mes2` varchar(120) NOT NULL default '',
- `emblem_len` int(11) unsigned NOT NULL default '0',
- `emblem_id` int(11) unsigned NOT NULL default '0',
- `emblem_data` blob,
- PRIMARY KEY (`guild_id`,`char_id`),
- UNIQUE KEY `guild_id` (`guild_id`),
- KEY `char_id` (`char_id`)
-) TYPE=MyISAM;
-
---
--- Table structure for table `guild_alliance`
---
-
-DROP TABLE IF EXISTS `guild_alliance`;
-CREATE TABLE `guild_alliance` (
- `guild_id` int(11) unsigned NOT NULL default '0',
- `opposition` int(11) unsigned NOT NULL default '0',
- `alliance_id` int(11) unsigned NOT NULL default '0',
- `name` varchar(24) NOT NULL default '',
- PRIMARY KEY (`guild_id`,`alliance_id`),
- KEY `alliance_id` (`alliance_id`)
-) TYPE=MyISAM;
-
---
--- Table structure for table `guild_castle`
---
-
-DROP TABLE IF EXISTS `guild_castle`;
-CREATE TABLE `guild_castle` (
- `castle_id` int(11) unsigned NOT NULL default '0',
- `guild_id` int(11) unsigned NOT NULL default '0',
- `economy` int(11) unsigned NOT NULL default '0',
- `defense` int(11) unsigned NOT NULL default '0',
- `triggerE` int(11) unsigned NOT NULL default '0',
- `triggerD` int(11) unsigned NOT NULL default '0',
- `nextTime` int(11) unsigned NOT NULL default '0',
- `payTime` int(11) unsigned NOT NULL default '0',
- `createTime` int(11) unsigned NOT NULL default '0',
- `visibleC` int(11) unsigned NOT NULL default '0',
- `visibleG0` int(11) unsigned NOT NULL default '0',
- `visibleG1` int(11) unsigned NOT NULL default '0',
- `visibleG2` int(11) unsigned NOT NULL default '0',
- `visibleG3` int(11) unsigned NOT NULL default '0',
- `visibleG4` int(11) unsigned NOT NULL default '0',
- `visibleG5` int(11) unsigned NOT NULL default '0',
- `visibleG6` int(11) unsigned NOT NULL default '0',
- `visibleG7` int(11) unsigned NOT NULL default '0',
- `gHP0` int(11) unsigned NOT NULL default '0',
- `ghP1` int(11) unsigned NOT NULL default '0',
- `gHP2` int(11) unsigned NOT NULL default '0',
- `gHP3` int(11) unsigned NOT NULL default '0',
- `gHP4` int(11) unsigned NOT NULL default '0',
- `gHP5` int(11) unsigned NOT NULL default '0',
- `gHP6` int(11) unsigned NOT NULL default '0',
- `gHP7` int(11) unsigned NOT NULL default '0',
- PRIMARY KEY (`castle_id`),
- KEY `guild_id` (`guild_id`)
-) TYPE=MyISAM;
-
---
--- Table structure for table `guild_expulsion`
---
-
-DROP TABLE IF EXISTS `guild_expulsion`;
-CREATE TABLE `guild_expulsion` (
- `guild_id` int(11) unsigned NOT NULL default '0',
- `name` varchar(24) NOT NULL default '',
- `mes` varchar(40) NOT NULL default '',
- `acc` varchar(40) NOT NULL default '',
- `account_id` int(11) unsigned NOT NULL default '0',
- `rsv1` int(11) unsigned NOT NULL default '0',
- `rsv2` int(11) unsigned NOT NULL default '0',
- `rsv3` int(11) unsigned NOT NULL default '0',
- PRIMARY KEY (`guild_id`,`name`)
-) TYPE=MyISAM;
-
---
--- Table structure for table `guild_member`
---
-
-DROP TABLE IF EXISTS `guild_member`;
-CREATE TABLE `guild_member` (
- `guild_id` int(11) unsigned NOT NULL default '0',
- `account_id` int(11) unsigned NOT NULL default '0',
- `char_id` int(11) unsigned NOT NULL default '0',
- `hair` tinyint(6) unsigned NOT NULL default '0',
- `hair_color` smallint(6) unsigned NOT NULL default '0',
- `gender` tinyint(6) unsigned NOT NULL default '0',
- `class` smallint(6) unsigned NOT NULL default '0',
- `lv` smallint(6) unsigned NOT NULL default '0',
- `exp` bigint(20) unsigned NOT NULL default '0',
- `exp_payper` tinyint(11) unsigned NOT NULL default '0',
- `online` tinyint(4) unsigned NOT NULL default '0',
- `position` tinyint(6) unsigned NOT NULL default '0',
- `rsv1` int(11) unsigned NOT NULL default '0',
- `rsv2` int(11) unsigned NOT NULL default '0',
- `name` varchar(24) NOT NULL default '',
- PRIMARY KEY (`guild_id`,`char_id`),
- KEY `char_id` (`char_id`)
-) TYPE=MyISAM;
-
---
--- Table structure for table `guild_position`
---
-
-DROP TABLE IF EXISTS `guild_position`;
-CREATE TABLE `guild_position` (
- `guild_id` int(9) unsigned NOT NULL default '0',
- `position` tinyint(6) unsigned NOT NULL default '0',
- `name` varchar(24) NOT NULL default '',
- `mode` tinyint(11) unsigned NOT NULL default '0',
- `exp_mode` tinyint(11) unsigned NOT NULL default '0',
- PRIMARY KEY (`guild_id`,`position`),
- KEY `guild_id` (`guild_id`)
-) TYPE=MyISAM;
-
---
--- Table structure for table `guild_skill`
---
-
-DROP TABLE IF EXISTS `guild_skill`;
-CREATE TABLE `guild_skill` (
- `guild_id` int(11) unsigned NOT NULL default '0',
- `id` smallint(11) unsigned NOT NULL default '0',
- `lv` tinyint(11) unsigned NOT NULL default '0',
- PRIMARY KEY (`guild_id`,`id`)
-) TYPE=MyISAM;
-
---
--- Table structure for table `guild_storage`
---
-
-DROP TABLE IF EXISTS `guild_storage`;
-CREATE TABLE `guild_storage` (
- `id` int(10) unsigned NOT NULL auto_increment,
- `guild_id` int(11) unsigned NOT NULL default '0',
- `nameid` int(11) unsigned NOT NULL default '0',
- `amount` int(11) unsigned NOT NULL default '0',
- `equip` mediumint(8) unsigned NOT NULL default '0',
- `identify` smallint(6) unsigned NOT NULL default '0',
- `refine` tinyint(3) unsigned NOT NULL default '0',
- `attribute` tinyint(4) unsigned NOT NULL default '0',
- `card0` smallint(11) NOT NULL default '0',
- `card1` smallint(11) NOT NULL default '0',
- `card2` smallint(11) NOT NULL default '0',
- `card3` smallint(11) NOT NULL default '0',
- PRIMARY KEY (`id`),
- KEY `guild_id` (`guild_id`)
-) TYPE=MyISAM;
-
---
--- Table structure for table `homunculus`
---
-
-DROP TABLE IF EXISTS `homunculus`;
-CREATE TABLE `homunculus` (
- `homun_id` int(11) NOT NULL auto_increment,
- `char_id` int(11) NOT NULL,
- `class` mediumint(9) unsigned NOT NULL default '0',
- `name` varchar(24) NOT NULL default '',
- `level` smallint(4) NOT NULL default '0',
- `exp` int(12) NOT NULL default '0',
- `intimacy` int(12) NOT NULL default '0',
- `hunger` smallint(4) NOT NULL default '0',
- `str` smallint(4) unsigned NOT NULL default '0',
- `agi` smallint(4) unsigned NOT NULL default '0',
- `vit` smallint(4) unsigned NOT NULL default '0',
- `int` smallint(4) unsigned NOT NULL default '0',
- `dex` smallint(4) unsigned NOT NULL default '0',
- `luk` smallint(4) unsigned NOT NULL default '0',
- `hp` int(12) NOT NULL default '1',
- `max_hp` int(12) NOT NULL default '1',
- `sp` int(12) NOT NULL default '1',
- `max_sp` int(12) NOT NULL default '1',
- `skill_point` smallint(4) unsigned NOT NULL default '0',
- `alive` tinyint(2) NOT NULL default '1',
- `rename_flag` tinyint(2) NOT NULL default '0',
- `vaporize` tinyint(2) NOT NULL default '0',
- PRIMARY KEY (`homun_id`)
-) TYPE=MyISAM;
-
---
--- Table structure for table `interlog`
---
-
-DROP TABLE IF EXISTS `interlog`;
-CREATE TABLE `interlog` (
- `time` datetime NOT NULL default '0000-00-00 00:00:00',
- `log` varchar(255) NOT NULL default ''
-) TYPE=MyISAM;
-
---
--- Table structure for table `inventory`
---
-
-DROP TABLE IF EXISTS `inventory`;
-CREATE TABLE `inventory` (
- `id` int(11) unsigned NOT NULL auto_increment,
- `char_id` int(11) unsigned NOT NULL default '0',
- `nameid` int(11) unsigned NOT NULL default '0',
- `amount` int(11) unsigned NOT NULL default '0',
- `equip` mediumint(8) unsigned NOT NULL default '0',
- `identify` smallint(6) NOT NULL default '0',
- `refine` tinyint(3) unsigned NOT NULL default '0',
- `attribute` tinyint(4) unsigned NOT NULL default '0',
- `card0` smallint(11) NOT NULL default '0',
- `card1` smallint(11) NOT NULL default '0',
- `card2` smallint(11) NOT NULL default '0',
- `card3` smallint(11) NOT NULL default '0',
- PRIMARY KEY (`id`),
- KEY `char_id` (`char_id`)
-) TYPE=MyISAM;
-
---
--- Table structure for table `ipbanlist`
---
-
-DROP TABLE IF EXISTS `ipbanlist`;
-CREATE TABLE `ipbanlist` (
- `list` varchar(255) NOT NULL default '',
- `btime` datetime NOT NULL default '0000-00-00 00:00:00',
- `rtime` datetime NOT NULL default '0000-00-00 00:00:00',
- `reason` varchar(255) NOT NULL default '',
- KEY (`list`)
-) TYPE=MyISAM;
-
---
--- Table structure for table `login`
---
-
-DROP TABLE IF EXISTS `login`;
-CREATE TABLE `login` (
- `account_id` int(11) unsigned NOT NULL auto_increment,
- `userid` varchar(255) NOT NULL default '',
- `user_pass` varchar(32) NOT NULL default '',
- `lastlogin` datetime NOT NULL default '0000-00-00 00:00:00',
- `sex` char(1) NOT NULL default 'M',
- `logincount` mediumint(9) unsigned NOT NULL default '0',
- `email` varchar(60) NOT NULL default '',
- `level` tinyint(3) NOT NULL default '0',
- `error_message` smallint(11) unsigned NOT NULL default '0',
- `connect_until` int(11) unsigned NOT NULL default '0',
- `last_ip` varchar(100) NOT NULL default '',
- `memo` smallint(11) unsigned NOT NULL default '0',
- `ban_until` int(11) unsigned NOT NULL default '0',
- `state` int(11) unsigned NOT NULL default '0',
- PRIMARY KEY (`account_id`),
- KEY `name` (`userid`)
-) TYPE=MyISAM AUTO_INCREMENT=2000000;
-
--- added standard accounts for servers, VERY INSECURE!!!
--- inserted into the table called login which is above
-
-INSERT INTO `login` (`account_id`, `userid`, `user_pass`, `sex`, `email`) VALUES ('1', 's1', 'p1', 'S','athena@athena.com');
-
---
--- Table structure for table `mapreg`
---
-
-DROP TABLE IF EXISTS `mapreg`;
-CREATE TABLE `mapreg` (
- `varname` varchar(32) NOT NULL,
- `index` int(11) unsigned NOT NULL default '0',
- `value` varchar(255) NOT NULL,
- KEY `varname` (`varname`),
- KEY `index` (`index`)
-) TYPE=MyISAM;
-
---
--- Table structure for table `sc_data`
---
-
-DROP TABLE IF EXISTS `sc_data`;
-CREATE TABLE `sc_data` (
- `account_id` int(11) unsigned NOT NULL,
- `char_id` int(11) unsigned NOT NULL,
- `type` smallint(11) unsigned NOT NULL,
- `tick` int(11) NOT NULL,
- `val1` int(11) NOT NULL default '0',
- `val2` int(11) NOT NULL default '0',
- `val3` int(11) NOT NULL default '0',
- `val4` int(11) NOT NULL default '0',
- KEY (`account_id`),
- KEY (`char_id`)
-) TYPE=MyISAM;
-
---
--- Table structure for table `loginlog`
---
-
-DROP TABLE IF EXISTS `loginlog`;
-CREATE TABLE `loginlog` (
- `time` datetime NOT NULL default '0000-00-00 00:00:00',
- `ip` int(10) unsigned NOT NULL default '0',
- `user` varchar(32) NOT NULL default '',
- `rcode` tinyint(4) NOT NULL default '0',
- `log` varchar(255) NOT NULL default '',
- INDEX (`ip`)
-) TYPE=MyISAM;
-
---
--- Table structure for table `memo`
---
-
-DROP TABLE IF EXISTS `memo`;
-CREATE TABLE `memo` (
- `memo_id` int(11) unsigned NOT NULL auto_increment,
- `char_id` int(11) unsigned NOT NULL default '0',
- `map` varchar(255) NOT NULL default '',
- `x` smallint(9) unsigned NOT NULL default '0',
- `y` smallint(9) unsigned NOT NULL default '0',
- PRIMARY KEY (`memo_id`),
- KEY `char_id` (`char_id`)
-) TYPE=MyISAM;
-
---
--- Table structure for table `party`
---
-
-DROP TABLE IF EXISTS `party`;
-CREATE TABLE `party` (
- `party_id` int(11) unsigned NOT NULL auto_increment,
- `name` char(100) NOT NULL default '',
- `exp` tinyint(11) unsigned NOT NULL default '0',
- `item` tinyint(11) unsigned NOT NULL default '0',
- `leader_id` int(11) unsigned NOT NULL default '0',
- `leader_char` int(11) unsigned NOT NULL default '0',
- PRIMARY KEY (`party_id`)
-) TYPE=MyISAM;
-
---
--- Table structure for table `pet`
---
-
-DROP TABLE IF EXISTS `pet`;
-CREATE TABLE `pet` (
- `pet_id` int(11) unsigned NOT NULL auto_increment,
- `class` mediumint(9) unsigned NOT NULL default '0',
- `name` varchar(24) NOT NULL default '',
- `account_id` int(11) unsigned NOT NULL default '0',
- `char_id` int(11) unsigned NOT NULL default '0',
- `level` smallint(4) unsigned NOT NULL default '0',
- `egg_id` smallint(11) unsigned NOT NULL default '0',
- `equip` mediumint(8) unsigned NOT NULL default '0',
- `intimate` smallint(9) unsigned NOT NULL default '0',
- `hungry` smallint(9) unsigned NOT NULL default '0',
- `rename_flag` tinyint(4) unsigned NOT NULL default '0',
- `incuvate` int(11) unsigned NOT NULL default '0',
- PRIMARY KEY (`pet_id`)
-) TYPE=MyISAM;
-
---
--- Table structure for table `ragsrvinfo`
---
-
-DROP TABLE IF EXISTS `ragsrvinfo`;
-CREATE TABLE `ragsrvinfo` (
- `index` int(11) NOT NULL default '0',
- `name` varchar(255) NOT NULL default '',
- `exp` int(11) unsigned NOT NULL default '0',
- `jexp` int(11) unsigned NOT NULL default '0',
- `drop` int(11) unsigned NOT NULL default '0',
- `motd` varchar(255) NOT NULL default ''
-) TYPE=MyISAM;
-
---
--- Table structure for table `skill`
---
-
-DROP TABLE IF EXISTS `skill`;
-CREATE TABLE `skill` (
- `char_id` int(11) unsigned NOT NULL default '0',
- `id` smallint(11) unsigned NOT NULL default '0',
- `lv` tinyint(4) unsigned NOT NULL default '0',
- PRIMARY KEY (`char_id`,`id`),
- KEY `char_id` (`char_id`)
-) TYPE=MyISAM;
-
---
--- Table structure for table `skill_homunculus`
---
-
-DROP TABLE IF EXISTS `skill_homunculus`;
-CREATE TABLE `skill_homunculus` (
- `homun_id` int(11) NOT NULL,
- `id` int(11) NOT NULL,
- `lv` smallint(6) NOT NULL,
- PRIMARY KEY (`homun_id`,`id`),
- KEY `homun_id` (`homun_id`)
-) TYPE=MyISAM;
-
---
--- Table structure for table `sstatus`
---
-
-DROP TABLE IF EXISTS `sstatus`;
-CREATE TABLE `sstatus` (
- `index` tinyint(4) unsigned NOT NULL default '0',
- `name` varchar(255) NOT NULL default '',
- `user` int(11) unsigned NOT NULL default '0'
-) TYPE=MyISAM;
-
---
--- Table structure for table `storage`
---
-
-DROP TABLE IF EXISTS `storage`;
-CREATE TABLE `storage` (
- `id` int(11) unsigned NOT NULL auto_increment,
- `account_id` int(11) unsigned NOT NULL default '0',
- `nameid` int(11) unsigned NOT NULL default '0',
- `amount` smallint(11) unsigned NOT NULL default '0',
- `equip` mediumint(8) unsigned NOT NULL default '0',
- `identify` smallint(6) unsigned NOT NULL default '0',
- `refine` tinyint(3) unsigned NOT NULL default '0',
- `attribute` tinyint(4) unsigned NOT NULL default '0',
- `card0` smallint(11) NOT NULL default '0',
- `card1` smallint(11) NOT NULL default '0',
- `card2` smallint(11) NOT NULL default '0',
- `card3` smallint(11) NOT NULL default '0',
- PRIMARY KEY (`id`),
- KEY `account_id` (`account_id`)
-) TYPE=MyISAM;
+-- MySQL dump 9.11
+-- Server version 4.0.24
+
+--
+-- Table structure for table `cart_inventory`
+--
+
+DROP TABLE IF EXISTS `cart_inventory`;
+CREATE TABLE `cart_inventory` (
+ `id` int(11) NOT NULL auto_increment,
+ `char_id` int(11) NOT NULL default '0',
+ `nameid` int(11) NOT NULL default '0',
+ `amount` int(11) NOT NULL default '0',
+ `equip` mediumint(8) unsigned NOT NULL default '0',
+ `identify` smallint(6) NOT NULL default '0',
+ `refine` tinyint(3) unsigned NOT NULL default '0',
+ `attribute` tinyint(4) NOT NULL default '0',
+ `card0` int(11) NOT NULL default '0',
+ `card1` int(11) NOT NULL default '0',
+ `card2` int(11) NOT NULL default '0',
+ `card3` int(11) NOT NULL default '0',
+ PRIMARY KEY (`id`),
+ KEY `char_id` (`char_id`)
+) TYPE=MyISAM;
+
+--
+-- Table structure for table `char`
+--
+
+DROP TABLE IF EXISTS `char`;
+CREATE TABLE `char` (
+ `char_id` int(11) unsigned NOT NULL auto_increment,
+ `account_id` int(11) unsigned NOT NULL default '0',
+ `char_num` tinyint(1) NOT NULL default '0',
+ `name` varchar(30) NOT NULL default '',
+ `class` smallint(6) unsigned NOT NULL default '0',
+ `base_level` smallint(6) unsigned NOT NULL default '1',
+ `job_level` smallint(6) unsigned NOT NULL default '1',
+ `base_exp` bigint(20) unsigned NOT NULL default '0',
+ `job_exp` bigint(20) unsigned NOT NULL default '0',
+ `zeny` int(11) unsigned NOT NULL default '0',
+ `str` smallint(4) unsigned NOT NULL default '0',
+ `agi` smallint(4) unsigned NOT NULL default '0',
+ `vit` smallint(4) unsigned NOT NULL default '0',
+ `int` smallint(4) unsigned NOT NULL default '0',
+ `dex` smallint(4) unsigned NOT NULL default '0',
+ `luk` smallint(4) unsigned NOT NULL default '0',
+ `max_hp` mediumint(8) unsigned NOT NULL default '0',
+ `hp` mediumint(8) unsigned NOT NULL default '0',
+ `max_sp` mediumint(6) unsigned NOT NULL default '0',
+ `sp` mediumint(6) unsigned NOT NULL default '0',
+ `status_point` smallint(4) unsigned NOT NULL default '0',
+ `skill_point` smallint(4) unsigned NOT NULL default '0',
+ `option` int(11) NOT NULL default '0',
+ `karma` tinyint(3) NOT NULL default '0',
+ `manner` tinyint(3) NOT NULL default '0',
+ `party_id` int(11) unsigned NOT NULL default '0',
+ `guild_id` int(11) unsigned NOT NULL default '0',
+ `pet_id` int(11) unsigned NOT NULL default '0',
+ `homun_id` int(11) unsigned NOT NULL default '0',
+ `hair` tinyint(4) unsigned NOT NULL default '0',
+ `hair_color` smallint(5) unsigned NOT NULL default '0',
+ `clothes_color` smallint(5) unsigned NOT NULL default '0',
+ `weapon` smallint(6) unsigned NOT NULL default '1',
+ `shield` smallint(6) unsigned NOT NULL default '0',
+ `head_top` smallint(6) unsigned NOT NULL default '0',
+ `head_mid` smallint(6) unsigned NOT NULL default '0',
+ `head_bottom` smallint(6) unsigned NOT NULL default '0',
+ `last_map` varchar(20) NOT NULL default 'prontera.gat',
+ `last_x` smallint(4) unsigned NOT NULL default '53',
+ `last_y` smallint(4) unsigned NOT NULL default '111',
+ `save_map` varchar(20) NOT NULL default 'prontera.gat',
+ `save_x` smallint(4) unsigned NOT NULL default '53',
+ `save_y` smallint(4) unsigned NOT NULL default '111',
+ `partner_id` int(11) unsigned NOT NULL default '0',
+ `online` tinyint(2) NOT NULL default '0',
+ `father` int(11) unsigned NOT NULL default '0',
+ `mother` int(11) unsigned NOT NULL default '0',
+ `child` int(11) unsigned NOT NULL default '0',
+ `fame` int(11) unsigned NOT NULL default '0',
+ PRIMARY KEY (`char_id`),
+ KEY `account_id` (`account_id`),
+ KEY `party_id` (`party_id`),
+ KEY `guild_id` (`guild_id`),
+ KEY `name` (`name`),
+ KEY `online` (`online`)
+) TYPE=MyISAM AUTO_INCREMENT=150000;
+
+--
+-- Table structure for table `charlog`
+--
+
+DROP TABLE IF EXISTS `charlog`;
+CREATE TABLE `charlog` (
+ `time` datetime NOT NULL default '0000-00-00 00:00:00',
+ `char_msg` varchar(255) NOT NULL default 'char select',
+ `account_id` int(11) NOT NULL default '0',
+ `char_num` tinyint(4) NOT NULL default '0',
+ `name` varchar(255) NOT NULL default '',
+ `str` int(11) unsigned NOT NULL default '0',
+ `agi` int(11) unsigned NOT NULL default '0',
+ `vit` int(11) unsigned NOT NULL default '0',
+ `int` int(11) unsigned NOT NULL default '0',
+ `dex` int(11) unsigned NOT NULL default '0',
+ `luk` int(11) unsigned NOT NULL default '0',
+ `hair` tinyint(4) NOT NULL default '0',
+ `hair_color` int(11) NOT NULL default '0'
+) TYPE=MyISAM;
+
+--
+-- Table structure for table `friends`
+--
+
+DROP TABLE IF EXISTS `friends`;
+CREATE TABLE `friends` (
+ `char_id` int(11) NOT NULL default '0',
+ `friend_account` int(11) NOT NULL default '0',
+ `friend_id` int(11) NOT NULL default '0',
+ KEY `char_id` (`char_id`)
+) TYPE=MyISAM;
+
+--
+-- Table structure for table `global_reg_value`
+--
+
+DROP TABLE IF EXISTS `global_reg_value`;
+CREATE TABLE `global_reg_value` (
+ `char_id` int(11) unsigned NOT NULL default '0',
+ `str` varchar(255) NOT NULL default '',
+ `value` varchar(255) NOT NULL default '0',
+ `type` int(11) NOT NULL default '3',
+ `account_id` int(11) unsigned NOT NULL default '0',
+ PRIMARY KEY (`char_id`,`str`,`account_id`),
+ KEY `account_id` (`account_id`),
+ KEY `char_id` (`char_id`)
+) TYPE=MyISAM;
+
+--
+-- Table structure for table `guild`
+--
+
+DROP TABLE IF EXISTS `guild`;
+CREATE TABLE `guild` (
+ `guild_id` int(11) unsigned NOT NULL auto_increment,
+ `name` varchar(24) NOT NULL default '',
+ `char_id` int(11) unsigned NOT NULL default '0',
+ `master` varchar(24) NOT NULL default '',
+ `guild_lv` tinyint(6) unsigned NOT NULL default '0',
+ `connect_member` tinyint(6) unsigned NOT NULL default '0',
+ `max_member` tinyint(6) unsigned NOT NULL default '0',
+ `average_lv` smallint(6) unsigned NOT NULL default '1',
+ `exp` int(11) unsigned NOT NULL default '0',
+ `next_exp` int(11) unsigned NOT NULL default '0',
+ `skill_point` tinyint(11) unsigned NOT NULL default '0',
+ `mes1` varchar(60) NOT NULL default '',
+ `mes2` varchar(120) NOT NULL default '',
+ `emblem_len` int(11) unsigned NOT NULL default '0',
+ `emblem_id` int(11) unsigned NOT NULL default '0',
+ `emblem_data` blob,
+ PRIMARY KEY (`guild_id`,`char_id`),
+ UNIQUE KEY `guild_id` (`guild_id`),
+ KEY `char_id` (`char_id`)
+) TYPE=MyISAM;
+
+--
+-- Table structure for table `guild_alliance`
+--
+
+DROP TABLE IF EXISTS `guild_alliance`;
+CREATE TABLE `guild_alliance` (
+ `guild_id` int(11) unsigned NOT NULL default '0',
+ `opposition` int(11) unsigned NOT NULL default '0',
+ `alliance_id` int(11) unsigned NOT NULL default '0',
+ `name` varchar(24) NOT NULL default '',
+ PRIMARY KEY (`guild_id`,`alliance_id`),
+ KEY `alliance_id` (`alliance_id`)
+) TYPE=MyISAM;
+
+--
+-- Table structure for table `guild_castle`
+--
+
+DROP TABLE IF EXISTS `guild_castle`;
+CREATE TABLE `guild_castle` (
+ `castle_id` int(11) unsigned NOT NULL default '0',
+ `guild_id` int(11) unsigned NOT NULL default '0',
+ `economy` int(11) unsigned NOT NULL default '0',
+ `defense` int(11) unsigned NOT NULL default '0',
+ `triggerE` int(11) unsigned NOT NULL default '0',
+ `triggerD` int(11) unsigned NOT NULL default '0',
+ `nextTime` int(11) unsigned NOT NULL default '0',
+ `payTime` int(11) unsigned NOT NULL default '0',
+ `createTime` int(11) unsigned NOT NULL default '0',
+ `visibleC` int(11) unsigned NOT NULL default '0',
+ `visibleG0` int(11) unsigned NOT NULL default '0',
+ `visibleG1` int(11) unsigned NOT NULL default '0',
+ `visibleG2` int(11) unsigned NOT NULL default '0',
+ `visibleG3` int(11) unsigned NOT NULL default '0',
+ `visibleG4` int(11) unsigned NOT NULL default '0',
+ `visibleG5` int(11) unsigned NOT NULL default '0',
+ `visibleG6` int(11) unsigned NOT NULL default '0',
+ `visibleG7` int(11) unsigned NOT NULL default '0',
+ `gHP0` int(11) unsigned NOT NULL default '0',
+ `ghP1` int(11) unsigned NOT NULL default '0',
+ `gHP2` int(11) unsigned NOT NULL default '0',
+ `gHP3` int(11) unsigned NOT NULL default '0',
+ `gHP4` int(11) unsigned NOT NULL default '0',
+ `gHP5` int(11) unsigned NOT NULL default '0',
+ `gHP6` int(11) unsigned NOT NULL default '0',
+ `gHP7` int(11) unsigned NOT NULL default '0',
+ PRIMARY KEY (`castle_id`),
+ KEY `guild_id` (`guild_id`)
+) TYPE=MyISAM;
+
+--
+-- Table structure for table `guild_expulsion`
+--
+
+DROP TABLE IF EXISTS `guild_expulsion`;
+CREATE TABLE `guild_expulsion` (
+ `guild_id` int(11) unsigned NOT NULL default '0',
+ `name` varchar(24) NOT NULL default '',
+ `mes` varchar(40) NOT NULL default '',
+ `acc` varchar(40) NOT NULL default '',
+ `account_id` int(11) unsigned NOT NULL default '0',
+ `rsv1` int(11) unsigned NOT NULL default '0',
+ `rsv2` int(11) unsigned NOT NULL default '0',
+ `rsv3` int(11) unsigned NOT NULL default '0',
+ PRIMARY KEY (`guild_id`,`name`)
+) TYPE=MyISAM;
+
+--
+-- Table structure for table `guild_member`
+--
+
+DROP TABLE IF EXISTS `guild_member`;
+CREATE TABLE `guild_member` (
+ `guild_id` int(11) unsigned NOT NULL default '0',
+ `account_id` int(11) unsigned NOT NULL default '0',
+ `char_id` int(11) unsigned NOT NULL default '0',
+ `hair` tinyint(6) unsigned NOT NULL default '0',
+ `hair_color` smallint(6) unsigned NOT NULL default '0',
+ `gender` tinyint(6) unsigned NOT NULL default '0',
+ `class` smallint(6) unsigned NOT NULL default '0',
+ `lv` smallint(6) unsigned NOT NULL default '0',
+ `exp` bigint(20) unsigned NOT NULL default '0',
+ `exp_payper` tinyint(11) unsigned NOT NULL default '0',
+ `online` tinyint(4) unsigned NOT NULL default '0',
+ `position` tinyint(6) unsigned NOT NULL default '0',
+ `rsv1` int(11) unsigned NOT NULL default '0',
+ `rsv2` int(11) unsigned NOT NULL default '0',
+ `name` varchar(24) NOT NULL default '',
+ PRIMARY KEY (`guild_id`,`char_id`),
+ KEY `char_id` (`char_id`)
+) TYPE=MyISAM;
+
+--
+-- Table structure for table `guild_position`
+--
+
+DROP TABLE IF EXISTS `guild_position`;
+CREATE TABLE `guild_position` (
+ `guild_id` int(9) unsigned NOT NULL default '0',
+ `position` tinyint(6) unsigned NOT NULL default '0',
+ `name` varchar(24) NOT NULL default '',
+ `mode` tinyint(11) unsigned NOT NULL default '0',
+ `exp_mode` tinyint(11) unsigned NOT NULL default '0',
+ PRIMARY KEY (`guild_id`,`position`),
+ KEY `guild_id` (`guild_id`)
+) TYPE=MyISAM;
+
+--
+-- Table structure for table `guild_skill`
+--
+
+DROP TABLE IF EXISTS `guild_skill`;
+CREATE TABLE `guild_skill` (
+ `guild_id` int(11) unsigned NOT NULL default '0',
+ `id` smallint(11) unsigned NOT NULL default '0',
+ `lv` tinyint(11) unsigned NOT NULL default '0',
+ PRIMARY KEY (`guild_id`,`id`)
+) TYPE=MyISAM;
+
+--
+-- Table structure for table `guild_storage`
+--
+
+DROP TABLE IF EXISTS `guild_storage`;
+CREATE TABLE `guild_storage` (
+ `id` int(10) unsigned NOT NULL auto_increment,
+ `guild_id` int(11) unsigned NOT NULL default '0',
+ `nameid` int(11) unsigned NOT NULL default '0',
+ `amount` int(11) unsigned NOT NULL default '0',
+ `equip` mediumint(8) unsigned NOT NULL default '0',
+ `identify` smallint(6) unsigned NOT NULL default '0',
+ `refine` tinyint(3) unsigned NOT NULL default '0',
+ `attribute` tinyint(4) unsigned NOT NULL default '0',
+ `card0` smallint(11) NOT NULL default '0',
+ `card1` smallint(11) NOT NULL default '0',
+ `card2` smallint(11) NOT NULL default '0',
+ `card3` smallint(11) NOT NULL default '0',
+ PRIMARY KEY (`id`),
+ KEY `guild_id` (`guild_id`)
+) TYPE=MyISAM;
+
+--
+-- Table structure for table `homunculus`
+--
+
+DROP TABLE IF EXISTS `homunculus`;
+CREATE TABLE `homunculus` (
+ `homun_id` int(11) NOT NULL auto_increment,
+ `char_id` int(11) NOT NULL,
+ `class` mediumint(9) unsigned NOT NULL default '0',
+ `name` varchar(24) NOT NULL default '',
+ `level` smallint(4) NOT NULL default '0',
+ `exp` int(12) NOT NULL default '0',
+ `intimacy` int(12) NOT NULL default '0',
+ `hunger` smallint(4) NOT NULL default '0',
+ `str` smallint(4) unsigned NOT NULL default '0',
+ `agi` smallint(4) unsigned NOT NULL default '0',
+ `vit` smallint(4) unsigned NOT NULL default '0',
+ `int` smallint(4) unsigned NOT NULL default '0',
+ `dex` smallint(4) unsigned NOT NULL default '0',
+ `luk` smallint(4) unsigned NOT NULL default '0',
+ `hp` int(12) NOT NULL default '1',
+ `max_hp` int(12) NOT NULL default '1',
+ `sp` int(12) NOT NULL default '1',
+ `max_sp` int(12) NOT NULL default '1',
+ `skill_point` smallint(4) unsigned NOT NULL default '0',
+ `alive` tinyint(2) NOT NULL default '1',
+ `rename_flag` tinyint(2) NOT NULL default '0',
+ `vaporize` tinyint(2) NOT NULL default '0',
+ PRIMARY KEY (`homun_id`)
+) TYPE=MyISAM;
+
+--
+-- Table structure for table `interlog`
+--
+
+DROP TABLE IF EXISTS `interlog`;
+CREATE TABLE `interlog` (
+ `time` datetime NOT NULL default '0000-00-00 00:00:00',
+ `log` varchar(255) NOT NULL default ''
+) TYPE=MyISAM;
+
+--
+-- Table structure for table `inventory`
+--
+
+DROP TABLE IF EXISTS `inventory`;
+CREATE TABLE `inventory` (
+ `id` int(11) unsigned NOT NULL auto_increment,
+ `char_id` int(11) unsigned NOT NULL default '0',
+ `nameid` int(11) unsigned NOT NULL default '0',
+ `amount` int(11) unsigned NOT NULL default '0',
+ `equip` mediumint(8) unsigned NOT NULL default '0',
+ `identify` smallint(6) NOT NULL default '0',
+ `refine` tinyint(3) unsigned NOT NULL default '0',
+ `attribute` tinyint(4) unsigned NOT NULL default '0',
+ `card0` smallint(11) NOT NULL default '0',
+ `card1` smallint(11) NOT NULL default '0',
+ `card2` smallint(11) NOT NULL default '0',
+ `card3` smallint(11) NOT NULL default '0',
+ PRIMARY KEY (`id`),
+ KEY `char_id` (`char_id`)
+) TYPE=MyISAM;
+
+--
+-- Table structure for table `ipbanlist`
+--
+
+DROP TABLE IF EXISTS `ipbanlist`;
+CREATE TABLE `ipbanlist` (
+ `list` varchar(255) NOT NULL default '',
+ `btime` datetime NOT NULL default '0000-00-00 00:00:00',
+ `rtime` datetime NOT NULL default '0000-00-00 00:00:00',
+ `reason` varchar(255) NOT NULL default '',
+ KEY (`list`)
+) TYPE=MyISAM;
+
+--
+-- Table structure for table `login`
+--
+
+DROP TABLE IF EXISTS `login`;
+CREATE TABLE `login` (
+ `account_id` int(11) unsigned NOT NULL auto_increment,
+ `userid` varchar(255) NOT NULL default '',
+ `user_pass` varchar(32) NOT NULL default '',
+ `lastlogin` datetime NOT NULL default '0000-00-00 00:00:00',
+ `sex` char(1) NOT NULL default 'M',
+ `logincount` mediumint(9) unsigned NOT NULL default '0',
+ `email` varchar(60) NOT NULL default '',
+ `level` tinyint(3) NOT NULL default '0',
+ `error_message` smallint(11) unsigned NOT NULL default '0',
+ `connect_until` int(11) unsigned NOT NULL default '0',
+ `last_ip` varchar(100) NOT NULL default '',
+ `memo` smallint(11) unsigned NOT NULL default '0',
+ `ban_until` int(11) unsigned NOT NULL default '0',
+ `state` int(11) unsigned NOT NULL default '0',
+ PRIMARY KEY (`account_id`),
+ KEY `name` (`userid`)
+) TYPE=MyISAM AUTO_INCREMENT=2000000;
+
+-- added standard accounts for servers, VERY INSECURE!!!
+-- inserted into the table called login which is above
+
+INSERT INTO `login` (`account_id`, `userid`, `user_pass`, `sex`, `email`) VALUES ('1', 's1', 'p1', 'S','athena@athena.com');
+
+--
+-- Table structure for table `mapreg`
+--
+
+DROP TABLE IF EXISTS `mapreg`;
+CREATE TABLE `mapreg` (
+ `varname` varchar(32) NOT NULL,
+ `index` int(11) unsigned NOT NULL default '0',
+ `value` varchar(255) NOT NULL,
+ KEY `varname` (`varname`),
+ KEY `index` (`index`)
+) TYPE=MyISAM;
+
+--
+-- Table structure for table `sc_data`
+--
+
+DROP TABLE IF EXISTS `sc_data`;
+CREATE TABLE `sc_data` (
+ `account_id` int(11) unsigned NOT NULL,
+ `char_id` int(11) unsigned NOT NULL,
+ `type` smallint(11) unsigned NOT NULL,
+ `tick` int(11) NOT NULL,
+ `val1` int(11) NOT NULL default '0',
+ `val2` int(11) NOT NULL default '0',
+ `val3` int(11) NOT NULL default '0',
+ `val4` int(11) NOT NULL default '0',
+ KEY (`account_id`),
+ KEY (`char_id`)
+) TYPE=MyISAM;
+
+--
+-- Table structure for table `loginlog`
+--
+
+DROP TABLE IF EXISTS `loginlog`;
+CREATE TABLE `loginlog` (
+ `time` datetime NOT NULL default '0000-00-00 00:00:00',
+ `ip` int(10) unsigned NOT NULL default '0',
+ `user` varchar(32) NOT NULL default '',
+ `rcode` tinyint(4) NOT NULL default '0',
+ `log` varchar(255) NOT NULL default '',
+ INDEX (`ip`)
+) TYPE=MyISAM;
+
+--
+-- Table structure for table `memo`
+--
+
+DROP TABLE IF EXISTS `memo`;
+CREATE TABLE `memo` (
+ `memo_id` int(11) unsigned NOT NULL auto_increment,
+ `char_id` int(11) unsigned NOT NULL default '0',
+ `map` varchar(255) NOT NULL default '',
+ `x` smallint(9) unsigned NOT NULL default '0',
+ `y` smallint(9) unsigned NOT NULL default '0',
+ PRIMARY KEY (`memo_id`),
+ KEY `char_id` (`char_id`)
+) TYPE=MyISAM;
+
+--
+-- Table structure for table `party`
+--
+
+DROP TABLE IF EXISTS `party`;
+CREATE TABLE `party` (
+ `party_id` int(11) unsigned NOT NULL auto_increment,
+ `name` char(100) NOT NULL default '',
+ `exp` tinyint(11) unsigned NOT NULL default '0',
+ `item` tinyint(11) unsigned NOT NULL default '0',
+ `leader_id` int(11) unsigned NOT NULL default '0',
+ `leader_char` int(11) unsigned NOT NULL default '0',
+ PRIMARY KEY (`party_id`)
+) TYPE=MyISAM;
+
+--
+-- Table structure for table `pet`
+--
+
+DROP TABLE IF EXISTS `pet`;
+CREATE TABLE `pet` (
+ `pet_id` int(11) unsigned NOT NULL auto_increment,
+ `class` mediumint(9) unsigned NOT NULL default '0',
+ `name` varchar(24) NOT NULL default '',
+ `account_id` int(11) unsigned NOT NULL default '0',
+ `char_id` int(11) unsigned NOT NULL default '0',
+ `level` smallint(4) unsigned NOT NULL default '0',
+ `egg_id` smallint(11) unsigned NOT NULL default '0',
+ `equip` mediumint(8) unsigned NOT NULL default '0',
+ `intimate` smallint(9) unsigned NOT NULL default '0',
+ `hungry` smallint(9) unsigned NOT NULL default '0',
+ `rename_flag` tinyint(4) unsigned NOT NULL default '0',
+ `incuvate` int(11) unsigned NOT NULL default '0',
+ PRIMARY KEY (`pet_id`)
+) TYPE=MyISAM;
+
+--
+-- Table structure for table `ragsrvinfo`
+--
+
+DROP TABLE IF EXISTS `ragsrvinfo`;
+CREATE TABLE `ragsrvinfo` (
+ `index` int(11) NOT NULL default '0',
+ `name` varchar(255) NOT NULL default '',
+ `exp` int(11) unsigned NOT NULL default '0',
+ `jexp` int(11) unsigned NOT NULL default '0',
+ `drop` int(11) unsigned NOT NULL default '0',
+ `motd` varchar(255) NOT NULL default ''
+) TYPE=MyISAM;
+
+--
+-- Table structure for table `skill`
+--
+
+DROP TABLE IF EXISTS `skill`;
+CREATE TABLE `skill` (
+ `char_id` int(11) unsigned NOT NULL default '0',
+ `id` smallint(11) unsigned NOT NULL default '0',
+ `lv` tinyint(4) unsigned NOT NULL default '0',
+ PRIMARY KEY (`char_id`,`id`),
+ KEY `char_id` (`char_id`)
+) TYPE=MyISAM;
+
+--
+-- Table structure for table `skill_homunculus`
+--
+
+DROP TABLE IF EXISTS `skill_homunculus`;
+CREATE TABLE `skill_homunculus` (
+ `homun_id` int(11) NOT NULL,
+ `id` int(11) NOT NULL,
+ `lv` smallint(6) NOT NULL,
+ PRIMARY KEY (`homun_id`,`id`),
+ KEY `homun_id` (`homun_id`)
+) TYPE=MyISAM;
+
+--
+-- Table structure for table `sstatus`
+--
+
+DROP TABLE IF EXISTS `sstatus`;
+CREATE TABLE `sstatus` (
+ `index` tinyint(4) unsigned NOT NULL default '0',
+ `name` varchar(255) NOT NULL default '',
+ `user` int(11) unsigned NOT NULL default '0'
+) TYPE=MyISAM;
+
+--
+-- Table structure for table `storage`
+--
+
+DROP TABLE IF EXISTS `storage`;
+CREATE TABLE `storage` (
+ `id` int(11) unsigned NOT NULL auto_increment,
+ `account_id` int(11) unsigned NOT NULL default '0',
+ `nameid` int(11) unsigned NOT NULL default '0',
+ `amount` smallint(11) unsigned NOT NULL default '0',
+ `equip` mediumint(8) unsigned NOT NULL default '0',
+ `identify` smallint(6) unsigned NOT NULL default '0',
+ `refine` tinyint(3) unsigned NOT NULL default '0',
+ `attribute` tinyint(4) unsigned NOT NULL default '0',
+ `card0` smallint(11) NOT NULL default '0',
+ `card1` smallint(11) NOT NULL default '0',
+ `card2` smallint(11) NOT NULL default '0',
+ `card3` smallint(11) NOT NULL default '0',
+ PRIMARY KEY (`id`),
+ KEY `account_id` (`account_id`)
+) TYPE=MyISAM;
diff --git a/sql-files/oA2eA-rc5.sql b/sql-files/oA2eA-rc5.sql
index 2e30fa4b8..b501b232c 100644
--- a/sql-files/oA2eA-rc5.sql
+++ b/sql-files/oA2eA-rc5.sql
@@ -1,204 +1,204 @@
-//
-// When converting from oA to eA, my oA db was in ragnarok so I created
-// a new db called eragnarok and then ran the following commands...
-//
-// /usr/local/mysql/bin/mysql -Deragnarok -u eragnarok -p< athena/sql-files/main.sql
-// /usr/local/mysql/bin/mysql -Deragnarok -u eragnarok -p< athena/sql-files/db_tables.sql
-// /usr/local/mysql/bin/mysql -Deragnarok -u eragnarok -p< athena/sql-files/mail.sql
-// /usr/local/mysql/bin/mysql -Deragnarok -u eragnarok -p< athena/sql-files/oA2eA-rc5.sql
-//
-// This creates a eragnarok database and fills everything in from the oA
-// database.
-//
-// -- MouseJstr
-
-CREATE TABLE `item_db` (
- `id` smallint(5) unsigned NOT NULL default '0',
- `name_english` varchar(24) NOT NULL default '',
- `name_japanese` varchar(24) NOT NULL default '',
- `type` tinyint(2) unsigned NOT NULL default '0',
- `price_buy` int(10) unsigned default NULL,
- `price_sell` int(10) unsigned default NULL,
- `weight` int(10) unsigned NOT NULL default '0',
- `attack` mediumint(9) unsigned default NULL,
- `defence` mediumint(9) unsigned default NULL,
- `range` tinyint(2) unsigned default NULL,
- `slots` tinyint(1) unsigned default NULL,
- `equip_jobs` mediumint(8) unsigned default NULL,
- `equip_genders` tinyint(1) unsigned default NULL,
- `equip_locations` smallint(4) unsigned default NULL,
- `weapon_level` tinyint(1) unsigned default NULL,
- `equip_level` tinyint(3) unsigned default NULL,
- `view` tinyint(3) unsigned default NULL,
- `script_use` text,
- `script_equip` text,
- PRIMARY KEY (`id`)
-) TYPE=MyISAM;
-
-CREATE TABLE `mob_db` (
- `ID` mediumint(9) NOT NULL default '0',
- `Name` text NOT NULL,
- `Name2` text NOT NULL,
- `LV` smallint(6) NOT NULL default '0',
- `HP` mediumint(9) NOT NULL default '0',
- `SP` mediumint(9) NOT NULL default '0',
- `EXP` mediumint(9) NOT NULL default '0',
- `JEXP` mediumint(9) NOT NULL default '0',
- `Range1` tinyint(4) NOT NULL default '0',
- `ATK1` smallint(6) NOT NULL default '0',
- `ATK2` smallint(6) NOT NULL default '0',
- `DEF` smallint(6) NOT NULL default '0',
- `MDEF` smallint(6) NOT NULL default '0',
- `STR` tinyint(4) NOT NULL default '0',
- `AGI` tinyint(4) NOT NULL default '0',
- `VIT` tinyint(4) NOT NULL default '0',
- `INT` tinyint(4) NOT NULL default '0',
- `DEX` tinyint(4) NOT NULL default '0',
- `LUK` tinyint(4) NOT NULL default '0',
- `Range2` tinyint(4) NOT NULL default '0',
- `Range3` tinyint(4) NOT NULL default '0',
- `Scale` tinyint(4) NOT NULL default '0',
- `Race` tinyint(4) NOT NULL default '0',
- `Element` tinyint(4) NOT NULL default '0',
- `Mode` smallint(6) NOT NULL default '0',
- `Speed` smallint(6) NOT NULL default '0',
- `ADelay` smallint(6) NOT NULL default '0',
- `aMotion` smallint(6) NOT NULL default '0',
- `dMotion` smallint(6) NOT NULL default '0',
- `Drop1id` mediumint(9) NOT NULL default '0',
- `Drop1per` mediumint(9) NOT NULL default '0',
- `Drop2id` mediumint(9) NOT NULL default '0',
- `Drop2per` mediumint(9) NOT NULL default '0',
- `Drop3id` mediumint(9) NOT NULL default '0',
- `Drop3per` mediumint(9) NOT NULL default '0',
- `Drop4id` mediumint(9) NOT NULL default '0',
- `Drop4per` mediumint(9) NOT NULL default '0',
- `Drop5id` mediumint(9) NOT NULL default '0',
- `Drop5per` mediumint(9) NOT NULL default '0',
- `Drop6id` mediumint(9) NOT NULL default '0',
- `Drop6per` mediumint(9) NOT NULL default '0',
- `Drop7id` mediumint(9) NOT NULL default '0',
- `Drop7per` mediumint(9) NOT NULL default '0',
- `Drop8id` mediumint(9) NOT NULL default '0',
- `Drop8per` mediumint(9) NOT NULL default '0',
- `MEXP` mediumint(9) NOT NULL default '0',
- `ExpPer` mediumint(9) NOT NULL default '0',
- `MVP1id` mediumint(9) NOT NULL default '0',
- `MVP1per` mediumint(9) NOT NULL default '0',
- `MVP2id` mediumint(9) NOT NULL default '0',
- `MVP2per` mediumint(9) NOT NULL default '0',
- `MVP3id` mediumint(9) NOT NULL default '0',
- `MVP3per` mediumint(9) NOT NULL default '0'
-) TYPE=MyISAM;
-
-INSERT INTO eragnarok.storage(`id`, `account_id`, `nameid`, `amount`, `equip`, `identify`, `refine`, `attribute`, `card0`, `card1`, `card2`, `card3`) SELECT `id`, `account_id`, `nameid`, `amount`, `equip`, `identify`, `refine`, `attribute`, `card0`, `card1`, `card2`, `card3` from ragnarok.storage;
-
- INSERT INTO eragnarok.cart_inventory(`id`, `char_id`, `nameid`, `amount`, `equip`, `identify`, `refine`, `attribute`, `card0`, `card1`, `card2`, `card3`, `broken`) SELECT `id`, `char_id`, `nameid`, `amount`, `equip`, `identify`, `refine`, `attribute`, `card0`, `card1`, `card2`, `card3`, `broken` from ragnarok.cart_inventory;
-
-INSERT INTO eragnarok.char( `char_id`, `account_id`, `char_num`, `name`, `class`, `base_level`, `job_level`, `base_exp`, `job_exp`, `zeny`, `str`, `agi`, `vit`, `int`, `dex`, `luk`, `max_hp`, `hp`, `max_sp`, `sp`, `status_point`, `skill_point`, `option`, `karma`, `manner`, `party_id`, `guild_id`, `pet_id`, `hair`, `hair_color`, `clothes_color`, `weapon`, `shield`, `head_top`, `head_mid`, `head_bottom`, `last_map`, `last_x`, `last_y`, `save_map`, `save_x`, `save_y`, `partner_id`, `online`) SELECT `char_id`, `account_id`, `char_num`, `name`, `class`, `base_level`, `job_level`, `base_exp`, `job_exp`, `zeny`, `str`, `agi`, `vit`, `int`, `dex`, `luk`, `max_hp`, `hp`, `max_sp`, `sp`, `status_point`, `skill_point`, `option`, `karma`, `manner`, `party_id`, `guild_id`, `pet_id`, `hair`, `hair_color`, `clothes_color`, `weapon`, `shield`, `head_top`, `head_mid`, `head_bottom`, `last_map`, `last_x`, `last_y`, `save_map`, `save_x`, `save_y`, `partner_id`, `online` from ragnarok.char;
-
-INSERT INTO eragnarok.charlog( `time`, `char_msg`, `account_id`, `char_num`, `name`, `str`, `agi`, `vit`, `int`, `dex`, `luk`, `hair`, `hair_color` ) SELECT `time`, `char_msg`, `account_id`, `char_num`, `name`, `str`, `agi`, `vit`, `int`, `dex`, `luk`, `hair`, `hair_color` from ragnarok.charlog;
-
-INSERT INTO eragnarok.global_reg_value ( `char_id`, `str`, `value`, `type`, `account_id`) SELECT `char_id`, `str`, `value`, `type`, `account_id` from ragnarok.global_reg_value ;
-
-INSERT INTO eragnarok.guild( `guild_id`, `name`, `master`, `guild_lv`, `connect_member`, `max_member`, `average_lv`, `exp`, `next_exp`, `skill_point`, `castle_id`, `mes1`, `mes2`, `emblem_len`, `emblem_id`, `emblem_data` ) SELECT `guild_id`, `name`, `master`, `guild_lv`, `connect_member`, `max_member`, `average_lv`, `exp`, `next_exp`, `skill_point`, `castle_id`, `mes1`, `mes2`, `emblem_len`, `emblem_id`, `emblem_data` from ragnarok.guild;
-
-INSERT INTO eragnarok.guild_alliance ( `guild_id`, `opposition`, `alliance_id`, `name` ) SELECT `guild_id`, `opposition`, `alliance_id`, `name` from ragnarok.guild_alliance ;
-
-INSERT INTO eragnarok.guild_castle ( `castle_id`, `guild_id`, `economy`, `defense`, `triggerE`, `triggerD`, `nextTime`, `payTime`, `createTime`, `visibleC`, `visibleG0`, `visibleG1`, `visibleG2`, `visibleG3`, `visibleG4`, `visibleG5`, `visibleG6`, `visibleG7` ) SELECT `castle_id`, `guild_id`, `economy`, `defense`, `triggerE`, `triggerD`, `nextTime`, `payTime`, `createTime`, `visibleC`, `visibleG0`, `visibleG1`, `visibleG2`, `visibleG3`, `visibleG4`, `visibleG5`, `visibleG6`, `visibleG7` from ragnarok.guild_castle ;
-
-INSERT INTO eragnarok.guild_expulsion ( `guild_id`, `name`, `mes`, `acc`, `account_id`, `rsv1`, `rsv2`, `rsv3` ) SELECT `guild_id`, `name`, `mes`, `acc`, `account_id`, `rsv1`, `rsv2`, `rsv3` from ragnarok.guild_expulsion ;
-
-INSERT INTO eragnarok.guild_member ( `guild_id`, `account_id`, `char_id`, `hair`, `hair_color`, `gender`, `class`, `lv`, `exp`, `exp_payper`, `online`, `position`, `rsv1`, `rsv2`, `name` ) SELECT `guild_id`, `account_id`, `char_id`, `hair`, `hair_color`, `gender`, `class`, `lv`, `exp`, `exp_payper`, `online`, `position`, `rsv1`, `rsv2`, `name` from ragnarok.guild_member ;
-
-INSERT INTO eragnarok.guild_position ( `guild_id`, `position`, `name`, `mode`, `exp_mode` ) SELECT `guild_id`, `position`, `name`, `mode`, `exp_mode` from ragnarok.guild_position ;
-
-INSERT INTO eragnarok.guild_skill ( `guild_id`, `id`, `lv` ) SELECT `guild_id`, `id`, `lv` from ragnarok.guild_skill ;
-
-INSERT INTO eragnarok.guild_storage ( `id`, `guild_id`, `nameid`, `amount`, `equip`, `identify`, `refine`, `attribute`, `card0`, `card1`, `card2`, `card3` ) SELECT `id`, `guild_id`, `nameid`, `amount`, `equip`, `identify`, `refine`, `attribute`, `card0`, `card1`, `card2`, `card3` from ragnarok.guild_storage ;
-
-INSERT INTO eragnarok.interlog ( `time`, `log` ) SELECT `time`, `log` from ragnarok.interlog ;
-
-INSERT INTO eragnarok.inventory ( `id`, `char_id`, `nameid`, `amount`, `equip`, `identify`, `refine`, `attribute`, `card0`, `card1`, `card2`, `card3` ) SELECT `id`, `char_id`, `nameid`, `amount`, `equip`, `identify`, `refine`, `attribute`, `card0`, `card1`, `card2`, `card3` from ragnarok.inventory ;
-
-INSERT INTO eragnarok.ipbanlist ( `list`, `btime`, `rtime`, `reason` ) SELECT `list`, `btime`, `rtime`, `reason` from ragnarok.ipbanlist ;
-
-
-# INSERT INTO eragnarok.login_error ( `err_id`, `reason` ) SELECT `err_id`, `reason` from ragnarok.login_error ;
-
-INSERT INTO eragnarok.loginlog ( `time`, `ip`, `user`, `rcode`, `log` ) SELECT `time`, `ip`, `user`, `rcode`, `log` from ragnarok.loginlog ;
-
-INSERT INTO eragnarok.memo ( `memo_id`, `char_id`, `map`, `x`, `y` ) SELECT `memo_id`, `char_id`, `map`, `x`, `y` from ragnarok.memo ;
-
-INSERT INTO eragnarok.party ( `party_id`, `name`, `exp`, `item`, `leader_id` ) SELECT `party_id`, `name`, `exp`, `item`, `leader_id` from ragnarok.party ;
-
-INSERT INTO eragnarok.pet ( `pet_id`, `class`, `name`, `account_id`, `char_id`, `level`, `egg_id`, `equip`, `intimate`, `hungry`, `rename_flag`, `incuvate` ) SELECT `pet_id`, `class`, `name`, `account_id`, `char_id`, `level`, `egg_id`, `equip`, `intimate`, `hungry`, `rename_flag`, `incuvate` from ragnarok.pet ;
-
-INSERT INTO eragnarok.ragsrvinfo ( `index`, `name`, `exp`, `jexp`, `drop` ) SELECT `index`, `name`, `exp`, `jexp`, `drop` from ragnarok.ragsrvinfo ;
-
-INSERT INTO eragnarok.skill ( `char_id`, `id`, `lv` ) SELECT `char_id`, `id`, `lv` from ragnarok.skill ;
-
-INSERT INTO eragnarok.sstatus ( `index`, `name`, `user` ) SELECT `index`, `name`, `user` from ragnarok.sstatus ;
-
-
-# INSERT INTO eragnarok.abra_db ( `ID`, `Dummy`, `Req_Lvl`, `Per`, `Comment`) SELECT `ID`, `Dummy`, `Req_Lvl`, `Per`, `Comment` from ragnarok.abra_db;
-
-# INSERT INTO eragnarok.attr_fix ( `Level`, `None`, `Water`, `Earth`, `Fire`, `Wind`, `Poison`, `Saint`, `Darkness`, `Sense`, `Immortality`, `Comment`) SELECT `Level`, `None`, `Water`, `Earth`, `Fire`, `Wind`, `Poison`, `Saint`, `Darkness`, `Sense`, `Immortality`, `Comment` from ragnarok.attr_fix;
-
-# INSERT INTO eragnarok.cast_db ( `ID`, `Cast_List`, `Delay_List`, `Upkeep_Time`, `Upkeep_Time2`, `Comment` ) SELECT `ID`, `Cast_List`, `Delay_List`, `Upkeep_Time`, `Upkeep_Time2`, `Comment` from ragnarok.cast_db;
-
-#INSERT INTO eragnarok.castle_db ( `CastleID`, `map_name`, `castle_name`, `switch_flag`, `Comment` ) SELECT `CastleID`, `map_name`, `castle_name`, `switch_flag`, `Comment` from ragnarok.castle_db;
-
-#INSERT INTO eragnarok.create_arrow_db ( `SourceID`, `MakeID1`, `MakeNum1`, `MakeID2`, `MakeNum2`, `MakeID3`, `MakeNum3`, `MakeID4`, `MakeNum4`, `MakeID5`, `MakeNum5`, `Comment` ) SELECT `SourceID`, `MakeID1`, `MakeNum1`, `MakeID2`, `MakeNum2`, `MakeID3`, `MakeNum3`, `MakeID4`, `MakeNum4`, `MakeID5`, `MakeNum5`, `Comment` from ragnarok.create_arrow_db;
-
-#INSERT INTO eragnarok.exp ( `EXP1`, `EXP2`, `EXP3`, `EXP4`, `EXP5`, `EXP6`, `EXP7`, `EXP8`, `EXP9`, `EXP10`, `EXP11`, `EXP12`, `EXP13`, `EXP14` ) SELECT `EXP1`, `EXP2`, `EXP3`, `EXP4`, `EXP5`, `EXP6`, `EXP7`, `EXP8`, `EXP9`, `EXP10`, `EXP11`, `EXP12`, `EXP13`, `EXP14` from ragnarok.exp;
-
-#INSERT INTO eragnarok.exp_guild ( `Level`, `EXP`, `Comment` ) SELECT `Level`, `EXP`, `Comment` from ragnarok.exp_guild;
-
-#INSERT INTO eragnarok.item_bluebox ( `NameID`, `item_name`, `rate`, `Comment` ) SELECT `NameID`, `item_name`, `rate`, `Comment` from ragnarok.item_bluebox;
-
-#INSERT INTO eragnarok.item_cardalbum ( `NameID`, `item_name`, `rate`, `Comment` ) SELECT `NameID`, `item_name`, `rate`, `Comment` from ragnarok.item_cardalbum;
-
-INSERT INTO eragnarok.item_db2 ( `ID`, `Name`, `Name2`, `Type`, `Price`, `Sell`, `Weight`, `ATK`, `DEF`, `Range`, `Slot`, `Job`, `Gender`, `Loc`, `wLV`, `eLV`, `View`, `UseScript`, `EquipScript`, `Comment` ) SELECT `ID`, `Name`, `Name2`, `Type`, `Price`, `Sell`, `Weight`, `ATK`, `DEF`, `Range`, `Slot`, `Job`, `Gender`, `Loc`, `wLV`, `eLV`, `View`, `UseScript`, `EquipScript`, `Comment` from ragnarok.item_db2;
-
-# INSERT INTO eragnarok.item_giftbox ( `NameID`, `item_name`, `rate`, `Comment` ) SELECT `NameID`, `item_name`, `rate`, `Comment` from ragnarok.item_giftbox;
-
-#INSERT INTO eragnarok.item_scroll ( `NameID`, `item_name`, `rate`, `Comment` ) SELECT `NameID`, `item_name`, `rate`, `Comment` from ragnarok.item_scroll;
-
-#INSERT INTO eragnarok.item_violetbox ( `NameID`, `item_name`, `rate`, `Comment` ) SELECT `NameID`, `item_name`, `rate`, `Comment` from ragnarok.item_violetbox;
-
-#INSERT INTO eragnarok.job_db1 ( `Class_ID`, `Weight`, `HP`, `HP2`, `SP`, `Empty`, `Dagger`, `Sword`, `Two_Handed_Sword`, `Spear`, `Two_Handed_Spear`, `Axe`, `Two_Handed_Axe`, `Rod`, `Club`, `Stick`, `Bow`, `Fist`, `Musical`, `Whip`, `Book`, `Katar`, `Comment` ) SELECT `Class_ID`, `Weight`, `HP`, `HP2`, `SP`, `Empty`, `Dagger`, `Sword`, `Two_Handed_Sword`, `Spear`, `Two_Handed_Spear`, `Axe`, `Two_Handed_Axe`, `Rod`, `Club`, `Stick`, `Bow`, `Fist`, `Musical`, `Whip`, `Book`, `Katar`, `Comment` from ragnarok.job_db1;
-
-INSERT INTO eragnarok.mob_boss ( `MobID`, `MobName`, `Rate`, `Comment` ) SELECT `MobID`, `MobName`, `Rate`, `Comment` from ragnarok.mob_boss;
-
-INSERT INTO eragnarok.mob_branch ( `MobID`, `MobName`, `Rate`, `Comment` ) SELECT `MobID`, `MobName`, `Rate`, `Comment` from ragnarok.mob_branch;
-
-INSERT INTO eragnarok.mob_db2 ( `ID`, `Name`, `Name2`, `LV`, `HP`, `SP`, `EXP`, `JEXP`, `Range1`, `ATK1`, `ATK2`, `DEF`, `MDEF`, `STR`, `AGI`, `VIT`, `INT`, `DEX`, `LUK`, `Range2`, `Range3`, `Scale`, `Race`, `Element`, `Mode`, `Speed`, `ADelay`, `aMotion`, `dMotion`, `Drop1id`, `Drop1per`, `Drop2id`, `Drop2per`, `Drop3id`, `Drop3per`, `Drop4id`, `Drop4per`, `Drop5id`, `Drop5per`, `Drop6id`, `Drop6per`, `Drop7d`, `Drop7per`, `Drop8id`, `Drop8per`, `Item1`, `Item2`, `MEXP`, `ExpPer`, `MVP1id`, `MVP1per`, `MVP2id`, `MVP2per`, `MVP3id`, `MVP3per`, `Comment` ) SELECT `ID`, `Name`, `Name2`, `LV`, `HP`, `SP`, `EXP`, `JEXP`, `Range1`, `ATK1`, `ATK2`, `DEF`, `MDEF`, `STR`, `AGI`, `VIT`, `INT`, `DEX`, `LUK`, `Range2`, `Range3`, `Scale`, `Race`, `Element`, `Mode`, `Speed`, `ADelay`, `aMotion`, `dMotion`, `Drop1id`, `Drop1per`, `Drop2id`, `Drop2per`, `Drop3id`, `Drop3per`, `Drop4id`, `Drop4per`, `Drop5id`, `Drop5per`, `Drop6id`, `Drop6per`, `Drop7d`, `Drop7per`, `Drop8id`, `Drop8per`, `Item1`, `Item2`, `MEXP`, `ExpPer`, `MVP1id`, `MVP1per`, `MVP2id`, `MVP2per`, `MVP3id`, `MVP3per`, `Comment` from ragnarok.mob_db2;
-
-INSERT INTO eragnarok.mob_poring ( `MobID`, `MobName`, `Rate`, `Comment` ) SELECT `MobID`, `MobName`, `Rate`, `Comment` from ragnarok.mob_poring;
-
-INSERT INTO eragnarok.mob_skill_db ( `Mob_ID`, `Dummy`, `State`, `Skill_ID`, `Skill_LV`, `Use_Rate`, `Cast_Time`, `Delay`, `Disturbance`, `Target`, `Condition_Type`, `Condition_Value`, `Value1`, `Value2`, `Value3`, `Value4`, `Value5`, `Comment` ) SELECT `Mob_ID`, `Dummy`, `State`, `Skill_ID`, `Skill_LV`, `Use_Rate`, `Cast_Time`, `Delay`, `Disturbance`, `Target`, `Condition_Type`, `Condition_Value`, `Value1`, `Value2`, `Value3`, `Value4`, `Value5`, `Comment` from ragnarok.mob_skill_db;
-
-#INSERT INTO eragnarok.pet_db ( `MobID`, `Name`, `JName`, `ItemID`, `EggID`, `AcceID`, `FoodID`, `Fullness`, `HungryDeray`, `R_Hungry`, `R_Full`, `Intimate`, `Die`, `Capture`, `Speed`, `S_Performance`, `Talk_Convert_Class`, `Attack_Rate`, `Defence_Attack_Rate`, `Change_Target_Rate`, `Pet_Script`, `Comment` ) SELECT `MobID`, `Name`, `JName`, `ItemID`, `EggID`, `AcceID`, `FoodID`, `Fullness`, `HungryDeray`, `R_Hungry`, `R_Full`, `Intimate`, `Die`, `Capture`, `Speed`, `S_Performance`, `Talk_Convert_Class`, `Attack_Rate`, `Defence_Attack_Rate`, `Change_Target_Rate`, `Pet_Script`, `Comment` from ragnarok.pet_db;
-
-#INSERT INTO eragnarok.produce_db ( `ID`, `ItemLV`, `RequireSkill`, `MaterialID1`, `MaterialAmount1`, `MaterialID2`, `MaterialAmount2`, `MaterialID3`, `MaterialAmount3`, `MaterialID4`, `MaterialAmount4`, `MaterialID5`, `MaterialAmount5`, `Comment` ) SELECT `ID`, `ItemLV`, `RequireSkill`, `MaterialID1`, `MaterialAmount1`, `MaterialID2`, `MaterialAmount2`, `MaterialID3`, `MaterialAmount3`, `MaterialID4`, `MaterialAmount4`, `MaterialID5`, `MaterialAmount5`, `Comment` from ragnarok.produce_db;
-
-#INSERT INTO eragnarok.refine_db ( `Refine_Bonus`, `Danger_Bonus`, `Safe_Limit`, `RefineChance1`, `RefineChance2`, `RefineChance3`, `RefineChance4`, `RefineChance5`, `RefineChance6`, `RefineChance7`, `RefineChance8`, `RefineChance9`, `RefineChance10`, `Comment` ) SELECT `Refine_Bonus`, `Danger_Bonus`, `Safe_Limit`, `RefineChance1`, `RefineChance2`, `RefineChance3`, `RefineChance4`, `RefineChance5`, `RefineChance6`, `RefineChance7`, `RefineChance8`, `RefineChance9`, `RefineChance10`, `Comment` from ragnarok.refine_db;
-
-#INSERT INTO eragnarok.size_fix ( `Element`, `Dagger`, `Sword`, `Two_Handed_Sword`, `Spear`, `Two_Handed_Spear`, `Axe`, `Two_Handed_Axe`, `Club`, `Whip`, `Stick`, `Bow`, `Fist`, `Musical`, `Rod`, `Book`, `Katar`, `Comment` ) SELECT `Element`, `Dagger`, `Sword`, `Two_Handed_Sword`, `Spear`, `Two_Handed_Spear`, `Axe`, `Two_Handed_Axe`, `Club`, `Whip`, `Stick`, `Bow`, `Fist`, `Musical`, `Rod`, `Book`, `Katar`, `Comment` from ragnarok.size_fix;
-
-#INSERT INTO eragnarok.skill_db ( `ID`, `Range`, `Hit`, `inf`, `nk`, `max`, `list_num`, `castcancel`, `cast_defence_rate`, `inf2`, `maxcount`, `skill_type`, `blow_count`, `Comment` ) SELECT `ID`, `Range`, `Hit`, `inf`, `nk`, `max`, `list_num`, `castcancel`, `cast_defence_rate`, `inf2`, `maxcount`, `skill_type`, `blow_count`, `Comment` from ragnarok.skill_db;
-
-#INSERT INTO eragnarok.skill_require_db ( `ID`, `List_HP`, `List_SP`, `List_HP_Rate`, `List_SP_Rate`, `List_Zeny`, `List_Weapon`, `State`, `Spiritball`, `ItemID1`, `Amount1`, `ItemID2`, `Amount2`, `ItemID3`, `Amount3`, `ItemID4`, `Amount4`, `ItemID5`, `Amount5`, `ItemID6`, `Amount6`, `ItemID7`, `Amount7`, `ItemID8`, `Amount8`, `ItemID9`, `Amount9`, `ItemID10`, `Amount10`, `Comment` ) SELECT `ID`, `List_HP`, `List_SP`, `List_HP_Rate`, `List_SP_Rate`, `List_Zeny`, `List_Weapon`, `State`, `Spiritball`, `ItemID1`, `Amount1`, `ItemID2`, `Amount2`, `ItemID3`, `Amount3`, `ItemID4`, `Amount4`, `ItemID5`, `Amount5`, `ItemID6`, `Amount6`, `ItemID7`, `Amount7`, `ItemID8`, `Amount8`, `ItemID9`, `Amount9`, `ItemID10`, `Amount10`, `Comment` from ragnarok.skill_require_db;
-
-#INSERT INTO eragnarok.skill_tree ( `Upper`, `JobNo`, `Skill_ID`, `MaxLV`, `Skill_ID_Require1`, `Skill_LV_Require1`, `Skill_ID_Require2`, `Skill_LV_Require2`, `Skill_ID_Require3`, `Skill_LV_Require3`, `Skill_ID_Require4`, `Skill_LV_Require4`, `Skill_ID_Require5`, `Skill_LV_Require5`, `Comment` ) SELECT `Upper`, `JobNo`, `Skill_ID`, `MaxLV`, `Skill_ID_Require1`, `Skill_LV_Require1`, `Skill_ID_Require2`, `Skill_LV_Require2`, `Skill_ID_Require3`, `Skill_LV_Require3`, `Skill_ID_Require4`, `Skill_LV_Require4`, `Skill_ID_Require5`, `Skill_LV_Require5`, `Comment` from ragnarok.skill_tree;
-
-INSERT INTO eragnarok.item_db ( `id`, `name_english`, `name_japanese`, `type`, `price_buy`, `price_sell`, `weight`, `attack`, `defence`, `range`, `slots`, `equip_jobs`, `equip_genders`, `equip_locations`, `weapon_level`, `equip_level`, `view`, `script_use`, `script_equip` ) SELECT `id`, `Name`, `Name2`, `type`, `Price`, `Sell`, `Weight`, `Atk`, `Def`, `range`, `Slot`, `Job`, `Gender`, `Loc`, `wLV`, `eLV`, `view`, `UseScript`, `EquipScript` from ragnarok.item_db;
-
-UPDATE item_db SET price_sell = price_buy/2;
-
-INSERT INTO eragnarok.mob_db (`ID`, `Name`, `Name2`, `LV`, `HP`, `SP`, `EXP`, `JEXP`, `Range1`, `ATK1`, `ATK2`, `DEF`, `MDEF`, `STR`, `AGI`, `VIT`, `INT`, `DEX`, `LUK`, `Range2`, `Range3`, `Scale`, `Race`, `Element`, `Mode`, `Speed`, `ADelay`, `aMotion`, `dMotion`, `Drop1id`, `Drop1per`, `Drop2id`, `Drop2per`, `Drop3id`, `Drop3per`, `Drop4id`, `Drop4per`, `Drop5id`, `Drop5per`, `Drop6id`, `Drop6per`, `Drop7id`, `Drop7per`, `Drop8id`, `Drop8per`, `MEXP`, `ExpPer`, `MVP1id`, `MVP1per`, `MVP2id`, `MVP2per`, `MVP3id`, `MVP3per`) SELECT `ID`, `Name`, `Name2`, `LV`, `HP`, `SP`, `EXP`, `JEXP`, `Range1`, `ATK1`, `ATK2`, `DEF`, `MDEF`, `STR`, `AGI`, `VIT`, `INT`, `DEX`, `LUK`, `Range2`, `Range3`, `Scale`, `Race`, `Element`, `Mode`, `Speed`, `ADelay`, `aMotion`, `dMotion`, `Drop1id`, `Drop1per`, `Drop2id`, `Drop2per`, `Drop3id`, `Drop3per`, `Drop4id`, `Drop4per`, `Drop5id`, `Drop5per`, `Drop6id`, `Drop6per`, `Drop7id`, `Drop7per`, `Drop8id`, `Drop8per`, `MEXP`, `ExpPer`, `MVP1id`, `MVP1per`, `MVP2id`, `MVP2per`, `MVP3id`, `MVP3per` from ragnarok.mob_db;
-
-DELETE FROM eragnarok.login;
-
-INSERT INTO eragnarok.login ( `account_id`, `userid`, `user_pass`, `lastlogin`, `sex`, `logincount`, `email`, `level` ) SELECT `account_id`, `userid`, `user_pass`, `lastlogin`, `sex`, `logincount`, `email`, `level` from ragnarok.login ;
+//
+// When converting from oA to eA, my oA db was in ragnarok so I created
+// a new db called eragnarok and then ran the following commands...
+//
+// /usr/local/mysql/bin/mysql -Deragnarok -u eragnarok -p< athena/sql-files/main.sql
+// /usr/local/mysql/bin/mysql -Deragnarok -u eragnarok -p< athena/sql-files/db_tables.sql
+// /usr/local/mysql/bin/mysql -Deragnarok -u eragnarok -p< athena/sql-files/mail.sql
+// /usr/local/mysql/bin/mysql -Deragnarok -u eragnarok -p< athena/sql-files/oA2eA-rc5.sql
+//
+// This creates a eragnarok database and fills everything in from the oA
+// database.
+//
+// -- MouseJstr
+
+CREATE TABLE `item_db` (
+ `id` smallint(5) unsigned NOT NULL default '0',
+ `name_english` varchar(24) NOT NULL default '',
+ `name_japanese` varchar(24) NOT NULL default '',
+ `type` tinyint(2) unsigned NOT NULL default '0',
+ `price_buy` int(10) unsigned default NULL,
+ `price_sell` int(10) unsigned default NULL,
+ `weight` int(10) unsigned NOT NULL default '0',
+ `attack` mediumint(9) unsigned default NULL,
+ `defence` mediumint(9) unsigned default NULL,
+ `range` tinyint(2) unsigned default NULL,
+ `slots` tinyint(1) unsigned default NULL,
+ `equip_jobs` mediumint(8) unsigned default NULL,
+ `equip_genders` tinyint(1) unsigned default NULL,
+ `equip_locations` smallint(4) unsigned default NULL,
+ `weapon_level` tinyint(1) unsigned default NULL,
+ `equip_level` tinyint(3) unsigned default NULL,
+ `view` tinyint(3) unsigned default NULL,
+ `script_use` text,
+ `script_equip` text,
+ PRIMARY KEY (`id`)
+) TYPE=MyISAM;
+
+CREATE TABLE `mob_db` (
+ `ID` mediumint(9) NOT NULL default '0',
+ `Name` text NOT NULL,
+ `Name2` text NOT NULL,
+ `LV` smallint(6) NOT NULL default '0',
+ `HP` mediumint(9) NOT NULL default '0',
+ `SP` mediumint(9) NOT NULL default '0',
+ `EXP` mediumint(9) NOT NULL default '0',
+ `JEXP` mediumint(9) NOT NULL default '0',
+ `Range1` tinyint(4) NOT NULL default '0',
+ `ATK1` smallint(6) NOT NULL default '0',
+ `ATK2` smallint(6) NOT NULL default '0',
+ `DEF` smallint(6) NOT NULL default '0',
+ `MDEF` smallint(6) NOT NULL default '0',
+ `STR` tinyint(4) NOT NULL default '0',
+ `AGI` tinyint(4) NOT NULL default '0',
+ `VIT` tinyint(4) NOT NULL default '0',
+ `INT` tinyint(4) NOT NULL default '0',
+ `DEX` tinyint(4) NOT NULL default '0',
+ `LUK` tinyint(4) NOT NULL default '0',
+ `Range2` tinyint(4) NOT NULL default '0',
+ `Range3` tinyint(4) NOT NULL default '0',
+ `Scale` tinyint(4) NOT NULL default '0',
+ `Race` tinyint(4) NOT NULL default '0',
+ `Element` tinyint(4) NOT NULL default '0',
+ `Mode` smallint(6) NOT NULL default '0',
+ `Speed` smallint(6) NOT NULL default '0',
+ `ADelay` smallint(6) NOT NULL default '0',
+ `aMotion` smallint(6) NOT NULL default '0',
+ `dMotion` smallint(6) NOT NULL default '0',
+ `Drop1id` mediumint(9) NOT NULL default '0',
+ `Drop1per` mediumint(9) NOT NULL default '0',
+ `Drop2id` mediumint(9) NOT NULL default '0',
+ `Drop2per` mediumint(9) NOT NULL default '0',
+ `Drop3id` mediumint(9) NOT NULL default '0',
+ `Drop3per` mediumint(9) NOT NULL default '0',
+ `Drop4id` mediumint(9) NOT NULL default '0',
+ `Drop4per` mediumint(9) NOT NULL default '0',
+ `Drop5id` mediumint(9) NOT NULL default '0',
+ `Drop5per` mediumint(9) NOT NULL default '0',
+ `Drop6id` mediumint(9) NOT NULL default '0',
+ `Drop6per` mediumint(9) NOT NULL default '0',
+ `Drop7id` mediumint(9) NOT NULL default '0',
+ `Drop7per` mediumint(9) NOT NULL default '0',
+ `Drop8id` mediumint(9) NOT NULL default '0',
+ `Drop8per` mediumint(9) NOT NULL default '0',
+ `MEXP` mediumint(9) NOT NULL default '0',
+ `ExpPer` mediumint(9) NOT NULL default '0',
+ `MVP1id` mediumint(9) NOT NULL default '0',
+ `MVP1per` mediumint(9) NOT NULL default '0',
+ `MVP2id` mediumint(9) NOT NULL default '0',
+ `MVP2per` mediumint(9) NOT NULL default '0',
+ `MVP3id` mediumint(9) NOT NULL default '0',
+ `MVP3per` mediumint(9) NOT NULL default '0'
+) TYPE=MyISAM;
+
+INSERT INTO eragnarok.storage(`id`, `account_id`, `nameid`, `amount`, `equip`, `identify`, `refine`, `attribute`, `card0`, `card1`, `card2`, `card3`) SELECT `id`, `account_id`, `nameid`, `amount`, `equip`, `identify`, `refine`, `attribute`, `card0`, `card1`, `card2`, `card3` from ragnarok.storage;
+
+ INSERT INTO eragnarok.cart_inventory(`id`, `char_id`, `nameid`, `amount`, `equip`, `identify`, `refine`, `attribute`, `card0`, `card1`, `card2`, `card3`, `broken`) SELECT `id`, `char_id`, `nameid`, `amount`, `equip`, `identify`, `refine`, `attribute`, `card0`, `card1`, `card2`, `card3`, `broken` from ragnarok.cart_inventory;
+
+INSERT INTO eragnarok.char( `char_id`, `account_id`, `char_num`, `name`, `class`, `base_level`, `job_level`, `base_exp`, `job_exp`, `zeny`, `str`, `agi`, `vit`, `int`, `dex`, `luk`, `max_hp`, `hp`, `max_sp`, `sp`, `status_point`, `skill_point`, `option`, `karma`, `manner`, `party_id`, `guild_id`, `pet_id`, `hair`, `hair_color`, `clothes_color`, `weapon`, `shield`, `head_top`, `head_mid`, `head_bottom`, `last_map`, `last_x`, `last_y`, `save_map`, `save_x`, `save_y`, `partner_id`, `online`) SELECT `char_id`, `account_id`, `char_num`, `name`, `class`, `base_level`, `job_level`, `base_exp`, `job_exp`, `zeny`, `str`, `agi`, `vit`, `int`, `dex`, `luk`, `max_hp`, `hp`, `max_sp`, `sp`, `status_point`, `skill_point`, `option`, `karma`, `manner`, `party_id`, `guild_id`, `pet_id`, `hair`, `hair_color`, `clothes_color`, `weapon`, `shield`, `head_top`, `head_mid`, `head_bottom`, `last_map`, `last_x`, `last_y`, `save_map`, `save_x`, `save_y`, `partner_id`, `online` from ragnarok.char;
+
+INSERT INTO eragnarok.charlog( `time`, `char_msg`, `account_id`, `char_num`, `name`, `str`, `agi`, `vit`, `int`, `dex`, `luk`, `hair`, `hair_color` ) SELECT `time`, `char_msg`, `account_id`, `char_num`, `name`, `str`, `agi`, `vit`, `int`, `dex`, `luk`, `hair`, `hair_color` from ragnarok.charlog;
+
+INSERT INTO eragnarok.global_reg_value ( `char_id`, `str`, `value`, `type`, `account_id`) SELECT `char_id`, `str`, `value`, `type`, `account_id` from ragnarok.global_reg_value ;
+
+INSERT INTO eragnarok.guild( `guild_id`, `name`, `master`, `guild_lv`, `connect_member`, `max_member`, `average_lv`, `exp`, `next_exp`, `skill_point`, `castle_id`, `mes1`, `mes2`, `emblem_len`, `emblem_id`, `emblem_data` ) SELECT `guild_id`, `name`, `master`, `guild_lv`, `connect_member`, `max_member`, `average_lv`, `exp`, `next_exp`, `skill_point`, `castle_id`, `mes1`, `mes2`, `emblem_len`, `emblem_id`, `emblem_data` from ragnarok.guild;
+
+INSERT INTO eragnarok.guild_alliance ( `guild_id`, `opposition`, `alliance_id`, `name` ) SELECT `guild_id`, `opposition`, `alliance_id`, `name` from ragnarok.guild_alliance ;
+
+INSERT INTO eragnarok.guild_castle ( `castle_id`, `guild_id`, `economy`, `defense`, `triggerE`, `triggerD`, `nextTime`, `payTime`, `createTime`, `visibleC`, `visibleG0`, `visibleG1`, `visibleG2`, `visibleG3`, `visibleG4`, `visibleG5`, `visibleG6`, `visibleG7` ) SELECT `castle_id`, `guild_id`, `economy`, `defense`, `triggerE`, `triggerD`, `nextTime`, `payTime`, `createTime`, `visibleC`, `visibleG0`, `visibleG1`, `visibleG2`, `visibleG3`, `visibleG4`, `visibleG5`, `visibleG6`, `visibleG7` from ragnarok.guild_castle ;
+
+INSERT INTO eragnarok.guild_expulsion ( `guild_id`, `name`, `mes`, `acc`, `account_id`, `rsv1`, `rsv2`, `rsv3` ) SELECT `guild_id`, `name`, `mes`, `acc`, `account_id`, `rsv1`, `rsv2`, `rsv3` from ragnarok.guild_expulsion ;
+
+INSERT INTO eragnarok.guild_member ( `guild_id`, `account_id`, `char_id`, `hair`, `hair_color`, `gender`, `class`, `lv`, `exp`, `exp_payper`, `online`, `position`, `rsv1`, `rsv2`, `name` ) SELECT `guild_id`, `account_id`, `char_id`, `hair`, `hair_color`, `gender`, `class`, `lv`, `exp`, `exp_payper`, `online`, `position`, `rsv1`, `rsv2`, `name` from ragnarok.guild_member ;
+
+INSERT INTO eragnarok.guild_position ( `guild_id`, `position`, `name`, `mode`, `exp_mode` ) SELECT `guild_id`, `position`, `name`, `mode`, `exp_mode` from ragnarok.guild_position ;
+
+INSERT INTO eragnarok.guild_skill ( `guild_id`, `id`, `lv` ) SELECT `guild_id`, `id`, `lv` from ragnarok.guild_skill ;
+
+INSERT INTO eragnarok.guild_storage ( `id`, `guild_id`, `nameid`, `amount`, `equip`, `identify`, `refine`, `attribute`, `card0`, `card1`, `card2`, `card3` ) SELECT `id`, `guild_id`, `nameid`, `amount`, `equip`, `identify`, `refine`, `attribute`, `card0`, `card1`, `card2`, `card3` from ragnarok.guild_storage ;
+
+INSERT INTO eragnarok.interlog ( `time`, `log` ) SELECT `time`, `log` from ragnarok.interlog ;
+
+INSERT INTO eragnarok.inventory ( `id`, `char_id`, `nameid`, `amount`, `equip`, `identify`, `refine`, `attribute`, `card0`, `card1`, `card2`, `card3` ) SELECT `id`, `char_id`, `nameid`, `amount`, `equip`, `identify`, `refine`, `attribute`, `card0`, `card1`, `card2`, `card3` from ragnarok.inventory ;
+
+INSERT INTO eragnarok.ipbanlist ( `list`, `btime`, `rtime`, `reason` ) SELECT `list`, `btime`, `rtime`, `reason` from ragnarok.ipbanlist ;
+
+
+# INSERT INTO eragnarok.login_error ( `err_id`, `reason` ) SELECT `err_id`, `reason` from ragnarok.login_error ;
+
+INSERT INTO eragnarok.loginlog ( `time`, `ip`, `user`, `rcode`, `log` ) SELECT `time`, `ip`, `user`, `rcode`, `log` from ragnarok.loginlog ;
+
+INSERT INTO eragnarok.memo ( `memo_id`, `char_id`, `map`, `x`, `y` ) SELECT `memo_id`, `char_id`, `map`, `x`, `y` from ragnarok.memo ;
+
+INSERT INTO eragnarok.party ( `party_id`, `name`, `exp`, `item`, `leader_id` ) SELECT `party_id`, `name`, `exp`, `item`, `leader_id` from ragnarok.party ;
+
+INSERT INTO eragnarok.pet ( `pet_id`, `class`, `name`, `account_id`, `char_id`, `level`, `egg_id`, `equip`, `intimate`, `hungry`, `rename_flag`, `incuvate` ) SELECT `pet_id`, `class`, `name`, `account_id`, `char_id`, `level`, `egg_id`, `equip`, `intimate`, `hungry`, `rename_flag`, `incuvate` from ragnarok.pet ;
+
+INSERT INTO eragnarok.ragsrvinfo ( `index`, `name`, `exp`, `jexp`, `drop` ) SELECT `index`, `name`, `exp`, `jexp`, `drop` from ragnarok.ragsrvinfo ;
+
+INSERT INTO eragnarok.skill ( `char_id`, `id`, `lv` ) SELECT `char_id`, `id`, `lv` from ragnarok.skill ;
+
+INSERT INTO eragnarok.sstatus ( `index`, `name`, `user` ) SELECT `index`, `name`, `user` from ragnarok.sstatus ;
+
+
+# INSERT INTO eragnarok.abra_db ( `ID`, `Dummy`, `Req_Lvl`, `Per`, `Comment`) SELECT `ID`, `Dummy`, `Req_Lvl`, `Per`, `Comment` from ragnarok.abra_db;
+
+# INSERT INTO eragnarok.attr_fix ( `Level`, `None`, `Water`, `Earth`, `Fire`, `Wind`, `Poison`, `Saint`, `Darkness`, `Sense`, `Immortality`, `Comment`) SELECT `Level`, `None`, `Water`, `Earth`, `Fire`, `Wind`, `Poison`, `Saint`, `Darkness`, `Sense`, `Immortality`, `Comment` from ragnarok.attr_fix;
+
+# INSERT INTO eragnarok.cast_db ( `ID`, `Cast_List`, `Delay_List`, `Upkeep_Time`, `Upkeep_Time2`, `Comment` ) SELECT `ID`, `Cast_List`, `Delay_List`, `Upkeep_Time`, `Upkeep_Time2`, `Comment` from ragnarok.cast_db;
+
+#INSERT INTO eragnarok.castle_db ( `CastleID`, `map_name`, `castle_name`, `switch_flag`, `Comment` ) SELECT `CastleID`, `map_name`, `castle_name`, `switch_flag`, `Comment` from ragnarok.castle_db;
+
+#INSERT INTO eragnarok.create_arrow_db ( `SourceID`, `MakeID1`, `MakeNum1`, `MakeID2`, `MakeNum2`, `MakeID3`, `MakeNum3`, `MakeID4`, `MakeNum4`, `MakeID5`, `MakeNum5`, `Comment` ) SELECT `SourceID`, `MakeID1`, `MakeNum1`, `MakeID2`, `MakeNum2`, `MakeID3`, `MakeNum3`, `MakeID4`, `MakeNum4`, `MakeID5`, `MakeNum5`, `Comment` from ragnarok.create_arrow_db;
+
+#INSERT INTO eragnarok.exp ( `EXP1`, `EXP2`, `EXP3`, `EXP4`, `EXP5`, `EXP6`, `EXP7`, `EXP8`, `EXP9`, `EXP10`, `EXP11`, `EXP12`, `EXP13`, `EXP14` ) SELECT `EXP1`, `EXP2`, `EXP3`, `EXP4`, `EXP5`, `EXP6`, `EXP7`, `EXP8`, `EXP9`, `EXP10`, `EXP11`, `EXP12`, `EXP13`, `EXP14` from ragnarok.exp;
+
+#INSERT INTO eragnarok.exp_guild ( `Level`, `EXP`, `Comment` ) SELECT `Level`, `EXP`, `Comment` from ragnarok.exp_guild;
+
+#INSERT INTO eragnarok.item_bluebox ( `NameID`, `item_name`, `rate`, `Comment` ) SELECT `NameID`, `item_name`, `rate`, `Comment` from ragnarok.item_bluebox;
+
+#INSERT INTO eragnarok.item_cardalbum ( `NameID`, `item_name`, `rate`, `Comment` ) SELECT `NameID`, `item_name`, `rate`, `Comment` from ragnarok.item_cardalbum;
+
+INSERT INTO eragnarok.item_db2 ( `ID`, `Name`, `Name2`, `Type`, `Price`, `Sell`, `Weight`, `ATK`, `DEF`, `Range`, `Slot`, `Job`, `Gender`, `Loc`, `wLV`, `eLV`, `View`, `UseScript`, `EquipScript`, `Comment` ) SELECT `ID`, `Name`, `Name2`, `Type`, `Price`, `Sell`, `Weight`, `ATK`, `DEF`, `Range`, `Slot`, `Job`, `Gender`, `Loc`, `wLV`, `eLV`, `View`, `UseScript`, `EquipScript`, `Comment` from ragnarok.item_db2;
+
+# INSERT INTO eragnarok.item_giftbox ( `NameID`, `item_name`, `rate`, `Comment` ) SELECT `NameID`, `item_name`, `rate`, `Comment` from ragnarok.item_giftbox;
+
+#INSERT INTO eragnarok.item_scroll ( `NameID`, `item_name`, `rate`, `Comment` ) SELECT `NameID`, `item_name`, `rate`, `Comment` from ragnarok.item_scroll;
+
+#INSERT INTO eragnarok.item_violetbox ( `NameID`, `item_name`, `rate`, `Comment` ) SELECT `NameID`, `item_name`, `rate`, `Comment` from ragnarok.item_violetbox;
+
+#INSERT INTO eragnarok.job_db1 ( `Class_ID`, `Weight`, `HP`, `HP2`, `SP`, `Empty`, `Dagger`, `Sword`, `Two_Handed_Sword`, `Spear`, `Two_Handed_Spear`, `Axe`, `Two_Handed_Axe`, `Rod`, `Club`, `Stick`, `Bow`, `Fist`, `Musical`, `Whip`, `Book`, `Katar`, `Comment` ) SELECT `Class_ID`, `Weight`, `HP`, `HP2`, `SP`, `Empty`, `Dagger`, `Sword`, `Two_Handed_Sword`, `Spear`, `Two_Handed_Spear`, `Axe`, `Two_Handed_Axe`, `Rod`, `Club`, `Stick`, `Bow`, `Fist`, `Musical`, `Whip`, `Book`, `Katar`, `Comment` from ragnarok.job_db1;
+
+INSERT INTO eragnarok.mob_boss ( `MobID`, `MobName`, `Rate`, `Comment` ) SELECT `MobID`, `MobName`, `Rate`, `Comment` from ragnarok.mob_boss;
+
+INSERT INTO eragnarok.mob_branch ( `MobID`, `MobName`, `Rate`, `Comment` ) SELECT `MobID`, `MobName`, `Rate`, `Comment` from ragnarok.mob_branch;
+
+INSERT INTO eragnarok.mob_db2 ( `ID`, `Name`, `Name2`, `LV`, `HP`, `SP`, `EXP`, `JEXP`, `Range1`, `ATK1`, `ATK2`, `DEF`, `MDEF`, `STR`, `AGI`, `VIT`, `INT`, `DEX`, `LUK`, `Range2`, `Range3`, `Scale`, `Race`, `Element`, `Mode`, `Speed`, `ADelay`, `aMotion`, `dMotion`, `Drop1id`, `Drop1per`, `Drop2id`, `Drop2per`, `Drop3id`, `Drop3per`, `Drop4id`, `Drop4per`, `Drop5id`, `Drop5per`, `Drop6id`, `Drop6per`, `Drop7d`, `Drop7per`, `Drop8id`, `Drop8per`, `Item1`, `Item2`, `MEXP`, `ExpPer`, `MVP1id`, `MVP1per`, `MVP2id`, `MVP2per`, `MVP3id`, `MVP3per`, `Comment` ) SELECT `ID`, `Name`, `Name2`, `LV`, `HP`, `SP`, `EXP`, `JEXP`, `Range1`, `ATK1`, `ATK2`, `DEF`, `MDEF`, `STR`, `AGI`, `VIT`, `INT`, `DEX`, `LUK`, `Range2`, `Range3`, `Scale`, `Race`, `Element`, `Mode`, `Speed`, `ADelay`, `aMotion`, `dMotion`, `Drop1id`, `Drop1per`, `Drop2id`, `Drop2per`, `Drop3id`, `Drop3per`, `Drop4id`, `Drop4per`, `Drop5id`, `Drop5per`, `Drop6id`, `Drop6per`, `Drop7d`, `Drop7per`, `Drop8id`, `Drop8per`, `Item1`, `Item2`, `MEXP`, `ExpPer`, `MVP1id`, `MVP1per`, `MVP2id`, `MVP2per`, `MVP3id`, `MVP3per`, `Comment` from ragnarok.mob_db2;
+
+INSERT INTO eragnarok.mob_poring ( `MobID`, `MobName`, `Rate`, `Comment` ) SELECT `MobID`, `MobName`, `Rate`, `Comment` from ragnarok.mob_poring;
+
+INSERT INTO eragnarok.mob_skill_db ( `Mob_ID`, `Dummy`, `State`, `Skill_ID`, `Skill_LV`, `Use_Rate`, `Cast_Time`, `Delay`, `Disturbance`, `Target`, `Condition_Type`, `Condition_Value`, `Value1`, `Value2`, `Value3`, `Value4`, `Value5`, `Comment` ) SELECT `Mob_ID`, `Dummy`, `State`, `Skill_ID`, `Skill_LV`, `Use_Rate`, `Cast_Time`, `Delay`, `Disturbance`, `Target`, `Condition_Type`, `Condition_Value`, `Value1`, `Value2`, `Value3`, `Value4`, `Value5`, `Comment` from ragnarok.mob_skill_db;
+
+#INSERT INTO eragnarok.pet_db ( `MobID`, `Name`, `JName`, `ItemID`, `EggID`, `AcceID`, `FoodID`, `Fullness`, `HungryDeray`, `R_Hungry`, `R_Full`, `Intimate`, `Die`, `Capture`, `Speed`, `S_Performance`, `Talk_Convert_Class`, `Attack_Rate`, `Defence_Attack_Rate`, `Change_Target_Rate`, `Pet_Script`, `Comment` ) SELECT `MobID`, `Name`, `JName`, `ItemID`, `EggID`, `AcceID`, `FoodID`, `Fullness`, `HungryDeray`, `R_Hungry`, `R_Full`, `Intimate`, `Die`, `Capture`, `Speed`, `S_Performance`, `Talk_Convert_Class`, `Attack_Rate`, `Defence_Attack_Rate`, `Change_Target_Rate`, `Pet_Script`, `Comment` from ragnarok.pet_db;
+
+#INSERT INTO eragnarok.produce_db ( `ID`, `ItemLV`, `RequireSkill`, `MaterialID1`, `MaterialAmount1`, `MaterialID2`, `MaterialAmount2`, `MaterialID3`, `MaterialAmount3`, `MaterialID4`, `MaterialAmount4`, `MaterialID5`, `MaterialAmount5`, `Comment` ) SELECT `ID`, `ItemLV`, `RequireSkill`, `MaterialID1`, `MaterialAmount1`, `MaterialID2`, `MaterialAmount2`, `MaterialID3`, `MaterialAmount3`, `MaterialID4`, `MaterialAmount4`, `MaterialID5`, `MaterialAmount5`, `Comment` from ragnarok.produce_db;
+
+#INSERT INTO eragnarok.refine_db ( `Refine_Bonus`, `Danger_Bonus`, `Safe_Limit`, `RefineChance1`, `RefineChance2`, `RefineChance3`, `RefineChance4`, `RefineChance5`, `RefineChance6`, `RefineChance7`, `RefineChance8`, `RefineChance9`, `RefineChance10`, `Comment` ) SELECT `Refine_Bonus`, `Danger_Bonus`, `Safe_Limit`, `RefineChance1`, `RefineChance2`, `RefineChance3`, `RefineChance4`, `RefineChance5`, `RefineChance6`, `RefineChance7`, `RefineChance8`, `RefineChance9`, `RefineChance10`, `Comment` from ragnarok.refine_db;
+
+#INSERT INTO eragnarok.size_fix ( `Element`, `Dagger`, `Sword`, `Two_Handed_Sword`, `Spear`, `Two_Handed_Spear`, `Axe`, `Two_Handed_Axe`, `Club`, `Whip`, `Stick`, `Bow`, `Fist`, `Musical`, `Rod`, `Book`, `Katar`, `Comment` ) SELECT `Element`, `Dagger`, `Sword`, `Two_Handed_Sword`, `Spear`, `Two_Handed_Spear`, `Axe`, `Two_Handed_Axe`, `Club`, `Whip`, `Stick`, `Bow`, `Fist`, `Musical`, `Rod`, `Book`, `Katar`, `Comment` from ragnarok.size_fix;
+
+#INSERT INTO eragnarok.skill_db ( `ID`, `Range`, `Hit`, `inf`, `nk`, `max`, `list_num`, `castcancel`, `cast_defence_rate`, `inf2`, `maxcount`, `skill_type`, `blow_count`, `Comment` ) SELECT `ID`, `Range`, `Hit`, `inf`, `nk`, `max`, `list_num`, `castcancel`, `cast_defence_rate`, `inf2`, `maxcount`, `skill_type`, `blow_count`, `Comment` from ragnarok.skill_db;
+
+#INSERT INTO eragnarok.skill_require_db ( `ID`, `List_HP`, `List_SP`, `List_HP_Rate`, `List_SP_Rate`, `List_Zeny`, `List_Weapon`, `State`, `Spiritball`, `ItemID1`, `Amount1`, `ItemID2`, `Amount2`, `ItemID3`, `Amount3`, `ItemID4`, `Amount4`, `ItemID5`, `Amount5`, `ItemID6`, `Amount6`, `ItemID7`, `Amount7`, `ItemID8`, `Amount8`, `ItemID9`, `Amount9`, `ItemID10`, `Amount10`, `Comment` ) SELECT `ID`, `List_HP`, `List_SP`, `List_HP_Rate`, `List_SP_Rate`, `List_Zeny`, `List_Weapon`, `State`, `Spiritball`, `ItemID1`, `Amount1`, `ItemID2`, `Amount2`, `ItemID3`, `Amount3`, `ItemID4`, `Amount4`, `ItemID5`, `Amount5`, `ItemID6`, `Amount6`, `ItemID7`, `Amount7`, `ItemID8`, `Amount8`, `ItemID9`, `Amount9`, `ItemID10`, `Amount10`, `Comment` from ragnarok.skill_require_db;
+
+#INSERT INTO eragnarok.skill_tree ( `Upper`, `JobNo`, `Skill_ID`, `MaxLV`, `Skill_ID_Require1`, `Skill_LV_Require1`, `Skill_ID_Require2`, `Skill_LV_Require2`, `Skill_ID_Require3`, `Skill_LV_Require3`, `Skill_ID_Require4`, `Skill_LV_Require4`, `Skill_ID_Require5`, `Skill_LV_Require5`, `Comment` ) SELECT `Upper`, `JobNo`, `Skill_ID`, `MaxLV`, `Skill_ID_Require1`, `Skill_LV_Require1`, `Skill_ID_Require2`, `Skill_LV_Require2`, `Skill_ID_Require3`, `Skill_LV_Require3`, `Skill_ID_Require4`, `Skill_LV_Require4`, `Skill_ID_Require5`, `Skill_LV_Require5`, `Comment` from ragnarok.skill_tree;
+
+INSERT INTO eragnarok.item_db ( `id`, `name_english`, `name_japanese`, `type`, `price_buy`, `price_sell`, `weight`, `attack`, `defence`, `range`, `slots`, `equip_jobs`, `equip_genders`, `equip_locations`, `weapon_level`, `equip_level`, `view`, `script_use`, `script_equip` ) SELECT `id`, `Name`, `Name2`, `type`, `Price`, `Sell`, `Weight`, `Atk`, `Def`, `range`, `Slot`, `Job`, `Gender`, `Loc`, `wLV`, `eLV`, `view`, `UseScript`, `EquipScript` from ragnarok.item_db;
+
+UPDATE item_db SET price_sell = price_buy/2;
+
+INSERT INTO eragnarok.mob_db (`ID`, `Name`, `Name2`, `LV`, `HP`, `SP`, `EXP`, `JEXP`, `Range1`, `ATK1`, `ATK2`, `DEF`, `MDEF`, `STR`, `AGI`, `VIT`, `INT`, `DEX`, `LUK`, `Range2`, `Range3`, `Scale`, `Race`, `Element`, `Mode`, `Speed`, `ADelay`, `aMotion`, `dMotion`, `Drop1id`, `Drop1per`, `Drop2id`, `Drop2per`, `Drop3id`, `Drop3per`, `Drop4id`, `Drop4per`, `Drop5id`, `Drop5per`, `Drop6id`, `Drop6per`, `Drop7id`, `Drop7per`, `Drop8id`, `Drop8per`, `MEXP`, `ExpPer`, `MVP1id`, `MVP1per`, `MVP2id`, `MVP2per`, `MVP3id`, `MVP3per`) SELECT `ID`, `Name`, `Name2`, `LV`, `HP`, `SP`, `EXP`, `JEXP`, `Range1`, `ATK1`, `ATK2`, `DEF`, `MDEF`, `STR`, `AGI`, `VIT`, `INT`, `DEX`, `LUK`, `Range2`, `Range3`, `Scale`, `Race`, `Element`, `Mode`, `Speed`, `ADelay`, `aMotion`, `dMotion`, `Drop1id`, `Drop1per`, `Drop2id`, `Drop2per`, `Drop3id`, `Drop3per`, `Drop4id`, `Drop4per`, `Drop5id`, `Drop5per`, `Drop6id`, `Drop6per`, `Drop7id`, `Drop7per`, `Drop8id`, `Drop8per`, `MEXP`, `ExpPer`, `MVP1id`, `MVP1per`, `MVP2id`, `MVP2per`, `MVP3id`, `MVP3per` from ragnarok.mob_db;
+
+DELETE FROM eragnarok.login;
+
+INSERT INTO eragnarok.login ( `account_id`, `userid`, `user_pass`, `lastlogin`, `sex`, `logincount`, `email`, `level` ) SELECT `account_id`, `userid`, `user_pass`, `lastlogin`, `sex`, `logincount`, `email`, `level` from ragnarok.login ;
diff --git a/sql-files/update_logs.sql b/sql-files/update_logs.sql
index 4c89ebdcf..7b12c454e 100644
--- a/sql-files/update_logs.sql
+++ b/sql-files/update_logs.sql
@@ -1,13 +1,13 @@
-#ZenyLog types (M)onsters,(T)rade,(V)ending Sell/Buy,(S)hop Sell/Buy,(N)PC Change amount,(A)dministrators
-#Database: log
-#Table: zenylog
-CREATE TABLE `zenylog` (
- `id` int(11) NOT NULL auto_increment,
- `time` datetime NOT NULL default '0000-00-00 00:00:00',
- `char_id` int(11) NOT NULL default '0',
- `src_id` int(11) NOT NULL default '0',
- `type` set('M','T','V','S','N','A') NOT NULL default 'S',
- `amount` int(11) NOT NULL default '0',
- `map` varchar(20) NOT NULL default 'prontera.gat',
- PRIMARY KEY (`id`)
-) TYPE=MyISAM AUTO_INCREMENT=1 ;
+#ZenyLog types (M)onsters,(T)rade,(V)ending Sell/Buy,(S)hop Sell/Buy,(N)PC Change amount,(A)dministrators
+#Database: log
+#Table: zenylog
+CREATE TABLE `zenylog` (
+ `id` int(11) NOT NULL auto_increment,
+ `time` datetime NOT NULL default '0000-00-00 00:00:00',
+ `char_id` int(11) NOT NULL default '0',
+ `src_id` int(11) NOT NULL default '0',
+ `type` set('M','T','V','S','N','A') NOT NULL default 'S',
+ `amount` int(11) NOT NULL default '0',
+ `map` varchar(20) NOT NULL default 'prontera.gat',
+ PRIMARY KEY (`id`)
+) TYPE=MyISAM AUTO_INCREMENT=1 ;
diff --git a/sql-files/upgrade_0.5.2_database.sql b/sql-files/upgrade_0.5.2_database.sql
index 266207104..4d328acf6 100644
--- a/sql-files/upgrade_0.5.2_database.sql
+++ b/sql-files/upgrade_0.5.2_database.sql
@@ -1 +1 @@
-# Upgrade database tables for eAthena 0.5.2 to 1.0 RC 2
+# Upgrade database tables for eAthena 0.5.2 to 1.0 RC 2
diff --git a/sql-files/upgrade_0.5.2_main.sql b/sql-files/upgrade_0.5.2_main.sql
index 76e092c4f..e11d226ba 100644
--- a/sql-files/upgrade_0.5.2_main.sql
+++ b/sql-files/upgrade_0.5.2_main.sql
@@ -1,62 +1,62 @@
-# Upgrade login and character server tables for eAthena 0.5.2 to 1.0 RC 2
-
-ALTER TABLE `cart_inventory` ADD `broken` int(11) NOT NULL default '0';
-
-ALTER TABLE `char` MODIFY `base_level` bigint(20) unsigned NOT NULL default '1';
-ALTER TABLE `char` MODIFY `job_level` bigint(20) unsigned NOT NULL default '1';
-ALTER TABLE `char` MODIFY `base_exp` bigint(20) NOT NULL default '0';
-ALTER TABLE `char` MODIFY `job_exp` bigint(20) NOT NULL default '0';
-ALTER TABLE `char` ADD `partner_id` int(11) NOT NULL default '0';
-
-ALTER TABLE `charlog` MODIFY `str` int(11) unsigned NOT NULL default '0';
-ALTER TABLE `charlog` MODIFY `agi` int(11) unsigned NOT NULL default '0';
-ALTER TABLE `charlog` MODIFY `vit` int(11) unsigned NOT NULL default '0';
-ALTER TABLE `charlog` MODIFY `int` int(11) unsigned NOT NULL default '0';
-ALTER TABLE `charlog` MODIFY `dex` int(11) unsigned NOT NULL default '0';
-ALTER TABLE `charlog` MODIFY `luk` int(11) unsigned NOT NULL default '0';
-
-ALTER TABLE `global_reg_value` MODIFY `value` varchar(255) NOT NULL default '0';
-ALTER TABLE `global_reg_value` ADD PRIMARY KEY (`char_id`, `str`, `account_id`);
-ALTER TABLE `global_reg_value` DROP INDEX `account_id`;
-ALTER TABLE `global_reg_value` ADD INDEX `account_id` (`account_id`);
-
-ALTER TABLE `guild_castle` ADD `gHP0` int(11) NOT NULL default '0';
-ALTER TABLE `guild_castle` ADD `gHP1` int(11) NOT NULL default '0';
-ALTER TABLE `guild_castle` ADD `gHP2` int(11) NOT NULL default '0';
-ALTER TABLE `guild_castle` ADD `gHP3` int(11) NOT NULL default '0';
-ALTER TABLE `guild_castle` ADD `gHP4` int(11) NOT NULL default '0';
-ALTER TABLE `guild_castle` ADD `gHP5` int(11) NOT NULL default '0';
-ALTER TABLE `guild_castle` ADD `gHP6` int(11) NOT NULL default '0';
-ALTER TABLE `guild_castle` ADD `gHP7` int(11) NOT NULL default '0';
-
-ALTER TABLE `guild_member` MODIFY `exp` bigint(20) NOT NULL default '0';
-
-ALTER TABLE `guild_storage` ADD `broken` int(11) NOT NULL default '0';
-
-ALTER TABLE `inventory` ADD `broken` int(11) NOT NULL default '0';
-
-ALTER TABLE `login` MODIFY `account_id` int(11) NOT NULL default '0' AUTO_INCREMENT, AUTO_INCREMENT=1000057;
-ALTER TABLE `login` MODIFY `userid` varchar(255) NOT NULL default '';
-ALTER TABLE `login` MODIFY `user_pass` varchar(32) NOT NULL default '';
-ALTER TABLE `login` ADD `error_message` int(11) NOT NULL default '0';
-ALTER TABLE `login` ADD `connect_until` int(11) NOT NULL default '0';
-ALTER TABLE `login` ADD `last_ip` varchar(100) NOT NULL default '';
-ALTER TABLE `login` ADD `memo` int(11) NOT NULL default '0';
-ALTER TABLE `login` ADD `ban_until` int(11) NOT NULL default '0';
-ALTER TABLE `login` ADD `state` int(11) NOT NULL default '0';
-ALTER TABLE `login` DROP INDEX `account_id`;
-ALTER TABLE `login` DROP INDEX `userid`;
-ALTER TABLE `login` ADD PRIMARY KEY (`account_id`), ADD INDEX `name` (`userid`);
-
-CREATE TABLE `login_error` (
- `err_id` int(11) NOT NULL default '0',
- `reason` varchar(100) NOT NULL default 'Unknown',
- PRIMARY KEY (`err_id`)
-) TYPE=MyISAM;
-
-ALTER TABLE `ragsrvinfo` DROP `type`, DROP `text1`, DROP `text2`, DROP `text3`, DROP `text4`;
-ALTER TABLE `ragsrvinfo` ADD `motd` varchar(255) NOT NULL default '';
-
-ALTER TABLE `skill` ADD PRIMARY KEY (`char_id`,`id`);
-
-ALTER TABLE `storage` ADD `broken` int(11) NOT NULL default '0';
+# Upgrade login and character server tables for eAthena 0.5.2 to 1.0 RC 2
+
+ALTER TABLE `cart_inventory` ADD `broken` int(11) NOT NULL default '0';
+
+ALTER TABLE `char` MODIFY `base_level` bigint(20) unsigned NOT NULL default '1';
+ALTER TABLE `char` MODIFY `job_level` bigint(20) unsigned NOT NULL default '1';
+ALTER TABLE `char` MODIFY `base_exp` bigint(20) NOT NULL default '0';
+ALTER TABLE `char` MODIFY `job_exp` bigint(20) NOT NULL default '0';
+ALTER TABLE `char` ADD `partner_id` int(11) NOT NULL default '0';
+
+ALTER TABLE `charlog` MODIFY `str` int(11) unsigned NOT NULL default '0';
+ALTER TABLE `charlog` MODIFY `agi` int(11) unsigned NOT NULL default '0';
+ALTER TABLE `charlog` MODIFY `vit` int(11) unsigned NOT NULL default '0';
+ALTER TABLE `charlog` MODIFY `int` int(11) unsigned NOT NULL default '0';
+ALTER TABLE `charlog` MODIFY `dex` int(11) unsigned NOT NULL default '0';
+ALTER TABLE `charlog` MODIFY `luk` int(11) unsigned NOT NULL default '0';
+
+ALTER TABLE `global_reg_value` MODIFY `value` varchar(255) NOT NULL default '0';
+ALTER TABLE `global_reg_value` ADD PRIMARY KEY (`char_id`, `str`, `account_id`);
+ALTER TABLE `global_reg_value` DROP INDEX `account_id`;
+ALTER TABLE `global_reg_value` ADD INDEX `account_id` (`account_id`);
+
+ALTER TABLE `guild_castle` ADD `gHP0` int(11) NOT NULL default '0';
+ALTER TABLE `guild_castle` ADD `gHP1` int(11) NOT NULL default '0';
+ALTER TABLE `guild_castle` ADD `gHP2` int(11) NOT NULL default '0';
+ALTER TABLE `guild_castle` ADD `gHP3` int(11) NOT NULL default '0';
+ALTER TABLE `guild_castle` ADD `gHP4` int(11) NOT NULL default '0';
+ALTER TABLE `guild_castle` ADD `gHP5` int(11) NOT NULL default '0';
+ALTER TABLE `guild_castle` ADD `gHP6` int(11) NOT NULL default '0';
+ALTER TABLE `guild_castle` ADD `gHP7` int(11) NOT NULL default '0';
+
+ALTER TABLE `guild_member` MODIFY `exp` bigint(20) NOT NULL default '0';
+
+ALTER TABLE `guild_storage` ADD `broken` int(11) NOT NULL default '0';
+
+ALTER TABLE `inventory` ADD `broken` int(11) NOT NULL default '0';
+
+ALTER TABLE `login` MODIFY `account_id` int(11) NOT NULL default '0' AUTO_INCREMENT, AUTO_INCREMENT=1000057;
+ALTER TABLE `login` MODIFY `userid` varchar(255) NOT NULL default '';
+ALTER TABLE `login` MODIFY `user_pass` varchar(32) NOT NULL default '';
+ALTER TABLE `login` ADD `error_message` int(11) NOT NULL default '0';
+ALTER TABLE `login` ADD `connect_until` int(11) NOT NULL default '0';
+ALTER TABLE `login` ADD `last_ip` varchar(100) NOT NULL default '';
+ALTER TABLE `login` ADD `memo` int(11) NOT NULL default '0';
+ALTER TABLE `login` ADD `ban_until` int(11) NOT NULL default '0';
+ALTER TABLE `login` ADD `state` int(11) NOT NULL default '0';
+ALTER TABLE `login` DROP INDEX `account_id`;
+ALTER TABLE `login` DROP INDEX `userid`;
+ALTER TABLE `login` ADD PRIMARY KEY (`account_id`), ADD INDEX `name` (`userid`);
+
+CREATE TABLE `login_error` (
+ `err_id` int(11) NOT NULL default '0',
+ `reason` varchar(100) NOT NULL default 'Unknown',
+ PRIMARY KEY (`err_id`)
+) TYPE=MyISAM;
+
+ALTER TABLE `ragsrvinfo` DROP `type`, DROP `text1`, DROP `text2`, DROP `text3`, DROP `text4`;
+ALTER TABLE `ragsrvinfo` ADD `motd` varchar(255) NOT NULL default '';
+
+ALTER TABLE `skill` ADD PRIMARY KEY (`char_id`,`id`);
+
+ALTER TABLE `storage` ADD `broken` int(11) NOT NULL default '0';
diff --git a/sql-files/upgrade_1.0.0-rc1_main.sql b/sql-files/upgrade_1.0.0-rc1_main.sql
index 4af7f6f5a..0ae05933f 100644
--- a/sql-files/upgrade_1.0.0-rc1_main.sql
+++ b/sql-files/upgrade_1.0.0-rc1_main.sql
@@ -1,3 +1,3 @@
-# Upgrade login and character server tables for eAthena 1.0 RC 1 to 1.0 RC 2
-
-ALTER TABLE `login` MODIFY `account_id` INT(11) NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=2000000;
+# Upgrade login and character server tables for eAthena 1.0 RC 1 to 1.0 RC 2
+
+ALTER TABLE `login` MODIFY `account_id` INT(11) NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=2000000;
diff --git a/sql-files/upgrade_1.0.0-rc2_database.sql b/sql-files/upgrade_1.0.0-rc2_database.sql
index ad6019df7..e1b041c97 100644
--- a/sql-files/upgrade_1.0.0-rc2_database.sql
+++ b/sql-files/upgrade_1.0.0-rc2_database.sql
@@ -1,4 +1,4 @@
-# Upgrade database tables for eAthena 1.0 RC2
-
-ALTER TABLE `item_db` MODIFY `name_english` varchar(28);
-ALTER TABLE `item_db` MODIFY `name_japanese` varchar(28);
+# Upgrade database tables for eAthena 1.0 RC2
+
+ALTER TABLE `item_db` MODIFY `name_english` varchar(28);
+ALTER TABLE `item_db` MODIFY `name_japanese` varchar(28);
diff --git a/sql-files/upgrade_1.0.0-rc5_database.sql b/sql-files/upgrade_1.0.0-rc5_database.sql
index b6f8ee6d8..8b60b7216 100644
--- a/sql-files/upgrade_1.0.0-rc5_database.sql
+++ b/sql-files/upgrade_1.0.0-rc5_database.sql
@@ -1,4 +1,4 @@
-# Upgrade database tables for eAthena 1.0 RC2
-
-ALTER TABLE `item_db` MODIFY `name_english` varchar(24);
-ALTER TABLE `item_db` MODIFY `name_japanese` varchar(24);
+# Upgrade database tables for eAthena 1.0 RC2
+
+ALTER TABLE `item_db` MODIFY `name_english` varchar(24);
+ALTER TABLE `item_db` MODIFY `name_japanese` varchar(24);
diff --git a/sql-files/upgrade_svn1759.sql b/sql-files/upgrade_svn1759.sql
index b53bc39c7..281cef6c9 100644
--- a/sql-files/upgrade_svn1759.sql
+++ b/sql-files/upgrade_svn1759.sql
@@ -1,18 +1,18 @@
-
-CREATE TABLE `chatlog` (
- `id` bigint(20) NOT NULL auto_increment,
- `time` datetime NOT NULL default '0000-00-00 00:00:00',
- `type` enum('W','P','G') NOT NULL default 'W',
- `type_id` int(11) NOT NULL default '0',
- `src_charid` int(11) NOT NULL default '0',
- `src_accountid` int(11) NOT NULL default '0',
- `src_map` varchar(17) NOT NULL default '',
- `src_map_x` tinyint(4) NOT NULL default '0',
- `src_map_y` tinyint(4) NOT NULL default '0',
- `dst_charname` varchar(25) NOT NULL default '',
- `message` varchar(150) NOT NULL default '',
- PRIMARY KEY (`id`)
-) ENGINE=MyISAM AUTO_INCREMENT=1 ;
-
-
-
+
+CREATE TABLE `chatlog` (
+ `id` bigint(20) NOT NULL auto_increment,
+ `time` datetime NOT NULL default '0000-00-00 00:00:00',
+ `type` enum('W','P','G') NOT NULL default 'W',
+ `type_id` int(11) NOT NULL default '0',
+ `src_charid` int(11) NOT NULL default '0',
+ `src_accountid` int(11) NOT NULL default '0',
+ `src_map` varchar(17) NOT NULL default '',
+ `src_map_x` tinyint(4) NOT NULL default '0',
+ `src_map_y` tinyint(4) NOT NULL default '0',
+ `dst_charname` varchar(25) NOT NULL default '',
+ `message` varchar(150) NOT NULL default '',
+ PRIMARY KEY (`id`)
+) ENGINE=MyISAM AUTO_INCREMENT=1 ;
+
+
+
diff --git a/sql-files/upgrade_svn1863.sql b/sql-files/upgrade_svn1863.sql
index 367dd44ea..f4b1b4910 100644
--- a/sql-files/upgrade_svn1863.sql
+++ b/sql-files/upgrade_svn1863.sql
@@ -1,7 +1,7 @@
-ALTER TABLE item_db ADD `refineable` tinyint(1) default NULL AFTER `equip_level`;
-ALTER TABLE item_db2 ADD `refineable` tinyint(1) default NULL AFTER `equip_level`;
-UPDATE item_db SET refineable=1 where type=4 or type=5;
-UPDATE item_db2 SET refineable=1 where type=4 or type=5;
-UPDATE item_db SET refineable = 0 where id = 1243 OR id = 1530 OR id = 2110 OR id = 2112 OR id = 2250 OR id = 2253 OR id = 2264 OR id = 2271 OR id = 2279 OR id = 2282 OR id = 2289 OR id = 2290 OR id = 2293 OR id = 2298 OR id = 2352 OR id = 2410 OR id = 2413 OR id = 2414 OR id = 2509 OR id = 2510 OR id = 5008 OR id = 5015 OR id = 5037 OR id = 5039 OR id = 5046 OR id = 5049 OR id = 5050 OR id = 5053 OR id = 5055 OR id = 5058 OR id = 5098;
-UPDATE item_db SET refineable = 0 where equip_locations = 513 OR equip_locations = 512 OR equip_locations = 136 OR equip_locations = 1;
-UPDATE item_db2 SET refineable = 0 where equip_locations = 513 OR equip_locations = 512 OR equip_locations = 136 OR equip_locations = 1;
+ALTER TABLE item_db ADD `refineable` tinyint(1) default NULL AFTER `equip_level`;
+ALTER TABLE item_db2 ADD `refineable` tinyint(1) default NULL AFTER `equip_level`;
+UPDATE item_db SET refineable=1 where type=4 or type=5;
+UPDATE item_db2 SET refineable=1 where type=4 or type=5;
+UPDATE item_db SET refineable = 0 where id = 1243 OR id = 1530 OR id = 2110 OR id = 2112 OR id = 2250 OR id = 2253 OR id = 2264 OR id = 2271 OR id = 2279 OR id = 2282 OR id = 2289 OR id = 2290 OR id = 2293 OR id = 2298 OR id = 2352 OR id = 2410 OR id = 2413 OR id = 2414 OR id = 2509 OR id = 2510 OR id = 5008 OR id = 5015 OR id = 5037 OR id = 5039 OR id = 5046 OR id = 5049 OR id = 5050 OR id = 5053 OR id = 5055 OR id = 5058 OR id = 5098;
+UPDATE item_db SET refineable = 0 where equip_locations = 513 OR equip_locations = 512 OR equip_locations = 136 OR equip_locations = 1;
+UPDATE item_db2 SET refineable = 0 where equip_locations = 513 OR equip_locations = 512 OR equip_locations = 136 OR equip_locations = 1;
diff --git a/sql-files/upgrade_svn2068.sql b/sql-files/upgrade_svn2068.sql
index c0ce870aa..33de1848c 100644
--- a/sql-files/upgrade_svn2068.sql
+++ b/sql-files/upgrade_svn2068.sql
@@ -1,3 +1,3 @@
-update mob_db set aMotion="185" where id=1275;
-update mob_db set aMotion="160" where id=1200;
-update mob_db set aMotion="160" where id=1482;
+update mob_db set aMotion="185" where id=1275;
+update mob_db set aMotion="160" where id=1200;
+update mob_db set aMotion="160" where id=1482;
diff --git a/sql-files/upgrade_svn2252.sql b/sql-files/upgrade_svn2252.sql
index 870a57144..c1d3884f1 100644
--- a/sql-files/upgrade_svn2252.sql
+++ b/sql-files/upgrade_svn2252.sql
@@ -1,14 +1,14 @@
-################################
-# NEW friend table #
-# NOTE -> if you dont write a #
-# converter, all your friends #
-# will be deleted #
-################################
-
-DROP TABLE `friends`;
-
-CREATE TABLE `friends` (
- `char_id` int(11) NOT NULL default '0',
- `friend_id` int(11) NOT NULL default '0'
-) TYPE=MyISAM;
-
+################################
+# NEW friend table #
+# NOTE -> if you dont write a #
+# converter, all your friends #
+# will be deleted #
+################################
+
+DROP TABLE `friends`;
+
+CREATE TABLE `friends` (
+ `char_id` int(11) NOT NULL default '0',
+ `friend_id` int(11) NOT NULL default '0'
+) TYPE=MyISAM;
+
diff --git a/sql-files/upgrade_svn2331.sql b/sql-files/upgrade_svn2331.sql
index 99b38ad61..e45c42185 100644
--- a/sql-files/upgrade_svn2331.sql
+++ b/sql-files/upgrade_svn2331.sql
@@ -1,3 +1,3 @@
-ALTER TABLE guild_position
-ADD CONSTRAINT `guild_position_ibfk_1` FOREIGN KEY (`guild_id`)
-REFERENCES `guild` (`guild_id`) ON DELETE CASCADE
+ALTER TABLE guild_position
+ADD CONSTRAINT `guild_position_ibfk_1` FOREIGN KEY (`guild_id`)
+REFERENCES `guild` (`guild_id`) ON DELETE CASCADE
diff --git a/sql-files/upgrade_svn2574.sql b/sql-files/upgrade_svn2574.sql
index 3804f0beb..35e444106 100644
--- a/sql-files/upgrade_svn2574.sql
+++ b/sql-files/upgrade_svn2574.sql
@@ -1,2 +1,2 @@
-ALTER TABLE friends ADD `friend_account` int(11) NOT NULL default 0 AFTER `char_id`;
-UPDATE friends, `char` SET friends.friend_account=`char`.account_id where friends.friend_id=`char`.char_id;
+ALTER TABLE friends ADD `friend_account` int(11) NOT NULL default 0 AFTER `char_id`;
+UPDATE friends, `char` SET friends.friend_account=`char`.account_id where friends.friend_id=`char`.char_id;
diff --git a/sql-files/upgrade_svn3273.sql b/sql-files/upgrade_svn3273.sql
index 4bf99f48c..c9e88d761 100644
--- a/sql-files/upgrade_svn3273.sql
+++ b/sql-files/upgrade_svn3273.sql
@@ -1,12 +1,12 @@
-CREATE TABLE `sc_data` (
- `account_id` int(11) unsigned NOT NULL,
- `char_id` int(11) unsigned NOT NULL,
- `type` smallint(11) unsigned NOT NULL,
- `tick` int(11) NOT NULL,
- `val1` int(11) NOT NULL default '0',
- `val2` int(11) NOT NULL default '0',
- `val3` int(11) NOT NULL default '0',
- `val4` int(11) NOT NULL default '0',
- CONSTRAINT `scdata_ibfk_1` FOREIGN KEY (`account_id`) REFERENCES `login` (`account_id`) ON DELETE CASCADE,
- CONSTRAINT `scdata_ibfk_2` FOREIGN KEY (`char_id`) REFERENCES `char` (`char_id`) ON DELETE CASCADE
-) TYPE=InnoDB;
+CREATE TABLE `sc_data` (
+ `account_id` int(11) unsigned NOT NULL,
+ `char_id` int(11) unsigned NOT NULL,
+ `type` smallint(11) unsigned NOT NULL,
+ `tick` int(11) NOT NULL,
+ `val1` int(11) NOT NULL default '0',
+ `val2` int(11) NOT NULL default '0',
+ `val3` int(11) NOT NULL default '0',
+ `val4` int(11) NOT NULL default '0',
+ CONSTRAINT `scdata_ibfk_1` FOREIGN KEY (`account_id`) REFERENCES `login` (`account_id`) ON DELETE CASCADE,
+ CONSTRAINT `scdata_ibfk_2` FOREIGN KEY (`char_id`) REFERENCES `char` (`char_id`) ON DELETE CASCADE
+) TYPE=InnoDB;
diff --git a/sql-files/upgrade_svn3746.sql b/sql-files/upgrade_svn3746.sql
index de5bcb558..893568358 100644
--- a/sql-files/upgrade_svn3746.sql
+++ b/sql-files/upgrade_svn3746.sql
@@ -1 +1 @@
-ALTER TABLE `char` MODIFY `manner` tinyint(11) NOT NULL default '0';
+ALTER TABLE `char` MODIFY `manner` tinyint(11) NOT NULL default '0';
diff --git a/sql-files/upgrade_svn4367.sql b/sql-files/upgrade_svn4367.sql
index 1dd63d63f..d0b52f9f4 100644
--- a/sql-files/upgrade_svn4367.sql
+++ b/sql-files/upgrade_svn4367.sql
@@ -1,9 +1,9 @@
-DROP TABLE IF EXISTS `mapreg`;
-CREATE TABLE `mapreg` (
- `varname` char(32) NOT NULL,
- `index` int(11) unsigned NOT NULL default '0',
- `value` char(255) NOT NULL
-) TYPE=MyISAM;
-
-ALTER TABLE `mapreg` ADD INDEX ( `varname` );
-ALTER TABLE `mapreg` ADD INDEX ( `index` );
+DROP TABLE IF EXISTS `mapreg`;
+CREATE TABLE `mapreg` (
+ `varname` char(32) NOT NULL,
+ `index` int(11) unsigned NOT NULL default '0',
+ `value` char(255) NOT NULL
+) TYPE=MyISAM;
+
+ALTER TABLE `mapreg` ADD INDEX ( `varname` );
+ALTER TABLE `mapreg` ADD INDEX ( `index` );
diff --git a/sql-files/upgrade_svn4941.sql b/sql-files/upgrade_svn4941.sql
index 29c4bf404..93037ef0c 100644
--- a/sql-files/upgrade_svn4941.sql
+++ b/sql-files/upgrade_svn4941.sql
@@ -1,6 +1,6 @@
-ALTER TABLE `char` MODIFY `last_map` varchar(20) NOT NULL default 'prontera.gat';
-ALTER TABLE `char` MODIFY `last_x` smallint(11) unsigned NOT NULL default '53';
-ALTER TABLE `char` MODIFY `last_y` smallint(11) unsigned NOT NULL default '111';
-ALTER TABLE `char` MODIFY `save_map` varchar(20) NOT NULL default 'prontera.gat';
-ALTER TABLE `char` MODIFY `save_x` smallint(11) unsigned NOT NULL default '53';
+ALTER TABLE `char` MODIFY `last_map` varchar(20) NOT NULL default 'prontera.gat';
+ALTER TABLE `char` MODIFY `last_x` smallint(11) unsigned NOT NULL default '53';
+ALTER TABLE `char` MODIFY `last_y` smallint(11) unsigned NOT NULL default '111';
+ALTER TABLE `char` MODIFY `save_map` varchar(20) NOT NULL default 'prontera.gat';
+ALTER TABLE `char` MODIFY `save_x` smallint(11) unsigned NOT NULL default '53';
ALTER TABLE `char` MODIFY `save_y` smallint(11) unsigned NOT NULL default '111'; \ No newline at end of file
diff --git a/sql-files/upgrade_svn5311.sql b/sql-files/upgrade_svn5311.sql
index e7b4db9a4..38bbbea3a 100644
--- a/sql-files/upgrade_svn5311.sql
+++ b/sql-files/upgrade_svn5311.sql
@@ -1 +1 @@
-ALTER TABLE `party` MODIFY `party_id` int(11) unsigned NOT NULL auto_increment;
+ALTER TABLE `party` MODIFY `party_id` int(11) unsigned NOT NULL auto_increment;
diff --git a/sql-files/upgrade_svn5322.sql b/sql-files/upgrade_svn5322.sql
index 6b801a1b3..a06d90326 100644
--- a/sql-files/upgrade_svn5322.sql
+++ b/sql-files/upgrade_svn5322.sql
@@ -1 +1 @@
-ALTER TABLE `guild` MODIFY `guild_id` int(11) unsigned NOT NULL auto_increment;
+ALTER TABLE `guild` MODIFY `guild_id` int(11) unsigned NOT NULL auto_increment;
diff --git a/sql-files/upgrade_svn5455.sql b/sql-files/upgrade_svn5455.sql
index 8d324230c..6c79a5159 100644
--- a/sql-files/upgrade_svn5455.sql
+++ b/sql-files/upgrade_svn5455.sql
@@ -1,2 +1,2 @@
-ALTER TABLE `char` MODIFY `karma` tinyint(3) NOT NULL default '0';
-ALTER TABLE `char` MODIFY `manner` tinyint(3) NOT NULL default '0';
+ALTER TABLE `char` MODIFY `karma` tinyint(3) NOT NULL default '0';
+ALTER TABLE `char` MODIFY `manner` tinyint(3) NOT NULL default '0';
diff --git a/sql-files/upgrade_svn5607.sql b/sql-files/upgrade_svn5607.sql
index 7c3f88527..51dae2c75 100644
--- a/sql-files/upgrade_svn5607.sql
+++ b/sql-files/upgrade_svn5607.sql
@@ -1 +1 @@
-ALTER TABLE `guild` MODIFY `average_lv` smallint(6) unsigned NOT NULL default '1';
+ALTER TABLE `guild` MODIFY `average_lv` smallint(6) unsigned NOT NULL default '1';
diff --git a/sql-files/upgrade_svn5834.sql b/sql-files/upgrade_svn5834.sql
index 2966b820e..467bc24bb 100644
--- a/sql-files/upgrade_svn5834.sql
+++ b/sql-files/upgrade_svn5834.sql
@@ -1 +1 @@
-UPDATE `item_db` SET `view`=1 where `type` = 10;
+UPDATE `item_db` SET `view`=1 where `type` = 10;
diff --git a/sql-files/upgrade_svn5902.sql b/sql-files/upgrade_svn5902.sql
index 174f512c5..382f92eb6 100644
--- a/sql-files/upgrade_svn5902.sql
+++ b/sql-files/upgrade_svn5902.sql
@@ -1,14 +1,14 @@
-update `char` set `class`='7' where `class`='13';
-update `char` set `class`='14' where `class`='21';
-update `char` set `class`='4008' where `class`='4014';
-update `char` set `class`='4015' where `class`='4022';
-update `char` set `class`='4030' where `class`='4036';
-update `char` set `class`='4037' where `class`='4044';
-update `char` set `class`='4047' where `class`='4048';
-update `guild_member` set `class`='7' where `class`='13';
-update `guild_member` set `class`='14' where `class`='21';
-update `guild_member` set `class`='4008' where `class`='4014';
-update `guild_member` set `class`='4015' where `class`='4022';
-update `guild_member` set `class`='4030' where `class`='4036';
-update `guild_member` set `class`='4037' where `class`='4044';
-update `guild_member` set `class`='4047' where `class`='4048';
+update `char` set `class`='7' where `class`='13';
+update `char` set `class`='14' where `class`='21';
+update `char` set `class`='4008' where `class`='4014';
+update `char` set `class`='4015' where `class`='4022';
+update `char` set `class`='4030' where `class`='4036';
+update `char` set `class`='4037' where `class`='4044';
+update `char` set `class`='4047' where `class`='4048';
+update `guild_member` set `class`='7' where `class`='13';
+update `guild_member` set `class`='14' where `class`='21';
+update `guild_member` set `class`='4008' where `class`='4014';
+update `guild_member` set `class`='4015' where `class`='4022';
+update `guild_member` set `class`='4030' where `class`='4036';
+update `guild_member` set `class`='4037' where `class`='4044';
+update `guild_member` set `class`='4047' where `class`='4048';
diff --git a/sql-files/upgrade_svn6533.sql b/sql-files/upgrade_svn6533.sql
index 60550dbe6..28ca04c50 100644
--- a/sql-files/upgrade_svn6533.sql
+++ b/sql-files/upgrade_svn6533.sql
@@ -1,2 +1,2 @@
-ALTER TABLE `loginlog` CHANGE `ip` `ip` CHAR( 15 ) NOT NULL;
-ALTER TABLE `loginlog` ADD INDEX ( `ip` ( 15 ) );
+ALTER TABLE `loginlog` CHANGE `ip` `ip` CHAR( 15 ) NOT NULL;
+ALTER TABLE `loginlog` ADD INDEX ( `ip` ( 15 ) );
diff --git a/sql-files/upgrade_svn6868.sql b/sql-files/upgrade_svn6868.sql
index 000237297..47f89b1a3 100644
--- a/sql-files/upgrade_svn6868.sql
+++ b/sql-files/upgrade_svn6868.sql
@@ -1,2 +1,2 @@
-UPDATE `loginlog` SET `ip` = inet_aton(`ip`);
+UPDATE `loginlog` SET `ip` = inet_aton(`ip`);
ALTER TABLE `loginlog` CHANGE `ip` `ip` INT( 10 ) UNSIGNED ZEROFILL NOT NULL DEFAULT '0'; \ No newline at end of file
diff --git a/sql-files/upgrade_svn7146.sql b/sql-files/upgrade_svn7146.sql
index d639229dc..f608ab273 100644
--- a/sql-files/upgrade_svn7146.sql
+++ b/sql-files/upgrade_svn7146.sql
@@ -1 +1 @@
-ALTER TABLE `char` ADD INDEX ( `account_id` );
+ALTER TABLE `char` ADD INDEX ( `account_id` );
diff --git a/sql-files/upgrade_svn7580.sql b/sql-files/upgrade_svn7580.sql
index 0df8894d0..e383d2f0e 100644
--- a/sql-files/upgrade_svn7580.sql
+++ b/sql-files/upgrade_svn7580.sql
@@ -1,2 +1,2 @@
-ALTER TABLE `char` MODIFY `party_id` int(11) unsigned NOT NULL default '0';
-ALTER TABLE `char` MODIFY `guild_id` int(11) unsigned NOT NULL default '0';
+ALTER TABLE `char` MODIFY `party_id` int(11) unsigned NOT NULL default '0';
+ALTER TABLE `char` MODIFY `guild_id` int(11) unsigned NOT NULL default '0';
diff --git a/sql-files/upgrade_svn7706.sql b/sql-files/upgrade_svn7706.sql
index afd91d220..0e847ad27 100644
--- a/sql-files/upgrade_svn7706.sql
+++ b/sql-files/upgrade_svn7706.sql
@@ -1,36 +1,36 @@
-ALTER TABLE `char` ADD `homun_id` int(11) unsigned NOT NULL default '0' AFTER `pet_id`;
-
-DROP TABLE IF EXISTS `homunculus`;
-CREATE TABLE `homunculus` (
- `homun_id` int(11) NOT NULL auto_increment,
- `char_id` int(11) NOT NULL,
- `class` mediumint(9) unsigned NOT NULL default '0',
- `name` varchar(24) NOT NULL default '',
- `level` smallint(4) NOT NULL default '0',
- `exp` int(12) NOT NULL default '0',
- `intimacy` int(12) NOT NULL default '0',
- `hunger` smallint(4) NOT NULL default '0',
- `str` smallint(4) unsigned NOT NULL default '0',
- `agi` smallint(4) unsigned NOT NULL default '0',
- `vit` smallint(4) unsigned NOT NULL default '0',
- `int` smallint(4) unsigned NOT NULL default '0',
- `dex` smallint(4) unsigned NOT NULL default '0',
- `luk` smallint(4) unsigned NOT NULL default '0',
- `hp` int(12) NOT NULL default '1',
- `max_hp` int(12) NOT NULL default '1',
- `sp` int(12) NOT NULL default '1',
- `max_sp` int(12) NOT NULL default '1',
- `skill_point` smallint(4) unsigned NOT NULL default '0',
- `alive` tinyint(2) NOT NULL default '1',
- `rename_flag` tinyint(2) NOT NULL default '0',
- `vaporize` tinyint(2) NOT NULL default '0',
- PRIMARY KEY (`homun_id`)
-) ENGINE=InnoDB DEFAULT CHARSET=latin1;
-
-
-CREATE TABLE `skill_homunculus` (
- `homun_id` int(11) NOT NULL,
- `id` int(11) NOT NULL,
- `lv` smallint(6) NOT NULL,
- PRIMARY KEY (`homun_id`)
-) ENGINE=InnoDB DEFAULT CHARSET=latin1;
+ALTER TABLE `char` ADD `homun_id` int(11) unsigned NOT NULL default '0' AFTER `pet_id`;
+
+DROP TABLE IF EXISTS `homunculus`;
+CREATE TABLE `homunculus` (
+ `homun_id` int(11) NOT NULL auto_increment,
+ `char_id` int(11) NOT NULL,
+ `class` mediumint(9) unsigned NOT NULL default '0',
+ `name` varchar(24) NOT NULL default '',
+ `level` smallint(4) NOT NULL default '0',
+ `exp` int(12) NOT NULL default '0',
+ `intimacy` int(12) NOT NULL default '0',
+ `hunger` smallint(4) NOT NULL default '0',
+ `str` smallint(4) unsigned NOT NULL default '0',
+ `agi` smallint(4) unsigned NOT NULL default '0',
+ `vit` smallint(4) unsigned NOT NULL default '0',
+ `int` smallint(4) unsigned NOT NULL default '0',
+ `dex` smallint(4) unsigned NOT NULL default '0',
+ `luk` smallint(4) unsigned NOT NULL default '0',
+ `hp` int(12) NOT NULL default '1',
+ `max_hp` int(12) NOT NULL default '1',
+ `sp` int(12) NOT NULL default '1',
+ `max_sp` int(12) NOT NULL default '1',
+ `skill_point` smallint(4) unsigned NOT NULL default '0',
+ `alive` tinyint(2) NOT NULL default '1',
+ `rename_flag` tinyint(2) NOT NULL default '0',
+ `vaporize` tinyint(2) NOT NULL default '0',
+ PRIMARY KEY (`homun_id`)
+) ENGINE=InnoDB DEFAULT CHARSET=latin1;
+
+
+CREATE TABLE `skill_homunculus` (
+ `homun_id` int(11) NOT NULL,
+ `id` int(11) NOT NULL,
+ `lv` smallint(6) NOT NULL,
+ PRIMARY KEY (`homun_id`)
+) ENGINE=InnoDB DEFAULT CHARSET=latin1;
diff --git a/sql-files/upgrade_svn7768.sql b/sql-files/upgrade_svn7768.sql
index 69f6f1333..c04d03973 100644
--- a/sql-files/upgrade_svn7768.sql
+++ b/sql-files/upgrade_svn7768.sql
@@ -1,8 +1,8 @@
-DROP TABLE IF EXISTS `skill_homunculus`;
-CREATE TABLE `skill_homunculus` (
- `homun_id` int(11) NOT NULL,
- `id` int(11) NOT NULL,
- `lv` smallint(6) NOT NULL,
- PRIMARY KEY (`homun_id`,`id`),
- KEY `homun_id` (`homun_id`)
+DROP TABLE IF EXISTS `skill_homunculus`;
+CREATE TABLE `skill_homunculus` (
+ `homun_id` int(11) NOT NULL,
+ `id` int(11) NOT NULL,
+ `lv` smallint(6) NOT NULL,
+ PRIMARY KEY (`homun_id`,`id`),
+ KEY `homun_id` (`homun_id`)
) TYPE=MyISAM; \ No newline at end of file
diff --git a/sql-files/upgrade_svn8630.sql b/sql-files/upgrade_svn8630.sql
index a94dbf116..33e218eb2 100644
--- a/sql-files/upgrade_svn8630.sql
+++ b/sql-files/upgrade_svn8630.sql
@@ -1 +1 @@
-ALTER TABLE `login` MODIFY `connect_until` int(11) unsigned NOT NULL default '0';
+ALTER TABLE `login` MODIFY `connect_until` int(11) unsigned NOT NULL default '0';
diff --git a/sql-files/upgrade_svn8675.sql b/sql-files/upgrade_svn8675.sql
index 5f6d15299..1499a748b 100644
--- a/sql-files/upgrade_svn8675.sql
+++ b/sql-files/upgrade_svn8675.sql
@@ -1 +1 @@
-ALTER TABLE `guild` MODIFY `emblem_data` blob;
+ALTER TABLE `guild` MODIFY `emblem_data` blob;
diff --git a/sql-files/upgrade_svn8728.sql b/sql-files/upgrade_svn8728.sql
index 71558893f..5a45f87c4 100644
--- a/sql-files/upgrade_svn8728.sql
+++ b/sql-files/upgrade_svn8728.sql
@@ -1,4 +1,4 @@
-ALTER TABLE `friends` ADD INDEX ( `char_id` );
-ALTER TABLE `memo` ADD INDEX ( `char_id` );
-ALTER TABLE `char` ADD INDEX ( `name` );
-ALTER TABLE `char` ADD INDEX ( `online` );
+ALTER TABLE `friends` ADD INDEX ( `char_id` );
+ALTER TABLE `memo` ADD INDEX ( `char_id` );
+ALTER TABLE `char` ADD INDEX ( `name` );
+ALTER TABLE `char` ADD INDEX ( `online` );
diff --git a/sql-files/upgrade_svn9050.sql b/sql-files/upgrade_svn9050.sql
index 932bc3b38..2e0c72489 100644
--- a/sql-files/upgrade_svn9050.sql
+++ b/sql-files/upgrade_svn9050.sql
@@ -1,6 +1,6 @@
-ALTER TABLE `picklog` ADD INDEX (`type`);
-ALTER TABLE `zenylog` ADD INDEX (`type`);
-ALTER TABLE `branchlog` ADD INDEX (`account_id`), ADD INDEX (`char_id`);
-ALTER TABLE `atcommandlog` ADD INDEX (`account_id`), ADD INDEX (`char_id`);
-ALTER TABLE `npclog` ADD INDEX (`account_id`), ADD INDEX (`char_id`);
-ALTER TABLE `chatlog` ADD INDEX (`src_accountid`), ADD INDEX (`src_charid`);
+ALTER TABLE `picklog` ADD INDEX (`type`);
+ALTER TABLE `zenylog` ADD INDEX (`type`);
+ALTER TABLE `branchlog` ADD INDEX (`account_id`), ADD INDEX (`char_id`);
+ALTER TABLE `atcommandlog` ADD INDEX (`account_id`), ADD INDEX (`char_id`);
+ALTER TABLE `npclog` ADD INDEX (`account_id`), ADD INDEX (`char_id`);
+ALTER TABLE `chatlog` ADD INDEX (`src_accountid`), ADD INDEX (`src_charid`);
diff --git a/sql-files/upgrade_svn9135.sql b/sql-files/upgrade_svn9135.sql
index 0647bc452..4b618a5ad 100644
--- a/sql-files/upgrade_svn9135.sql
+++ b/sql-files/upgrade_svn9135.sql
@@ -1,2 +1,2 @@
-alter table `item_db` modify `view` smallint(3) unsigned default null;
+alter table `item_db` modify `view` smallint(3) unsigned default null;
alter table `item_db2` modify `view` smallint(3) unsigned default null; \ No newline at end of file