Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- ---------------
- -- Null System Daemon --
- ---------------
- local Locales = {
- ["Null System Daemon"] = {
- [1] = "Null System Daemon",
- [2] = "Phagenschlund",
- [3] = "Phagegueule",
- },
- ["Binary System Daemon"] = {
- [1] = "Binary System Daemon",
- [2] = "Phagenschlund",
- [3] = "Phagegueule",
- },
- ["Disconnect"] = {
- [1] = "Disconnect",
- [2] = "Sprengbomben",
- [3] = "Bombes explosives",
- },
- ["Power Surge"] = {
- [1] = "Power Surge",
- [2] = "Flugphase",
- [3] = "Envol",
- },
- ["Adds"] = {
- [1] = "Adds",
- [2] = "Flugphase",
- [3] = "Envol",
- },
- ["Purge"] = {
- [1] = "Purge",
- [2] = "Flugphase",
- [3] = "Envol",
- },
- ["Basement Adds Spawning!"] = {
- [1] = "Basement Adds Spawning!",
- [2] = "Flugphase",
- [3] = "Envol",
- },
- ["Pillar Phase Duration"] = {
- [1] = "Pillar Phase Duration",
- [2] = "Flugphase",
- [3] = "Envol",
- },
- ["Enhancement Module"] = {
- [1] = "Pillar Phase Duration",
- [2] = "Flugphase",
- [3] = "Envol",
- },
- }
- local transition = 0
- local function NullSystemDaemon(tUnits)
- local currTime = GameLib.GetGameTime()
- for unitid, unitdata in pairs(tUnits) do
- local unitname = unitdata.unit:GetName()
- if unitname == Raiderino.L["Null System Daemon"] then
- local castname = Raiderino:GetCast(unitid,unitdata.unit)
- if castname then
- if castname == Raiderino.L["Disconnect"] then
- if Raiderino:FeatureCheck("Null System Daemon","Disconnect") then
- local msg = {text = "Disconnect", maxtime = 45, icon = nil, destroyAtEnd = true}
- Raiderino.timers:AddTimer(msg)
- end
- elseif castname == Raiderino.L["Purge"] then
- if Raiderino:FeatureCheck("Null System Daemon","Purge") then
- local msg = {text = "Purge", maxtime = 25, icon = nil, destroyAtEnd = true}
- Raiderino.timers:AddTimer(msg)
- end
- Raiderino:UntimedCastAdd(unitname,castname)
- else
- end
- if not Raiderino:GetPhase("Null System Daemon") == 2 and Raiderino:GetHealthPercent(unitdata.unit) < 70 and transition == 0 then
- Raiderino:PhaseSwitch("Null System Daemon",2)
- end
- if not Raiderino:GetPhase("Null System Daemon") == 2 and Raiderino:GetHealthPercent(unitdata.unit) < 30 then
- Raiderino:PhaseSwitch("Null System Daemon",2)
- end
- elseif unitname == Raiderino.L["Binary System Daemon"] then
- if castname then
- local castname = Raiderino:GetCast(unitid,unitdata.unit)
- Raiderino:UntimedCastAdd(unitname,castname)
- else
- end
- elseif unitname == Raiderino.L["Enhancement Module"] then
- if castname then
- local castname = Raiderino:GetCast(unitid,unitdata.unit)
- Raiderino:UntimedCastAdd(unitname,castname)
- end
- else
- end
- end
- end
- end
- local function StartNull()
- Apollo.RegisterTimerHandler("NullTimer", "OnNullTimer", self)
- Apollo.RegisterTimerHandler("NullPhaseTimer", "OnNullPhaseTimer", self)
- -- if Raiderino:FeatureCheck("Null System Daemon","Disconnect") then
- -- local msg = {text = "Disconnect", maxtime = 40, icon = nil, destroyAtEnd = true}
- -- Raiderino.timers:AddTimer(msg)
- -- end
- -- if Raiderino:FeatureCheck("Null System Daemon","Adds") then
- -- local msg = {text = "Basement Adds Spawning!", maxtime = 15, icon = nil, destroyAtEnd = true}
- -- Raiderino.timers:AddTimer(msg)
- -- Apollo.CreateTimer("NullTimer", 15.0, false)
- -- Apollo.StartTimer("NullTimer")
- -- end
- Raiderino:PhaseSwitch("Null System Daemon",1)
- -- Print("Phase: " .. Raiderino:GetPhase("Null System Daemon"))
- end
- function OnNullTimer()
- if GameLib.GetPlayerUnit():IsInCombat() then
- local msg = {text = "Basement Adds Spawning!", maxtime = 50, icon = nil, destroyAtEnd = true}
- Raiderino.timers:AddTimer(msg)
- Apollo.CreateTimer("NullTimer", 50, false)
- else
- end
- end
- function OnNullPhaseTimer()
- Raiderino:PhaseSwitch("Null System Daemon",1)
- end
- local function PhaseNull(phase)
- if phase == 2 then
- local msg = {text = "Pillar Phase Duration", maxtime = 90, icon = nil, destroyAtEnd = true}
- transition = 1
- Raiderino.timers:AddTimer(msg)
- Apollo.StopTimer("NullTimer")
- Apollo.CreateTimer("NullTimer", 90, false)
- if Raiderino.timers.content["Basement Adds Spawning!"] then
- Raiderino.timers.content["Basement Adds Spawning!"].Frame:Destroy()
- Raiderino.timers.content["Basement Adds Spawning!"] = nil
- end
- if Raiderino.notifications.content["Disconnect"] then
- Raiderino.notifications.content["Disconnect"].Frame:Destroy()
- Raiderino.notifications.content["Disconnect"] = nil
- end
- elseif phase == 1 then
- if Raiderino.timers.content["Enhancement Module"] then
- Raiderino.timers.content["Enhancement Module"].Frame:Destroy()
- Raiderino.timers.content["Enhancement Module"] = nil
- end
- if Raiderino:FeatureCheck("Null System Daemon","Disconnect") then
- local msg = {text = "Disconnect", maxtime = 40, icon = nil, destroyAtEnd = true}
- Raiderino.timers:AddTimer(msg)
- end
- if Raiderino:FeatureCheck("Null System Daemon","Adds") then
- local msg = {text = "Basement Adds Spawning!", maxtime = 15, icon = nil, destroyAtEnd = true}
- Raiderino.timers:AddTimer(msg)
- Apollo.CreateTimer("NullTimer", 15.0, false)
- Apollo.StartTimer("NullTimer")
- end
- else
- end
- end
- ----------------
- -- /Null System Daemon --
- ----------------
- local encounteroptions = {
- enabled = true,
- position = 1,
- zone = "Halls of the Infinite Mind",
- fBossFunction = NullSystemDaemon,
- fPhaseFunction = PhaseNull,
- fOnStartCombat = StartNull,
- features = {
- ["Disconnect"] = {
- displayname = "Disconnect",
- enabled = true
- },
- ["Purge"] = {
- displayname = "Purge",
- enabled = true
- },
- ["Adds"] = {
- displayname = "Adds",
- enabled = true
- },
- },
- }
- if _G["RaiderinoLibs"] == nil then
- _G["RaiderinoLibs"] = { }
- end
- if _G["RaiderinoLibs"]["Encounters"] == nil then
- _G["RaiderinoLibs"]["Encounters"] = { }
- end
- _G["RaiderinoLibs"]["Encounters"]["Null System Daemon"] = encounteroptions
- if _G["RaiderinoLibs"]["Locales"] == nil then
- _G["RaiderinoLibs"]["Locales"] = { }
- end
- for locale, localedata in pairs(Locales) do
- if not RaiderinoLibs.Locales[locale] then
- RaiderinoLibs.Locales[locale] = {}
- for i,localestring in pairs(localedata) do
- RaiderinoLibs.Locales[locale][i] = localestring
- end
- end
- end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement