Addon from WOTLK to WOTLKclassic

I trying to make addon work (CLC_DK 3.1 wersion for 3.3.5) on WOTLKclassic.
I get to a problem where i dont know how to make it work right. Can someone help witch solwing this problem?

5x CLC_DK\CLC_DK-3.1.lua:81: attempt to call method 'RegisterForClicks' (a nil value)
[string "@CLC_DK\CLC_DK-3.1.lua"]:81: in main chunk

Locals:
CLCDK = <unnamed> {
 0 = <userdata>
 OnBackdropLoaded = <function> defined @SharedXML\Backdrop.lua:152
 Center = <unnamed> {
 }
 GetBackdropColor = <function> defined @SharedXML\Backdrop.lua:390
 SetupTextureCoordinates = <function> defined @SharedXML\Backdrop.lua:214
 OnBackdropSizeChanged = <function> defined @SharedXML\Backdrop.lua:182
 HasBackdropInfo = <function> defined @SharedXML\Backdrop.lua:278
 SetBackdropBorderColor = <function> defined @SharedXML\Backdrop.lua:422
 RightEdge = <unnamed> {
 }
 backdropInfo = <table> {
 }
 BottomEdge = <unnamed> {
 }
 GetEdgeSize = <function> defined @SharedXML\Backdrop.lua:188
 BottomLeftCorner = <unnamed> {
 }
 BottomRightCorner = <unnamed> {
 }
 TopEdge = <unnamed> {
 }
 ApplyBackdrop = <function> defined @SharedXML\Backdrop.lua:294
 SetBackdrop = <function> defined @SharedXML\Backdrop.lua:329
 ClearBackdrop = <function> defined @SharedXML\Backdrop.lua:282
 TopRightCorner = <unnamed> {
 }
 GetBackdropBorderColor = <function> defined @SharedXML\Backdrop.lua:409
 GetBackdrop = <function> defined @SharedXML\Backdrop.lua:347
 TopLeftCorner = <unnamed> {
 }
 SetupPieceVisuals = <function> defined @SharedXML\Backdrop.lua:246
 SetBackdropColor = <function> defined @SharedXML\Backdrop.lua:399
 LeftEdge = <unnamed> {
 }
 SetBorderBlendMode = <function> defined @SharedXML\Backdrop.lua:266
}
spec = nil
GoD = nil
FS = nil
updatetimer = 0
runes_colour = <table> {
 1 = <table> {
 }
 2 = <table> {
 }
 3 = <table> {
 }
 4 = <table> {
 }
}
spells = <table> {
 Strangulate = "Strangulate"
 Death and Decay = "Death and Decay"
 Blood Strike = "Blood Strike"
 Mind Freeze = "Mind Freeze"
 Blood Tap = "Blood Tap"
 Blood Plague = "Blood Plague"
 Army of the Dead = "Army of the Dead"
 Death Strike = "Death Strike"
 Raise Ally = "Raise Ally"
 Hysteria = "Unholy Frenzy"
 Obliterate = "Obliterate"
 Desolation = "Desolation"
 Anti-Magic Shell = "Anti-Magic Shell"
 Frost Strike = "Frost Strike"
 Frost Fever = "Frost Fever"
 Death Grip = "Death Grip"
 Summon Gargoyle = "Summon Gargoyle"
 Scourge Strike = "Scourge Strike"
 Raise Dead = "Raise Dead"
 Pestilence = "Pestilence"
 Icebound Fortitude = "Icebound Fortitude"
 Howling Blast = "Howling Blast"
 Killing Machine = "Killing Machine"
 Icy Touch = "Icy Touch"
 Bone Shield = "Bone Shield"
 Empower Rune Weapon = "Empower Rune Weapon"
 Death Pact = "Death Pact"
 Unbreakable Armor = "Unbreakable Armor"
 Horn of Winter = "Horn of Winter"
 Death Coil = "Death Coil"
 Ghoul Frenzy = "Ghoul Frenzy"
 Heart Strike = "Heart Strike"
 Plague Strike = "Plague Strike"
 Freezing Fog = "Freezing Fog"
 Dark Command = "Dark Command"
}
(*temporary) = nil
(*temporary) = <unnamed> {
 0 = <userdata>
 OnBackdropLoaded = <function> defined @SharedXML\Backdrop.lua:152
 Center = <unnamed> {
 }
 GetBackdropColor = <function> defined @SharedXML\Backdrop.lua:390
 SetupTextureCoordinates = <function> defined @SharedXML\Backdrop.lua:214
 OnBackdropSizeChanged = <function> defined @SharedXML\Backdrop.lua:182
 HasBackdropInfo = <function> defined @SharedXML\Backdrop.lua:278
 SetBackdropBorderColor = <function> defined @SharedXML\Backdrop.lua:422
 RightEdge = <unnamed> {
 }
 backdropInfo = <table> {
 }
 BottomEdge = <unnamed> {
 }
 GetEdgeSize = <function> defined @SharedXML\Backdrop.lua:188
 BottomLeftCorner = <unnamed> {
 }
 BottomRightCorner = <unnamed> {
 }
 TopEdge = <unnamed> {
 }
 ApplyBackdrop = <function> defined @SharedXML\Backdrop.lua:294
 SetBackdrop = <function> defined @SharedXML\Backdrop.lua:329
 ClearBackdrop = <function> defined @SharedXML\Backdrop.lua:282
 TopRightCorner = <unnamed> {
 }
 GetBackdropBorderColor = <function> defined @SharedXML\Backdrop.lua:409
 GetBackdrop = <function> defined @SharedXML\Backdrop.lua:347
 TopLeftCorner = <unnamed> {
 }
 SetupPieceVisuals = <function> defined @SharedX

What did you change so far? RegisterForClicks should exist for every frame, so that would likely mean that the CLCDK variable is nil at that point instead.

You have better chances looking for a Retail addon that does what you want and ports it to Classic WOTLK than an actual WOTLK addon.

Keep in mind that even if Classic WOTLK is based on WOTLK it actually all Retail modern Lua version and Blizzard’s API changes that have happened in the last 10 years. The only difference is that Blizzard has disabled in Classic WOTLK UI and APIs things that are not present in that version like Guild Achievements.

So, porting an addon from Retail to Classic WOTLK could be easy, but porting an addon from WOTLK to Classic WOTLK is extremely hard, you have to adapt the addon for 10 years of Lua changes.

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.