ALTER TABLE `custom_npcaidata`
CHANGE `npc_id` `npcId` mediumint(7) unsigned NOT NULL,
ADD `minSkillChance` tinyint(3) unsigned NOT NULL DEFAULT '7' AFTER `npcId`,
CHANGE `skill_chance` `maxSkillChance` tinyint(3) unsigned NOT NULL DEFAULT '15',
CHANGE `primary_attack` `primarySkillId` smallint(5) unsigned DEFAULT '0',
CHANGE `can_move` `canMove` tinyint(1) unsigned NOT NULL DEFAULT '1',
CHANGE `minrangeskill` `minRangeSkill` smallint(5) unsigned DEFAULT '0',
CHANGE `minrangechance` `minRangeChance` tinyint(3) unsigned DEFAULT '0',
CHANGE `maxrangeskill` `maxRangeSkill` smallint(5) unsigned DEFAULT '0',
CHANGE `maxrangechance` `maxRangeChance` tinyint(3) unsigned DEFAULT '0',
CHANGE `soulshot` `soulShot` smallint(4) unsigned DEFAULT '0',
CHANGE `spiritshot` `spiritShot` smallint(4) unsigned DEFAULT '0',
CHANGE `spschance` `spsChance` tinyint(3) unsigned DEFAULT '0',
CHANGE `sschance` `ssChance` tinyint(3) unsigned DEFAULT '0',
CHANGE `ischaos` `isChaos` smallint(4) unsigned DEFAULT '0',
MODIFY `clan` varchar(40) DEFAULT NULL,
CHANGE `clan_range` `clanRange` smallint(4) unsigned DEFAULT '0',
MODIFY `enemyRange` smallint(4) unsigned DEFAULT '0' AFTER `enemyClan`,
MODIFY `dodge` tinyint(3) unsigned DEFAULT '0',
CHANGE `ai_type` `aiType` varchar(8) NOT NULL DEFAULT 'fighter',
DROP PRIMARY KEY, ADD PRIMARY KEY (`npcId`);