-- Overlord Agmar SAI
SET @ENTRY := 26379;
UPDATE `creature_template` SET `AIName`="SmartAI" WHERE `entry`=@ENTRY;
DELETE FROM `smart_scripts` WHERE `entryorguid`=@ENTRY AND `source_type`=0;
INSERT INTO `smart_scripts` (`entryorguid`,`source_type`,`id`,`link`,`event_type`,`event_phase_mask`,`event_chance`,`event_flags`,`event_param1`,`event_param2`,`event_param3`,`event_param4`,`action_type`,`action_param1`,`action_param2`,`action_param3`,`action_param4`,`action_param5`,`action_param6`,`target_type`,`target_param1`,`target_param2`,`target_param3`,`target_x`,`target_y`,`target_z`,`target_o`,`comment`) VALUES
(@ENTRY,0,0,1,19,0,100,0,12140,0,0,0,81,1,0,0,0,0,0,1,0,0,0,0,0,0,0,"Overlord Agmar - On Quest 'All Hail Roanauk!' Taken - Set Npc Flag Gossip"),
(@ENTRY,0,1,2,61,0,100,0,12140,0,0,0,91,257,0,0,0,0,0,1,0,0,0,0,0,0,0,"Overlord Agmar - On Quest 'All Hail Roanauk!' Taken - Remove Flag <Unknown bytes1 (UnitStandStateType)>"),
(@ENTRY,0,2,3,61,0,100,0,12140,0,0,0,1,0,0,0,0,0,0,1,0,0,0,0,0,0,0,"Overlord Agmar - On Quest 'All Hail Roanauk!' Taken - Say Line 0"),
(@ENTRY,0,3,7,61,0,100,0,12140,0,0,0,53,0,26379,0,0,0,0,1,0,0,0,0,0,0,0,"Overlord Agmar - On Quest 'All Hail Roanauk!' Taken - Start Waypoint"),
(@ENTRY,0,4,0,40,0,100,0,10,0,0,0,66,0,0,0,0,0,0,19,26810,0,0,0,0,0,0,"Overlord Agmar - On Waypoint 10 Reached - Set Orientation Closest Creature 'Roanauk Icemist'"),
(@ENTRY,0,5,0,38,0,100,0,1,1,0,0,24,0,0,0,0,0,0,1,0,0,0,0,0,0,0,"Overlord Agmar - On Data Set 1 1 - Evade"),
(@ENTRY,0,6,0,21,0,100,0,0,0,0,0,81,3,0,0,0,0,0,1,0,0,0,0,0,0,0,"Overlord Agmar - On Reached Home - Set Npc Flags Gossip & Questgiver"),
(@ENTRY,0,7,8,61,0,100,0,12140,0,0,0,48,1,0,0,0,0,0,1,0,0,0,0,0,0,0,"Overlord Agmar - On Quest 'All Hail Roanauk!' Taken - Set Active On"),
(@ENTRY,0,8,0,61,0,100,0,12140,0,0,0,80,@ENTRY*100+00,2,0,0,0,0,1,0,0,0,0,0,0,0,"Overlord Agmar - On Quest 'All Hail Roanauk!' Taken - Run Script");
-- Actionlist SAI
SET @ENTRY := 2637900;
DELETE FROM `smart_scripts` WHERE `entryorguid`=@ENTRY AND `source_type`=9;
INSERT INTO `smart_scripts` (`entryorguid`,`source_type`,`id`,`link`,`event_type`,`event_phase_mask`,`event_chance`,`event_flags`,`event_param1`,`event_param2`,`event_param3`,`event_param4`,`action_type`,`action_param1`,`action_param2`,`action_param3`,`action_param4`,`action_param5`,`action_param6`,`target_type`,`target_param1`,`target_param2`,`target_param3`,`target_x`,`target_y`,`target_z`,`target_o`,`comment`) VALUES
(@ENTRY,9,0,0,0,0,100,0,320000,320000,0,0,24,0,0,0,0,0,0,1,0,0,0,0,0,0,0,"On Script - Evade");
atomatischer reset nach 5 min, wenn der andere npc nicht angelabert wurde