Page 1 of 2 12 Last
  1. #1

    Current HP/SP Values Do Not Synchronize to Changes to Max HP/SP

    On the Main tab in the SFRPG character sheet, when a user changes the Max HP/SP values at the lower left of the sheet, the corresponding Current HP/SP should update automatically to match. And, failing that, as a workaround, giving the character an overnight rest should synchronize the Current values to the Max values.

    In the first case above, the Current values do not automatically update on changes to the Max values.
    In the second case above, an overnight rest only syncs Current SP to Max SP and does not sync Current HP to Max HP.
    Last edited by HoloGnome; November 26th, 2019 at 13:58.
    FG Wish List - http://fg2app.idea.informer.com/
    License: Ultimate [Unlicensed/Free Trial FG users can play in my games]
    Teamspeak: ts.fg-con.com (alternate server in case of trouble: voice.fg-con.com)
    Password: Dungeoneers
    FG Server Alias: cold wand bold fang

  2. #2
    Why would an overnight rest give you max HP...that's not a function in the game...indeed, the most you gain from an overnight rest is your 1 hp/level unless you do 24 hours of bed rest to recover 2 hp/level. There's always magical and technological healing to assist.
    aka Laendra

    Discord: Laendra#9660
    Ultimate license (FGC/FGU)
    Current Timezone : Central (CDT) (GMT -5)
    Playtime: Prefer 8pm Central, or later
    Playing: Starfinder on Tuesday evenings
    DCI: 3317036507
    Organized Play: 2369539

  3. #3
    Yes - you are correct...and the same is true in Pathfinder, but that's not what I was trying to report. Sorry I wasn't more clear. And, I wasn't thinking when I wrote the part about fully syncing on overnight rest.

    There is a bug in the HP/SP setting logic where Current doesn't sync to Max. I was just using overnight rest as a quick way to try to sync up the sheet and wasn't seeing any changes.

    Users want/need to edit their character sheets and the Current fields should either be unlocked or should ideally adjust themselves when users make changes.

    When changing the Max HP value, the following rules should apply:
    1. On Max change, if Wounds are 0, then set Current to Max. (assume the user is editing their sheet)
    2. On Max change, if Wounds are X, then set Current to Max-X.
    3. If Max-X is negative, set Current to 0 and Wounds to Max.

    When changing the MAX SP value, similar rules should apply with the respective Current/Fatigue fields:
    1. On Max change, if Fatigue is 0, then set Current to Max. (assume the user is editing their sheet)
    2. On Max change, if Fatigue is X, then set Current to Max-X.
    3. If Max-X is negative, set Current to 0 and Fatigue to Max.

    I checked basic HP/level recovery on overnight rest, and that seems to be OK now. I thought there was an issue in my previous test...but I guess I was mistaken. Don't know.

    Finally, the work-around to the above HP/SP Max change case is that if you subsequently set Wounds or Fatigue to Max and then clear them, the Current value will be correct. But, when a user is editing, it makes sense that updates to Current values should just quickly key off of the Max values. Given the Starfinder system, there is clear value in auto-calculating the Current value. The piece that is missing is correcting for changes to Max.

    Hopefully, the above makes things more clear. I can certainly use the workaround, but it would be nice if there were a small amount of extra logic to do the right thing on Max changes. It would be very helpful and make the HP/SP implementation very solid.
    Last edited by HoloGnome; November 27th, 2019 at 20:12.
    FG Wish List - http://fg2app.idea.informer.com/
    License: Ultimate [Unlicensed/Free Trial FG users can play in my games]
    Teamspeak: ts.fg-con.com (alternate server in case of trouble: voice.fg-con.com)
    Password: Dungeoneers
    FG Server Alias: cold wand bold fang

  4. #4
    Simplest way to currently do what you are wanting without making a change that could potentially break the ruleset code...is what you already stated...

    Set your Max HP to X, set your wounds to some value other than what it is currently, then back to what it was...so if you had 0 Wounds, set it to 5, then set it back to 0...done.
    Same with your Max SP but use Fatigue instead of Wounds...
    aka Laendra

    Discord: Laendra#9660
    Ultimate license (FGC/FGU)
    Current Timezone : Central (CDT) (GMT -5)
    Playtime: Prefer 8pm Central, or later
    Playing: Starfinder on Tuesday evenings
    DCI: 3317036507
    Organized Play: 2369539

  5. #5
    Yep. That is the workaround I posted above. But, otherwise, the change I suggest is extremely simple and should not break the ruleset.

    Maybe something like this:

    Code:
    [read in signed maxHP, wounds values and collect newMaxHP and/or wounds on user change]
    
    newMaxHP = math.abs(newMaxHP);  -- certify user HP entry as positive number
    wounds = math.abs(wounds); -- certify user Wounds entry as positive number
    if (maxHP ~= newMaxHP) then -- did the user change maxHP?
      if (wounds == 0) then        -- is there a value set in wounds?
        currentHP = maxHP;  -- if not, sync currentHP and we're done
      elseif ((currentHP = (newMaxHP - wounds)) < 0)    -- wounds is non-zero - is recalculated currentHP negative?
         currentHP = 0; -- if so, clip at 0
         wounds = newMaxHP; -- set out-of-bounds wounds to new maxHP
      end
    end -- the user didn't change the HP value, OK to write out certified wounds value
    
    [write out newMaxHP, currentHP and wounds]
    -- same logic for SP and fatigue.

    In the majority of cases, users will be editing their sheets and the wounds and fatigue values will be 0, so direct sync of max/current values is the optimal choice.
    Last edited by HoloGnome; November 28th, 2019 at 00:26.
    FG Wish List - http://fg2app.idea.informer.com/
    License: Ultimate [Unlicensed/Free Trial FG users can play in my games]
    Teamspeak: ts.fg-con.com (alternate server in case of trouble: voice.fg-con.com)
    Password: Dungeoneers
    FG Server Alias: cold wand bold fang

  6. #6
    Samarex's Avatar
    Join Date
    Sep 2015
    Location
    Philippines
    Posts
    902
    Quote Originally Posted by HoloGnome View Post
    Yep. That is the workaround I posted above. But, otherwise, the change I suggest is extremely simple and should not break the ruleset.

    Maybe something like this:

    Code:
    [read in signed maxHP, wounds values and collect newMaxHP and/or wounds on user change]
    
    newMaxHP = math.abs(newMaxHP);  -- certify user HP entry as positive number
    wounds = math.abs(wounds); -- certify user Wounds entry as positive number
    if (maxHP ~= newMaxHP) then -- did the user change maxHP?
      if (wounds == 0) then        -- is there a value set in wounds?
        currentHP = maxHP;  -- if not, sync currentHP and we're done
      elseif ((currentHP = (newMaxHP - wounds)) < 0)    -- wounds is non-zero - is recalculated currentHP negative?
         currentHP = 0; -- if so, clip at 0
         wounds = newMaxHP; -- set out-of-bounds wounds to new maxHP
      end
    end -- the user didn't change the HP value, OK to write out certified wounds value
    
    [write out newMaxHP, currentHP and wounds]
    -- same logic for SP and fatigue.

    In the majority of cases, users will be editing their sheets and the wounds and fatigue values will be 0, so direct sync of max/current values is the optimal choice.
    Current is not editable as it is a calulation of Max HP - Wounds, if we unlock Current and players start changing this value we will get a effect I call Chrismas tree effect the code gose crazy between Character sheet and CT, this happened early in the SFRPG development.
    Why would players need to change current value. I can look to see if change in Max HP is triggering a update, but current will not be unlocked.
    Russell Campbell
    FG Product Development Projects Link


    Discord User : Samarex#0318
    Ultimate License
    Starfinder Society ID#:274538
    Lets Play a RPG

  7. #7
    I understand, but I don't think players need the restriction and hand-holding. However, if it's a big issue, then put a lock icon in the upper-left corner of the bottom panel of the main tab (default to locked) so that users can unlock all the fields for editing and character-building. But, failing that, please synchronize based on changes to MaxHP and MaxSP, for example, as in above code.

    Also, MaxRP has the same problem and is not correctly recalculating based on changes to ability stats. I just applied a personal upgrade to bump the primary stat by +2 and the RP never changed. MaxRP should not be locked.
    FG Wish List - http://fg2app.idea.informer.com/
    License: Ultimate [Unlicensed/Free Trial FG users can play in my games]
    Teamspeak: ts.fg-con.com (alternate server in case of trouble: voice.fg-con.com)
    Password: Dungeoneers
    FG Server Alias: cold wand bold fang

  8. #8
    Resolve points are calculated correctly just not updated. After you modify ability points, do a Long rest and the resolve points will display correctly. It is not idea but every situation I have had including adding an ability upgrade as you just did, resolve and max resolve was corrected with a Long rest.

    EDITED because its a long rest that resets and syncs then. Not a short.
    Last edited by msbranin; November 29th, 2019 at 19:20.

  9. #9
    It's a fine line between just giving the players a blank character sheet, expecting them to add/calculate everything and giving them some automation to allow them to just drop some data and expect that it is correct. As the "bugs" mentioned in several of your other posts would indicate, the automation that you "expect" isn't there.

    This is still a fairly new ruleset in FG, and has had 2 different "owners" working on it. I've added my development help when I can but it can take a lot of time to "correct" things that previous developers have done that make things a lot harder to work properly, or extend functionality of existing systems.

    Add that to the fact that the ruleset "owner" is the one that also has to create the content for the additional rulebooks (Alien Archive 3 and COM being the most recent) and there are (sometimes not insignificant) ruleset changes that must be made to accommodate those books (and the unrealistic expectations of some of the community that as soon as Paizo releases a book that it should be in FG) and you can begin to understand why it can take so long to get things going as smoothly as it does for rulesets like 5e.
    aka Laendra

    Discord: Laendra#9660
    Ultimate license (FGC/FGU)
    Current Timezone : Central (CDT) (GMT -5)
    Playtime: Prefer 8pm Central, or later
    Playing: Starfinder on Tuesday evenings
    DCI: 3317036507
    Organized Play: 2369539

  10. #10
    Sure - I understand that people are busy. I am just putting stuff out there so that you can capture all the feedback, since there is no public-facing bug database (a long-standing issue).

    That being said, as above, I have provided a basic code snippet to try to help resolve the (simple) Current HP/SP issue and there's no reason for RP Max to be locked, although I didn't try a long rest as a workaround.

    I think the best solution may be to simply provide a lock or magnifying glass UI element. For users who want to edit, they can unlock. Otherwise, they can live with the automation. Personally, I prefer the ability to directly edit when building characters, where there isn't really any editing of Max values after handing the sheet off to a GM for a game.

    It's important that things like MaxSP work in real time with manual editing, because if the player has an in-game CON change, they may need to edit the Max value.
    FG Wish List - http://fg2app.idea.informer.com/
    License: Ultimate [Unlicensed/Free Trial FG users can play in my games]
    Teamspeak: ts.fg-con.com (alternate server in case of trouble: voice.fg-con.com)
    Password: Dungeoneers
    FG Server Alias: cold wand bold fang

Thread Information

Users Browsing this Thread

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

Posting Permissions

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

Log in

Log in