FG Spreadshirt Swag
  1. #1

    Non-energy typed modifiers? (5e ruleset)

    What is a non-energy typed modifiers? These seem to be the only ones that use a set value (don't add up modifiers).

    This bit of code is from manager_effect5E.lua.

    Code:
    -- COMBINE BONUSES AND PENALTIES FOR NON-ENERGY TYPED MODIFIERS
    	for k2,v2 in pairs(bonuses) do
    		if results[k2] then
    			results[k2].mod = results[k2].mod + v2;
    		else
    			results[k2] = {dice = {}, mod = v2, remainder = {}};
    		end
    	end
    	for k2,v2 in pairs(penalties) do
    		if results[k2] then
    			results[k2].mod = results[k2].mod + v2;
    		else
    			results[k2] = {dice = {}, mod = v2, remainder = {}};
    		end
    	end
    I've got an effect I'd like to use that needs the best value and not incremental and would like to figure out how to use this bit.
    ---
    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.

  2. #2
    That code is left over from borrowing code from 3.5E ruleset, in case it was needed.

    Basically, the tag must be included in DataCommon.bonustypes, and then any bonuses/penalties with the same tag will be merged. If the tag also in DataCommon.stackablebonustypes, then the bonuses are additive; otherwise, the only the maximum bonus is used.

    In 5E, both DataCommon.bonustypes and DataCommon.stackablebonustypes are empty, because there are no typed bonuses. Try looking in 3.5E ruleset for example with types.

    Regards,
    JPG

  3. #3
    Quote Originally Posted by Moon Wizard View Post
    That code is left over from borrowing code from 3.5E ruleset, in case it was needed.

    Basically, the tag must be included in DataCommon.bonustypes, and then any bonuses/penalties with the same tag will be merged. If the tag also in DataCommon.stackablebonustypes, then the bonuses are additive; otherwise, the only the maximum bonus is used.

    In 5E, both DataCommon.bonustypes and DataCommon.stackablebonustypes are empty, because there are no typed bonuses. Try looking in 3.5E ruleset for example with types.

    Regards,
    JPG
    I was just about to follow up explaining what I had found and it was nothing used it

    I did end up creating my own basetypes = {}; with the names I needed and worked perfectly using that bit of code.

    What I was trying to do was make it so I could put in BSTR, BDEX, BINT/etc and the value given would be the BASE score (not a modifer) for effects.

    Doing this because I've added a feature to items that will apply effects when equipped. Gauntlets of ogre power (18/100 str) and the like. It'll actually just apply any effect string you've placed on a item when equipped.

    Trying to re-purpose the effects to handle it w/o re-writing so much like I did previously (just tossed what I did and started over). Few minor tweaks to the pre-3.3.2 stuff and it's working now. The one caveat is that they need to be in the Combat-tracker. Once 3.3.2 goes live I'll back port the last few updates you've had so that it's "CoreRPG/5e" effects with the few tweaks.

    Once all that's done perhaps I can make it an extension or submit diffs for it (minus AD&D specific stuff). I've been really happy with how it works.
    ---
    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.

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
  •  
STAR TREK 2d20

Log in

Log in