This topic is now archived and is closed to further replies.


Starting DBM pull timer via 3rd party lua

3 posts in this topic

I'm making essentially a Pull Timer addon and would like to incorporate a method to addon a auto start for a DBM pull timer

Now I'm not brilliant at .lua so staring at the DBM-Core.lua I'm a bit lost in it but I think the function for starting the timer off the /pull commands is at line 1015

here's my code

--Pull countdown

local pull, seconds, onesec

local frame = CreateFrame("Frame")


frame:SetScript("OnUpdate", function(self, elapsed)

	--Start DBM pull timer

    onesec = onesec - elapsed

    pull = pull - elapsed

    if pull <= 0 then

        SendChatMessage("Pulling!", "SAY")


    elseif onesec <= 0 then

        SendChatMessage(seconds, "SAY")

        seconds = seconds - 1

        onesec = 1



SlashCmdList["COUNTDOWN"] = function(t)

    t = tonumber(t) or 6

    pull = t + 1

    seconds = t

    onesec = 1




Share this post

Link to post
Share on other sites

The pull command sends an addon message and our addon message handler does the actual work. This part of the API is not accessible from the outside.

However, you can simply invoke the slash command handler:

This will have the same effect as typing /pull 10 in the game

SlashCmdList["DEADLYBOSSMODS"]("pull 10") 

Share this post

Link to post
Share on other sites

  • Recently Browsing   0 members

    No registered users viewing this page.