by Kelrugem
Description
For bug reports: https://www.fantasygrounds.com/forums/showthread.php?50895-Kelrugem-s-extensions or https://www.fantasygrounds.com/forums/showthread.php?51299-(Prototype)-Extension-for-(dis)advantage
How to activate: This is an extension for CoreRPG based rulesets; download it from the forge using the update button in the Fantasy Grounds Unity launcher after subscribing to this item using this website; afterwards, before you launch your campaign, turn on Feature: Advantage and disadvantage effects with automatic removal in the extension list of your campaign.
For fellow developers: My GitHub profile is at https://github.com/Kelrugem; the extension installs into the /extensions directory, and its file name is Dis advantage.ext.
For 5E users: You do not need this extension because this is natively implemented in the 5E ruleset :)
Description:
This extension adds effects for advantage and disadvantage, keladvantage and keldisadvantage, respectively.
Applying these effects will activate (dis)advantage on the next roll; the effect will be then automatically removed after the next roll. If you do not want that these effects are removed automatically, then turn this removal off in the campaign options under Effect automation.
The number of effects will be taken into account, so, if there are more effects of keladvantage than keldisadvantage, then advantage will be applied; the same vice versa.
In the modifier window, click the +/- button in the upper right of the sidebar, are also two new modifier buttons for advantage and disadvantage in the category General. Clicking on one of them will force advantage and disadvantage, respectively, regardless of how many effects exist in the combat tracker.
The chat message will show what type of effect one had and which numbers were dropped. If more than one die was affected, then the order of the dropped numbers is the same order as of the shown results they were compared to. So, in case of advantage you see for example things like [ADV] [DROPPED 5, 7], and a result of 6, 8 means that 5 and 7 were dropped because they were smaller than 6 and 8, respectively. Thus, each die was doubled giving rise to a pair, and the results of each pair were compared.
Note: Depending on the ruleset it may or may not be quirky for certain rolls! :) Hence, test first :) For example damage type distribution may be wrong if you use it for damage rolls in 3.5e/PF1
Note for 3.5e/PF1: This is included in the extended automation extensions (previously called: Full OverlayPackage)
Note for devs who build upon this extension: This extension adds rRoll.adv as an integer to affected rolls. If rRoll.adv is positive or negative, then it has advantage or disadvantage, respectively. If it is zero or nil, then the corresponding roll is not affected. This allows to count (dis)advantage effects.
Extension logo: By Bmos, thanks :)
UUID 6340777c-d479-11eb-8c52-0050562be458