Thread: Advantages Extension (FGU 5E)
-
February 28th, 2021, 04:22 #1
Advantages Extension (FGU 5E)
Advantages Extension (FGU 5e) (in the Forge now)
My personal grab bag I add simple stuff into that I want for my campaigns. Use at your own risk "as is".
Now the Forge delivery will contain 3 different extensions (broke out the more risky stuff so it could be separately loaded/unloaded without losing other functionality. This code is free for anyone to take and use even FGU.
"5e - Advantages" - Advantages.ext
V1.16 - Update - support of new chat command "/chatLogWhisperer [search string]" where [search string] is a string used to do a find on the current chatlog.html in the campaign directory and then output any session blocks that contained that string while bold/italic/underline each matching string in the Chat Log Whisperer Output window. Which is fully editable so you can mangle the text and its format (like story format) to then copy/paste to notes and share with players or put someplace else. Just something I wanted for me to freely display and edit history of chatlogs with. Delete the campaign's chatlog.html if you want it to start over (save it someplace first if you want to hold onto it). You can lock up your machine if you have a huge chatlog or some search that hits a lot of it or is formatted poorly (have to kill FGU app or sign out or reboot). The search string "raw" will get the whole chatlog.html output. Use at your own risk.
V1.17 - FGU Update - update broke templates used by chatLogWhisperer - stopped using their templates as they shift around to much.
V1.18 - FGU Update - removed ability to store group selections from record list between sessions as FGU has finally implemented it - so I no longer have to support it myself.
V1.19 - Update - Token will be frozen until roll actions are processed - this is a new option defaulted to "off". Basically if anything initiates a roll applying to a token its movement will be frozen in place until its completed. This can result in the token jumping after being unfrozen to wherever someone has there mouse dragged to if they did not release it when it froze. Was needed to keep roll calculations from being screwed up by moving tokens (moving into aura trigger or player moving it while it is being attacked will be frozen till its completed).
V1.20 - Fix: Was not returning the return code of the override for ActionsManager.applyModifiersAndRoll - fixed.
V1.21 - Update - added option to turn off/on logs for V1.19 defaulted to "off".
V1.22 - Fix - removal of frozen array had incorrect table operation - fixed.
V1.23- Fix - V1.22 had a cut/paste error causing error at line 310.
"5e - Advantages CharacterWizard" - AdvantagesCW.ext
V2.0 - FGU changes - major rewrite to preserve ability to use module priorities to insure that there are no duplicates in Character Wizards data lists (one with priority is only one used). Also, implemented node and childList changes to code that SW wanted.
V2.1 - FGU changes - the function I used to hook in and override the record lists was removed completely from CW - so I had to choose another function to override the records with. While this fixes the record lists for race/class/etc. the spell list they use has been rewritten to only display one spell now which they randomly choose (previously it had all spells listed with duplicate names from different modules) - I can't fix this as my code here goes through records and chooses the one based on the priority module. But if they have removed all duplicates with no rhyme or reason then CW will only provide that randomly chosen list. You can see this with or without this extension as some will be spells from PHB others from other modules. Can't fix that. I'll provide a generic fix which fixes the problem where my code was no longer executing but the way they implemented the spell list it can no longer properly respect any module priority. Nothing I can do about that for now. Other record lists in CW will contain all data so can have module priority respected - just not spell lists.
V2.2 - FGU changes - another major update where all the tables I used changed format.
V2.3 - FGU changes - getModule returns "" instead of nil now for empty modules - had to fix so Campaign data would get priority.
"5e - Advantages Pointer Areas" - AdvantagesPA.ext
V1.0 - Feature - New option "Target Pointer Area" that is defaulted to "off". Will store the last active pointer area you defined and use it to target any tokens within that area in the same way map target mode indicator does. In fact, the target mode icon on the map toolbar is hijacked when this option is turned on so that if it has a stored last pointer area (defined by right/mouse held down with shift/alt/ctr key held down or with right mouse draw pointers option) and there are tokens in that area it will select them unless all are already selected then it unselects them (just like normal targeting mode behavior). If nothing is found inside the stored pointer area or no stored last pointer area exists then it will do normal targeting mode behavior. The only way I could find to remove the last active pointer after all user pointers are removed from map was to turn off and back on the option. No code to determine when a pointer was removed could be found, so this was "good enough". This is User based so is only relevant for the users last active pointers regardless where that graphics originated from (if its on your map its yours as far as your map is concerned - no way to determine who "did it"). In case you are unfamiliar with pointer areas they are the temporary graphics of a circle, square, or cone that you can place in your map. Risky modification hijacking some code not meant to do what I'm doing with it (all the pointer logic I really need is buried in the engine and not exposed for access) so I'm putting this in here - free - guarded with option. Use at own risk.
Feature - for the V1.5 feature having CTR key pressed while selecting map toolbar targeting icon while an active pointer area is present will only select tokens that are same faction as selected token(s). Having ALT key pressed will only select tokens that are different faction from selected token(s). Both keys will not allow things that are not in CT to be selected. Same behavior as V1.5 - will target tokens unless all are currently targeted then it will unselect them.
V1.7 - Update - set loadorder to 151 as I'm told other extensions are whacking my code. I do call partial original code when the pointers are not actually in play and or my option is off. If it conflicts disable this one or turn off the option to do pointers. As it appears usually other things work if I'm a higher load order and only my stuff does not when I'm a lower one I'll try it this way.
V1.8 - FGU update - fixes to enable this to work again in new FGU update.
V1.9 - Bug - the "NOTARGETING" effect supported in Generic Actions Layer extension must not be processed or it will cause issues. Thus this also supports not processing "NOTARGETING" effect now.
Reported Conflicts:
Advantages PA does not work with Critical Awesome Essentials.
Extensions = RISK: This note is added to all the extensions I maintain. I want users to understand that extensions are code that is added to or overrides portions of code in the Fantasy Grounds Unity (FGU) application. When the underlying code in FGU changes it can break an extension. When you run with other extensions they can conflict by trying to overwrite the same parts of the FGU code. I will keep my extensions working with FGU changes, and the extensions I use (listed in my FGU signature) as I have direct control over those things. I cannot make the same promise with other extensions. If I am notified of an incompatibility I will attempt to resolve it - but if I cannot I will list what the known extension incompatibilities are. Understand before you get any extensions that it comes with RISK. Not just my extensions - any extension. These extensions are also maintained by me for me. I provide them outside of my own games purely to those who wish to take advantages of things I use for myself.
Included is original text used for describing this extension - provided for reference if needed.Last edited by SilentRuin; March 4th, 2025 at 04:19.
-
February 28th, 2021, 06:00 #2
Forgot to add in the extension (sigh) Fixed.
Free(Forums/Forge) Extension(FGU 5E):
Paid (Forge) Extension(FGU 5E):
-
February 28th, 2021, 14:35 #3
Added text (host only) to remembering groups between sessions.
Free(Forums/Forge) Extension(FGU 5E):
Paid (Forge) Extension(FGU 5E):
-
February 28th, 2021, 17:53 #4
Caveat: If you have an empty group name then FGU does not really treat it as really in the list when you come back up. If this was the last one chosen it will show in list but pulldown will not show it - just pick a valid one or recreate the group name. This is just how those group/category lists work.
Free(Forums/Forge) Extension(FGU 5E):
Paid (Forge) Extension(FGU 5E):
-
March 10th, 2021, 18:00 #5
V1.2 - Fix: needed to fake/translate DB active_category value "**" as uncategorized(true category is "") so that it could be stored in DB.
Free(Forums/Forge) Extension(FGU 5E):
Paid (Forge) Extension(FGU 5E):
-
April 19th, 2021, 02:48 #6
I should warn about using hot keys that require CTRL, ALT, or SHIFT to trigger because if you put anything in a hot key that also reacts to CTRL, ALT, or SHIFT you can't really trigger it without those effects being applied. For example, with this extension if you had a CTRL hot key with some kind of dice roll it would always roll it with advantage. If you had an ALT hot key with some kind of dice roll it would always roll it with disadvantage. And if you are in regular FGU even with no extensions you had a SHIFT hot key with some kind of damage roll it would always make it a critical roll.
This is going to be true with anything you put in CTRL, ALT, or SHIFT hot key triggers because those keys will be detected by the simple act of trying to put something in that reacts to them in there.Free(Forums/Forge) Extension(FGU 5E):
Paid (Forge) Extension(FGU 5E):
-
May 25th, 2021, 23:47 #7
- Join Date
- Jan 2020
- Location
- Suzano-SP
- Posts
- 71
-
May 25th, 2021, 23:57 #8
Not enough information to go on. You'll have to supply the error in my code here. This is a very simple extensions in that part and calls the original code - so if they are doing the same (calling the original code in what they do) there should be no issue. Super simple. Not sure what it can conflict with. UNLESS you already have the advantages set some other place - then of course you'd not want this extension.
Code:function encodeAdvantage(rRoll, bADV, bDIS) if Input.isControlPressed() then bADV = true; else if Input.isAltPressed() then bDIS = true; end end saveencodeAdvantage(rRoll, bADV, bDIS); end
Free(Forums/Forge) Extension(FGU 5E):
Paid (Forge) Extension(FGU 5E):
-
May 26th, 2021, 00:02 #9
- Join Date
- Jan 2020
- Location
- Suzano-SP
- Posts
- 71
-
May 26th, 2021, 00:11 #10
Yeah that is not this code. I would have no idea why they are not guarding against nil values for data. You will have to check with the author or not use this code. I can fix my stuff - I can't fix someone else's. It's possible they are doing something with the other part of this code involving master index and saving of the group name - but I really have no idea. Sorry.
Free(Forums/Forge) Extension(FGU 5E):
Paid (Forge) Extension(FGU 5E):
Thread Information
Users Browsing this Thread
There are currently 1 users browsing this thread. (0 members and 1 guests)
Bookmarks