• 0

    posted a message on Addon comms changes
    Could it be that the GUILD addon channel is ready before the WHISPER addon channel is? I have an addon that upon login send a message to the GUILD addon channel and other clients report back via the WHISPER addon channel. But for some reason, the whispers do not always seem to make it back. Any insight knowledge here?
    Posted in: Lua Code Discussion
  • 0

    posted a message on Addon comms changes
    Quote from Xinhuan
    Any messages (both normal and addon ones) sent between PLAYER_LEAVING_WORLD and PLAYER_ENTERING_WORLD events will be lost. Make sure your addon doesn't send any messages between those 2 events. (yes, other events can happen between those 2 events).


    Ok, I can check for that, but will any messages sent to me during that time also not reach me?
    Posted in: Lua Code Discussion
  • 0

    posted a message on Tabbing to windows blocks chat/addon messages?
    Quote from Xinhuan
    It is generally safe after the first GUILD_ROSTER_UPDATE event, which happens after a GuildRoster() call.


    Is this the earliest time when it is safe to use the GUILD addon channel? Because that even doesn't happen all that often. :-P
    Posted in: Lua Code Discussion
  • 0

    posted a message on Tabbing to windows blocks chat/addon messages?
    I am currently trying to have my addon log off from the GUILD channel when it has received 2-3 events with at least 1 second intervals without any OnUpdate calls having happened. When the OnUpdate calls start flowing again, the addon will log on again.

    Cumbersome, and annoying, as the time with wow minimized would be a good time to exchange the data.
    Posted in: Lua Code Discussion
  • 0

    posted a message on Tabbing to windows blocks chat/addon messages?
    Just tried with RegisterAllEvents but it failed as in a isolated area, no events are occuring for a long time. Is there any way to cause events to happen in the background without triggering any communication? Sending addon messages to yourself constantly would work, but consumes network bandwidth and loads the server with (I hope) needless work.
    Posted in: Lua Code Discussion
  • 0

    posted a message on Tabbing to windows blocks chat/addon messages?
    After a login, when is it safe to use the guild channel? I think I am sending stuff too early and while I could implement a delay, I would rather use an event...
    Posted in: Lua Code Discussion
  • 0

    posted a message on Tabbing to windows blocks chat/addon messages?
    Quote from funkydude
    OnUpdates not working during alt tab has been happening since sometime during WotlK, it's "intended" though I can't remember the specific details/reasoning behind the issue itself someone else will probably remember. The general advice is play windowed if you want to work on different tabs whilst playing.


    Not really the solution I can recommend to all the users of my addon. :-P

    Also, having wow windows and minimizing it will still stop the OnUpdate events from happening.

    Is there an even that trigger if wow is minimized/restored? I could use that to register/unregister all events and create pseudo OnUpdate calls.
    Posted in: Lua Code Discussion
  • 0

    posted a message on Tabbing to windows blocks chat/addon messages?
    Currently I am thinking about using RegisterAllEvents and in the event handler use GetTime to at least get some processing done, but RegisterAllEvents isn't really a favorite of mine to use...
    Posted in: Lua Code Discussion
  • 0

    posted a message on Tabbing to windows blocks chat/addon messages?
    Hmm the problem is different to what I thought. The messages do arrive (tested with /eventtrace) but I put my messages in a queue and pop them in a fixed rate (to prevent bursts causing screen freeze). This works fine, but it seems my scheduler is stopped when the game is minimized.

    I listen to update events like this:

    frame = CreateFrame("Frame")
        frame:SetScript("OnUpdate", OnUpdate)


    This apparently isn't enough to cause the events to keep running when the game is minimized. The Frame update event doesn't fire in that case.

    How should I create a frame or attach an OnUpdate script so it will continue to run even when wow is minimized?
    Posted in: Lua Code Discussion
  • 0

    posted a message on Tabbing to windows blocks chat/addon messages?
    It seems (for some time already) that if a client tabs out to windows, that wow blocks incoming messages (both chat and addon) and replays them when the player switches back to wow. Does anyone know more about this issue? It wreaks havoc with my addon. :-/
    Posted in: Lua Code Discussion
  • 0

    posted a message on Addon comms changes
    My issue seems to be something else. I'll start a new thread.
    Posted in: Lua Code Discussion
  • 0

    posted a message on Addon comms changes
    It seems this issue is still a problem somehow. A guild member and me were in Orgrimmar and we both have the same (my) addon loaded that communicates using the guild addon channel. When he ported to Tol Barad, apparently a guild addon message was lost/deleted by the client/server (not by the addon). Or is the addon channel known to be lossy? I never experienced this using the chat channels (which I may just revert to if this is to be expected). :-/
    Posted in: Lua Code Discussion
  • 0

    posted a message on Detecting update of tradeskills
    What would be the most efficient way to detect if the player has just learned a new recipe?

    Is it listening to CHAT_MSG_SYSTEM when arg1 looks like ERR_LEARN_RECIPE_S (eg. "You have learned how to create a new item: Bristle Whisker Catfish.")

    or is there a better way?

    When the event occurs, I'll read the updated tradeskill link and continue from there. I don't need to know the recipe learned from the event.
    Posted in: Lua Code Discussion
  • 0

    posted a message on Read guild tradeskill links
    Is it possible to gather the tradeskill links from all players in the guild you are in? I can't seem to find the API for it.
    Posted in: Lua Code Discussion
  • 0

    posted a message on Max lines in tooltip?
    I think I am referencing invalid item:* links (as they are provided by LibPeriodicTable) and asking wow to fetch the tooltip. But I thought fetching invalid items wouldn't crash wow. Worst I'd expect to be disconnected...

    But the client crash occurs after my code has enumerated all the links (extracted name and quality info) and wow often manages to display the tooltip before actually crashing. This strengthens my suspicion that something is corrupting wow's memory, causing a delayed crash. I can only hope Blizzard puts in better API parameter verification... :-P

    For now I have worked around it my using GetItemInfo directly instead of using a mix of GetItemInfo(itemlink) and tooltip:SetHyperlink(itemlink) to get item and enchant information (as this can crash wow).
    Posted in: Lua Code Discussion
  • To post a comment, please or register a new account.