------------------------------------------------------------------------------------
--Name：            200814[简体征服][活动脚本]全球中秋节活动-NPC
--Creator:      江宇君
--Created:     2020/08/14
------------------------------------------------------------------------------------
--/callluafunc </F>User_PlayPlot</N>63

-- 设置摄像机指向位置(网格坐标)
CppScriptMgr:SetViewPosByCell(52,115)
------------------------------------------------------------
--玩家对象操作接口,Hero、Player、Npc接口都一样
-- 查询/创建，玩家自己
-- 参数：无

local hero = CppScriptMgr:QueryHero()
hero:SetCtrlMapView(1)
hero:SetPos(52,115)
hero:SetDir(7)
hero:AddEffect("zf2-e280")

local playerTianPeng = CppScriptMgr:AddSimplePlayer(1064204, 53,120, "MarshalTianpeng", 4003000001,1)
playerTianPeng:SetZoomPercent(135)
playerTianPeng:SetDir(4)

local playerChangE = CppScriptMgr:AddSimplePlayer(1061210, 43,80, "MoonFairy", 4003000002,1)
playerChangE:SetZoomPercent(150)
playerChangE:SetDir(0)

local playerRabbitBoss = CppScriptMgr:AddSimplePlayer(31391, 50,86, "RabbitSupervisor", 4003000003,1)
playerRabbitBoss:SetZoomPercent(120)
playerRabbitBoss:SetDir(1)

local playerRabbit3 = CppScriptMgr:AddSimplePlayer(31407, 41,93, "RabbitSanko", 4003000004,1)
playerRabbit3:SetZoomPercent(100)
playerRabbit3:SetDir(7)

local playerRabbit8 = CppScriptMgr:AddSimplePlayer(31413, 45,97, "RabbitBudd", 4003000005,1)
playerRabbit8:SetZoomPercent(100)
playerRabbit8:SetDir(3)


CppScriptMgr:AddEffect("Exit",54,110)
CppScriptMgr:AddEffect("Exit",51,97)


-- 天蓬
playerTianPeng:SetDir(4)
playerTianPeng:Say("Why does my little Moon Fairy look sad? What happened?",1500)
CppScriptMgr:WaitMilSec(500)
CppScriptMgr:NpcCallOut("Little Moon Fairy is on that boat. Her melancholy look breaks my heart. Go to see what is going on.\n\n\n                                     Press ESC to skip the story.", 3000, 1, "NPCBust_bg", "", 320, 570, 400, 580, "NPCBust_npc27064", 150, 430, "MarshalTianpeng", 250, 655)
CppScriptMgr:WaitMilSec(3000)

hero:RunTo(54,110)
CppScriptMgr:WaitMilSec(500)
CppScriptMgr:SetViewPosByCell(42,85)
hero:AddEffect("zf2-e280")
CppScriptMgr:WaitMilSec(500)
hero:SetPos(42,85)
hero:SetDir(3)
playerChangE:AddEffect("TakeOnLilySuit")



hero:Say("What`s wrong, Moon Fairy?", 1500)
CppScriptMgr:WaitMilSec(1500)
playerChangE:Say("The Mid-Autumn Festival is coming, but I haven`t got enough Mooncakes!#08#08", 1500)
playerRabbitBoss:Say("Hurry up! Hurry up!", 3000)
CppScriptMgr:WaitMilSec(1500)
hero:SetAction(160)
playerRabbit3:Say("Come on, Budd!", 3000)
CppScriptMgr:WaitMilSec(500)
hero:SetAction(160)
CppScriptMgr:WaitMilSec(1000)
playerRabbit8:Say("Come on, Sanko!", 3000)
hero:Say("Don`t cry. Let me help you.", 1500)
CppScriptMgr:WaitMilSec(1500)
playerChangE:Say("Well then, go to urge those rabbits for me.", 1500)
CppScriptMgr:WaitMilSec(1500)
hero:AddEffect("fighter")

playerRabbitBoss:Say("Hurry up! Hurry up!", 3000)
CppScriptMgr:WaitMilSec(1000)
playerRabbit3:Say("Come on, Budd!", 3000)
CppScriptMgr:NpcCallOut("Stop crying, little Moon Fairy. My heart is broken. My friend, go to check those rabbits to see if there is any way to make Mooncakes faster.\n\n\n                                     Press ESC to skip the story.", 3000, 1, "NPCBust_bg", "", 320, 570, 400, 580, "NPCBust_npc27064", 150, 430, "MarshalTianpeng", 250, 655)
CppScriptMgr:WaitMilSec(1000)
playerRabbit8:Say("Come on, Sanko!", 3000)
CppScriptMgr:WaitMilSec(2000)

-- 月兔主管
hero:RunTo(48,85)
CppScriptMgr:WaitMilSec(1000)
playerRabbitBoss:AddEffect("zf2-e024")
hero:SetAction(190)
CppScriptMgr:WaitMilSec(500)
hero:SetAction(190)
CppScriptMgr:WaitMilSec(1000)
hero:Say("I am the new supervisor. Make those lazy bones work harder!", 1500)
playerRabbit3:Say("Come on, Budd!", 3000)
CppScriptMgr:WaitMilSec(1500)
playerRabbitBoss:Say("Hurry up! Do you want to work overtime?", 1500)
playerRabbit8:Say("Come on, Sanko!", 3000)
CppScriptMgr:WaitMilSec(1500)

-- 兔三哥
hero:RunTo(43,93)
CppScriptMgr:WaitMilSec(1000)
playerRabbit3:AddEffect("eddy")
CppScriptMgr:WaitMilSec(700)
hero:SetAction(160)
CppScriptMgr:WaitMilSec(500)
hero:SetAction(160)
CppScriptMgr:WaitMilSec(1000)
hero:Say("What took you so long to knead a dough? We are all waiting for you!", 1500)
CppScriptMgr:WaitMilSec(1500)
playerRabbit3:Say("How can I manage with just these few rabbits? Budd, I need flour!", 1500)
CppScriptMgr:WaitMilSec(1500)

-- 兔八弟
hero:RunTo(46,96)
CppScriptMgr:WaitMilSec(500)
playerRabbit8:AddEffect("eddy")
CppScriptMgr:WaitMilSec(500)
hero:SetAction(160)
CppScriptMgr:WaitMilSec(500)
hero:SetAction(160)
CppScriptMgr:WaitMilSec(1000)
hero:Say("Are you making hamburgers? We are not preparing for Christmas!", 1500)
CppScriptMgr:WaitMilSec(1500)
playerRabbit8:Say("Calm down! I am trying my best!", 1500)
CppScriptMgr:WaitMilSec(1500)


hero:AddEffect("goldendragon")
CppScriptMgr:NpcCallOut("I see. We need more rabbits to improving the efficiency!\n\n\n                                     Press ESC to skip the story.", 3000, 1, "NPCBust_bg", "", 320, 570, 400, 580, "NPCBust_npc27064", 150, 430, "MarshalTianpeng", 250, 655)
CppScriptMgr:WaitMilSec(3000)

hero:RunTo(42,85)
CppScriptMgr:WaitMilSec(2000)
hero:SetAction(200)
CppScriptMgr:WaitMilSec(1000)
-- hero:SetAction(200)
-- CppScriptMgr:WaitMilSec(1000)
hero:Say("Don`t worry. I promise you will have enough Mooncakes for the festival.", 1500)
CppScriptMgr:WaitMilSec(1500)
playerChangE:SetAction(150)
CppScriptMgr:WaitMilSec(500)
playerChangE:SetAction(150)
CppScriptMgr:WaitMilSec(1000)
playerChangE:Say("Thank you so much! Let me know if you have any question.", 1500)
CppScriptMgr:WaitMilSec(1500)


CppScriptMgr:NpcCallOut("Sure, little Moon Fairy. See you later!\n\n\n                                     Press ESC to skip the story.", 3000, 1, "NPCBust_bg", "", 320, 570, 400, 580, "NPCBust_npc27064", 150, 430, "MarshalTianpeng", 250, 655)
CppScriptMgr:WaitMilSec(3000)
hero:AddEffect("accession")
CppScriptMgr:WaitMilSec(1000)
