5E Character Create Playlist
Page 1 of 2 12 Last
  1. #1
    Kelrugem's Avatar
    Join Date
    Sep 2018
    Location
    Geneva, Switzerland, and Lyon, France
    Posts
    3,097

    [Extension] Targetable CRIT

    Deprecated since the functionality provided here is now integrated in the base code

    Hi

    EDIT2: The CRIT stuff is now in the main code! So, only about the DMGTYPE stuff, see the EDIT note

    I have seen that question very frequently, so, I made a very small extension: The effect CRIT is now targetable, that means that you can code things like IFT: CUSTOM(test); CRIT: 19; moreover, it supports the descriptors melee, ranged and opportunity, so, CRIT: 19, melee would only affect melee weapons

    EDIT: Now DMGTYPE is targetable, too

    But: It may be incompatible with other extensions (I can rewrite it for better compatibility but I have no time right now), and I may not have time to maintain it, hence, I would be very glad when someone could take over.

    For devs: It is very easy:

    Overwrite AttackManager of the 5e ruleset, search for

    Code:
    local aCritRange = EffectManager5E.getEffectsByType(rSource, "CRIT")
    and replace it with

    Code:
    local aCritRange = EffectManager5E.getEffectsByType(rSource, "CRIT", aAttackFilter, rTarget);
    Best,

    Kelrugem

    LICENSE: Normally CC-BY-NC for my extensions, i.e. you can use and change it however you want, integrate it in your code and reupload it etc., so you can do everything what you want with these extensions but do not commercialize it (and SmiteWorks is allowed to do anything and everything with it ) But since this code is so simple and straightforward I do not dare to take any copyright over this, so, do what you want with that, but no commercialization

    EDIT: Now DMGTYPE is targetable, too The code change is similar as above, search for the following in the DamageManager:
    Code:
    local aEffects = EffectManager5E.getEffectsByType(rSource, "DMGTYPE", {});
    and change to
    Code:
    local aEffects = EffectManager5E.getEffectsByType(rSource, "DMGTYPE", {}, rTarget);
    Attached Files Attached Files
    Last edited by Kelrugem; April 27th, 2021 at 21:09.

  2. #2
    Zacchaeus's Avatar
    Join Date
    Dec 2014
    Location
    Scotland
    Posts
    16,599
    Nice one
    If you need to contact customer support or if there is something that you would like to see in Fantasy Grounds that isn't currently part of the software or if there is something you think would improve a ruleset then add your idea here http://fgapp.idea.informer.com/

  3. #3
    LordEntrails's Avatar
    Join Date
    May 2015
    Location
    -7 UTC
    Posts
    13,910
    Blog Entries
    9
    Nice.

    And since you are hoping someone takes over, perhaps you could list a license (CC-NC or CC-BY-NC) so folks can know and carry that forward?

    There's always that link in my sig to help you decide which license to use.

  4. #4
    Kelrugem's Avatar
    Join Date
    Sep 2018
    Location
    Geneva, Switzerland, and Lyon, France
    Posts
    3,097
    Quote Originally Posted by LordEntrails View Post
    Nice.

    And since you are hoping someone takes over, perhaps you could list a license (CC-NC or CC-BY-NC) so folks can know and carry that forward?

    There's always that link in my sig to help you decide which license to use.
    Yeah, my license stuff is in my general extension thread, but I clarified it here again in the first post since it is for 5e

  5. #5
    Hey Kelrugem,

    I was trying to see if I could use your extension to make the coding of a 5e Short Sword of Life Stealing work better.* The magic sword is supposed to do an additional 3D6 damage if you hit with a critical swing.* Right now I have it as an effect on the PC holding the sword as "Shortsword of Life Stealing;DMG: 3d6 necrotic, critical;" so that it adds the 3D6 when it they crit.* The only drawback is that when they use a different weapon like a bow, they may forget this blanket effect is on and it will apply the 3D6 despite it not being with the sword.* Would this extension be able to make it exclusive to melee?* I tried using the effect "Shortsword of Life Stealing;DMG: 3d6 necrotic, melee, critical;" thinking the melee tag would work as you wrote, but to no luck.* Any advice?**

  6. #6
    Kelrugem's Avatar
    Join Date
    Sep 2018
    Location
    Geneva, Switzerland, and Lyon, France
    Posts
    3,097
    Quote Originally Posted by Dudin View Post
    Hey Kelrugem,

    I was trying to see if I could use your extension to make the coding of a 5e Short Sword of Life Stealing work better.* The magic sword is supposed to do an additional 3D6 damage if you hit with a critical swing.* Right now I have it as an effect on the PC holding the sword as "Shortsword of Life Stealing;DMG: 3d6 necrotic, critical;" so that it adds the 3D6 when it they crit.* The only drawback is that when they use a different weapon like a bow, they may forget this blanket effect is on and it will apply the 3D6 despite it not being with the sword.* Would this extension be able to make it exclusive to melee?* I tried using the effect "Shortsword of Life Stealing;DMG: 3d6 necrotic, melee, critical;" thinking the melee tag would work as you wrote, but to no luck.* Any advice?**
    My extension does not do something in that regard, but with the native code you could try Shortsword of Life Stealing;DMG: 3d6 necrotic, critical, melee; instead critical is treated as damage type by FG, so, list it with the damage types before you add descriptors like melee However, it will still apply to other melee weapons

    There is this extension: https://www.fantasygrounds.com/forum...cs-characters)
    That should allow to attach certain effects just to certain weapons But I heard of that it is a bit incompatible with the recent changes of the 5e ruleset (the finesse stuff etc.), so, you may need to test it a bit

  7. #7
    I don't know if FGU recognizes "melee" natively. I tried using DMG: 3d6 necrotic, critical, melee; as you said in a bare campaign with zero extensions on. It still would do it regardless of whether it was a ranged or melee ability. I already use the extension you point to, but it just allows you to attach the same effect to a weapon. It doesn't make that effect only apply to that exact weapon. I may just have to make the extra 3d6 an extra attack/power on the PC's sheet and have them roll it when they get a nat 20. Thanks for the help though

  8. #8
    Kelrugem's Avatar
    Join Date
    Sep 2018
    Location
    Geneva, Switzerland, and Lyon, France
    Posts
    3,097
    Quote Originally Posted by Dudin View Post
    I don't know if FGU recognizes "melee" natively. I tried using DMG: 3d6 necrotic, critical, melee; as you said in a bare campaign with zero extensions on. It still would do it regardless of whether it was a ranged or melee ability. I already use the extension you point to, but it just allows you to attach the same effect to a weapon. It doesn't make that effect only apply to that exact weapon. I may just have to make the extra 3d6 an extra attack/power on the PC's sheet and have them roll it when they get a nat 20. Thanks for the help though
    Ah, I know why, because the range descriptor comes before the damage type! So, use DMG: 3d6 melee, necrotic, critical; Sorry, I mixed up the order

    About the extension: Yes, but there is some checkmark next to weapons' effects, "Action Only" or something like that; you need to mark that in order that that effect is only used for that weapon (when it worked correctly, you should see in the CT something like "Applied by: [Weapon name]" )

  9. #9
    The "action only" trick worked. From the description given to the option, I didn't realize it would make the effect only apply to the item it is housed on. It is only working on the sword now. Thanks for your help!

  10. #10
    Kelrugem's Avatar
    Join Date
    Sep 2018
    Location
    Geneva, Switzerland, and Lyon, France
    Posts
    3,097
    DMGTYPE is now targetable, too, so, stuff like IFT: TYPE(undead); DMGTYPE: radiant is now possible

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
  •  
DMsGuild

Log in

Log in