Thread: CoreRPG Coins Weight
-
May 23rd, 2021, 19:35 #31Grand Templar
- Join Date
- Mar 2020
- Posts
- 209
I downloaded it one hour ago, more or less :-)
-
May 23rd, 2021, 21:46 #32Grand Templar
- Join Date
- Mar 2020
- Posts
- 209
Here the db.xml filedb.xml
-
May 23rd, 2021, 22:09 #33
-
May 23rd, 2021, 22:37 #34Grand Templar
- Join Date
- Mar 2020
- Posts
- 209
-
May 24th, 2021, 02:07 #35
bmos, I took a look and the two extensions are definitely conflicting. Basically both extensions are overwriting the charsheet_inventory_contents windowclass.
Looking at your extension, it seems that the only reason you are overwriting the class is to monitor the field for changes. Is that correct? The file just seems to be a series of onValueChanged functions. If thats the case, I think there may be another way to get that trigger without having to overwrite the windowclass at all. If in your coinweight.lua file, you set a DB handler to watch for each characters coin value for changes. You could monitor every coin change without overwriting the windowclass.
Something like this. (assuming 5e, but other than a name change it should be similar for others)
Code:function onInit() DB.addHandler("charsheet.*.coins.slot1.amount, "onUpdate", onCoinUpdate) DB.addHandler("charsheet.*.coins.slot1.name, "onUpdate", onCoinUpdate) DB.addHandler("charsheet.*.coins.slot2.amount, "onUpdate", onCoinUpdate) DB.addHandler("charsheet.*.coins.slot2.name, "onUpdate", onCoinUpdate) etc... end function onCoinUpdate(nodeUpdated) --do your stuff here whenever a value gets updated. you can easily pull the parent nodes to get the charsheet or name of the coin type. local nodeChar = nodeUpdated.getParent().getParent().getParent(); onCoinsValueChanged(nodeChar) endLast edited by mattekure; May 24th, 2021 at 02:19.
For support with any of my extensions, visit my #mattekure-stuff channel on Rob2e's discord https://discord.gg/rob2e
-
May 24th, 2021, 02:31 #36
Actually if you look at the history of the codebase that is how it once worked.
I moved it to the windowclass because I wanted to use the delaykeyupdate option to keep thing moving faster.
However since you say it's because of the windowclass I think I have a solution. What is the loadorder of that extension?
-
May 24th, 2021, 02:36 #37
it has no load order defined
For support with any of my extensions, visit my #mattekure-stuff channel on Rob2e's discord https://discord.gg/rob2e
-
May 24th, 2021, 11:12 #38
-
May 24th, 2021, 13:32 #39For support with any of my extensions, visit my #mattekure-stuff channel on Rob2e's discord https://discord.gg/rob2e
-
June 7th, 2021, 14:54 #40Crusader
- Join Date
- Jan 2017
- Posts
- 10
Hi, how do i adjust the .coinweight.lua? i cant find it within my FG files and im assuming its within the compiled extension?
Cheers
Thread Information
Users Browsing this Thread
There are currently 1 users browsing this thread. (0 members and 1 guests)

Reply With Quote


Bookmarks