-
Notifications
You must be signed in to change notification settings - Fork 757
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Added rAthena to Hercules main database upgrader.
This has been added because a lot of people were suggesting this on the forums. Check the news topic for more info: http://hercules.ws/board/topic/2906-introducing-rathena-to-hercules-database-converters/?p=19260
- Loading branch information
Showing
1 changed file
with
80 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,80 @@ | ||
-- rAthena to Hercules main database upgrade query. | ||
-- This upgrades a FULLY UPGRADED rAthena to a FULLY UPGRADED Hercules | ||
-- Please don't use if either rAthena or Hercules launched a SQL update after last revision date of this file. | ||
-- Remember to make a backup before applying. | ||
-- We are not liable for any data loss this may cause. | ||
-- Apply in the same database you applied your main.sql | ||
-- Last revision: November 10, 2013, 19:00 | ||
|
||
|
||
-- Drop table `skillcooldown` since it's not used in Hercules | ||
DROP TABLE IF EXISTS `skillcooldown`; | ||
|
||
-- Upgrades for table `cart_inventory` | ||
ALTER TABLE `cart_inventory` MODIFY `equip` INT(11) UNSIGNED NOT NULL default '0', | ||
MODIFY `bound` tinyint(1) unsigned NOT NULL default '0'; | ||
|
||
-- Upgrades for table `char` | ||
ALTER TABLE `char` DROP COLUMN `moves`, | ||
ADD `slotchange` SMALLINT(3) UNSIGNED NOT NULL default '0', | ||
ADD `char_opt` INT( 11 ) UNSIGNED NOT NULL default '0', | ||
ADD `font` TINYINT( 3 ) UNSIGNED NOT NULL DEFAULT '0'; | ||
|
||
-- Upgrades for table `guild_storage` | ||
ALTER TABLE `guild_storage` MODIFY `equip` INT(11) UNSIGNED NOT NULL default '0', | ||
MODIFY `bound` tinyint(1) unsigned NOT NULL default '0'; | ||
|
||
-- Upgrades for table `inventory` | ||
ALTER TABLE `inventory` MODIFY `equip` INT(11) UNSIGNED NOT NULL default '0', | ||
MODIFY `bound` tinyint(1) unsigned NOT NULL default '0'; | ||
|
||
-- | ||
-- Table structure for table `sql_updates` | ||
-- | ||
CREATE TABLE IF NOT EXISTS `sql_updates` ( | ||
`timestamp` int(11) unsigned NOT NULL, | ||
`ignored` enum('Yes','No') NOT NULL DEFAULT 'No', | ||
PRIMARY KEY (`timestamp`) | ||
) ENGINE=MyISAM; | ||
|
||
-- Existent updates to enter | ||
INSERT INTO `sql_updates` (`timestamp`) VALUES (1360858500); | ||
INSERT INTO `sql_updates` (`timestamp`) VALUES (1360951560); | ||
INSERT INTO `sql_updates` (`timestamp`) VALUES (1362445531); | ||
INSERT INTO `sql_updates` (`timestamp`) VALUES (1362528000); | ||
INSERT INTO `sql_updates` (`timestamp`) VALUES (1362794218); | ||
INSERT INTO `sql_updates` (`timestamp`) VALUES (1364409316); | ||
INSERT INTO `sql_updates` (`timestamp`) VALUES (1366075474); | ||
INSERT INTO `sql_updates` (`timestamp`) VALUES (1366078541); | ||
INSERT INTO `sql_updates` (`timestamp`) VALUES (1381354728); | ||
INSERT INTO `sql_updates` (`timestamp`) VALUES (1381423003); | ||
INSERT INTO `sql_updates` (`timestamp`) VALUES (1382892428); | ||
INSERT INTO `sql_updates` (`timestamp`) VALUES (1383162785); | ||
INSERT INTO `sql_updates` (`timestamp`) VALUES (1383167577); | ||
INSERT INTO `sql_updates` (`timestamp`) VALUES (1383205740); | ||
INSERT INTO `sql_updates` (`timestamp`) VALUES (1383955424); | ||
|
||
-- Updates to table `storage` | ||
ALTER TABLE `storage` MODIFY `equip` INT(11) UNSIGNED NOT NULL default '0', | ||
MODIFY `bound` tinyint(1) unsigned NOT NULL default '0'; | ||
|
||
-- | ||
-- Table structure for table `account_data` | ||
-- | ||
|
||
CREATE TABLE IF NOT EXISTS `account_data` ( | ||
`account_id` int(11) unsigned NOT NULL default '0', | ||
`bank_vault` int(11) unsigned NOT NULL default '0', | ||
`base_exp` TINYINT( 4 ) UNSIGNED NOT NULL default '100', | ||
`base_drop` TINYINT( 4 ) UNSIGNED NOT NULL default '100', | ||
`base_death` TINYINT( 4 ) UNSIGNED NOT NULL default '100', | ||
PRIMARY KEY (`account_id`) | ||
) ENGINE=MyISAM; | ||
|
||
-- Saving bank_vault data from rAthena's login table | ||
-- to our account_data table. There may be some not working cases. | ||
|
||
INSERT INTO `account_data` (`account_id`, `bank_vault`) SELECT `account_id`, `bank_vault` FROM `login` WHERE `bank_vault` > 0 ; | ||
|
||
-- Dropping bank_vault column from login table | ||
ALTER TABLE `login` DROP COLUMN `bank_vault`; |