-- Migration generated at 2020/04/28 07:41:12
-- 20200428074112_AddBattleNpcTable.sql

CREATE TABLE IF NOT EXISTS `battlenpc` (
  `TerritoryType` int(11) NOT NULL,
  `TerritoryName` varchar(22) NOT NULL,
  `name` varchar(12) NOT NULL,
  `instanceId` int(11) NOT NULL,
  `x` decimal(12,6) NOT NULL,
  `y` decimal(11,6) NOT NULL,
  `z` decimal(11,6) NOT NULL,
  `BaseId` int(11) NOT NULL,
  `PopWeather` int(11) NOT NULL,
  `PopTimeStart` int(11) NOT NULL,
  `PopTimeEnd` int(11) NOT NULL,
  `MoveAI` int(11) NOT NULL,
  `WanderingRange` int(11) NOT NULL,
  `Route` int(11) NOT NULL,
  `EventGroup` int(11) NOT NULL,
  `NameId` int(11) NOT NULL,
  `DropItem` int(11) NOT NULL,
  `SenseRangeRate` decimal(9,6) NOT NULL,
  `Level` int(11) NOT NULL,
  `ActiveType` int(11) NOT NULL,
  `PopInterval` int(11) NOT NULL,
  `PopRate` int(11) NOT NULL,
  `PopEvent` int(11) NOT NULL,
  `LinkGroup` int(11) NOT NULL,
  `LinkFamily` int(11) NOT NULL,
  `LinkRange` int(11) NOT NULL,
  `LinkCountLimit` int(11) NOT NULL,
  `NonpopInitZone` int(11) NOT NULL,
  `InvalidRepop` int(11) NOT NULL,
  `LinkParent` int(11) NOT NULL,
  `LinkOverride` int(11) NOT NULL,
  `LinkReply` int(11) NOT NULL,
  `HorizontalPopRange` decimal(9,6) NOT NULL,
  `VerticalPopRange` decimal(9,6) NOT NULL,
  `BNpcBaseData` int(11) NOT NULL,
  `RepopId` int(11) NOT NULL,
  `BNPCRankId` int(11) NOT NULL,
  `TerritoryRange` int(11) NOT NULL,
  `BoundInstanceID` int(11) NOT NULL,
  `FateLayoutLabelId` int(11) NOT NULL,
  `NormalAI` int(11) NOT NULL,
  `ServerPathId` int(11) NOT NULL,
  `EquipmentID` int(11) NOT NULL,
  `CustomizeID` int(11) NOT NULL,
  PRIMARY KEY (`TerritoryType`,`instanceId`)
) ENGINE=InnoDB DEFAULT CHARSET=latin1;