Quantcast
WoWInterface - View Single Post - 'My' ClassPower element seems to crash with '/fstack'
View Single Post
10-11-18, 12:48 AM   #3
Lyak
A Cyclonian
Join Date: Jul 2018
Posts: 46
Hi lightspark,

First of all, Thank you so much and I really appreciate your help!

I gave each of those elements a name to avoid '/fstack' crying

Yeap, it's definitely working

Lua Code:
  1. -- Class Power
  2. local classPower = CreateFrame("Frame", "$parentClassPower", self);
  3. classPower:SetHeight(setting.height);
  4. classPower:CustomSetPoint(setting.point);
  5.  
  6. for i = 1, 10 do
  7.     local bar = CreateFrame("StatusBar", "$parentBar" .. i, classPower);
  8.     bar:SetStatusBarTexture(LSM:Fetch("statusbar", setting.texture));
  9.     bar:SetWidth(setting.width);
  10.     bar:SetPoint("TOP");
  11.     bar:SetPoint("BOTTOM");
  12.  
  13.     bar:SetTemplate();
  14.     bar:SetBackground();
  15.  
  16.     if i == 1 then
  17.         bar:SetPoint("LEFT");
  18.     else
  19.         bar:SetPoint("LEFT", classPower[i - 1], "RIGHT", 3, 0);
  20.     end
  21.  
  22.     classPower[i] = bar;
  23. end
  24.  
  25. classPower.UpdateColor = ClassPowerUpdateColor;
  26. classPower.PostUpdate = ClassPowerPostUpdate;
  27.  
  28. self.ClassPower = classPower;

So, I do get that it's happening because of nested frames, with numeric as their key instead of string for inner frames, where inner frames do not have their unique name.

But why...?

I had a look at Blizzard_DebugTools-1.0.lua as stated on a error log, but it's totally out of my field
  Reply With Quote