PDA

View Full Version : 5E - Turn Based Effects



kentmccullough
April 4th, 2020, 20:49
This is now available on DMs Guild Here (https://www.dmsguild.com/product/312684?affiliate_id=1307708)

This simple extension adds in a flag
ONTURN which can be added to any effect. This will deactivate the effect after it fires, and then on anyone's turn end it would reactivate. The idea is to support Ranger's Colossus Slayer feature with a persistent effect.
Colossus Slayer; IFT: wounded; DMG: 1d8; ONTURN;

This way the ranger can always have the effect on them and active in the combat tracker and it will only apply the damage when it can, and only once per turn. This could be used for any other effect that can only trigger once per turn, Rogue's sneak attack is another that it can work with (although you'd be assuming that they can always proc it through advantage or an ally within 5').

Let me know if there are any questions, comments, bugs, requests, or any other general feedback.

Thanks and Enjoy!

Version 1.1: Fixed a bug where some standard effects weren't being parsed properly, like ADVATK and such.
Version 2.0: Changed keyword from TURN to ONTURN so it doesn't have potential overlap with AD&D ruleset.
Version 2.1: Allow setting the effects as GM only for visibility when they deactivate/reactivate.
Version 2.2: Update which should make this play nicely with other extensions.
Version 2.3: Fixed a bug where it wasn't working in some cases.
Version 2.4: Fixed an issue with this not working correctly for players.

wmljohn
April 9th, 2020, 15:54
Amazing. I can not wait to try this out.

kentmccullough
April 9th, 2020, 21:02
Updated to version 2.2 this version should play nicely with any other extensions.

celestian
April 9th, 2020, 21:19
Updated to version 2.2 this version should play nicely with any other extensions.

Does this mean you dont need me to look at the code to integrate? ;)

kentmccullough
April 9th, 2020, 21:35
It does yes, but you may be interested in looking at how I made that happen, imo, should probably be a best practice.

Instead of overwriting the EffectsManager5E.hasEffect and such outright, I make a local variable of what it is, and call that inside my new custom handler so that any previous ways it worked will still work so I could just inject my own code into it.



local getEffectsByType = nil;
local hasEffect = nil;

function onInit()
CombatManager.setCustomTurnEnd(endTurn);

getEffectsByType = EffectManager5E.getEffectsByType;
hasEffect = EffectManager5E.hasEffect;

EffectManager5E.getEffectsByType = customGetEffectsByType;
EffectManager5E.hasEffect = customHasEffect;
end


function customGetEffectsByType(rActor, sEffectType, aFilter, rFilterActor, bTargetedOnly)
local results = getEffectsByType(rActor, sEffectType, aFilter, rFilterActor, bTargetedOnly) or {};
-- custom code here

return results;
end



Once I realized that it made it simple to not mess up your extension or any other that's overwriting those functions, at least as long as my loadorder is later. If someone's load order is later, but does this, then my custom code will be called also, and everything will be fine.

4wire
April 14th, 2020, 10:41
Hey man! I was loading your extension but not yet using it but it somehow was screwing up my game last night with latest FGU. 5E enhancer was also loaded. I was getting tbe_ files error but I’ll try to reproduce and get you more details today. Examples of things failing: spiritual weapon couldn’t roll damages, barbarian couldn’t make a cons saving throw, etc.

kentmccullough
April 14th, 2020, 15:34
Do you have the latest version? That would be 2.3 I introduced a bug in 2.2 but it should be fixed now.

4wire
April 14th, 2020, 19:39
I was on 2.2 indeed! Now for some tests!

kentmccullough
April 15th, 2020, 08:52
Updated to Version 2.4:
- Fixed an issue with this not working correctly for players. I'm now using OOB messages so that things can be properly handled on host end (who owns the CT nodes)

4wire
April 15th, 2020, 14:11
Are you on github by any chance? I'd rather pull a new version than come here and download+copy :)

kentmccullough
April 16th, 2020, 16:14
I likely wont be adding this to a git repo, the code is just too simple to bother. Sorry.

ScriedRaven
May 4th, 2020, 23:13
In FGC when used with Combat Enhancer Classic I get the following error.


Script Error: [string "scripts/manager_effect_tbe.lua"]:33: attempt to call field 'deactivateEffect' (a nil value)


Any chance you'd be willing to look into it, or are you going to focus on Unity?

kentmccullough
May 5th, 2020, 15:04
Combat enhancer decided to remove that function from CoreRPG.

ScriedRaven
May 5th, 2020, 18:00
Ok, thank sucks, thanks for letting me know

robotdjuret
May 6th, 2020, 19:15
Hey Kent, I'm not finding this on DM's Guild. I found your name, but only one extension.

kentmccullough
May 6th, 2020, 19:16
Sorry about that, it's in progress of being posted and should be up shortly.

Beemanpat
May 6th, 2020, 20:17
May want to put link to dmsguild in first post when you get it.

dotsoncs
May 6th, 2020, 20:29
Was the extension removed from the initial post?

Beemanpat
May 6th, 2020, 20:30
Was the extension removed from the initial post?

Yes they are being put on dmsguild.

dotsoncs
May 6th, 2020, 20:33
That sucks - should've grabbed it when I saw it posted here yesterday.

robotdjuret
May 6th, 2020, 20:34
That sucks - should've grabbed it when I saw it posted here yesterday.

Yeah, life is pain. :p

Beemanpat
May 6th, 2020, 20:38
That sucks - should've grabbed it when I saw it posted here yesterday.

You wouldn't have access to updates incase something breaks. I have mixed feelings on this. I get it the guy should make something for his work but on the other hand why aren't these built into FG already? I will support him and buy it though

dotsoncs
May 6th, 2020, 20:44
I've found the paid-for add-on extensions to be hit or miss. It would've been nice to try these before purchasing. No biggie - we can handle all of this stuff manually.

Beemanpat
May 6th, 2020, 20:46
I've found the paid-for add-on extensions to be hit or miss. It would've been nice to try these before purchasing. No biggie - we can handle all of this stuff manually.

I used them before they went dmsguild they are all worth it.

Lou Ciphor
May 6th, 2020, 23:35
I don't mind contributing toward good work and system improvements, but $4 for this?

Greywolf411
June 3rd, 2020, 22:53
You wouldn't have access to updates incase something breaks. I have mixed feelings on this. I get it the guy should make something for his work but on the other hand why aren't these built into FG already? I will support him and buy it though

I agree about them being part of the system, but they seem like great extensions. I bought some stuff off of DM'sGuild that were Effects coding for a lot of spells, items, etc, that was pricey and thought it would be worth it. Sadly, I don't believe it was worth, enough that I wrote a review about that fact, which is rare for me to do so. However, these are cheaper, and also deal with more intricate elements than the other effects I bought so I'll likely pick them up. Ugh, this hobby and spending money :)

eriktedesco
June 4th, 2020, 19:40
Hi all, I'm cracking my head over a doubt and I'm pretty sure you can enlight me.
For my campaign I'm using the spell code extension from Rob. However, I'd like to implement Kent operator (SAVEO, ONTURN, SAVEEND, etc) on Rob coded spell. Is there a way to do that?
I know I can add some effect in the effects list, but I really love to drop the spell on my character sheet.
Can I update the code and save the spell somehow?

Thanks a lot!

Erik

kentmccullough
June 4th, 2020, 19:51
Rob has updated the spell code module to include versions that work with my extensions, they're noted with a * in their names. If you notice any (after downloading the update from DMsGuild) that are not right let us know in Rob's discord.
https://discord.gg/FVgtecr

eriktedesco
June 6th, 2020, 08:28
Will the same thing be done for the other modules? Class feature and so on? Sneak attack is non update (no ONTURN operator)

kentmccullough
June 6th, 2020, 14:02
I believe so. If there’s anything that needs it that you notice poke rob in his discord server.
https://discord.gg/FVgtecr
He’ll update whatever part is pointed out. I think/thought everything was corrected, but I’m sure there’s a few edge cases that have been missed.

grimmlock
June 9th, 2020, 00:17
This extension fires off the effect once on your turn then deactivates it, correct? So, that means it would not work for the Samurai archetype's Fighting Spirit which lasts for all attacks until the end of your turn?

ScriedRaven
June 9th, 2020, 01:44
This extension fires off the effect once on your turn then deactivates it, correct? So, that means it would not work for the Samurai archetype's Fighting Spirit which lasts for all attacks until the end of your turn?

Correct. The effect for fighting spirit would be something like "Fighting Spirit; ADVATK;" with a duration set for 1 round.

grimmlock
June 9th, 2020, 02:11
Correct. The effect for fighting spirit would be something like "Fighting Spirit; ADVATK;" with a duration set for 1 round.

Ish. Like, if you make an AOO you don't get Advantage because it's not your turn, so, technically, it doesn't last the whole round.

ScriedRaven
June 9th, 2020, 02:48
Yes, but doing that would require using a different extension, Ongoing Saves (Which is still Kent). It'd be "Fighting Spirit; ADVATK; SAVEEND: WIS DC 0", although this doesn't work because someone else needs to apply the effect onto you for it to work properly

Athinar
August 31st, 2020, 00:11
Where do you place the Code with the "ONTURN", in the "Effects" or in the "Actions". I.E. (Sneak Attack; DMG; ONTURN;)
I have Sneak Attack in Actions, (Sneak Attack; DMG; ONTURN;) and in "Effects"; do I keep "Effects" open for Play and select S.A. each round?
Do I select it from the "Actions"? is there a video?

Beemanpat
August 31st, 2020, 01:42
Where you select it from does not matter the dm can set an effect up in the effects button(top right corner of screen) or you can set up on the characters action tab.
I(the DM) prefer both incase the effect gets deleted from character in the combat tracker the PC can re-add it to their character. But once you have set up it should be automatic.

Hope this helps.


Found this video
https://youtu.be/hG8TvWC-T7k

kentmccullough
September 2nd, 2020, 04:32
Where do you place the Code with the "ONTURN", in the "Effects" or in the "Actions". I.E. (Sneak Attack; DMG; ONTURN;)
I have Sneak Attack in Actions, (Sneak Attack; DMG; ONTURN;) and in "Effects"; do I keep "Effects" open for Play and select S.A. each round?
Do I select it from the "Actions"? is there a video?

Let me know if you’ve gotten this sorted out. If you’d like to chat or have more hands on support visit our discord at https://discord.gg/FVgtecr

Athinar
September 2nd, 2020, 22:13
So, on the "Effects Customs" the "Sneak Attack; ONTURN" has the "Roll" and I don't see "never expire", I'm the DM
39016

Beemanpat
September 3rd, 2020, 12:30
I believe that is correct but I'm AFK right. Did it work?

Fingersome
March 6th, 2022, 03:51
Is there a good way to automate the Fey Wanderer's Dreadful Strikes using this or another extension? afaik I can't seem to find a good way to automate it. If you're fighting one creature, then this works fine, but Dreadful Strikes procs as many times as you want in a turn, as long as it's only once per turn per target.

Roach
July 25th, 2022, 10:36
You might be able to set up s.th. like that using 'Untrue Effects' and use an analogous setp to Warlock Hex effects...
Ger an effect on the target that expires at the end of the round and check for (absence of) that ffect on a hit.

MrDDT
July 26th, 2022, 20:04
You can use untrue effects couple with BCEG.

Use the effect that adds an effect when you do damage. This will track when you hit a target. This effect have it fall off once the turn changes. Then use untrue effects to detect to see before each attack if it has that effect.