From 3cc2fccbc5e44d9f3b984e29a0e9063c0cc4f1be Mon Sep 17 00:00:00 2001 From: HT Cesta <58153179+htc16@users.noreply.github.com> Date: Sat, 2 Nov 2024 14:28:48 -0300 Subject: [PATCH] phlinho10@gmail.com --- .../the_dream_courts/bosses/alptramun.lua | 1 - .../the_dream_courts/bosses/maxxenius.lua | 1 - .../the_dream_courts/bosses/plagueroot.lua | 1 - .../actions_dreamscarLevers.lua | 9 ++-- .../creaturescripts_dreamCourtsDeath.lua | 2 +- .../globalevents_dream_courts_worldchange.lua | 41 ------------------- .../globalevents_the_dream_courts.lua} | 13 +++--- data-otservbr-global/startup/tables/item.lua | 1 + 8 files changed, 12 insertions(+), 57 deletions(-) delete mode 100644 data-otservbr-global/scripts/quests/the_dream_courts_quest/globalevents_dream_courts_worldchange.lua rename data-otservbr-global/scripts/{world_changes/the_dream_courts.lua => quests/the_dream_courts_quest/globalevents_the_dream_courts.lua} (61%) diff --git a/data-otservbr-global/monster/quests/the_dream_courts/bosses/alptramun.lua b/data-otservbr-global/monster/quests/the_dream_courts/bosses/alptramun.lua index e6aa5b5d530..d84d619d849 100644 --- a/data-otservbr-global/monster/quests/the_dream_courts/bosses/alptramun.lua +++ b/data-otservbr-global/monster/quests/the_dream_courts/bosses/alptramun.lua @@ -22,7 +22,6 @@ monster.manaCost = 0 monster.events = { "dreamCourtsDeath", - "facelessHealth", } monster.changeTarget = { diff --git a/data-otservbr-global/monster/quests/the_dream_courts/bosses/maxxenius.lua b/data-otservbr-global/monster/quests/the_dream_courts/bosses/maxxenius.lua index 3f3549b6bba..93e9d150baa 100644 --- a/data-otservbr-global/monster/quests/the_dream_courts/bosses/maxxenius.lua +++ b/data-otservbr-global/monster/quests/the_dream_courts/bosses/maxxenius.lua @@ -22,7 +22,6 @@ monster.manaCost = 0 monster.events = { "dreamCourtsDeath", - "facelessHealth", } monster.changeTarget = { diff --git a/data-otservbr-global/monster/quests/the_dream_courts/bosses/plagueroot.lua b/data-otservbr-global/monster/quests/the_dream_courts/bosses/plagueroot.lua index 8a7093a46c0..5da19934a60 100644 --- a/data-otservbr-global/monster/quests/the_dream_courts/bosses/plagueroot.lua +++ b/data-otservbr-global/monster/quests/the_dream_courts/bosses/plagueroot.lua @@ -22,7 +22,6 @@ monster.manaCost = 0 monster.events = { "dreamCourtsDeath", - "facelessHealth", } monster.changeTarget = { diff --git a/data-otservbr-global/scripts/quests/the_dream_courts_quest/actions_dreamscarLevers.lua b/data-otservbr-global/scripts/quests/the_dream_courts_quest/actions_dreamscarLevers.lua index 531bee268a9..a130f090453 100644 --- a/data-otservbr-global/scripts/quests/the_dream_courts_quest/actions_dreamscarLevers.lua +++ b/data-otservbr-global/scripts/quests/the_dream_courts_quest/actions_dreamscarLevers.lua @@ -1,6 +1,6 @@ local transform = { - [9110] = 9111, - [9111] = 9110, + [8911] = 8912, + [8912] = 8911, } local bossNames = { @@ -247,7 +247,7 @@ function actions_dreamscarLevers.onUse(player, item, fromPosition, target, toPos local pPos = player:getPosition() local nightmareLever = Position(32212, 32069, 15) - if item.itemid == 9110 then + if item.itemid == 8911 then if iPos == nightmareLever then if player:doCheckBossRoom(lastBoss.bossName, lastBoss.roomFromPosition, lastBoss.roomToPosition) then if pPos:isInRange(lastBoss.fromPositionPush, lastBoss.toPositionPush) then @@ -332,14 +332,11 @@ function actions_dreamscarLevers.onUse(player, item, fromPosition, target, toPos monster:registerEvent("facelessHealth") elseif leverTable.bossName:lower() == "izcandar the banished" then monster:registerEvent("izcandarThink") - spawnSummons(1, "the heat of summer", false, 15, heatOfSummer, leverTable.bossPosition) spawnSummons(1, "the cold of winter", false, 15, coldOfWinter, leverTable.bossPosition) - Game.setStorageValue(Storage.Quest.U12_00.TheDreamCourts.DreamScarGlobal.IzcandarOutfit, 0) elseif leverTable.bossName:lower() == "plagueroot" then spawnSummons(1, "plant attendant", false, 15, plantAttendants, leverTable.bossPosition) - monster:registerEvent("facelessHealth") elseif leverTable.bossName:lower() == "malofur mangrinder" then for i = 1, #whirlingBlades do diff --git a/data-otservbr-global/scripts/quests/the_dream_courts_quest/creaturescripts_dreamCourtsDeath.lua b/data-otservbr-global/scripts/quests/the_dream_courts_quest/creaturescripts_dreamCourtsDeath.lua index 0ed9afb6060..a2005f8641d 100644 --- a/data-otservbr-global/scripts/quests/the_dream_courts_quest/creaturescripts_dreamCourtsDeath.lua +++ b/data-otservbr-global/scripts/quests/the_dream_courts_quest/creaturescripts_dreamCourtsDeath.lua @@ -44,7 +44,7 @@ local questlog = { [7] = { bossName = "Plagueroot", storageQuestline = Storage.Quest.U12_00.TheDreamCourts.DreamScar.BossCount, - storageTimer = Storage.Quest.U12_00.TheDreamCourts.DreamScarGlobal.PlaguerootTimer, + storageTimer = Storage.Quest.U12_00.TheDreamCourts.DreamScarGlobal.PlagueRootTimer, middlePosition = Position(32208, 32048, 14), maxValue = 5, }, diff --git a/data-otservbr-global/scripts/quests/the_dream_courts_quest/globalevents_dream_courts_worldchange.lua b/data-otservbr-global/scripts/quests/the_dream_courts_quest/globalevents_dream_courts_worldchange.lua deleted file mode 100644 index 348f1e4bfb0..00000000000 --- a/data-otservbr-global/scripts/quests/the_dream_courts_quest/globalevents_dream_courts_worldchange.lua +++ /dev/null @@ -1,41 +0,0 @@ -local config = { - ["Monday"] = "Alptramun", - ["Tuesday"] = "Izcandar_the_Banished", - ["Friday"] = "Malofur_Mangrinder", - ["Thursday"] = "Maxxenius", - ["Wednesday"] = "Malofur_Mangrinder", - ["Saturday"] = "Plagueroot", - ["Sunday"] = "Maxxenius", -} - -local spawnByDay = true - -local globalevents_dream_courts_worldchange = GlobalEvent("startupCourts") - -function globalevents_dream_courts_worldchange.onStartup(interval) - if spawnByDay then - logger.info("[The Dream Courts Quest] loaded: " .. config[os.date("%A")]) - Game.loadMap("data/world/worldchanges/dream_courts_bosses/" .. config[os.date("%A")] .. ".otbm") - else - logger.warn("[The Dream Courts Quest] bosses: not boss today") - end - return true -end - -globalevents_dream_courts_worldchange:register() - -local globalevents_dream_courts_worldchange = GlobalEvent("fixCourts") - -function globalevents_dream_courts_worldchange.onTime(interval) - if spawnByDay then - logger.info("[The Dream Courts Quest] loaded: " .. config[os.date("%A")]) - Game.loadMap("data/world/worldchanges/dream_courts_bosses/" .. config[os.date("%A")] .. ".otbm") - else - logger.warn("[The Dream Courts Quest] bosses: not boss today") - end - - return true -end - -globalevents_dream_courts_worldchange:time("00:00") -globalevents_dream_courts_worldchange:register() diff --git a/data-otservbr-global/scripts/world_changes/the_dream_courts.lua b/data-otservbr-global/scripts/quests/the_dream_courts_quest/globalevents_the_dream_courts.lua similarity index 61% rename from data-otservbr-global/scripts/world_changes/the_dream_courts.lua rename to data-otservbr-global/scripts/quests/the_dream_courts_quest/globalevents_the_dream_courts.lua index bb3bcc3a6a8..b6a340e1e68 100644 --- a/data-otservbr-global/scripts/world_changes/the_dream_courts.lua +++ b/data-otservbr-global/scripts/quests/the_dream_courts_quest/globalevents_the_dream_courts.lua @@ -1,11 +1,11 @@ local dreamCourtsConfig = { - ["Monday"] = { map = "plagueroot", bossName = "Plagueroot" }, - ["Tuesday"] = { map = "malofur_mangrinder", bossName = "Malofur Mangrinder" }, - ["Wednesday"] = { map = "maxxenius", bossName = "Maxxenius" }, - ["Thursday"] = { map = "alptramun", bossName = "Alptramun" }, + ["Monday"] = { map = "alptramun", bossName = "Alptramun" }, + ["Tuesday"] = { map = "izcandar_the_banished", bossName = "Izcandar the Banished" }, + ["Wednesday"] = { map = "malofur_mangrinder", bossName = "Malofur Mangrinder" }, + ["Thursday"] = { map = "maxxenius", bossName = "Maxxenius" }, ["Friday"] = { map = "izcandar_the_banished", bossName = "Izcandar the Banished" }, - ["Saturday"] = { map = "maxxenius", bossName = "Maxxenius" }, - ["Sunday"] = { map = "alptramun", bossName = "Alptramun" }, + ["Saturday"] = { map = "plagueroot", bossName = "Plagueroot" }, + ["Sunday"] = { map = "maxxenius", bossName = "Maxxenius" }, } local dreamCourtsEvent = GlobalEvent("DreamCourts") @@ -20,6 +20,7 @@ function dreamCourtsEvent.onStartup() Game.loadMap(DATA_DIRECTORY .. "/world/quest/the_dream_courts/" .. dayConfig.map .. ".otbm") logger.info("[World Change] The Dream Courts today's boss is: {}!", dayConfig.bossName) + return true end diff --git a/data-otservbr-global/startup/tables/item.lua b/data-otservbr-global/startup/tables/item.lua index 7a1afb788ae..99854dad8c8 100644 --- a/data-otservbr-global/startup/tables/item.lua +++ b/data-otservbr-global/startup/tables/item.lua @@ -1250,6 +1250,7 @@ ItemAction = { { x = 32211, y = 32081, z = 15 }, { x = 32720, y = 32270, z = 8 }, { x = 33618, y = 32546, z = 13 }, + { x = 32208, y = 32033, z = 13 }, }, }, [23104] = {