Starfinder Playlist
Page 1 of 2 12 Last
  1. #1

    [2E] Ability effects in CT not updating character sheet (onChildUpdate)

    Hi,

    Summary:
    In the 2E ruleset the character sheet is not updated when you add/remove ability effects. For example "INT:-4"
    This works fine in FGC, but not in FGU. As illustrated here:


    int-fgc-fgu.png

    I tried to trace down why this was in the ruleset code and ended at "cta/scripts/cta_combatants_host.lua" on line 12.
    Code:
    DB.addHandler(DB.getPath(node, ".*.effects"), "onChildUpdate", updateForEffectChanges);
    In FGU the onChildUpdate is never called. In FGC it is.

    Related, the three following lines in the same file are never called in FGU either, but they are in FGC.
    Code:
    DB.addHandler(DB.getPath(node, ".*.targets"), "onChildUpdate", onTargets);
    DB.addHandler(DB.getPath(node, ".*.targets"), "onChildDeleted", onTargetsDelete);
    DB.addHandler(DB.getPath(node, ".*.targets"), "onChildAdded", onTargetsAdd);
    Also related (I think) is that the summary windows for targets and effects often goes blank and are not updated until you switch to another tab and back in the combat tracker. But I have not tested whether those events get called.

    So it seems to me there might be an issue with the events here?

    Oh, and I also did a diff on both the CoreRPG and 2E rulesets between FGC and FGU to make sure it was the same version I tested on.

    Ruleset(s):
    2E

    Operating System / Language Setting:
    Windows 10.

    Steps to Reproduce:
    In a new 2E campaign in FGU
    - Create a character
    - Add character to combat tracker
    - Add an effect to the character "INT:-4"
    - Observe that the INT stat is not updated in the character sheet

    Extra info:
    If you have added the effect as described above, then close FGU, open and launch the campaign again and open the character sheet, the INT modification will display correctly. So the "update sheet" code IS working, it is just not called after adding the effect.


    I do not have enough knowledge of the rulesets / core systems to know where else to look to see if the problem lies elsewhere. But hopefully this will serve as a start for you who have deeper insights

    Regards,
    Tideturner

  2. #2
    Oh, I forgot a bit of info on my setup

    FGU version: 2020-03-13

    No extensions

    Ruleset versions from the chat log:
    Advanced Dungeons & Dragons 2nd Edition (c) Wizards of the Coast
    2E v2020.08.06 For Fantasy Grounds& --by Celestian 2017-2020
    CoreRPG ruleset v3.3.11B for Fantasy Grounds Copyright 2019 Smiteworks USA, LLC

  3. #3
    Quote Originally Posted by Tideturner View Post
    Oh, I forgot a bit of info on my setup

    FGU version: 2020-03-13

    No extensions

    Ruleset versions from the chat log:
    Advanced Dungeons & Dragons 2nd Edition (c) Wizards of the Coast
    2E v2020.08.06 For Fantasy Grounds& --by Celestian 2017-2020
    CoreRPG ruleset v3.3.11B for Fantasy Grounds Copyright 2019 Smiteworks USA, LLC
    About your version: that is a preeeety old version You should try to update, when this doesn't work, then try a reinstall (or the 03 was supposed to be a 08 maybe? then ignore my message )

  4. #4
    Hehe yeah that was a typo. My FGU version is 2020-08-13

  5. #5
    It does look like the handlers are not entirely working in FGU. I think this might have been reported before (I know I've looked at it myself also) but I it's not been addressed yet in patches.

    I tested locally and used STR:10 and saw the same results you did. I use STR to test to make sure it's not just a window/refresh issue because the attacks should use the bonus as well. It did not, because as you noted the handler is just not adding the effect unless you restart FGU entirely.

    Hopefully Carl/JPG will have the chance to take a look at this.
    Last edited by celestian; August 17th, 2020 at 15:53.
    ---
    Fantasy Grounds AD&D Reference Bundle, AD&D Adventure Bundle 1, AD&D Adventure Bundle 2
    Documentation for AD&D 2E ruleset.
    Custom Maps (I2, S4, T1-4, Barrowmaze,Lost City of Barakus)
    Note: Please do not message me directly on this site, post in the forums or ping me in FG's discord.

  6. #6
    Checked after patch today and not been addressed yet. Several unrelated issues resolved tho
    ---
    Fantasy Grounds AD&D Reference Bundle, AD&D Adventure Bundle 1, AD&D Adventure Bundle 2
    Documentation for AD&D 2E ruleset.
    Custom Maps (I2, S4, T1-4, Barrowmaze,Lost City of Barakus)
    Note: Please do not message me directly on this site, post in the forums or ping me in FG's discord.

  7. #7
    Yeah, took a look as well. The summary windows in the combat tracker no longer disappear, so that's very good
    And much better (well, equally much better ), the "/reload" command has been implemented now. Phew.


    Also, some extra info reg. the addHandler problem.
    While this does not work:
    Code:
    DB.addHandler(DB.getPath(node, ".*.effects"), "onChildUpdate", updateForEffectChanges);
    These DO work:
    Code:
    DB.addHandler(DB.getPath(node, "*.effects"), "onChildUpdate", updateForEffectChanges);
    DB.addHandler(DB.getPath(node, "*.effects.*"), "onChildUpdate", updateForEffectChanges);
    DB.getPath(node, ".*.effects") returns "combattracker.list..*.effects"

    Just guessing here, but that looks like an invalid DB path with the double dots.
    Might be the path parser is more lenient in FGC than it is in FGU.

    And no clue if this is then considered a FGU or ruleset bug

  8. #8
    Quote Originally Posted by Tideturner View Post
    DB.getPath(node, ".*.effects") returns "combattracker.list..*.effects"

    Just guessing here, but that looks like an invalid DB path with the double dots.
    Might be the path parser is more lenient in FGC than it is in FGU.
    Good catch. I spun up and tested it locally and it works. I did not notice the .*.effects versus *.effects.

    Thanks for seeing this. I look over this code a lot and roll over such things. Second pair of eyes is a great help.

    I'll push out a fix for this that should see "live" around Sept 1. I'm also cleaning up some other style issues that JPG was kind enough to point out that should resolve some of these issues in the future as well.

    There are various situations where FGU's methods are more strict on formatting/style and this certainly seems to be the case. I reviewed the other calls and did not see any other handlers using this style.

    "the "/reload" command has been implemented now."

    I still get the message it's not working in alpha

    Last edited by celestian; August 21st, 2020 at 20:13.
    ---
    Fantasy Grounds AD&D Reference Bundle, AD&D Adventure Bundle 1, AD&D Adventure Bundle 2
    Documentation for AD&D 2E ruleset.
    Custom Maps (I2, S4, T1-4, Barrowmaze,Lost City of Barakus)
    Note: Please do not message me directly on this site, post in the forums or ping me in FG's discord.

  9. #9
    Quote Originally Posted by celestian View Post
    "the "/reload" command has been implemented now."

    I still get the message it's not working in alpha

    Huh strange, worked for me since I updated today. Version 2020-08-20 on the live channel.

    Doing dev without the /reload is frustrating, so hopefully you get it working

  10. #10
    @celestian,

    Make sure you are in the Live channel, and not the Prev channel.

    Regards,
    JPG

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
  •  
DICE PACKS BUNDLE

Log in

Log in