DICE PACKS BUNDLE
Page 12 of 18 First ... 21011121314 ... Last
  1. #111
    Hey @Svandal, I would like to use this Extension on my existing campaign as well. Unfortunately, I already have the "Token Height" from GKEnialb, and have the [string "campaign/scripts/image.lua"]:155: attempt to index local 'targetToken' (a nil value) error. How did you fix this? Did you remove/update something in the db.xml?

  2. #112
    Quote Originally Posted by Arnagus View Post
    Hey @Svandal, I would like to use this Extension on my existing campaign as well. Unfortunately, I already have the "Token Height" from GKEnialb, and have the [string "campaign/scripts/image.lua"]:155: attempt to index local 'targetToken' (a nil value) error. How did you fix this? Did you remove/update something in the db.xml?
    I am still troubleshooting.
    Creating a new campaign works, but the bug has reappeared in the new campaign. When it appears it is always a problem, and the only fix is creating a new campaign.
    I have tried to recreate the problem in the new new campaign, but I have not managed to find what the trigger is.

    So the fix is creating a new campaign and hope it does not reappear.
    Might also be an idea to post your whole campaign with the bug. I plan to do this if I manage to find the trigger, but I have not had the time or luck to do it yet.

  3. #113
    I was digging into it in parallel. I traced it to a token which is on another map (due to being "up the stairs") while the combat is occurring downstairs. As all tokens from the Combat Tracker are evaluated, this causes an error (Token Height: getTokensWithinDistance function is calling getPosition, causing the error). Either the Combat Modifier Calculation should check if the tokens are on the same map before calling the getTokenWithinDistance (used for "adjTokens = srcImage.getTokensWithinDistance({x=tgtCoord.x, y=(tgtCoord.y * -1)}, 5);" within the checkShootMelee fuction, already pointed out by you (Svandal) here: https://www.fantasygrounds.com/forum...619#post617619), or the Token Height needs to fail more gently (e.g. something like "if targetToken and targetToken ~= sourceToken then" on line 146).

    *** Edited ***
    Actually, this is exactly the fix (line 146 in Token Height.ext\campaign\scripts\image.lua):
    ORIG: if targetToken ~= sourceToken then
    BUGFIX: if targetToken and targetToken ~= sourceToken then

    I have cross-posted there: https://www.fantasygrounds.com/forum...152#post640152
    Last edited by Arnagus; February 13th, 2022 at 17:59.

  4. #114
    GKEnialb's Avatar
    Join Date
    Jul 2017
    Location
    Castle Rock, CO
    Posts
    523
    Okay, new version live on the Forge with the suggestion from Arganus.

  5. #115
    @GKEnialb - many thanks, works for me now in both cases: Token (while on CT) on a different map, or on no map.
    @Svandal - can you please check your campaigns?

    CMC calculation seems to be correct, as far as I can tell, so this should solve the issue (at least for my case):

    [ATTACK (R)] Dagger [CRIT 19][RANGE -6] for 40'
    [ATTACK (R)] Dagger [CRIT 19][EFFECT +1][RANGE -4] for 30' - this includes the automatically added PBS & rng30
    [ATTACK (R)] Dagger [CRIT 19][EFFECT +1][RANGE -4][SHOOT MELEE -4] for 30' - with adjacent token to target (and PBS)
    [ATTACK (R)] Dagger [CRIT 19][EFFECT +1][RANGE -4][SHOOT MELEE -4] for 30' - with two adjacent tokens to target (and PBS)
    -> [DAMAGE (R)] Dagger [EFFECTS +1][TYPE: piercing,slashing (1d4+1=3)] - no sneak attack as target is only flanked (by the two adjacent tokens) but not by the rogue
    [ATTACK (R)] Dagger [CRIT 19][EFFECT +1][RANGE -4][SHOOT MELEE -4] for 30' - with adjacent token to flat-footed target (and PBS)
    -> [DAMAGE (R)] Dagger [EFFECTS 5d6+1][TYPE: piercing,slashing (1d4+1=4)][TYPE: piercing,slashing,precision (5d6=27)] - sneak attack ("nodex" from Kelrugem's "Extended automation and overlays" extension)
    [ATTACK (M)] Dagger [CRIT 19][FLANK +2] meele - directly adjacent with a second token flanking
    -> [DAMAGE (M)] Dagger [EFFECTS 5d6][TYPE: piercing,slashing (1d4=4)][TYPE: piercing,slashing,precision (5d6=23)] - sneak attack

    Hint: I add the "Sneak Attack" effects (names are just cosmetic) using bmos "Advanced Effects" to the rogue:
    Sneak Attack; NIFT: nodex; DMG: 5d6 precision, accuracy
    Sneak Attack; IFT: nodex; DMG: 5d6 meele, precision
    Sneak Attack; IFT: nodex; IF: CUSTOM(rng30); DMG: 5d6 ranged, precision
    Sneak Attack; IF: CUSTOM(Flanking); DMG: 5d6 meele, precision

    I deliberately left out things like "Sneak Attack; IF: Invisible; NIFT: CUSTOM(trueseeing); DMG: 5d6 meele,precision" similar to what has been proposed here https://www.fantasygrounds.com/forum...503#post583503 and rather use the <CTRL>+Attack Roll = "accuracy" mode for sneak attacks on the "border" cases.

  6. #116
    Hi i love this extension...but.i find that it clashes with traps...
    i get a script error page when attacking with a trap...

  7. #117
    Quote Originally Posted by wakhere View Post
    Hi i love this extension...but.i find that it clashes with traps...
    i get a script error page when attacking with a trap...
    You should post what the script error is

  8. #118
    @wakhere - indeed, please
    a) only load the two clashing extensions
    b) properly name the clashing extensions in question (with URL to Forge or Forum thread)
    c) provide the full error message from the FGU\console.log, preferable with any debug enabled

  9. #119
    Quote Originally Posted by Arnagus View Post
    @GKEnialb - many thanks, works for me now in both cases: Token (while on CT) on a different map, or on no map.
    @Svandal - can you please check your campaigns?
    I can confirm that I do not see the bug anymore. Great work Arnagus, and thank you for the fast update GKEnialb.

  10. #120
    GKEnialb's Avatar
    Join Date
    Jul 2017
    Location
    Castle Rock, CO
    Posts
    523
    No worries - easy when Arnagus pointed out the fix.

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
FG Spreadshirt Swag

Log in

Log in