rgd87 / Aptechka

WoW Addon - Raid Frames
http://www.wowinterface.com/downloads/info14339-Injector.html
33 stars 9 forks source link

Classic SoD Error - 'assignto' nil value in function ListSpellsForWidget #120

Open cdmichaelb opened 6 months ago

cdmichaelb commented 6 months ago

I'm not sure if it's related to this, but I can't get spell traces to work for shaman, the precreated traces nor custom created traces. Doesn't work if I use SoD or normal spells (such as Lesser Healing Wave id 8004) They seem to work fine on priest, even for SoD Spells (although there are retail equivilents). Unsure if this is SoD exclusive error.

1x Aptechka/Aptechka.lua:3747: attempt to index field 'assignto' (a nil value) [string "@Aptechka/Aptechka.lua"]:3747: in function `ListSpellsForWidget' [string "@Aptechka/Options/WidgetForms.lua"]:189: in function <Aptechka/Options/WidgetForms.lua:187>

[string "@Altoholic/libs/AceGUI-3.0-41/AceGUI-3.0.lua"]:66: in function <...faceAltoholic/libs/AceGUI-3.0/AceGUI-3.0.lua:64> [string "@Altoholic/libs/AceGUI-3.0-41/AceGUI-3.0.lua"]:300: in function `Fire' [string "@Altoholic/libs/AceGUI-3.0-41/widgets/AceGUIWidget-Button.lua"]:26: in function <...olic/libs/AceGUI-3.0/widgets/AceGUIWidget-Button.lua:25>

Locals: self = Aptechka { 0 = UNIT_MAXPOWER = defined @Aptechka/Aptechka.lua:1474 loadedAuras =

{ } UNIT_AFK_CHANGED = defined @Aptechka/Aptechka.lua:1407 ForEachFrame = defined @Aptechka/Aptechka.lua:1918 FrameColorize = defined @Aptechka/Aptechka.lua:2002 UNIT_MAXHEALTH = defined @Aptechka/Aptechka.lua:1114 FrameStartTrace = defined @Aptechka/Aptechka.lua:1264 ScanAuras = defined @Aptechka/Aptechka.lua:3463 IsGroupEnabled = defined @Aptechka/Aptechka.lua:2336 FrameUpdateIncomingCast = defined @Aptechka/Aptechka.lua:4208 FrameUpdateStagger = defined @Aptechka/Aptechka.lua:1702 RepositionAnchors = defined @Aptechka/Aptechka.lua:2512 RAID_TARGET_UPDATE = defined @Aptechka/Aptechka.lua:1913 FrameReadyCheckFinished = defined @Aptechka/Aptechka.lua:1985 NormalizeWidgetContent = defined @Aptechka/frame.lua:627 Reconfigure = defined @Aptechka/Aptechka.lua:910 UNIT_HEAL_PREDICTION = defined @Aptechka/Aptechka.lua:426 PLAYER_LOGIN = defined @Aptechka/Aptechka.lua:299 FixWidgetsAfterUpgrade = defined @Aptechka/frame.lua:93 UNIT_SPELLCAST_SENT = defined @Aptechka/Aptechka.lua:1672 UNIT_SPELLCAST_DELAYED = defined @Aptechka/Aptechka.lua:4298 PLAYER_FOCUS_CHANGED = defined @Aptechka/Aptechka.lua:1958 Lock = defined @Aptechka/Aptechka.lua:3730 db =
{ } ReconfigureTestHeaders = defined @Aptechka/frame.lua:3889 CreateCoordStatusBar = defined @Aptechka/frame.lua:3745 SafeCall = defined @Aptechka/Aptechka.lua:2619 EffectListPostUpdate = defined @Aptechka/Aptechka.lua:3355 GenerateMergedConfig = defined @Aptechka/Aptechka.lua:709 ShakeUnitButtons = defined @Aptechka/Aptechka.lua:2146 TestDebuffSlotsForUnit = defined @Aptechka/Aptechka.lua:3564 ToggleCompactRaidFrames = defined @Aptechka/Aptechka.lua:826 FrameUpdateUnitColor = defined @Aptechka/Aptechka.lua:929 DispelTypeProc = defined @Aptechka/Aptechka.lua:3399 UpdateWidget = defined @Aptechka/Aptechka.lua:2895 FrameCheckPhase = defined @Aptechka/Aptechka.lua:1218 TestCastBars = defined @Aptechka/Aptechka.lua:3611 UNIT_ENTERED_VEHICLE = defined @Aptechka/Aptechka.lua:1584 INCOMING_RESURRECT_CHANGED = defined @Aptechka/Aptechka.lua:1213 FrameUpdateRaidTarget = defined @Aptechka/Aptechka.lua:1905 GetCurrentGroupType = defined @Aptechka/Aptechka.lua:1840 ReconfigureProtected = defined @Aptechka/Aptechka.lua:982 UpdateAbsorbBarConfig = defined @Aptechka/Aptechka.lua:1065 FrameReadyCheckConfirm = defined @Aptechka/Aptechka.lua:1970 FrameUpdateName = defined @Aptechka/Aptechka.lua:862 PrintDeadAssignmentWarning = defined @Aptechka/Aptechka.lua:2813 UNIT_HEAL_ABSORB_AMOUNT_CHANGED = defined @Aptechka/Aptechka.lua:1102 ToggleUnlock = defined @Aptechka/Aptechka.lua:3722 UNIT_THREAT_SITUATION_UPDATE = defined @Aptechka/Aptechka.lua:1668

d87 commented 6 months ago

Hmm, are you sure you have those spells assigned somewhere? That error is very benign and only affects GUI, nothing to do with traces not working. Otherwise, traces should work fine as long as spell ID is correct, and each rank has its own spell ID btw, in case you added something.

d87 commented 6 months ago

Post me your config from WTF/.../SavedVariables/Aptechka.lua if you won't fix it

cdmichaelb commented 6 months ago

I stripped out my character names if that's ok, but here it is. I tried 399954 because the others weren't working.

    ["DB_VERSION"] = 15,
    ["global"] = {
        ["customDebuffHighlights"] = {
            ["Custom"] = {
                [23230] = {
                    23230, -- [1]
                    3, -- [2]
                    "Warrior Blood Fury debuff", -- [3]
                },
            },
        },
        ["customBlacklist"] = {
            [26218] = true,
        },
    },
    ["profiles"] = {
        ["Default"] = {
            ["y"] = -198.0948944091797,
            ["x"] = -407.3653259277344,
            ["showCCList"] = true,
            ["petGroup"] = true,
            ["clampIncomingHeal"] = false,
            ["showTargetedCount"] = true,
        },
        ["Shaman"] = {
            ["y"] = -198.0948944091797,
            ["x"] = -407.3653259277344,
            ["showTargetedCount"] = true,
            ["petGroup"] = true,
        },
    },
}
AptechkaConfigCustom = {
    ["HUNTER"] = {
    },
    ["WARRIOR"] = {
    },
    ["WARLOCK"] = {
    },
    ["SHAMAN"] = {
        ["traces"] = {
            [415240] = {
                ["clones"] = false,
                ["template"] = "HealTrace",
                ["isAdded"] = true,
                ["id"] = 415240,
                ["name"] = "Healing RainTrace",
            },
            [399954] = {
                ["name"] = "Chest Rune AbilityTrace",
                ["isAdded"] = true,
                ["id"] = 399954,
                ["assignto"] = {
                    ["spell1"] = true,
                },
                ["fade"] = 0.7,
            },
            [8004] = {
                ["id"] = 8004,
                ["template"] = "HealTrace",
                ["name"] = "Lesser Healing WaveTrace",
                ["isAdded"] = true,
            },
        },
        ["auras"] = {
            [415240] = {
                ["isAdded"] = true,
                ["id"] = 415240,
                ["text"] = "R",
                ["assignto"] = {
                    ["icon"] = false,
                    ["spell1"] = false,
                    ["border"] = true,
                    ["totemCluster1"] = false,
                },
                ["infoType"] = "DURATION",
                ["isMine"] = true,
                ["name"] = "Healing Rain",
                ["realID"] = 415240,
                ["priority"] = 75,
                ["color"] = {
                    0.7647059559822083, -- [1]
                    1, -- [2]
                    0.5215686559677124, -- [3]
                    1, -- [4]
                },
            },
        },
    },
    ["MAGE"] = {
    },
    ["DRUID"] = {
    },
    ["GLOBAL"] = {
        ["auras"] = {
            [401859] = {
                ["clones"] = {
                    [401880] = true,
                    [401882] = true,
                    [401877] = true,
                    [402832] = true,
                    [401863] = true,
                },
                ["global"] = true,
                ["isAdded"] = true,
                ["color"] = {
                    1, -- [1]
                    0, -- [2]
                    0.5254902243614197, -- [3]
                    1, -- [4]
                },
                ["isMine"] = false,
                ["infoType"] = "COUNT",
                ["name"] = "Prayer of Mending",
                ["maxCount"] = 5,
                ["assignto"] = {
                    ["spell1"] = false,
                    ["bar4text"] = true,
                    ["bar4"] = true,
                },
                ["realID"] = 401859,
                ["id"] = 401859,
                ["foreigncolor"] = {
                    1, -- [1]
                    0.05882353335618973, -- [2]
                    0.5372549295425415, -- [3]
                },
            },
        },
    },
    ["PRIEST"] = {
    },
}
d87 commented 6 months ago

Alright, I didn't find anything wrong there, just wrong spell IDs. But I separated Lesser Healing Wave from Healing Wave in the config, maybe that was the issue somehow. And I added /apt debug command in the update to look for the correct spell IDs. Just look for the one with SPELL_HEAL event or SPELL_PRERIODIC_HEAL for Healing Rain.

cdmichaelb commented 6 months ago

But I separated Lesser Healing Wave from Healing Wave in the config, maybe that was the issue somehow. This fixed the LHW issue.

And I added /apt debug command in the update to look for the correct spell IDs. Just look for the one with SPELL_HEAL event or SPELL_PRERIODIC_HEAL for Healing Rain.

This helped, and I got it working for healing rain, I noticed that the changes don't actually take effect until a /reload though. Not sure if that's intentional or bug.

Healing Stream Totem still doesn't work. I'm guessing because it's not actually cast by the player, but instead cast by the totem. It's not a huge deal, just thought it'd be fun to test.

ID: 5672 Healing Stream SPELL_PERIODIC_HEAL 8465 Creature-0-5163-1-18526-3527-000013B969 ==> Creature-0-5163-1-18526-3527-000013B969 8465 6