Thread: 5E Character Wizard Bug Reports
-
June 6th, 2022, 14:13 #941
EDIT:
Spotted the actual issue...
in 'function getDefaultRaceTraitMod(nodeTrait)', you have..
for a1, sIncrease in v:gmatch("your (%w+) score increases by (%d+)") do
local nIncrease = tonumber(sIncrease) or 0;
table.insert(aIncreases, {stat = a1, increase = nIncrease})
end
for a1, sDecrease in v:gmatch("your (%w+) score is reduced by (%d+)") do
local nDecrease = tonumber(sDecrease) or 0;
table.insert(aIncreases, {stat = a1, increases = nDecrease * -1})
end
you have an extra 's'.. so the decrease entry in the table has no [v.increase] entry because its in [v.increases] by accident.
line 669
-pete
--------------------- original post --------------------
'Error in manager_charwizard.lua, line 815: table index is nil
issue is caused by,
In function 'function getDefaultRaceTraitMod(nodeTrait)' the use of "your (%w+) score is reduced by (%d+)", inserts into the 'aIncreases' table a stat and a negative value into 'increases' for the table entry.
Then in 'function applyRacialAbilityDefault(wndSummary, wList)', when it checks the 'if not tFinalChoices[v.increase] then' line the lua tries to store 'tFinalChoices[v.increase] = 1;' by accessing a negative array index due to 'v.increase' been negative.
-peteLast edited by bratch9; June 6th, 2022 at 14:18.
Forge Profile
DMsGuild Profile
Forge Modules: B9's Steel Defender.
Forge Extensions: B9's Spell Tokens, B9's Encumbrance Tweak, B9's Damage Per Round, B9's Surprise Round.
DMsGuild Extensions: Advanced Weapon Damage, Advanced Spell Damage, Aspect Of The Bear, Spell Long Rest For NPC, Spell Domain.
-
June 6th, 2022, 19:16 #942
Thanks for reporting the typo. I'll have that pushed with Tuesday's update. I haven't really looked into the negative modifiers, so I might want a closer look at the parsing of those, but will have this typo resolved with the weekly update.
Dominic Morta
Ruleset Developer
Smiteworks
How to zip up your campaign if the Developers ask for it-How to zip up your campaign if the Developers ask for it
How to provide an Unity Connection issue?-Connection Issues and What to Provide
Unity Updater issue?-Updater Issues
Classic and Unity Port Forwarding?-Fantasy Grounds Connections Explained
Comcast or Cox ISP User?-Comcast XFinity and Cox Users
Have a suggestion?-Feature Request
-
June 6th, 2022, 20:10 #943
Last edited by bratch9; June 6th, 2022 at 20:16.
Forge Profile
DMsGuild Profile
Forge Modules: B9's Steel Defender.
Forge Extensions: B9's Spell Tokens, B9's Encumbrance Tweak, B9's Damage Per Round, B9's Surprise Round.
DMsGuild Extensions: Advanced Weapon Damage, Advanced Spell Damage, Aspect Of The Bear, Spell Long Rest For NPC, Spell Domain.
-
June 6th, 2022, 20:25 #944
As I am not able to think off the top of my head where a negative ability score takes place in the WotC books, it must have been in there prior to me taking over the feature. I can fix the error report, but might take longer with it working as a negative result.
Dominic Morta
Ruleset Developer
Smiteworks
How to zip up your campaign if the Developers ask for it-How to zip up your campaign if the Developers ask for it
How to provide an Unity Connection issue?-Connection Issues and What to Provide
Unity Updater issue?-Updater Issues
Classic and Unity Port Forwarding?-Fantasy Grounds Connections Explained
Comcast or Cox ISP User?-Comcast XFinity and Cox Users
Have a suggestion?-Feature Request
-
June 6th, 2022, 20:32 #945
Ive dm'ed you a module that has negatives in to use. When using the non-wizard character create race drag on from the module the positive and negative stat changes are applied.
Having it not 'crash' the wizard is a good first step.. but I hope its a simple fix to get it working.. most of the code looks to be in place from what I can see.
-peteForge Profile
DMsGuild Profile
Forge Modules: B9's Steel Defender.
Forge Extensions: B9's Spell Tokens, B9's Encumbrance Tweak, B9's Damage Per Round, B9's Surprise Round.
DMsGuild Extensions: Advanced Weapon Damage, Advanced Spell Damage, Aspect Of The Bear, Spell Long Rest For NPC, Spell Domain.
-
June 7th, 2022, 17:20 #946
- Join Date
- Jan 2020
- Posts
- 31
Ok, this is probably more of a bug for the Modern Dark Theme, but I thought for the longest time that the "Level Up" part of the character wizard was just busted. But since it could've been an extension I run (I have a lot of extensions in my sessions) I wanted to do some digging first as to what extension it was before filing a report. (because surely if it was just totally busted it would've been fixed by now was my thinking). Got time to do that today
So turns out that you can't see the level up and level down arrows with the Modern Dark Theme. You just can't. At one point in the past there was a drop down menu for the level to go to, and that was what I was trying to use (clicks started doing nothing), and I couldn't see that there are now arrows pointing up, or down.
Once I switched my theme to the default I saw them, and then switched back to the Modern Dark Theme, and while I couldn't see them, I could click them. SMH. (not a huge deal, drag and drop a class level still worked fine).
-
June 7th, 2022, 17:24 #947
Thanks for the report. I'll pass this along to have it looked at.
Dominic Morta
Ruleset Developer
Smiteworks
How to zip up your campaign if the Developers ask for it-How to zip up your campaign if the Developers ask for it
How to provide an Unity Connection issue?-Connection Issues and What to Provide
Unity Updater issue?-Updater Issues
Classic and Unity Port Forwarding?-Fantasy Grounds Connections Explained
Comcast or Cox ISP User?-Comcast XFinity and Cox Users
Have a suggestion?-Feature Request
-
June 8th, 2022, 00:30 #948
EDIT NOTE: since the wizard has a check/warning for >20 stat value, with reduction support now... it might also need a <1 stat warning as well...
Had some spare time to look at the negative modifiers..
function applyRacialAbilityDefault(wndSummary, wList)
local aRaceIncreases, bTasha = CharWizardManager.getDefaultRaceMods(wList);
if bTasha then
return
end
local tSelectChoicesI = {};
local tSelectChoicesR = {};
for _,k in pairs(DataCommon.abilities) do
tSelectChoicesI[k] = { tooltip = "Select Ability to increase." };
tSelectChoicesR[k] = { tooltip = "Select Ability to reduce." };
end
local tFinalChoices = {};
local tFinalDefaults = {};
local bInnateIncrease = false;
for k,v in pairs(aRaceIncreases) do
if not tFinalChoices[v.increase] then
tFinalChoices[v.increase] = 1;
else
tFinalChoices[v.increase] = tFinalChoices[v.increase] + 1;
end
if v.stat ~= "any" then
tFinalDefaults[v.stat] = v.increase;
end
bInnateIncrease = true;
end
for k,v in pairs(tFinalChoices) do
CharWizardManager.createSelectionWindows(wList, "SELECT CHOICE RACIAL MOD " .. (k < 0 and '' or '+') .. k, (k < 0 and tSelectChoicesR or tSelectChoicesI), v);
end
if bInnateIncrease then
for _,vModWin in pairs(wList.getWindows()) do
if vModWin.group_name.getValue():lower():match("selec t choice racial mod") then
local sSign, sIncrease = vModWin.group_name.getValue():lower():match("selec t choice racial mod ([%+%-]*)(%d+)");
local nIncrease = tonumber(sIncrease) or 0;
if sSign and sSign == '-' then
nIncrease = -nIncrease;
end
for k,v in pairs(tFinalDefaults) do
if v == nIncrease then
for _,vMod in pairs(vModWin.selection_window.getWindows()) do
if vMod.name.getValue():lower() == k then
vMod.bname.onButtonPress();
break
end
end
end
end
end
end
return true
end
return
end
function calcRacialAbilityMods(wndSummary, wList)
CharWizardManager.clearRacialAbilityMods(wndSummar y);
local tRacialMod = {};
for _,wGroup in pairs(wList.getWindows()) do
local sGroup = wGroup.group_name.getValue();
if sGroup:match("^CHOICE RACIAL MOD") then
local sSign, sValue = sGroup:match("([%+%-]*)(%d+)");
local nIncrease = tonumber(sValue) or 0;
if sSign and sSign == '-' then
nIncrease = -nIncrease;
end
if nIncrease then
for _,wSelection in pairs(wGroup.selection_window.getWindows()) do
if wSelection.value.getValue() == "1" then
local sAbilityLower = wSelection.name.getValue():lower();
tRacialMod[sAbilityLower] = (tRacialMod[sAbilityLower] or 0) + nIncrease;
end
end
end
end
end
for k,v in pairs(tRacialMod) do
if StringManager.contains(DataCommon.abilities, k) then
wndSummary.summary.subwindow["summary_race_" .. k].setValue(v);
end
end
wndSummary.calcSummaryStats();
endLast edited by bratch9; June 8th, 2022 at 00:38.
Forge Profile
DMsGuild Profile
Forge Modules: B9's Steel Defender.
Forge Extensions: B9's Spell Tokens, B9's Encumbrance Tweak, B9's Damage Per Round, B9's Surprise Round.
DMsGuild Extensions: Advanced Weapon Damage, Advanced Spell Damage, Aspect Of The Bear, Spell Long Rest For NPC, Spell Domain.
-
June 8th, 2022, 02:05 #949
I looked over your Forge item and looks like you are trying to use it to not build a character but a companion/summoner. If I am wrong, please clarify. The race you are attempting to use is to facilitate this creation and such is not a published race. As the attempt to work with third party products and homebrew is still not fully investigated and worked on, this will not be a quick addition to the code. Currently, I'm not aware of negative ability scores for any race currently from WotC products and that is why the code shored up this logic. The code you have found was remnants from the previous developer attempting to get this ball rolling, but never fully realized. I can't promise any ETA on this expanded to include reduction. So it might be some time till it is completed.
Dominic Morta
Ruleset Developer
Smiteworks
How to zip up your campaign if the Developers ask for it-How to zip up your campaign if the Developers ask for it
How to provide an Unity Connection issue?-Connection Issues and What to Provide
Unity Updater issue?-Updater Issues
Classic and Unity Port Forwarding?-Fantasy Grounds Connections Explained
Comcast or Cox ISP User?-Comcast XFinity and Cox Users
Have a suggestion?-Feature Request
-
June 8th, 2022, 02:15 #950Forge Profile
DMsGuild Profile
Forge Modules: B9's Steel Defender.
Forge Extensions: B9's Spell Tokens, B9's Encumbrance Tweak, B9's Damage Per Round, B9's Surprise Round.
DMsGuild Extensions: Advanced Weapon Damage, Advanced Spell Damage, Aspect Of The Bear, Spell Long Rest For NPC, Spell Domain.
Thread Information
Users Browsing this Thread
There are currently 1 users browsing this thread. (0 members and 1 guests)
Bookmarks