PDA

View Full Version : customdice script fails to load



JMessmer
October 30th, 2019, 22:28
I am seeing this behaviour in FGU only with my custom Dark Eye ruleset.

The console shows this error:
[10/30/2019 10:10:27 PM] [WARNING] Could not load script file () (customdice_scripts/customdice_3.lua)
[10/30/2019 10:10:27 PM] [WARNING] Could not load script file (d3) (customdice_scripts/customdice_3.lua)

Definition in gameelements.xml
<customdie name="d3">
<model>d6</model>
<menuicon>customdice</menuicon>
<script file="customdice_scripts/customdice_3.lua" />
</customdie>


content of customdice_3.lua:
function onValue(result)
DebugM.printLogMessage("customdice_scripts/customdice_3.lua, onValue");
DebugM.printLogMessage("customdice_scripts/customdice_3.lua, onValue, Ende");
return math.ceil(result/2);
end

I was fixing the game version to <root version="2.9">
Is it connected to this and does FGU ignore the root version tag or is there another problem I am not aware of?
Loading the same ruleset in FGC works fine.

JMessmer
October 31st, 2019, 19:00
Any ideas anyone? Right now I am clueless.

damned
November 1st, 2019, 03:23
There is a similar post by Valarian and Moon Wizard has replied.

LordEntrails
November 1st, 2019, 04:48
Yes, customdice not working at the moment :(

Moon Wizard
November 4th, 2019, 05:29
Are you still seeing this? Can you point me at a version of a ruleset that does this?

I just tried setting up a custom_d3.lua script in CoreRPG; and replacing the built-in d3 in-line script with that file reference. And, it worked without any issues for me.

Thanks,
JPG

JMessmer
November 4th, 2019, 20:50
the only way I managed to get it working was with inline scripting...
I don't know why it did not work.

Moon Wizard
November 5th, 2019, 21:29
I understand; but I tried with a separate file as well, and it was working for me.

Perhaps it was the specific way that you did it that caused an issue? Do you still have the problem version of the files?

Regards,
JPG

JMessmer
November 9th, 2019, 18:55
I have no idea why it is working inline but not as external script. I even removed the DebugMessages because I thought they might not have been initialized yet but that was not the reason.

The issue still persists. I just checked with the latest FGU version. Inline works while with an external script I receive this error message:
[11/9/2019 6:33:33 PM] [WARNING] Could not load script file () (scripts/customdice_3.lua)
[11/9/2019 6:33:33 PM] [WARNING] Could not load script file (d3) (scripts/customdice_3.lua)

Moon Wizard
November 11th, 2019, 23:03
Can you provide a link to the ruleset or extension that is throwing this error?

Thanks,
JPG

JMessmer
November 14th, 2019, 16:53
Hi Jpg, I sent you a PM just now with the link. The rule set has some license issues and cannot be published yet. Thanks a lot for trying to investigating this.

Moon Wizard
November 16th, 2019, 22:58
That's really odd. I tried the .PAK file directly, as well as an unzipped version of the ruleset as a folder; but I did not get any error messages.

* Are you loading any extensions?
* Are you running the latest update of FGU beta?
* Can you try running the exact same "DSA_DZ_4.1WE.pak" file you sent me, and removed any other folders/PAK files from rulesets folder that is not part of standard install?

Regards,
JPG

JMessmer
November 17th, 2019, 10:01
I sent you the version I am testing with currently. In there I changed all customdice script references to inline.

You would have to uncomment gameelements.xml in line 179 and comment 180 to 184

<script file="scripts/customdice_3.lua" />
<!--
<script>
function onValue(result)
return math.ceil(result/2);
end
</script>
-->

I am not using any expansions and I am on the latest update version. Did you change the gameelements.xml?

Moon Wizard
November 17th, 2019, 22:04
Thanks, I was able to reproduce; and I'll have a fix in the next beta push.

Regards,
JPG