Distance also seems broken as well, latest FG update causing issues?
Printable View
I can't recreate - dropping effects works just fine and distance is working as expected. What other extensions are you using?
Another suggestion:
Token.getTokensWithinDistance(token, distance) also exists like getDistanceBetween. I have not yet tested whether replacing getDistanceBetween changes the result of getTokensWithinDistance.
I got an error from Automatic Flanking and Range
[6/21/2021 8:28:37 PM] [ERROR] Script execution error: [string "scripts/manager_action_attack_afar.lua"]:530: attempt to compare nil with number
The line is this:
return Token.getDistanceBetween(token, targetToken) <= GameSystem.getDistanceUnitsPerGrid()
I assume the CombatTracker or something disappeared and getDistanceBetween returned nil instead of a value.
Last week I ran Height without aura and I never got an error. This week I ran height and aura and got the error. The thing is though I never have an Aura effect during the session when I get an error. Aura is just loaded so I assume it probably isn't doing much of anything. I'm still stumped on how to recreate this issue.
[6/21/2021 4:56:33 PM] EXTENSION: D&D Official Language Fonts (FR)\rfor Fantasy Grounds\rCopyright 2015 Smiteworks USA, LLC.\rD&D Copyright 2015 Wizards of the Coast LLC
[6/21/2021 4:56:33 PM] EXTENSION: D&D Official Language Fonts\rfor Fantasy Grounds\rCopyright 2015 Smiteworks USA, LLC.\rD&D Copyright 2015 Wizards of the Coast LLC
[6/21/2021 4:56:33 PM] EXTENSION: Dungeons & Dragons Theme v1.0\rfor Fantasy Grounds\rCopyright 2015 Smiteworks USA, LLC.\rD&D Copyright 2015 Wizards of the Coast LLC.
[6/21/2021 4:56:33 PM] EXTENSION: Dungeons & Dragons, D&D, Wizards of the Coast, their respective logos, the dragon ampersand, all Wizards titles, the fifth edition rules, and Wizards' character names and distinctive likenesses are property and copyright of Wizards of the Coast LLC in the USA and other countries. Used with permission.
[6/21/2021 4:56:33 PM] EXTENSION: Miss Flavor Text - Extension v2.0\r5E version for Fantasy Grounds\r--by Kent McCullough 2020
[6/21/2021 4:56:33 PM] EXTENSION: Token Height Indication v4.4 by GKEnialb
[6/21/2021 4:56:33 PM] EXTENSION: 5e Legendary Assistant v1.2 by Stv
[6/21/2021 4:56:33 PM] EXTENSION: Automatic Critical Damage - Extension v1.0.1\r5E version for Fantasy Grounds\r--by Kent McCullough 2020
[6/21/2021 4:56:33 PM] EXTENSION: Automatic Death Resistance - Extension v2.0\r5E version for Fantasy Grounds\r--by Kent McCullough 2020
[6/21/2021 4:56:33 PM] EXTENSION: Automatic Flanking and Range- Extension v2.1\r5E version for Fantasy Grounds\r--by Kent McCullough 2020
[6/21/2021 4:56:33 PM] EXTENSION: Automatic Halfling Luck - Extension v1.2.2\r5E version for Fantasy Grounds\r--by Kent McCullough 2020
[6/21/2021 4:56:33 PM] EXTENSION: Automatic Pack Tactics - Extension v1.7\r5E version for Fantasy Grounds\r--by Kent McCullough 2020
[6/21/2021 4:56:33 PM] EXTENSION: Automatic Sneak Attack - Extension v2.0\r5E version for Fantasy Grounds\r--by Kent McCullough 2020
[6/21/2021 4:56:33 PM] EXTENSION: Advanced Effects - 5E v4.9\rby Celestian, 2017-2020
[6/21/2021 4:56:33 PM] EXTENSION: Better Combat Effects - v1.4\r5E version for Fantasy Grounds Unity\r--by Ryan Hagelstrom 2021
[6/21/2021 4:56:33 PM] EXTENSION: Assistant GM v1.4 for Fantasy Grounds Unity \rCopyright 2021 SilentRuin \rPlayer(s) can fully control NPCs as an Assistant GM.
[6/21/2021 4:56:33 PM] EXTENSION: Constitutional Amendments v2.0 for 5E by MeAndUnique.\r\nCurrent HP functionality designed and implemented by Tielc; FGU fixes by Zuilin.
[6/21/2021 4:56:33 PM] EXTENSION: Kit'N'Kaboodle v1.3.1 for 5E by MeAndUnique.
[6/21/2021 4:56:33 PM] EXTENSION: 5E - Indicators v12.
[6/21/2021 4:56:33 PM] EXTENSION: 5E Extension - Combat Automation v1.1 by Xelab\nAutomates Spellcasting and Weapon Attacks.\nDouble-click "Upcast" button for help.
[6/21/2021 4:56:33 PM] EXTENSION: Aura Effects - Extension v1.2\r--by Kent McCullough 2020 updated by SoxMax and bmos
[6/21/2021 4:56:33 PM] EXTENSION: Automatic Save Advantage - Extension v1.4\r5E version for Fantasy Grounds\r--by Kent McCullough 2020
[6/21/2021 4:56:33 PM] EXTENSION: Mad Nomad's Party Combat Stats v3.9 \n For support, updates, and bonus content visit www.madnomadmedia.com (LINK)
[6/21/2021 4:56:33 PM] EXTENSION: Turn Based Effects - Extension v2.8\r5E version for Fantasy Grounds\r--by Kent McCullough 2020
[6/21/2021 4:56:33 PM] EXTENSION: Drowbe's Chat Aesthetics Resplendent Configurator
Yeah, that'd be my guess. It can only return nil if either token is nil or CombatManager goes away. I can update it to return 0, which would prevent the error, but of course the value won't be useful at all...
It is interesting that Token.getDistanceBetween is being called and not the getDistanceBetween for imagecontrol, which is the only one I'm technically overriding. Maybe I'll also override Token.getDistanceBetween and see if that helps with anything.
Am I correct in assuming that the extension (and likely getDistance) play no role in adjudicating "adjacent target"? I ask, because in our last session, 3 tokens were next to one another, but the third was at +50' (so, not actually next to anything), but the Rogue still received advantage on their attack roll - I'm assuming this is a factor of Automatic Sneak Attack but thought I'd ask just to be safe.
I found that I needed to change automatic sneak attack. I posted a ways back in the thread, a solution that I found in discord (see below).
"On a side note. I was on the Discord channel for rob2e and Jeremy post this:
Jeremy Putman — 05/15/2021
for example. I changed a single line in the checkForNerbyEnemies function from
if checkMeleeDistanceBetweenTokens(token, sourceToken) == true then
return true;
end
to
if Token.getDistanceBetween(token, sourceToken) <= 5 then
return true;
end
And it seemed to trigger the same way with or without the new height extension on the FG forums, but also took into account that extensions height variable so if they were side by side, buy 10 ft up it didn't trigger the disadvantage.
It worked for sneak attack and I also tried it in the flanking & range ext from kent and it worked there as well. The one that did not work was pack tactics from kent. This is a big deal for those of us that want to use height and range rules. I let Jeremy know it was a great find. I thought I would share it."
Aren't you?
I did override Token.getDistanceBetween in my original contribution:
https://www.fantasygrounds.com/forum...l=1#post598151