GSE: Sequences, Variables, Macros

GSE: Sequences, Variables, Macros

8M Downloads

[BUG] Cataclysm Classic: GetSpellBookItemInfo() invalid spell slot

Road-block opened this issue ยท 7 comments

commented

๐Ÿ”ต Describe the bug:
A clear and concise description of what the bug is.

๐Ÿ”ต To reproduce: (Steps to reproduce the behavior)
Happens on a fresh login

๐Ÿ”ต The error:
Paste the error message in this blockquote.

4x GSE_Utils/Events.lua:121: GetSpellBookItemInfo(): Invalid spell slot
[string "=[C]"]: in function `GetSpellBookItemInfo'
[string "@GSE_Utils/Events.lua"]:121: in function `?'
[string "@Ace3/CallbackHandler-1.0-8/CallbackHandler-1.0.lua"]:109: in function <...Ons/Ace3/CallbackHandler-1.0/CallbackHandler-1.0.lua:109>
[string "=[C]"]: ?
[string "@Ace3/CallbackHandler-1.0-8/CallbackHandler-1.0.lua"]:19: in function <...Ons/Ace3/CallbackHandler-1.0/CallbackHandler-1.0.lua:15>
[string "@Ace3/CallbackHandler-1.0-8/CallbackHandler-1.0.lua"]:54: in function `Fire'
[string "@Ace3/AceEvent-3.0-4/AceEvent-3.0.lua"]:120: in function <Ace3/AceEvent-3.0/AceEvent-3.0.lua:119>

Locals:
(*temporary) = <table> {
 castTime = 0
 name = "LOGINEFFECT"
 minRange = 0
 originalIconID = 136243
 iconID = 136243
 maxRange = 0
 spellID = 836
}

๐Ÿ”ต Screenshots:
If applicable, add screenshots to help explain your problem.

๐Ÿ”ต Expected behavior:
N/A

๐Ÿ”ต GSE.lua file:
Please provide your GSE.lua file or the export string for the specific macro that is causing an issue.

  • To find the GSE.lua file:
  1. First, make sure you have enabled the "File Name Extensions" checkbox in Explorer (View tab)
  2. Browse to C:\path\to\wow\_retail_\WTF\Account\YourAccountName\SavedVariables\ or /path/to/WoW/_retail_/WTF/Account/YourAccountName/SavedVariables
  3. Copy the GSE.lua file to your Desktop
  4. Rename this copy to GSA.lua.txt
  5. Then just drag it here in your message
  • Note: If you do not include your GSE.lua file you are wasting your time and mine. 90% of the time, the first thing I will ask for is "Can you please upload your GSE.lua file?". This file is needed with the error to work out Why that error occured for you.

๐Ÿ”ต Desktop (please complete the following information):

  • OS: Windows 10 64bit
  • Game Version : Cataclysm Classic 4.4.1

๐Ÿ”ต GSE Version:

๐Ÿ”ต Additional context:
Add any other context about the problem here.

commented

https://www.wowhead.com/cata/spell=836/logineffect
seems to be the spell to cause the error as part of the UNIT_SPELLCAST_SUCCEEDED handler in GSE_Utils.

commented

Oh I see what's the issue.
C_Spell.GetSpellInfo return is a spellInfo array not a tuple.
Something like this maybe for the L:119-130 block

        else
            local spellInfo = C_Spell.GetSpellInfo(elements[6])
            local spell = spellInfo and spellInfo.name
            local fskilltype, _ = spell and GetSpellBookItemInfo(spell)
            if not GSE.isEmpty(fskilltype) then
                if GSE.RecorderActive then
                    GSE.GUIRecordFrame.RecordSequenceBox:SetText(
                        GSE.GUIRecordFrame.RecordSequenceBox:GetText() .. "/cast " .. spell .. "\n"
                    )
                end
            end
        end
commented

I dont have Cataclysm installed so I cant test this yet. In the mean time there is an alpha available to GSE Patrons on the GSE Discord and will be on Curse in the next few hours. Let me know how it goes.

3.2.20-a-1-g01fae92-PatronBuild

commented

GSE isn't throwing errors like it used to, although my sequence feels less efficient using 3.2.20-a-1-g01fae92-PatronBuild, which is subjective.

commented

@Gutitout Yeah the changes in this release are related to plugins with no changes to sequence execution. This error was caused as Blizzard removed the backwards compatibility on Cata Classic.

commented

Oh I see what's the issue. C_Spell.GetSpellInfo return is a spellInfo array not a tuple. Something like this maybe for the L:119-130 block

    else
        local spellInfo = C_Spell.GetSpellInfo(elements[6])
        local spell = spellInfo and spellInfo.name
        local fskilltype, _ = spell and GetSpellBookItemInfo(spell)
        if not GSE.isEmpty(fskilltype) then
            if GSE.RecorderActive then
                GSE.GUIRecordFrame.RecordSequenceBox:SetText(
                    GSE.GUIRecordFrame.RecordSequenceBox:GetText() .. "/cast " .. spell .. "\n"
                )
            end
        end
    end

not to hijack your issue, but this also happens in classic era (anniversary realms)

and testing the above fix does indeed keep the login error from happening

commented

This is the error I am getting:

151x GSE_Utils/Events.lua:121: GetSpellBookItemInfo(): Invalid spell slot
[string "=[C]"]: in function GetSpellBookItemInfo' [string "@GSE_Utils/Events.lua"]:121: in function ?'
[string "@AtlasLootClassic/Libs/CallbackHandler-1.0-8/CallbackHandler-1.0.lua"]:109: in function <...sic/Libs/CallbackHandler-1.0/CallbackHandler-1.0.lua:109>
[string "=[C]"]: ?
[string "@AtlasLootClassic/Libs/CallbackHandler-1.0-8/CallbackHandler-1.0.lua"]:19: in function <...sic/Libs/CallbackHandler-1.0/CallbackHandler-1.0.lua:15>
[string "@AtlasLootClassic/Libs/CallbackHandler-1.0-8/CallbackHandler-1.0.lua"]:54: in function `Fire'
[string "@BagBrother/libs/AceEvent-3.0-4/AceEvent-3.0.lua"]:120: in function <BagBrother/libs/AceEvent-3.0/AceEvent-3.0.lua:119>

Locals:
(*temporary) =

{
castTime = 0
name = "Precious's Ribbon"
minRange = 0
originalIconID = 134411
iconID = 134411
maxRange = 0
spellID = 72968
}