Свернуть ↑
-- ----------------------------
-- Table structure for `accounts`
-- ----------------------------
DROP TABLE IF EXISTS `accounts`;
CREATE TABLE `accounts` (
`login` varchar(45) NOT NULL DEFAULT '',
`password` varchar(100) DEFAULT '',
`lastactive` int(15) unsigned NOT NULL DEFAULT '0',
`access_level` tinyint(6) NOT NULL DEFAULT '0',
`lastIP` varchar(15) DEFAULT '',
`lastServer` int(4) DEFAULT '1',
`comments` text,
`email` varchar(45) NOT NULL DEFAULT 'null@null',
`pay_stat` tinyint(1) NOT NULL DEFAULT '1',
`bonus` float NOT NULL DEFAULT '1',
`bonus_expire` int(11) NOT NULL DEFAULT '0',
`banExpires` int(11) NOT NULL DEFAULT '0',
`AllowIPs` varchar(256) NOT NULL DEFAULT '*',
`lock_expire` int(11) NOT NULL DEFAULT '604800',
PRIMARY KEY (`login`),
KEY `bonus` (`bonus`),
KEY `access_level` (`access_level`),
KEY `pay_stat` (`pay_stat`)
) ENGINE=MyISAM DEFAULT CHARSET=latin1;
-- ----------------------------
-- Table structure for `castle`
-- ----------------------------
DROP TABLE IF EXISTS `castle`;
CREATE TABLE `castle` (
`id` tinyint(3) unsigned NOT NULL DEFAULT '0',
`name` varchar(25) NOT NULL,
`taxPercent` tinyint(3) unsigned NOT NULL DEFAULT '15',
`treasury` bigint(20) unsigned NOT NULL DEFAULT '0',
`siegeDate` int(10) unsigned NOT NULL DEFAULT '0',
`siegeDayOfWeek` tinyint(3) unsigned NOT NULL DEFAULT '7',
`siegeHourOfDay` tinyint(3) unsigned NOT NULL DEFAULT '20',
`townId` tinyint(3) unsigned NOT NULL DEFAULT '0',
`skills` varchar(32) NOT NULL DEFAULT '0;0',
`ownDate` int(11) NOT NULL DEFAULT '0',
PRIMARY KEY (`name`),
KEY `id` (`id`)
) ENGINE=MyISAM DEFAULT CHARSET=latin1;
-- ----------------------------
-- Table structure for `clan_data`
-- ----------------------------
DROP TABLE IF EXISTS `clan_data`;
CREATE TABLE `clan_data` (
`clan_id` int(11) NOT NULL DEFAULT '0',
`clan_name` varchar(45) CHARACTER SET utf8 DEFAULT NULL,
`clan_level` tinyint(3) unsigned NOT NULL DEFAULT '0',
`hasCastle` tinyint(3) unsigned NOT NULL DEFAULT '0',
`hasFortress` tinyint(3) unsigned NOT NULL DEFAULT '0',
`hasHideout` tinyint(3) unsigned NOT NULL DEFAULT '0',
`ally_id` int(11) NOT NULL DEFAULT '0',
`leader_id` int(11) NOT NULL DEFAULT '0',
`crest` varbinary(256) DEFAULT NULL,
`largecrest` varbinary(8192) DEFAULT NULL,
`reputation_score` int(11) NOT NULL DEFAULT '0',
`warehouse` int(11) NOT NULL DEFAULT '0',
`expelled_member` int(10) unsigned NOT NULL DEFAULT '0',
`leaved_ally` int(10) unsigned NOT NULL DEFAULT '0',
`dissolved_ally` int(10) unsigned NOT NULL DEFAULT '0',
`auction_bid_at` int(11) NOT NULL DEFAULT '0',
PRIMARY KEY (`clan_id`),
KEY `leader_id` (`leader_id`),
KEY `ally_id` (`ally_id`)
) ENGINE=MyISAM DEFAULT CHARSET=latin1;
-- ----------------------------
-- Table structure for `items`
-- ----------------------------
DROP TABLE IF EXISTS `items`;
CREATE TABLE `items` (
`object_id` int(11) NOT NULL DEFAULT '0',
`owner_id` int(11) NOT NULL,
`item_id` smallint(5) unsigned NOT NULL DEFAULT '0',
`name` varchar(65) DEFAULT NULL,
`count` bigint(20) unsigned NOT NULL DEFAULT '0',
`enchant_level` smallint(5) unsigned NOT NULL DEFAULT '0',
`class` enum('CONSUMABLE','MISC','EQUIPMENT','MATHERIALS', 'OTHER','PIECES','RECIPIES','SPELLBOOKS') NOT NULL DEFAULT 'OTHER',
`loc` enum('CLANWH','CWH_BACK','FREIGHT','INVENTORY','LE ASE','PAPERDOLL','VOID','WAREHOUSE','MONSTER') NOT NULL,
`loc_data` int(11) DEFAULT NULL,
`custom_type1` smallint(5) unsigned NOT NULL DEFAULT '0',
`custom_type2` smallint(5) unsigned NOT NULL DEFAULT '0',
`shadow_life_time` int(11) NOT NULL DEFAULT '0',
`flags` int(11) NOT NULL DEFAULT '0',
PRIMARY KEY (`object_id`),
KEY `key_owner_id` (`owner_id`),
KEY `key_loc` (`loc`),
KEY `key_item_id` (`item_id`),
KEY `key_class` (`class`),
KEY `key_loc_data` (`loc_data`)
) ENGINE=MyISAM DEFAULT CHARSET=latin1;
-- ----------------------------
-- Table structure for `npc`
-- ----------------------------
DROP TABLE IF EXISTS `npc`;
CREATE TABLE `npc` (
`ordinal` smallint(4) unsigned NOT NULL DEFAULT '0',
`id` int(11) unsigned NOT NULL DEFAULT '0',
`name` varchar(45) DEFAULT NULL,
`title` varchar(35) NOT NULL,
`class` varchar(50) DEFAULT NULL,
`collision_radius` decimal(5,2) DEFAULT NULL,
`collision_height` decimal(5,2) DEFAULT NULL,
`level` int(11) NOT NULL DEFAULT '1',
`sex` varchar(6) NOT NULL DEFAULT 'male',
`type` varchar(20) NOT NULL DEFAULT 'L2Npc',
`ai_type` varchar(50) NOT NULL DEFAULT 'npc',
`attackrange` int(11) NOT NULL DEFAULT '40',
`hp` int(11) NOT NULL DEFAULT '2444',
`base_hp_regen` double(11,3) NOT NULL DEFAULT '7.500',
`mp` int(11) NOT NULL DEFAULT '2444',
`base_mp_regen` double(11,3) NOT NULL DEFAULT '2.700',
`str` int(11) NOT NULL DEFAULT '40',
`con` int(11) NOT NULL DEFAULT '43',
`dex` int(11) NOT NULL DEFAULT '30',
`int` int(11) NOT NULL DEFAULT '21',
`wit` int(11) NOT NULL DEFAULT '20',
`men` int(11) NOT NULL DEFAULT '10',
`exp` int(11) NOT NULL DEFAULT '0',
`sp` int(11) NOT NULL DEFAULT '0',
`patk` int(11) NOT NULL DEFAULT '500',
`pdef` int(11) NOT NULL DEFAULT '500',
`matk` int(11) NOT NULL DEFAULT '500',
`mdef` int(11) NOT NULL DEFAULT '500',
`atkspd` int(11) NOT NULL DEFAULT '253',
`aggro` int(11) NOT NULL DEFAULT '0',
`matkspd` int(11) NOT NULL DEFAULT '500',
`rhand` int(11) NOT NULL DEFAULT '0',
`lhand` int(11) NOT NULL DEFAULT '0',
`armor` int(11) NOT NULL DEFAULT '0',
`walkspd` int(11) NOT NULL DEFAULT '110',
`runspd` int(11) NOT NULL DEFAULT '180',
`faction_id` varchar(40) NOT NULL,
`faction_range` int(11) NOT NULL DEFAULT '0',
`displayId` int(11) NOT NULL DEFAULT '0',
`shield_defense_rate` int(11) NOT NULL DEFAULT '0',
`shield_defense` int(11) NOT NULL DEFAULT '0',
`corpse_time` int(11) NOT NULL DEFAULT '7',
`base_rand_dam` int(11) NOT NULL DEFAULT '30',
`base_critical` int(11) NOT NULL DEFAULT '4',
`physical_hit_modify` int(11) NOT NULL DEFAULT '4',
`base_reuse_delay` int(11) NOT NULL DEFAULT '0',
`physical_avoid_modify` int(11) NOT NULL DEFAULT '0',
`hit_time_factor` double(11,2) NOT NULL DEFAULT '0.60',
`isDropHerbs` enum('false','true') NOT NULL DEFAULT 'true',
`shots` enum('NONE','SOUL','SPIRIT','BSPIRIT','SOUL_SPIRIT ','SOUL_BSPIRIT') NOT NULL DEFAULT 'NONE',
`map_flag` tinyint(1) NOT NULL DEFAULT '0',
`boss_flag` tinyint(1) NOT NULL DEFAULT '0',
PRIMARY KEY (`id`),
KEY `map_flag` (`map_flag`,`boss_flag`)
) ENGINE=MyISAM DEFAULT CHARSET=utf8;
-- ----------------------------
-- Table structure for `random_spawn`
-- ----------------------------
DROP TABLE IF EXISTS `random_spawn`;
CREATE TABLE `random_spawn` (
`groupId` int(11) NOT NULL DEFAULT '0',
`npcId` int(11) NOT NULL DEFAULT '0',
`count` int(11) NOT NULL DEFAULT '0',
`initialDelay` bigint(20) NOT NULL DEFAULT '-1',
`respawnDelay` bigint(20) NOT NULL DEFAULT '-1',
`despawnDelay` bigint(20) NOT NULL DEFAULT '-1',
`broadcastSpawn` enum('false','true') NOT NULL DEFAULT 'false',
`randomSpawn` enum('false','true') NOT NULL DEFAULT 'true',
PRIMARY KEY (`groupId`)
) ENGINE=MyISAM DEFAULT CHARSET=latin1;
-- ----------------------------
-- Table structure for `seven_signs`
-- ----------------------------
DROP TABLE IF EXISTS `seven_signs`;
CREATE TABLE `seven_signs` (
`char_obj_id` int(11) NOT NULL DEFAULT '0',
`cabal` enum('dawn','dusk','No Cabal') NOT NULL DEFAULT 'No Cabal',
`seal` tinyint(4) NOT NULL DEFAULT '0',
`dawn_red_stones` int(11) NOT NULL DEFAULT '0',
`dawn_green_stones` int(11) NOT NULL DEFAULT '0',
`dawn_blue_stones` int(11) NOT NULL DEFAULT '0',
`dawn_ancient_adena_amount` int(11) NOT NULL DEFAULT '0',
`dawn_contribution_score` int(11) NOT NULL DEFAULT '0',
`dusk_red_stones` int(11) NOT NULL DEFAULT '0',
`dusk_green_stones` int(11) NOT NULL DEFAULT '0',
`dusk_blue_stones` int(11) NOT NULL DEFAULT '0',
`dusk_ancient_adena_amount` int(11) NOT NULL DEFAULT '0',
`dusk_contribution_score` int(11) NOT NULL DEFAULT '0',
PRIMARY KEY (`char_obj_id`)
) ENGINE=MyISAM DEFAULT CHARSET=latin1;
-- ----------------------------
-- Table structure for `characters`
-- ----------------------------
DROP TABLE IF EXISTS `characters`;
CREATE TABLE `characters` (
`account_name` varchar(45) NOT NULL DEFAULT '',
`obj_Id` int(11) NOT NULL DEFAULT '0',
`char_name` varchar(35) CHARACTER SET cp1251 NOT NULL DEFAULT '',
`face` tinyint(3) unsigned DEFAULT NULL,
`hairStyle` tinyint(3) unsigned DEFAULT NULL,
`hairColor` tinyint(3) unsigned DEFAULT NULL,
`sex` tinyint(1) DEFAULT NULL,
`heading` mediumint(9) DEFAULT NULL,
`x` mediumint(9) DEFAULT NULL,
`y` mediumint(9) DEFAULT NULL,
`z` mediumint(9) DEFAULT NULL,
`karma` int(11) DEFAULT NULL,
`pvpkills` int(11) DEFAULT NULL,
`pkkills` int(11) DEFAULT NULL,
`clanid` int(11) DEFAULT NULL,
`createtime` int(10) unsigned NOT NULL DEFAULT '0',
`deletetime` int(10) unsigned NOT NULL DEFAULT '0',
`title` varchar(16) DEFAULT NULL,
`rec_have` tinyint(3) unsigned NOT NULL DEFAULT '0',
`rec_left` tinyint(3) unsigned NOT NULL DEFAULT '0',
`accesslevel` tinyint(4) DEFAULT NULL,
`online` tinyint(1) DEFAULT NULL,
`onlinetime` int(10) unsigned NOT NULL DEFAULT '0',
`lastAccess` int(10) unsigned NOT NULL DEFAULT '0',
`clan_privs` int(11) DEFAULT '0',
`wantspeace` int(11) DEFAULT '0',
`leaveclan` int(10) unsigned NOT NULL DEFAULT '0',
`deleteclan` int(10) unsigned NOT NULL DEFAULT '0',
`nochannel` int(11) NOT NULL DEFAULT '0',
`noble` decimal(2,0) NOT NULL DEFAULT '0',
`ketra` decimal(5,0) NOT NULL DEFAULT '0',
`varka` decimal(5,0) NOT NULL DEFAULT '0',
`ram` decimal(5,0) NOT NULL DEFAULT '0',
`pledge_type` smallint(6) NOT NULL DEFAULT '0',
`pledge_rank` tinyint(3) unsigned NOT NULL DEFAULT '0',
`lvl_joined_academy` tinyint(3) unsigned NOT NULL DEFAULT '0',
`apprentice` int(10) unsigned NOT NULL DEFAULT '0',
`key_bindings` varbinary(8192) DEFAULT NULL,
`pcBangPoints` int(11) NOT NULL DEFAULT '0',
`vitality` smallint(5) unsigned NOT NULL DEFAULT '10000',
`fame` int(11) NOT NULL DEFAULT '0',
`bookmarks` tinyint(3) unsigned NOT NULL DEFAULT '0',
`LastHWID` varchar(32) CHARACTER SET latin1 NOT NULL DEFAULT '00000000000000000000000000000000',
`lastteleport` decimal(20,0) DEFAULT NULL,
PRIMARY KEY (`obj_Id`),
UNIQUE KEY `char_name` (`char_name`),
KEY `account_name` (`account_name`),
KEY `clanid` (`clanid`)
) ENGINE=MyISAM DEFAULT CHARSET=utf8;
-- ----------------------------
-- Table structure for `character_subclasses`
-- ----------------------------
DROP TABLE IF EXISTS `character_subclasses`;
CREATE TABLE `character_subclasses` (
`char_obj_id` int(11) NOT NULL,
`class_id` tinyint(3) unsigned NOT NULL,
`level` tinyint(3) unsigned NOT NULL DEFAULT '1',
`exp` bigint(20) unsigned NOT NULL DEFAULT '0',
`sp` bigint(20) unsigned NOT NULL DEFAULT '0',
`curHp` decimal(9,4) unsigned NOT NULL DEFAULT '0.0000',
`curMp` decimal(9,4) unsigned NOT NULL DEFAULT '0.0000',
`curCp` decimal(11,4) unsigned NOT NULL DEFAULT '0.0000',
`maxHp` mediumint(8) unsigned NOT NULL DEFAULT '0',
`maxMp` mediumint(8) unsigned NOT NULL DEFAULT '0',
`maxCp` mediumint(8) unsigned NOT NULL DEFAULT '0',
`active` tinyint(1) NOT NULL DEFAULT '0',
`isBase` tinyint(1) NOT NULL DEFAULT '0',
`death_penalty` tinyint(4) NOT NULL DEFAULT '0',
`skills` varchar(50) NOT NULL,
PRIMARY KEY (`char_obj_id`,`class_id`)
) ENGINE=MyISAM DEFAULT CHARSET=latin1;