-
July 20th, 2024, 22:33 #21
This is rather vague...
Review any overrides to the following scripts:
LibraryData, ItemManager
I use (don't override) calls in LibraryData.
I override ItemManager functions:
ItemManager.getItemSourceType
ItemManager.handleAnyDrop
ItemManager.addItemToList
ItemManager.sendItemTransfer
ItemManager.getDisplayName
All of these will call original code (if not deciding to go its own way).Free(Forums/Forge) Extension(FGU 5E):
Paid (Forge) Extension(FGU 5E):
-
July 20th, 2024, 22:48 #22
Supreme Deity
- Join Date
- Mar 2007
- Posts
- 21,164
That's correct. If you are overriding the core functionality of either of those global scripts; you will need to review your code and compare with the core version.
Regards,
JPG
-
July 20th, 2024, 23:55 #23Free(Forums/Forge) Extension(FGU 5E):
Paid (Forge) Extension(FGU 5E):
-
July 21st, 2024, 00:57 #24
- Join Date
- Mar 2016
- Posts
- 262
Is it possible to release the files used to create this new theme, so that it will be easier for others to create their own theme? Something like the link below, but for all the various pieces in multiple Photoshop files?
https://fantasygroundsunity.atlassia...ar+Dock+Frames
-
July 21st, 2024, 01:35 #25
Bug?
Previously ItemManager.getItemSourceType would return the following for this node:
s'treasureparcels.id-00005.itemlist.id-00001'
s'treasureparcel'
In TEST this now returns "" which causes me much grief.
This still returns the correct value in TEST for the following node:
s'treasureparcels.id-00005'
s'treasureparcel'
So was this an intentional "no longer works as it did" change that I have to now resolve on my own or is this actually a bug in TEST?Free(Forums/Forge) Extension(FGU 5E):
Paid (Forge) Extension(FGU 5E):
-
July 21st, 2024, 11:40 #26
The new theme looks excellent. The interface is visually less cluttered, but I think the spacing between elements needs some work, as it's clearly the same as before, although it could definitely be reduced.
I have a question/suggestion on a slightly different topic. I've been using the new item functionality, and learned that the item picture can be put on the map. Are there plans to make this picture also a link to the item's statblock? To be able to open the item from a token on the map? Is there a chance of such functionality in Parcels?
Or maybe it's better to write it in Feature Request if there are no such plans?
-
July 21st, 2024, 16:03 #27
The first three of these are required to get ItemManager.getItemSourceType back to working in my world (not sure if there are more that are busted but these are ones returning "" that I know are different that they were) - the last two I don't know if I require or not but figured I'd play it safe. Gist being if this new TEST stuff returns "" I can't believe it and have to do these checks to make sure.
Code:if StringManager.startsWith(sNodePath, "treasureparcel") then return "treasureparcel"; elseif StringManager.startsWith(sNodePath, "partysheet") then return "partysheet"; elseif StringManager.startsWith(sNodePath, "charsheet") then return "charsheet"; elseif StringManager.startsWith(sNodePath, "temp") then return "temp"; elseif StringManager.startsWith(sNodePath, "item") then return "item"; end
Last edited by SilentRuin; July 21st, 2024 at 16:19.
Free(Forums/Forge) Extension(FGU 5E):
Paid (Forge) Extension(FGU 5E):
-
July 21st, 2024, 16:33 #28
I don't know why TEST has added these verifications for records
-- bCurrency = Enables currency can be transferred to this record type. (See ItemManager for default currency paths; or use custom data registration to set different one.)
-- bInventory = Enables items can be transferred to this record type. (See ItemManager for default inventory paths; or use custom data registration to set different one.)
But of course for Extensions (more than one does this) that have inventory tabs added onto NPC/VEHICLE sheets this needlessly breaks them all.
I suppose the only recourse is to now override
Code:aRecords = { ["vehicle"] = { aDataMap = { "vehicle", "reference.vehicles" }, aGMListButtons = { "button_vehicle_type" }, aCustomFilters = { ["Type"] = { sField = "type" }, }, tOptions = { bExport = true, bID = true, bPicture = true, bToken = true, bCurrency = true, bInventory = true, }, ["npc"] = { aDataMap = { "npc", "reference.npcs" }, sListDisplayClass = "masterindexitem_id", aGMEditButtons = { "button_add_npc_import" }, aCustom = { tWindowMenu = { ["left"] = { "chat_speak" } }, }, tOptions = { bExport = true, bID = true, bPicture = true, bToken = true, bCurrency = true, bInventory = true, } }
I'm actually not even sure how much has been broken due to these checks. Or what will happen if I set these in aRecords now.Last edited by SilentRuin; July 21st, 2024 at 16:37.
Free(Forums/Forge) Extension(FGU 5E):
Paid (Forge) Extension(FGU 5E):
-
July 21st, 2024, 17:09 #29
Not even setting these flags can get this working again. I'll have to rip out and override these new guards as they are unusable. To test I did the following in my onInit()...
Code:RecordDataManager.setRecordTypeOption("npc", "bInventory", true); RecordDataManager.setRecordTypeOption("npc", "bCurrency", true); RecordDataManager.setRecordTypeOption("vehicle", "bInventory", true); RecordDataManager.setRecordTypeOption("vehicle", "bCurrency", true);
So I overrode the following to see why it refuses to recognize bCurrency for npc sheet - just to add some Debug.console() checks:
Code:CurrencyManager.addActorCurrency = addActorCurrency;
Code:function addActorCurrency(nodeActor, sNewCurrency, nNewCurrency) Debug.console(DB.getPath(nodeActor)); local sRecordType = RecordDataManager.getRecordTypeFromRecordPath(DB.getPath(nodeActor)); Debug.console(sRecordType); Debug.console(RecordDataManager.getRecordTypeOption(sRecordType, "bCurrency")); if not ItemManager.doesRecordTypeHaveCurrency(sRecordType) then ...
[7/21/2024 10:59:44 AM] s'combattracker.list.id-00028'
[7/21/2024 10:59:44 AM] s''
[7/21/2024 10:59:44 AM] bFALSE
Which of course will never get processed.
Before I'm forced to butcher all this code to make it ignore these checks I'd like to understand why they are being done.Free(Forums/Forge) Extension(FGU 5E):
Paid (Forge) Extension(FGU 5E):
-
July 21st, 2024, 17:17 #30
Supreme Deity
- Join Date
- Mar 2007
- Posts
- 21,164
The code allows records to specify that they support inventory and/or currency via flags on the records; and the ItemManager script was updated to support that behavior.
Regards,
JPG
Thread Information
Users Browsing this Thread
There are currently 1 users browsing this thread. (0 members and 1 guests)
Bookmarks