From 56491266ccc63f65608c81267c7244fa561238e7 Mon Sep 17 00:00:00 2001 From: Tahir Akhlaq Date: Fri, 22 Sep 2017 03:26:12 +0100 Subject: [PATCH] another attempt to get opening fight working (client hangs after talking to yda for second time for some reason..) --- .../actors/director/Director.cs | 7 +--- .../directors/Quest/QuestDirectorMan0g001.lua | 39 ++++++++++++++----- 2 files changed, 31 insertions(+), 15 deletions(-) diff --git a/FFXIVClassic Map Server/actors/director/Director.cs b/FFXIVClassic Map Server/actors/director/Director.cs index 321645ab..53eee828 100644 --- a/FFXIVClassic Map Server/actors/director/Director.cs +++ b/FFXIVClassic Map Server/actors/director/Director.cs @@ -127,8 +127,8 @@ namespace FFXIVClassic_Map_Server.actors.director { ((GuildleveDirector)this).LoadGuildleve(); } - - StartCoroutine("main", this); + + CallLuaScript("main", this, contentGroup); } public void StartContentGroup() @@ -314,8 +314,5 @@ namespace FFXIVClassic_Map_Server.actors.director DynValue value = coroutine.Resume(args2); LuaEngine.GetInstance().ResolveResume(player, coroutine, value); } - - - } } \ No newline at end of file diff --git a/data/scripts/directors/Quest/QuestDirectorMan0g001.lua b/data/scripts/directors/Quest/QuestDirectorMan0g001.lua index 26c73050..56fb527d 100644 --- a/data/scripts/directors/Quest/QuestDirectorMan0g001.lua +++ b/data/scripts/directors/Quest/QuestDirectorMan0g001.lua @@ -22,23 +22,35 @@ function onCreateContentArea(players, director, contentArea, contentGroup) mob3 = GetWorldManager():SpawnBattleNpcById(5, contentArea); local added = false; - for _, player in pairs(players) do + for i = 0, players.Count do + local player = players[i]; if player.currentParty and not added then - player.currentParty.AddMember(yshtola); - player.currentParty.AddMember(stahlmann); + player.currentParty.members.Add(6); + print("cunt") + player.currentParty.members.Add(7); + print("dickbag") added = true; end; -- dont let player die - player.SetModifier(modifiersGlobal.MinimumHpLock, 1); - + player.SetMod(modifiersGlobal.MinimumHpLock, 1); + print("shittttt") contentGroup:AddMember(player); + player:EndEvent(); + i = i + 1; end; + print("shit") contentGroup:AddMember(director); + print("shit2"); contentGroup:AddMember(yshtola); + print("shit3") contentGroup:AddMember(stahlmann); - contentGroup:AddMember(mob1); - contentGroup:AddMember(mob2); - contentGroup:AddMember(mob3); + print("shit4") + contentGroup:AddMember(mob1); + print("shit5") + contentGroup:AddMember(mob2); + print("shit6") + contentGroup:AddMember(mob3); + print("dicks") end function onEventStarted(player, actor, triggerName) @@ -62,7 +74,7 @@ function onEventStarted(player, actor, triggerName) man0g0Quest:NextPhase(6); closeTutorialWidget(player); - + print("ass") --[[ IF DoW: OpenWidget (TP) @@ -84,6 +96,7 @@ function onEventStarted(player, actor, triggerName) end function onUpdate(deltaTime, area) + print("fuck") end function onTalkEvent(player, npc) @@ -101,4 +114,10 @@ function onEventUpdate(player, npc) end function onCommand(player, command) -end \ No newline at end of file +end + +function main(director, contentGroup) + print("shitstain") + onCreateContentArea(director:GetPlayerMembers(), director, director:GetZone(), contentGroup); + player:EndEvent(); +end; \ No newline at end of file