1. #1
    Deleted

    [Solved] clcInfo and Rapture

    Hai i would like to remove Ingela's rapture from my list of addons since i am using Clcinfo for quite some time now.
    As you can imagine i want it to track Internal cooldown for Rapture.
    Tho i can't seem to find the code for it.
    Code:
    return IconICD(63853, 45, 0, 1, 0.3)
    is not correct
    I tried something like this also in case it would work but it didn't, since that code is for a buff/stacks of a buff on the player.
    Code:
    local visible, texture, start, duration, enable, reversed, count = IconAura("HELPFUL|PLAYER", "player", "Rapture")
    if not visible then
      visible, texture, start, duration, enable, reversed, count = IconAura("HELPFUL|PLAYER", "player", "Rapture")
      if not visible then return IconSpell("Rapture") end
      return visible, texture, start, duration, enable, reversed, count
    end
    return visible, texture, start, duration, enable, reversed, count
    There are these pages also for the addon,but i have no idea how to use them
    Event handling
    Active display elements (icons, multi icons, bars, multi bars and texts) have a way of hooking event calls. In order to catch events for a specific element you must add at least one event through the edit box in Behavior Tab, Events section (attention, for some of the elements is located under the Alerts section, so you need to scroll down).

    The function used to add event listeners is:

    AddEventListener(EventHandler, ...)

    eventHandler: function that handles the event calls
    ...: list of events that will be associated with eventHandler

    EventHandler should have the following format:

    local FunctionName(storage, event, ...)

    storage: table where you can store data to be used in the main code by the element
    event: name of the event that triggered the call
    ...: list of arguments passed to the event by the game

    In the main code of the element (the one entered in the Code section) you can access storage data with:

    GetStorage()

    .

    Example: display combat events sent to your client in a text element.

    Create a new text element. Go to the Behavior Tab in it's options. In the Code section add the following code:

    return GetStorage().v

    In the Events section add the following code:

    local function f(storage, event, ...)
    storage.v = select(2, ...)
    end
    AddEventListener(f, "COMBAT_LOG_EVENT_UNFILTERED")

    Alert handling
    Alert(animationIndex, texture, sound)

    animationIndex: index of an alert element where the icon will be displayed with respective animation
    texture: texture to be displayed in the animation
    sound: string representing a LibSharedMedia sound entry, for example: "clcInfo: explosion".

    Careful when you call it, it will restart play on every call.


    The following functions go into the alert edit box not the code one. Their usage is described in their name format.

    ...Expiration: triggers when element cooldown has less than timeLeft seconds
    ...Start: triggers when cooldown starts

    Arguments:

    id: used for multi bars or icons to trigger on respective element in the group
    animationIndex: index of an alert element where the icon will be displayed with respective animation
    timeLeft: how long on cooldown until it triggers
    sound: string representing a sound from the list available under the code box


    AddAlertIconExpiration(animationIndex, timeLeft, sound)
    AddAlertIconStart(animationIndex, sound)

    AddAlertMIconExpiration(id, animationIndex, timeLeft, sound)
    AddAlertMIconStart(id, animationIndex, sound)

    AddAlertBarExpiration(animationIndex, timeLeft, sound)
    AddAlertBarStart(animationIndex, sound)

    AddAlertMBarExpiration(id, animationIndex, timeLeft, sound)
    AddAlertMBarStart(id, animationIndex, sound)
    Anyone familiar with the addon could provide me with the code?

  2. #2
    I used to use Ingela's Rapture too a long time ago but switched to TellMeWhen and it can handle it as well as a few other jobs I give it.

    Gershuun @ Borean Tundra US - Interface & Macros Moderator

  3. #3
    Deleted
    I used Tellmewhen for a while also.But i prefer seeing icons in my screen over bars.
    Currently using ClCinfo for everything that i wanna track,buff/debuff durations,mana,raid buffs and more..
    I have all the codes i need besides Rapture one,but i looked everywhere and cannot find any code similar to it.
    So thought to ask here,to get some help.
    Last edited by mmoc800c2071bc; 2012-01-15 at 03:44 PM.

  4. #4
    Yeah I understand. I prefer icons too, and TellMeWhen is icons, not bars however.

    Edit: Sorry not familiar at all with clcInfo.
    Last edited by lawomous; 2012-01-15 at 06:54 PM.

    Gershuun @ Borean Tundra US - Interface & Macros Moderator

  5. #5
    Deleted
    Thx for replying.
    I guess i am gonna post on the paladin forums on the thread about clcinfo and hope that someone will help.
    Tho Rapture is kinda unique to track,since it doesn't give any buff that has duration and you can track it probably only from combat log,so i really don't know how the code would be like..
    Anyway,still looking for help!Anyone else using it?

  6. #6
    In the behavior tab for the icon:

    code editbox:
    Code:
    local rapture = ___e.___storage.rapture
    if GetTime() <= rapture.expire then return true, rapture.tex, rapture.start, 12, 1 end
    events editbox (scroll down for it):
    Code:
    local pguid = UnitGUID("player")
    ___e.___storage.rapture = { start = 0, expire = 12, tex = GetSpellTexture(47755)}
    local function cleu(storage, event, timestamp, combatEvent, hideCaster, sourceGUID, sourceName, sourceFlags, sourceRaidFlags, destGUID, destName, destFlags, destRaidFlags, spellId)
    	if spellId == 47755 and sourceGUID == pguid and combatEvent == "SPELL_ENERGIZE" then
    		local t = GetTime()
    		storage.rapture.start = t
    		storage.rapture.expire = t + 12
    	end	
    end
    AddEventListener(cleu, "COMBAT_LOG_EVENT_UNFILTERED")

  7. #7
    Deleted
    It works!
    Thank you so much abijax

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •