function c9010357_On_Talk(MapID, InstanceID, TargetID, TargetTypeID, RoleID, TalkIndex) local quest = role.IsRoleHaveQuest(MapID, InstanceID, RoleID, 53001) if TalkIndex == -1 then local MsgID = msg.BeginMsgEvent() msg.AddMsgEvent(MsgID, 20, 950378) msg.AddMsgEvent(MsgID, 24, TargetID) msg.AddMsgEvent(MsgID, 21, 4) msg.AddMsgEvent(MsgID, 1, 950379) msg.AddMsgEvent(MsgID, 21, 5) msg.AddMsgEvent(MsgID, 1, 100002) msg.DispatchRoleMsgEvent(RoleID, MsgID) elseif TalkIndex == 4 then if quest == true then role.RoleGotoNewMap(MapID, InstanceID, RoleID, 201103695, 1276, 7356, 519) unit.AddBuff(MapID, InstanceID, RoleID, 9812201,RoleID) else local MsgID = msg.BeginMsgEvent() msg.AddMsgEvent(MsgID, 20, 950380) msg.AddMsgEvent(MsgID, 24, TargetID) msg.AddMsgEvent(MsgID, 21, 6) msg.AddMsgEvent(MsgID, 1, 100002) msg.DispatchRoleMsgEvent(RoleID, MsgID) end end end aux.RegisterCreatureEvent(9010357, 7, "c9010357_On_Talk")