items.sql 837 B

12345678910111213141516171819
  1. CREATE TABLE IF NOT EXISTS `items` (
  2. `owner_id` INT, -- object id of the player or clan,owner of this item
  3. `object_id` INT NOT NULL DEFAULT 0, -- object id of the item
  4. `item_id` INT,
  5. `count` BIGINT UNSIGNED NOT NULL DEFAULT 0,
  6. `enchant_level` INT,
  7. `loc` VARCHAR(10), -- inventory,paperdoll,npc,clan warehouse,pet,and so on
  8. `loc_data` INT, -- depending on location: equiped slot,npc id,pet id,etc
  9. `time_of_use` INT, -- time of item use, for calculate of breackages
  10. `custom_type1` INT DEFAULT 0,
  11. `custom_type2` INT DEFAULT 0,
  12. `mana_left` decimal(5,0) NOT NULL DEFAULT -1,
  13. `time` decimal(13) NOT NULL DEFAULT 0,
  14. PRIMARY KEY (`object_id`),
  15. KEY `owner_id` (`owner_id`),
  16. KEY `item_id` (`item_id`),
  17. KEY `loc` (`loc`),
  18. KEY `time_of_use` (`time_of_use`)
  19. ) ENGINE=InnoDB DEFAULT CHARSET=utf8;