PDA

View Full Version : Help! Changes to Arcane Background code in new update?



Leperchan5
May 1st, 2018, 05:26
Hi, I had made an extension previously that added a new Arcane background and had it loaded after any setting but with the new update I'm getting a "nil" value, when it loads... So any help would be useful.

I used this post to help me with my code.

https://www.fantasygrounds.com/forums/showthread.php?26363-Savage-Worlds-API&highlight=arcane+background

Trenloe
May 1st, 2018, 05:42
What is the exact error? It will also help if you include the extension code (a copy of the extension would be best).

Leperchan5
May 1st, 2018, 06:00
"Script Error: [string "scripts/launcher.lua"]:8: attempt to index global 'ArcanePropertyManager' (a nil value)"

Ikael
May 1st, 2018, 12:56
When using v4.6 see the changelog note:

[Dev] ArcanePropertyManager refactored to ArcaneManager

Leperchan5
May 1st, 2018, 16:24
Thanks, once I get home I'll redo it

Doswelk
May 1st, 2018, 18:21
Here's my DLR extension that adds all the extra arcane backgrounds, this is the contents of the .lua file


function onInit()
ArcaneManager.registerArcaneType("Blessed", "indicator_faith", "power_faith", {skill = "Faith", powerpoints = "main"})
ArcaneManager.registerArcaneType("Hexslinger", "indicator_magic", "power_magic", {skill = "Hexslinging", powerpoints = "main"})
ArcaneManager.registerArcaneType("Metal Mage", "indicator_faith", "power_magic", {skill = "Thaumaturgical Diffusion", powerpoints = "main"})
ArcaneManager.registerArcaneType("Voodooist", "indicator_faith", "power_faith", {skill = "Voodoo", powerpoints = "main"})
end

Leperchan5
May 1st, 2018, 18:28
Thanks I’ll check it out when I get home

Leperchan5
May 2nd, 2018, 00:24
Thanks everyone... it is fixed :)

Hendell
May 3rd, 2018, 01:54
I think the hellfrost setting has the same issue. I am not seeing the setting Arcane backgrounds listed now in the drop down box on the Powers tab of the character sheet.

Nyghtmare
May 3rd, 2018, 04:13
I think the hellfrost setting has the same issue. I am not seeing the setting Arcane backgrounds listed now in the drop down box on the Powers tab of the character sheet.
None of the Hellfrost arcane backgrounds are in the dropdown for me either... only the ones from the Core rules.

Doswelk
May 3rd, 2018, 07:28
The file is in my copy of the hellfrost module, but I am having real issues when I try and update the SVN right now

Here is the launcher.lua that should be in the ruleset:



function onInit()
-- unregister arcane backgrounds
-- ArcaneManager.unregisterType("Psionics") -- Psionics is added in Hellfrost Bestiary
ArcaneManager.unregisterType("Weird Science")
ArcaneManager.unregisterType("Super Powers")

-- new arcane background
ArcaneManager.registerArcaneType("Druidism", "indicator_magic", "power_magic", {skill = "Druidism", powerpoints = "main"})
ArcaneManager.registerArcaneType("Elementalism", "indicator_magic", "power_magic", {skill = "Elementalism", powerpoints = "main"})
ArcaneManager.registerArcaneType("Heahwisardry", "indicator_magic", "power_magic", {skill = "Heahwisardry", powerpoints = "main"})
ArcaneManager.registerArcaneType("Hrimwisardry", "indicator_magic", "power_magic", {skill = "Hrimwisardry", powerpoints = "main"})
ArcaneManager.registerArcaneType("Rune Magic", "indicator_magic", "power_magic", {powerpoints = "main", untraineddescription = "Rune Magic skill not set"})
ArcaneManager.registerArcaneType("Song Magic", "indicator_magic", "power_magic", {skill = "Song Magic", powerpoints = "main"})
ArcaneManager.registerArcaneType("Soul Binding", "indicator_magic", "power_magic", {skill = "Soul Binding", powerpoints = "main"})
ArcaneManager.registerArcaneType("Wind Priest", "indicator_magic", "power_magic", {skill = "Faith", powerpoints = "main"})
ArcaneManager.registerArcaneType("Glamour", "indicator_magic", "power_magic", {skill = "Glamour", powerpoints = "main"})
ArcaneManager.registerArcaneType("Solar Magic", "indicator_magic", "power_magic", {skill = "Solar Magic", powerpoints = "main"})
ArcaneManager.registerArcaneType("Demonism", "indicator_magic", "power_magic", {skill = "Demonic Magic", powerpoints = "main"})

-- setup desktop decal
OptionsManager.addOptionValue("DDCL", "Hellfrost", "desktopdecal_hellfrost")
OptionsManager.addOptionValue("DDCL", "HellfrostLogo", "desktopdecal_hellfrostlogo")
OptionsManager.addOptionValue("DDCL", "HellfrostDragon", "desktopdecal_hellfrostdragon")
OptionsManager.setOptionDefault("DDCL", "desktopdecal_hellfrost")
end

dstuffle
May 3rd, 2018, 15:34
If the setting has custom/new/overriding types of arcane powers, it needs to be updated.

Ikael
May 3rd, 2018, 16:15
I think the hellfrost setting has the same issue. I am not seeing the setting Arcane backgrounds listed now in the drop down box on the Powers tab of the character sheet.

Can you type /version in your FG and post whole result here? Hellfrost products have been updated to reflected required changes. If you are still seeing the issue try running FG Updater again.

EDIT: I was able to reproduce the situation. FG Updater is providing out-dated files regarding Hellfrost extensions. I have requested Smiteworks to look into this.

Nyghtmare
May 4th, 2018, 00:02
Looks like the update today fixed things. Once I ran the update and then closed out of FG and restarted it, all of the backgrounds were available once again in the dropdown on the POWER tab.

Thanks, guys!!

Hendell
May 4th, 2018, 01:27
Same here, everything looks good to go.

Thank you for the quick fix.

dstuffle
December 8th, 2018, 21:15
What are all the different icon that can be used?

indicator_Magic
indicator_Faith
Indicator_???

Ikael
December 8th, 2018, 21:20
What are all the different icon that can be used?

indicator_Magic
indicator_Faith
Indicator_???

Currently these are deprecated graphics. Originally they were to express different Arcane types in Power sheet but they are removed and won't be around much longer.

dstuffle
December 8th, 2018, 22:17
Can you tell me what the current/new icon names are?