#MidiQOL
1 messages · Page 73 of 1
no that was (still is till I update it) an issue in the MidiMacros.laughter
For reference, I was using something like this:
turn=end,damageRoll=(@spellLevel)d10,damageType=psychic,saveAbility=wis,saveDC=@attributes.spelldc,label=Phantasmal Killer
and it was working really well.
I did change your item, but I didn't think it would matter, I changed them from statusEffect to Macro.ce....changing back to see if thats my fault
oh shit it is my fault, I renamed the item to Tasha's Hideous Laughter and am noticing you call the item name
BTW, would you have a blurb of code I could steal to do that ? :)
yeah it still throws same error
man I kinda don't like statuseffect now that macro.ce is working right its a much cleaner workflow and spits out the dfreds CE messages for helpers for the DM
Something like that:
// Temporary spell data for the burst effect
const areaSpellData = {
_id: randomID(),
type: "spell",
name: `${itemName}: Burst`,
img: sourceItem?.img,
system: {
level: level,
chatFlavor: `[${nbDice}d10 - piercing] Target of the attack and each creature within 5 feet of it`,
damage: { parts: [[`${nbDice}d10[piercing]`, "piercing"]], versatile: "" },
actionType: "save",
save: { ability: "dex" },
preparation: { mode: "atwill" },
target: { type: "creature" },
},
};
setProperty(areaSpellData, "flags.midi-qol.onUseMacroName", `[preambleComplete]ItemMacro.${itemName}`);
const areaSpell = new Item.implementation(areaSpellData, {
parent: macroData.actor,
temporary: true,
});
const targetToken = macroData.hitTargets[0].object;
let aoeTargets = MidiQOL.findNearby(null, targetToken, 5);
aoeTargets.unshift(targetToken);
const options = {
targetUuids: aoeTargets.map((t) => t.document.uuid),
configureDialog: false,
};
await MidiQOL.completeItemUse(areaSpell, {}, options);
Wasn't sure if it changed in v10 or not
Dfreds ce is lookin quite stable I'm changing the copy paste
I've been using js let spell = new CONFIG.Item.documentClass(spellData, {parent: targetActor});
I'm in v9.
not sure I like how statusEffect is smooshin them together in an overtime
@broken bridge
As Chris says, it will need some modifications to adapt to v9…
Huh?
I think you got accidently responded to
Prob a fail reply ^^
@spice kraken sorry for the ping, wrong reply to…
Haha, I was confused there
pings again
The way I see it, if you're a helper in this disc, be ready for pings, haha
fair
#macro-polo Might be able to point you the right way for synthetic items in v9. Or I'm betting you could look at source code for modules that do it
this past weeks session I ran was one of the smoothest runs I've had yet. Had only one outstanding error message. Just am waiting for simbuls to fix their debugger and should be a smooth console
You know you can just edit that out right?
Just like delete whatever console.log or whatever is laying around
I figured they'd fix it soon on their own since they answered both of our issues directly in their git
nah its messier than that
the debugger resides in the support module
Then delete it out of there?
You can click on it in console and it'll show you the exact line that has a leftover console.log
bugbear gave me the instructions I'll find them
The instructions are incomplete
did you make a feature for your module where we can just press a button and it finds and updates any existing versions of your premades?
I have created an issue in simbul's with what needs to be done more or less
Me? Yes.
Look for the med kit icon on your items
nice, starting to work your stuff into my custom worlds
Okay, a midi specific question as I'm pretty sure the 5E system doesn't handle this out of the box. Does Midi store the most recent skill or ability check rolls anywhere? And if so is it possible to retrieve them for use in macros or other modules? For instance, if I roll a stealth check, is that value saved anywhere?
nope. But you can access the chatMessage to retrieve it if need be
What are you trying to do?
If this roll is called from a MidiQOL workflow, like an Item rolling that check or something, you could access the Worklfow for some time to retrieve that as well (from the same client that rolled it)
If its indeed for banking stealth, Stealthy module is a masterpiece module, so good.
Streamline accessing information when I'm running combat by adding the stuff I use most to Ilandril's Token Tooltips. I thought having a token's most recent stealth check result would be handy for determining hidden status.
I will look into this, thanks.
bro get Stealthy your mind is gonna be blown
that module is AMAZING for spot/stealth
are you on v10?
Its conditional visibility for v10 on steroids for Stealth checks 😄
I should really install that module
yar its pretty dope for midi setups
Everyone is my game is a bunch of magic casters so I haven't had much for sneaking
Can automate hidden Doors too (regular doors only though, don't try to use it on Secret Doors)
I haven't turned that setting on yet now I'm even more excited
It's my own fault, since I had everyone use Ravnica backgrounds and ebberon races.
Hhhhngh...
i always ban the ravnica backgrounds and strixhaven shennanigans in a similar vein
also the new stuff in spelljammer
just the wonky backgrounds
Yea, I wouldn't normally allow Ravnica backgrounds outside the setting
But my game is purposefully using them
Do I need to do anything special to get Stealthy to work with Midi? Or are they independent of each other?
I got my players building their next campaign toons cause I have a feeling they are going to outpace my patreon artist I went with for dotmm, so far I got a divine soul sorcerer astral elf and a changeling champion fighter.
3 pending builds
I refuse to use any other artist for my dotmm needs, Tychmaps are like in a league of their own
Divine soul so good to one level dip into
Shes going full divine soul
I had them all roll 4d6kh3 and they got 3 stat sets equalling 84
Can do some fun stuff with that
I don't care if they are high stats, I'm just happy theres going to be no pally this run lol
That's surprising
I only play that class when the stats are above average
And those are 100% pally stats
they can basically multiclass anything with those
For my next campaign my plan for stats is to get each of my players to roll 4d6KH3 once, and then i'll roll as well to give six randomised ability scores, and then that will be the default array for all characters.
Equalises power level but everyone gets to have fun rolling.
Do you guys think Arbron’s Summoning will get proper updates? Or should I just spin up my own summoning functions for my module?
I have them all roll and myself too, and then they can pick whatever set they want in whatever order
My issue with arbrons summoning is why have it if you have to use warpgate/sequencer anyway in a macro with it
if it did it all then I'd use it, but its ripe for trimming when trying to reduce module counts due to the fact its not doing the whole thing
I've been using p4535992's fork of Automated Evocations. But that's not exactly something I can easily do for the published module
hes got like 100 modules to maintain, talk to him, I wonder if he'd gladly hand it over
Arbron’s Summoning doesn't have enough API methods for me to properly work with at the end of the day
I wouldn't want it
just merge it into cpr
The issue is making the module easy to install
ehh
jbowens already mentioned merging their stuff from more items
I still need to take a proper look at the stuff from that
If I rename Acid Arrow to Melf's Acid Arrow will that break anything with CPR?
Nah
I should actually rename that in the module
It's just a pre-setup overtime IIRC
I should actually confirm it's working as intended
@vast bane
That acid arrow isn't handling the half damage part. I'll update that.
(And rename it)
Question: Is there a way to make an effect that makes its target only do half damage? I'm trying to automate Ray of Enfeeblement.
I should add this to my module.
The DDB importer has it's own version of the spell, but it's janky
MidiSRD changes all weapons damage parts to be 1/2 when they use strength, but using MidiQOL workflows make much more sense
MidiSRD? oh my
less breaky IMO
hm okay
yeah 'd rather learn how to do it the hard way anyways lol
then it won't be hard later
more or less have the effect apply an on use macro
and have that on use macro check for str attacks and halve the damage
not sure if you can rename right? its using the copyright name
I'm not including descriptions
I doubt they're going to care that the name is mentioned
How else are you supposed to find the matching automation if I couldn't use the name of said automation
Sources of premade stuff for Midiqol:
Midi Sample Items Compendium(comes with the module)
Midi SRD's compendiums
https://raw.githubusercontent.com/thatlonelybugbear/midi-srd/master/module.json
More Automated Spells Items and Features compendiums
https://foundryvtt.com/packages/more-automated-spells-items-and-feats
Mr.Primates premade macros:
https://github.com/MrPrimate/ddb-importer/tree/main/macros
Chris' Premade macros:
https://github.com/chrisk123999/foundry-macros
Chris' Module form of his macros:
https://foundryvtt.com/packages/chris-premades
Activation condition examples by ThatLonelyBugbear
#1010273821401555087 message
This is working cleanly
its not using MTB but honestly if you think about it, this is one of those times where DM auto is impossible to mess up anyway since the spell insists the rolls are advantage no matter what
Oh I need to include the if int < 5 do not apply
can it be renamed or will it break the macro?
Rename the Effect's name too and will be fine
Now I forget which 4 letter green name is the author to ping so they see the love
Am I dumb? I've made the effect and called it "HalfDamage" as a macro and the attached it to the effect I made
either rule or idle lol
yet it still isn't doing it
share some screenshots of the setup
Keep in mind that example does half damage for everything
that's fine. just as long as something does half, i can manual the rest lol
if you install the midi srd fork you don't have to make anything and can just drag and drop
DFreds CE issue I think. Make that on a DAE directly
You'll want to do a check on workflow.item to see what stat it uses
@jade gazelle try creating the DAE directly on the spell
i'll try making on DAE
have we cleared advanced macros from our premades yet or is it still required? he doesn't have it fyi
I still have the module, but nothing uses it anymore
AA template auras needs it iirc
yeah
So if you have stuff that uses that...
that might not even actually need it, thats carried over from kandashi's builds and is just checking for it
wonder if we can just clear that line out of the macro
I think it's needed to pass the args
Anyways off to bed, I'll take a look at acid arrow and zellot barb tomorrow
I actually think acid arrow is also in midi samples
I willing to bet it won't work on a nat 1
Since damage workflows aren't run for that
Unless it manually rolls the half damage
Is there a way to see why midiQOL is making a roll at advantage or disadvantage if you aren't sure why?
Thank you
Oh
I had that happen. I couldn't figure it out. It was actually that the scenes weren't globally lit so... the tokens couldn't see... and always rolled disadvantage
I actually think Tposney should make attribution on by default cause that hidden flag is sneaking up on everyone lol
I'm using midi .32 - is this function working as expected? I seem to recall there being a reason I turned it off
Should be fine now
Nothing special needed - it takes advantage of the 'Hidden' effect processing already in place in midi
Quick question because reading the documentation, I'm confused on how it works:
With itemMacro and midi-qol, is there a way to alter the targets of an ongoing workflow?
Because when you cast an AOE spell, it targets everything in it, and I want it to only target allies. Can I do that with an itemMacro?
Better change the Target entry of the Item in its details if you want to affect allies around the caster within a specific radius
Like 30 | Ft | Ally
Cannot do that.
If you want to put down a MeasuredTemplate at some other point then you can use a macro
Cuz ally is in the same menu as "sphere", and I have to have a measuredTemplate.
Because it's not an aura, it's an aoe on a point within range.
- Added preTargeting onUse macro call and preTargeting Hook. This is called before any item use processing is done It is also called before the workflow is created so only very limited data is available. A dummy workflow (if a workflow does not already exist for the item) is created, with the item/actor and selected targets is passed to the macro/hook.
Yeah, I read that, but I'm having a hard time using it, I was asking for help on how to implement it :)
You can change them there probably, or you can change the ones you want after the template is created called only once the template is placed
I have used just the game.user.updateTokenTargets([ids]) to change them by getting the game.user.targets returned by the automatic MidiQOL (or other module's) targeting for AoE and then filtering for the allies
In general, I have a hard time understand how mutability works in foundry. Are the arguments passed to macro copies or references to the actual arguments of the workflow?
Hmm.
Ok
Imma try
one example I found <#1010273821401555087 message>
and sculpt Spell <#1010273821401555087 message>
That's with a hook though right?
Yeah, I did that, I get the args.
My qyestion is, if I modify that, is it just modifying a copy, or am I actually modifying the actual workflow?
You can modify the Actual MidiQOL workflow in that stage
Oh, cool. So I just have to edit hitTargetUuids?
nope. Before that. targets.
OK bear with me I am in a meeting 😄
I'm not pressing you for answers, I"m grateful for your time :)
Yeah no worries, didnt mean it like that. its just I need some time 😄
So theorically, I can just do :
args[0].targets = args[0].targets.filter(t => t.data.disposition == -1);
in the item Macro and I'm good?
Try this at any point after the template has been placed. ```js
game.user.updateTokenTargets(args[0].targets.filter(tok=>tok.disposition === canvas.tokens.get(args[0].tokenId).document.disposition).map(i=>i.id))
This will not change the workflow.
That was my question when I was asking if the args from item Macro was a copy or a ref. So it's a copy?
Ok, I'll try the updateTokenTargets.
You will need to change the ```js
let workflow = MidiQOL.Workflow.getWorkFlow(args[0].item.uuid)
workflow.targets = ...
Created a magic item for Boots of Elvenkind and was surprised when I didn't get the advantage roll. V10.291 5e 2.1.4 midiqol 10.0.32 I can see the passive effect on the character, but am not getting the advantage rolls. Any ideas?
or just plainly using ```
this.targets = ...
Change add to custom and put "1" in value.
This Spiritual Weapon item macro is from the MidiQoL sample items compendium. It's not quite working for me. The SW actor that warpgate creates isn't set up correctly (I think - the attack isn't equipped, so there's no attack roll). I have an actor that the macro could use, but I'm not sure how to get it to do that. Any help would be gratefully received. (the macro is apparently too long for discord)
I'll give it a try
Oh that looks promising.
this.targets doesn't work, imma try fetching the workflow.
No joy. Still only a single roll
Strange. Does for me
this.targets = [token] as an ItemMacro | Called before targeting is resolved
I did it on "call after template is placed", Imma try.
Fetching the workflow doesn't work either ><
let workflow = MidiQOL.Workflow.getWorkflow(args[0].item.uuid);
workflow.targets = new Set(args[0].targets.filter(t => t.data.disposition == 1));
Should work, right?
(I'm trying to target only allies for healing).
Either use workflow.targets which if I remember correctly is a set that holds Token5e or
args[0].targets which is an Array that returns the TokenDocument5e
oh you are v9
Try without the data before the disposition
Yeah, but it's the same from what I can see in logs.
So my code is:
console.log(args)
let workflow = MidiQOL.Workflow.getWorkflow(args[0].item.uuid);
console.log(workflow);
workflow.targets = new Set(args[0].targets.filter(t => t.data.disposition == 1));
console.log(workflow)
And for some reason, on the second log, the targets are unchanged.
This is kinda frustrating x)
Likely the template actor needs a particular item on it for the macro to scale
Hmm I don't want to think that you hit a limitation of v9 MidiQOL 🤔
When do you run the macro?
"After Targeting complete"
Imma try the game.user.updateTokenTargets thing
Oh! A change!
Now there are no targets anymore. I think I messed up in the ids, but it's promising! Thanks a ton !
Yeah the game.user.updateTokenTargets is my go-to method TBH
It works. Thanks again. You're the best bugbear there ever was.
Is that a really low bar?
Dunno. There are a lot of bugbears out there.
Hi guys is there a way to create a weapon with two damage type (piercing / slashing for example), but only one damage roll, just so that it applies on resistance / vunlerability etc with piercing AND slashing
Just add more Damage Formulas
Not with the default system. Why would you want a single roll to be multi-typed?
two damage type (piercing / slashing for example), but only one damage roll
Emphasis mine
I'm reading that as a 1d6[slashing/piercing] that they want 🤔
well that is a strange request that did't cross my mind!
Because im from pathfinder 1, and some weapons have two damage type thats why 😄
and on Midi i can't like change the damage type
it does rolls instantly
Hello everyone
I was just looking at the MidiQOL class features for Bardic inspiration and there are 2: Bardic Inspiration (Valor) DND2.0.2 MQ10.0.10 & Bardic Inspiration DND2.0.2 MQ10. It also says: "You must ensure your bard has the dnd1.6 bard class not the older 1.5 version or scaling won't work."
Does anyone know which one should I use and how do I know which dnd bard class I have 1.5 or 1.6?
Thanks in advance
You can create a Dialog to choose damageType to apply, but it's like homebrew stuff which MidiQOL doesn't have an already baked in solution for.
It's doable, but macro territory
Okok thanks you a lot
You can also use the versatile field, then you can use [] to have a different type in there
Through then you have to pick the type before you start the roll still
I think it needs the attack actually equipped, but I don't know how to do that.
You can automate it. For instance if the description of the item is something like damageTypes: ["slashing", "piercing"]
ItemMacro | Before Damage Roll ```js
//const damageTypes = ["slashing","piercing"]; will make it work better later
const targetActor = args[0].hitTargets[0].actor;
if (targetActor.system.traits.di.value.has("slashing") || targetActor.system.traits.dr.value.has("slashing")) this.item.system.damage.parts[0][1] = "piercing"
else if (targetActor.system.traits.di.value.has("piercing") || targetActor.system.traits.dr.value.has("piercing")) this.item.system.damage.parts[0][1] = "slashing"
hmm this might work actually 🤔
It needs some cleaning up! There are situations that this will fail and need to filter them.
What happens if it has both slashing and piercing resistance etc. no need to change anything then
I might play more with it when I have time
Can change the damageType to target damage vulnerability also
Like right now, it only applies to damage resistance right ?
I changed it from probably when you copied it
The latest should be fine for dr and di
I should really clean it up to be easier to read
hi, @scarlet gale just FYI, The vampiric touch isn't working. Getting an getItemDescription is undefined error....
think it's line 12 in the macro: featureData.system.description.value = getItemDescription('CPR - Descriptions', 'Vampiric Touch Attack');
there's no CPR -Descriptions compendium, and it might need to be chris.getItemDescription... is that right?
yes
Did you delete the journal entry that gets generated?
Could you screenshot the error in console?
instead of just the snippet
Easier to figure out the line the error is on
oh
i see the error
I dropped a chris.
from before it
Just pushed the update
You may need to force re-download it
ah, i also see an issue. When I target a token and cast the spell, it creates the vampiric touch attack but doesn't execute an attack. Maybe it's just interpreting the rules differently, but my impression was that you made a mêlée spell attack, it did the damage/healing, then it added the vampiric touch attack item which you could use on your subsequent turns. since the vampiric touch is linked to the target, right?
Oh, you should use the created attack as well
I didn't have it doing that automatically because it was problematic to do with renamed spells
so cast the spell with no target then use the created item?
pretty much
although I just thought of a fix for that
but for now it's intended that you just click the spell, then click the created feature
ah, ok. i was using another macro before that made the attack then created an at-will spell for later use.
but i'm trying to cut down on multiple sources of macros
I'm making an update for it that'll do the initial attack
if anyone is interested, I wrote a script that will get various compendia (you can define them in the macro) and let you select one to update all your spells and items, etc. in one push.
I plan on making a button in the actor hotbar that will do that for my stuff. Right now you need to do it on a per-item basis. Click on the med kit icon on a spell or feature you have and it'll look for my own automation for it.
that's what got me thinking of this.
For the split second I saw yours, it looked like a variation of my spell updater macro
Looks like mine honestly
might be, but with some modifications
I put the dryRun part at the top of mine lol
(as i see deletes in that, be sure to make backups before executing for safety reasons) 🙂
probably from you then. 🙂
Just FYI, that can result in problems on NPCs, since a lot of monster share the same feature name
yes, it actually replaces items and spells, instead of just updating them. I found I was getting multiple AEs if I let it update
i should make a note this is just for PCs
might be a bit specialized for wider use.
Also, you have a .data in you script
let actorID = actorD.data._id; should probably be let actorID = actorD.id;
thank you1
I created an actor with a melee spell attack feature and didn't modify the supplied macro at all. I did have to give the spiritual weapon 1 HP (and AC 30 to reduce accidental death) also uses a hardcoded attack modifier that I'll have to update when the cleric gets an ASI... (and when proficiency bonus goes up... it's a bit of a kludge)
Next update will auto use Vampiric Touch Attack on the initial casting
I'd recommend giving it immunities to all types of damage and conditions, should make it easier to auto-apply if there is an AoE spell
const isFavorite = oldItem.flags.favtab && oldItem.flags.favtab.isFavorite && oldItem.flags[ "tidy5e-sheet" ]?.favorite || false;```
I think this won't ever detect anything as being a favorite. Since you're setting it to have the old favorite flag and the new one.
You can set the creature type to NoTarget and midi will just ignore it.
Huh, I never knew 😮
At least for AOE stuff
@opaque patrol this mod is awesome.
Thanks. It's what happens when a programmer gets annoyed playing a gloomstalker!
@violet meadow Did something happen to the 'ReactionFilter' in the last couple updates? It doesn't seem to be respecting the adjusted item list anymore.
Hey, I'm using the MidiQOL Sample Item for Sneak Attack, on a half-orc rogue that also has Savage Attacks (roll an extra damage die when you crit with a melee weapon attack).
Everything seems to work fine except for it's rolling 6d6 for sneak attack damage when I think it should still be rolling 3d6 as the rogue is level 6. I don't think savage attacks should give an extra damage die for each die rolled on Sneak Attack.
So the order is this that is currently happening:
- Rogue goes first in combat and uses scimitar+1
- Rogue rolls with advantage due to Assassinate, rolls 26 total
- Target has surprised status so Assassinate causes the attack to automatically crit
- Rogue rolls 3d6 +1 + 2 damage on the +1 scimitar, which would normally be 2d6 due to the crit, Savage Attacks makes that 3d6
- Option then appears to use sneak attack
- Press yes
- Rolls 6d6 - I think this should still be 3d6 as the rogue is level 6
How I have assassinate set up is as an item macro on the +1 scimitar, which is below, and I am using the Sneak Attack item from the MidiQOL Sample Items compendium. Savage Attacks is set up by adding a Special Trait to add one extra crit die.
The ItemMacro for the +1 Scimitar to automate Assassinate is the same one that @violet meadow posted above in this channel:
if (game.combat.round !== 1) return;
const sourceTokenId = args[0].tokenId;
const targetToken = args[0].targets[0];
const targetActor = args[0].targets[0].actor;
const targetTokenId = targetToken.id;
const sourceTurn = game.combat.turns.findIndex(t => t.tokenId === sourceTokenId);
const targetTurn = game.combat.turns.findIndex(t => t.tokenId === targetTokenId);
if (sourceTurn < targetTurn) {
game.assassinateAttackHookdId = Hooks.once("midi-qol.preAttackRoll", (workflow) => {
foundry.utils.setProperty(workflow, "advantage", true);
})
if (targetActor.effects.find(eff => eff.label === "Surprised")) {
game.assassinateDamageHookdId = Hooks.once("midi-qol.preDamageRoll", (workflow) => {
foundry.utils.setProperty(workflow.rollOptions, "critical", true);
})
}
}
Hooks.once("midi-qol.RollComplete", () => {
if (game.assassinateAttackHookdId) Hooks.off("", game.assassinateAttackHookdId);
if (game.assassinateDamageHookdId) Hooks.off("", game.assassinateDamageHookdId);
});
Nothing comes to mind, but I haven't used that recently tbh
Maybe you need to poke the Big Master 😁
This does do critical damage for the sneak attack when it should assassinate
Hmm I am on the phone now so not easy to follow that
Seems a problem on my end - a reaction damaged turned back to just reaction. Never mind.....
No worries, appreciate any help when you have time. Think I confused myself writing it out but I think it's the current behaviour I've seen haha
@knotty hollow the critical sneak attack should be 6d6, correct?
Plus 3d6 + mods for savage attack and critical for the scimitar.
Do you see something else?
No that's what's happening, but I don't believe Savage Attacks should stack with Sneak Attack in that way, since Savage Attacks only gives an extra 1 damage dice on the melee weapon attack, I don't think it should add anything to Sneak Attack. Even if it did, I would've thought that should only be 4d6 (3d6+1d6) rather than rolling an extra damage die for each sneak attack damage die, 6d6 (3d6+3d6)
I don't know if there's some change I can make to the macro to account for that specific scenario?
It’s perfectly possible I’m either wrong or totally dumb
I am confused.
Lvl 6 rogue does 3d6 sneak attack.
Critical sneak attack is 6d6.
…I’m dumb
This
Ignore me haha
Hahaha no worries. I have done worse 😁
Think I was just taken aback by the damage for a level 6 - not used to rogues at all haha, thought something had to be wrong
They do tend to be dealing lots of damage thats why I hate the shoot and hide mechanics for rogues
hey all-- i'm trying to automate a wisdom saving throw on an attack that is described like so: Melee Spell Attack: +8, reach 5 ft., one target. Hit: [[/r 1d6 + 3 + 3]] slashing damage. If the target is poisoned, it must succeed on a Constitution saving throw against your spell save DC or be paralyzed until the end of its next turn.
I've got the condition working.
which triggers an item macro:
and the item macro is getting the target, and its uuid: ```js
const lastArg = args[args.length -1];
let target = await fromUuid(lastArg.tokenUuid);
let uuid = target.actor.uuid
console.log("uuid:", uuid);
await game.MonksTokenBar.requestRoll([{"token":target}],{request:[{"type":"save","key":"wis","slug":"save:wis"}], dc:16, silent:true, fastForward:true, rollMode:'roll'})
ui.notifications.info("This macro worked!")```
but i'm not sure a) how to get the spell dc from the original caster (this is an attack from a summoned creature, and the save is the original caster's spell DC) and b) how to call the saving throw elegantly.
basically three tokens/actors are involved
summoner > need spell DC
summoned > making attack
Target > poisoned and has to make wisdom save vs. summoner's spell DC
Generally do not use [slashing] when the damageType of the formula is already Slashing
add @target @attributes.spelldc
Undead Spirit? 😄
target.effects.some(eff=>eff.label === 'Poisoned') as an Activation condition on the attack
Ah you got that already, nice
I just use an actor with the attackBonus, damage and saveDC pre defined cause I am bored
on my summon spells, I'm using Crymic's macro to summon from a single Undead Spirit that has all the items on it, but which get deleted/scaled depending on the type of summoning.
My group is gonna be playing without me this weekend 😔. I think I have .30 installed right now which had some issues iirc. Am I pretty safe to just update midi, dae, CE to the latest versions before they play? Or am I gonna be wreaking havoc for them?
hello! have a way to setup magic resistance for the player? mid flag not working.. add feature with the name and nothing. Thanks
They seem safe to update.
Thanks. I think I saw some potentially worrying post from Moto that the Do Not Apply CE checkboxes might be misbehaving or something. But if you and Chris are all fine that’s good enough for me!
I think DFreds issued an update
I can’t really test right now, in hospital for a few days
Wait for Moto to chime in
Hope everything is OK ❤️
Yeah man super ok thanks, I’m a dad now… twin boys 👀
How dare my group carry on without me tho
Congratulations!!
Thanks midi fam
I sensed my name
But congrats!!!
@coarse mesa Congrats on boys and the statusid bug was fixed, the toggle now works right, and macro.ce is working great. I'm fairly confident the newest of all 3 is the new stable unless I see otherwise. Now the only outstanding instability is Simbuls Cover Calculator as it throws a ton of errors and it still has that debugger issue.
is anyone else unable to get flanking to work in the newest midi?
Nm hostiles can't flank hostiles
Hello 🙂 I am experiencing a problem with MIDI-QOL. Specifically when casting lightning bolt against foes, I get this :
Uncaught (in promise) TypeError: undefined. Cannot read properties of undefined (reading 'ignoreTotalCover')
[Detected 1 package: midi-qol]
Strangely enough it doesn't seem to happen, e.g. , with cone of cold
MidiQOL version?
isn't the solution to that to toggle the cover checkbox?
I can't find it.
(I supposed it would be something simple like that, but I can't find where that checkbox is)
What MidiQOL version are you on EA?
Latest I think, I just uninstalled and reinstalled - 10.0.32
Strange. This should be fixed in 10.0.32 🤔
it doesn't happen for, say, fireball or cone of cold
Just lightning bolt I've discovered so far.
lightning bolt from the SRD spells?
I think I imported from DDB
Can you get the Lightning Bolt from the Spells (SRD) and try again?
Can you click on the utils.js:1907 link?
Awesome, thanks!
does the user have spellsniper?
yeah it seems it needs optional chaining there too ```js
item?.flags.midiProperties?.ignoreTotalCover &&
That did it, thank you
The issue is why would it not find the midiProperties if the Item is a Spell?
I really have no clue...
Maybe something is wrong with my foundry setup, and it's not your fault? Maybe something was imported the wrong way...I truly don't know
It can't be mine, cause it's not my module 😅 but I am wondering why 😄
yeah I wonder how
are you a ddb importer?
I wonder if that could be it?
Can you uncheck the box and try again now?
Upon checking/unchecking it works.
But they said that they tried the Lightning Bolt from the Spells (SRD) too with the same issue
weird
Sorry I can't be of more help :/
Somehow the midiqol flags were not set
All latest
yeah no worries. Its like academic interest by this point 😄
any chance we can get the actual numbers?
Man that bug is gonna bother me forever, I hope tposney says what fixes it when he finds it lol
the ignoreTotalCover?
yeah just knowing whats causing it
what's strange to me, is that it shouldn't throw up
Just a ? in that line is what it will need
in the utils.breakpoint, I moused over. item?.flags is null.
But null checking is there with ?.
I really have no clue.
item.flags will exist
But not item?.flags ?
item.flags.midiProperties was the issue
I don't get the error and I have the same versions as them
The error shouldn't be triggered
Something was bugged cause the Item didn't have a flag what was supposed to be there 🤷
What's weird is
if I try a similar spell (e.g. Aganazar's scorcher), it works fine
Ah well, no harm no foul 🙂
since tim just changed that checkbox's functionality maybe he changed something about it and mr.primates imports aren't following the change?
maybe the srd got replaced by the ddb one through that feature
doesn't ddb replace srds
Does it????? 👀
midis shapin up to be in a good place again, all the support mod authors are updating to 32 well
misremembered - it worked better with an active ability
is it possible to automate the damage that reduce maximum health like the bite of a vampire ? 🤔
install Chris' module he has a feature premade that does that
the clay golem attack and the probiscus
Sources of premade stuff for Midiqol:
Midi Sample Items Compendium(comes with the module)
Midi SRD's compendiums
https://raw.githubusercontent.com/thatlonelybugbear/midi-srd/master/module.json
More Automated Spells Items and Features compendiums
https://foundryvtt.com/packages/more-automated-spells-items-and-feats
Mr.Primates premade macros:
https://github.com/MrPrimate/ddb-importer/tree/main/macros
Chris' Premade macros:
https://github.com/chrisk123999/foundry-macros
Chris' Module form of his macros:
https://foundryvtt.com/packages/chris-premades
Activation condition examples by ThatLonelyBugbear
#1010273821401555087 message
Pro tip, install all of the dependencies manually for Chris's Premades cause it bugs out cause his module has like 10 dependencies lol
one thing of note about automated animations and midi when you have check hits/saves is if the spell is multi target it applies the animations to all regardless of save/fail. Noticed that last session. Blindness deafness was upcasted and 1/3 succeeded and it had the animation on it.
thats prolly an Otigan thing not tposney though
There is no check for save in AA, it only hooks on AttackRollComplete, DamageRollComplete and RollComplete events.
But it could probably be added…
I'll write up a feature request for him in a lil bit
He said he was going away for maybe a month, so don’t expect to have this soon…
totally understandable
Thanks Moto <:]
I'm just the messenger, Chris, Bugbear, Tposney, and Mr.Primate are the heroes here there.
Has anyone found or devised a way to prompt for on hit effects like Divine Smite via midi and/or item macro? There's the midi damage bonus flag, but since something like smite is variable based on spell slot used, I assume you'd need to trigger a prompt on hit to ask for what level spell or something to effect the actual damage bonus
Sources of premade stuff for Midiqol:
Midi Sample Items Compendium(comes with the module)
Midi SRD's compendiums
https://raw.githubusercontent.com/thatlonelybugbear/midi-srd/master/module.json
More Automated Spells Items and Features compendiums
https://foundryvtt.com/packages/more-automated-spells-items-and-feats
Mr.Primates premade macros:
https://github.com/MrPrimate/ddb-importer/tree/main/macros
Chris' Premade macros:
https://github.com/chrisk123999/foundry-macros
Chris' Module form of his macros:
https://foundryvtt.com/packages/chris-premades
Activation condition examples by ThatLonelyBugbear
#1010273821401555087 message
Chris' premades is a good smite
Thanks a bunch! Can't wait to dig through these. I checked the pinned posts (for once) first looking to see if there were resources listed but I didnt know of these. I'll have to bookmark asap
So interestingly enough Chris's divine smite seems to be following a similar philosophy that I was thinking, inspired by bugbear's hexblade curse iirc. However, the workflow loses me. Equipping the item gives you an effect, that effect triggers a macro by name and passes a parameter. That macro came with Chris's module and imported a macro folder, so I found the named macro. After that though I don't see where it goes, the macro is just one line and is calling:
await chrisPremades.macros.actorOnUse(this, "divineSmite");
I'm not sure where the workflow goes after this macro is triggered
It almost feels circular but I can't figure out where the parameter goes or where the dialogue comes from
midi srd and CPR use that method so he can update things easier
theres a file in the module folder you can open and search for divine smite
Oh interesting, I saw that when browsing his repo before installing. So that method isn't front facing? As in, there's nowhere in the foundry UI I could view it like the compendiums etc..?
Does it function like a normal macro or does it have other dependencies? Like if I copied the script and dropped it into a regular macro, and had the DAE effect call straight to that macro would it work similarly?
Just trying to figure out how it works for inspiration if I wanted to build my own down the line
I'd wait for them to be active here and ask them, Chris and bugbear could answer that as they both maintain modules that do that, midi srd and CPR
I know its there for easier maintenance when midi changes how things are done
For sure, it's a robust setup for the stuff they have, but a smidge harder to replicate on custom designs. Lol. But I think it does provide some good ideas on how stuff like this works overall. Thanks again!
You do need to rename the item to Blessed Healer when it is added to the cleric. Then it should work - I use it in my game all the time.
Hello everyone - I posted this earlier but no hits so far😃
I was just looking at the MidiQOL class features for Bardic inspiration and there are 2: Bardic Inspiration (Valor) DND2.0.2 MQ10.0.10 & Bardic Inspiration DND2.0.2 MQ10. It also says: "You must ensure your bard has the dnd1.6 bard class not the older 1.5 version or scaling won't work."
Does anyone know which one should I use and how do I know which dnd bard class I have 1.5 or 1.6?
Thanks in advance
So I searched around but is there a @raceOrType for custom subtype / type ? 🤔 I just learned how Activation Condition worked, but I need to slay a specific homebrew type of creature
try that specific name
My module passes the midi-qol workflow to my own functions in the module.
This is essentially what it gets funneled too in the end
I'm not proud of the switch statement in there
But it works
¯_(ツ)_/¯
On an item macro this is the workflow. So instead of doing let workflow = args[0].workflow you can just do this
Like @theHomebrewName ? or "@raceOrType".includes("Homebrewname") ? (Number 2 won't activate)
Edit: Wtf, now it's working 😠
Edit 2 : Nvm, it's not working 😢
I wish I had the knowledge to use it as a base for my macro. But I got a question about that line : if (type === 'undead' || type === 'fiend') damageDiceNum += 1; is the type only define by default types of 5e ?
show me the details of the slayer weapon
what on earth is that lol
I don't know 🤣
My helper function sorts it out. If the target is a npc it uses whatever was selected as the monster type. Of us a character it'll use the race
It's mostly just a test to see if I could easily make a homebrew slayer weapon with a custom type
why are you making one from scratch?
and the other damage formula is in the details of the item, you don't do an active effect
I've missed that folder, i might come back to you Thank you again "messenger "
Oh my, it's not the same code as from the wiki
it doesn't work though
I dunno why but custom type is not firing slayer
I'd use an effect or something instead I guess
or world script a new custom creature type
I doubt many modules check the custom type box
Including my own
I should take a look at that
Dang.
A world script to add a new creature type would work
Time to learn world script then, thank you people !
you could also include the creature type in every monsters actor name and then do a check for partial on actor name instead
like gray/green/red slaad
check for if actor has name slaad
Yeaaah it's a Unique named monster, that's the reason I did not that first ( And I would like to have a bunch of this type too)
Is there a way to have effects from conditions automated when they have the icons for them on an actor? (blinded, paralysed, etc)
install midiqol, dynamic effects using active effects, and dfreds ce
and get rid of cub if you have that
cub was stopping it from working
thanks
target.details.type?.value === "undead" || target.details.type?.custom?.toLocaleLowerCase() === "buggybear" || target.details.type?.subtype?.toLocaleLowerCase().includes("buggybear") || target.details.race?.toLocaleLowerCase().includes("undead")
Activation condition including custom and subtype race checks for NPCs.
Includes gives you some leeway when checking as it can match only part of the string
I've no objection in principle. The combat ones can be handled via a Hooks.on(....) already, but I guess it's a little tedious to have to add those in the itemMacro first use, so will have a look at that. The onReactionTriggered is potentially tricky - but will have a think
There was also a suggestion that the special duration expiry also trigger an item macro call - which might be useful
@gilded yacht did you happen to see the message I sent regarding the bardic inspiration?
I answered you, the way you find out is if your bard has a scale value for inspiration
because his macros are referencing scale values made by the srd class and the ddb class
Oh my gosh I didn’t see that! So sorry and thanks a bunch will take a look when I get home this evening!
The issue I had with the Hooks.on approach is that sometimes a client can be reloaded mid game and the hooks of a specific ongoing spell for example would be purged. Workaround was to provide on toggle on/off Effect Macros to register again those hooks when/if needed.
Hello, Is it possible to replicate the ifSave settings with activation being enabled ?
I made it work with 'workflow.saves.size == 0'
Hey guys. When creating an effect via macro scripting, does anyone know how I can specify the special durations from midi? I want the effect to go away after the next saving throw.
I see in the documentation isSave.wis but I don't know if I pyut that in the changes or in the duration field.
@sinful phoenix here
thank you
is there a way to give a +2/-2 to rolls with an additional source of advantage/disadvantage
Like generally in all of your game?
yes if possible
Advantage gives +2 instead of double the dice?
Its in the DAE flags of the effect
So create an Active Effect as you want it on the actor.
Log that effect in the console.
more like +2 after they get advantage
Use case example to get my brain going?
If they have advantage, attack with 2d20 + 2?
yeas
Does it happen always or when a specific feature is active?
i guess always just in case?
Why isn't there a blurb somewhere in the doc that shows how to set it, though, I'll never understand ><.
For reference :
flags: {
dae: {specialDuration: ["isSave"]},
},
apparently is the answer?
Although for some obscure reason, when that effect is applied, the change mode goes from CUSTOM to ADD and I have no idea why.
Module data is always in the flags
Is there a list somewhere of the socket handlers registered by a module?
MidiQOL.socket() in console will give you the midi ones.
socketlib in console will give you the modules with registered ones too
and you can access the FunctionLocation down the road
Ooooh. Didn't know you could call it without arguments to have the list.
Good to know.
This is from the MidiQoL Sample items -- it's a little confusing. Do we need to add something related to spell level, or is that taken care of by the item macro? My quick very noob read of the item macro seems to imply that it's taken care of by the macro?
Blessed Healer
@gilded yacht it seems that when you make an attack with (dis/)advantage, the workflow is updated to indicate workflow.advantage/workflow.disadvantage on AttackRollComplete.
I was trying to add a situational attackBonus to the workflow (<#1010273821401555087 message>), by either a js if (!!workflow.advantage) workflow.setAttackRoll(await new Roll(workflow.attackRoll.formula.concat(" +2").evaluate())) during the preCheckHits (hooking on preCheckHits)
or js if (!!workflow.advantage) Hooks.once("dnd5e.preRollAttack", (item,config) => {config.parts.push("2")}) during preAttackRoll (hooking on preAttackRoll),
but both ways failed cause the workflow.advantage was still undefined by these points.
Any way around it?
Nope just change the name as indicated.
The ** is from the normal description of the Item, provided by the relevant Foundry SRD compendium that states what needs to be done in case you use it with Core Foundry.
Perfect, thanks for the update.
This: <#1010273821401555087 message> was what I was trying to do for your case. I will pick it up after tposney takes a look 😉
ok thank you
@vast bane about the request for AA to support saves, could you detail the use cases that you want to be supported, I may take a look at how to implement it in AA.
i have hit a dead end with this macro. It's part of the macro for blight, and i've got it correctly determining target's type and managing the data... But I can't to get it to apply half (maximized) damage to a plant creature with the midi damageOnlyWorkflow. It consistently applies full damage even when the plant makes the saving throw:
also, because there is a macro applying the damage (and it's a damageOnlyWorkflow), how can I determined what item made the attack and called the damage. The workflow is returning "null" for item.
Use case 1: The spell Bane, targets 3+ targets and each makes a save, if they succeed they should not get the animation on them.
Use case 2: The spell Blindness/Deafness when upcasted allows you to pick an additional target, if one fails and the other succeeds then same thing happens, one should get the animation while the other doesn't.
Use case 3: Sorcerers can twin a single target spell, basically same as use case 2.
Use case 4: Slow spell has the caster pick X targets in an area and if they save they are unaffected, if they fail they should get the animation effects.
yes, the "null" item is an issue for another automation (Grim Harvest) i'm working on. It has a Hooks.on("midi-qol.RollComplete) trigger, but because this damage is being applied by an ItemMacro, there's no item in the workflow. How would I correct for that?
rephrased: how would I inject the item parent item object into the midi damage only workflow so that it triggers a hook?
put that into my blight macro, which isn't returning a workflow.item?
The idea we to call the hook with the information from the item macro, which has the item in it's scope
Ok, regarding the issue I had yesterday with MidiQOL + coverCalculations
What fixed it for me is this (I disabled each module, once'/turn, etc, and it was Dice so Nice)
And this setting in particular. Enabling it as shown below fixed it :
maybe it locks or overwrites the item.flags bit, while waiting for the dice to roll
and midiqol can't find the midiproperties, or who knows
But with that bit checked, it works
I am a backend dev 😦 I am not cool enough to know the answer to this...
But at least this works for now.. 😄
Sounds more like midi or cc are waiting for (or failing at for) a chat message to appear. Which is a bit silly in this day and age so I hope not
is there some way to get midi to create an effect or flag that ignores resistances the way elemental adept does?
have you seen how elemental adept is done in midi?
the dr.value key has all the resistance types duplicated with -acid and acid and the negative one means its removed from the target, however most of the time you want to do this before the items rolled with midi so you gotta do a macro, my preferred method is to make a dfreds CE and apply it pre item roll
There is also the case with spells that deals damage but allow a save or no damage, or half damage but a target has a special ability like Evasion to take into account…
I suppose you could pull this off alot easier if you tethered the animation to the active effect instead and disabled animation on spell cast
then the only scenario you need to account for is yours you just mentioned
I've had active effect animations off forever due to a really old bug with spirit guardians, I prolly should turn it back on and start using it instead of spells for duration effects
@scarlet gale I have a feature request, the stench abilities, either from the Hezrou, Troglodyte, or um...Ghoul or Ghast I forget which. All 3 have a stench like ability that is save within range or be sick, once you save it off immune for 24 hours.
like the stench part is easy, its the immune for 24 hours that gets me
Probably easiest to drop an effect on targets that become immune
I'm trying this, but the flags aren't showing up
I can type them manually, sure, but when I look them up they're not there
(Got midiQOL installed of course)
(Well, my GM does)
they aren't showing up because the actor doesn't have the ae, you have to set the first tab checkbox on the ae
if its a feature thats always on, apply on equip
if its meant to be rolled and applied to someone, then don't check a box at all
if its meant to roll and apply to self also DONT check any box no matter how right they may seem for you. Instead don't check a box and set the details of the items range/target to self/self
I mean they don't show up here
they don't show up in his either bud
its because you are MAKING a key
notice how his dae field below each key is blank?
OH
that implies that dae aint got nothin stored for it to match
you still have to match his key though
Yeyeye
cause its a special midi key where you can set your own name in that one section of it
if you are curious what feature it is in the readme, I think its called an "optional.name.macro" or something
and infact dae auto populates that, but you shouldn't use "name"
otherwise you gonna have a bunch of things walking around with the same flags
I have midi, but I didn't know about dae...
Honestly don't wanna ask my DM to install a whole module just for this
honestly a midi user without dae is strange af
you also didn't put the flavor in the damage
+@prof[cold]
Thanks, of course the problem was missing DAE
I tried using the midi-qol Lay on Hands but I couldn't get it working. It just kept wanting to do 65 points
read the bottom of its description
(and always read the bottom of the sample item descriptions)
is there a way to interrupt a midi workflow if a certain condition is met? like so: ```js
if ( macroPass === "preDamageRoll" ) {
;console.log("Rolling Damage Here!")
const [ target ] = targets;
const isUndeadConstruct = target.actor.system?.details?.type?.value === "undead" || target.actor.system?.details?.type?.value === "construct";
console.log( "isUndeadConstruct:", isUndeadConstruct );
if ( isUndeadConstruct ) {
return;
}
}
f12 for console
your paladin is not a paladin
LoH only works on player characters with a paladin class
and if you have that, you aren't using an srd paladin class
(or hes out of resource)
OR, you don't have dae installed
are these the right things?
then that's good
your problem is probably user error, did you not long rest them after they got the feature?
what is their primary resource set to is it 0/25?
0/50 I mean
it's 25/25
f12
try to use it with the console open
lets stop dancing around the obvious and see what the error actuall is
it should be 0/50 fyi
or 50/50 if its a level 5 paladin
oh wait I forgot I homebrewed mine lol
nope just f12 and look at the console please
Just return false when you want to cancel the workflow in the preItemRoll hook
I suspect item macro character sheet hooks
what am I looking for here?
once you have the console open, try to use lay on hands
console tab
perform the act of healing someone with lay on hands
the actor is unlinked
in the sidebar, click the actor, does he have the resource full?
A?
(From #dnd5e: #dnd5e message)
Discord is the easiest way to communicate over voice, video, and text. Chat, hang out, and stay close with your friends and communities.
<#1010273821401555087 message>
Elemental adept. Let me know if it doesn't work
on the map, double click the paladin, does that actor not have it full?
same 25/25
Midi does not work with:
Ready Set Roll
Better Rolls for 5e
Roll Groups
Fast Rolling by Default
Fast Rolls or Quick Rolls
Dice Tooltips
Taragnor's Gm Paranoia
WIRE(Whistler's Item Rolls Extended)
Minimal Roll Enhancements
Retroactive Advantage/Disadvantage
Max Crit
Multiattack 5e
The following modules have template settings that step on midi:
Spell Template Manager
SIFT(Spells, Items, Features Toolkit)
Advanced Spell Effects module is in beta in v10 and often the culprit of things...
Midi requires Item Macro to have its "Character sheet hooks" feature set to unchecked in order for on use macros to work right.
When editing owned items(items on actors) active effects beware of duplicating active effects that interfere. Always check the actors effect tab for rogue ae's.
If you are on dnd5e 2.0.3, I recommend midi 23 or 24, dae 14, and dfreds 3.1.1
If on dnd5e 2.1.x update to 2.1.5 and all three modules can be updated to newest.
If you use any others you are playtesting and expect issues to arise.
Dfreds CE 4.0 requires midi 32+ and dae 22+.
(the list keeps getting bigger 😄 )
you likely have another roller rolling lay on hands
I have none of those modules, and updated all my modules to current
that midiqol | itemhandling wrapped hmmm
show me the button you press to roll lay on hands, and show me what lay on hands looks like in chat
I think I saw that earlier
using the old one or the new one?
oh I didn't even think to look at the console
I didn't see red so I didn't care lol
item handling failure hmmm
character sheet hooks?
argh, that doesn't relaly work. I want it to still remove the spell slot. I just want to do NO damage to undeads or constructs.
nope nope
its the way hes rolling it I bet
show me a snippet of the literal thing that you click that starts the lay on hands process
OK postDamageRoll macro then```js
if (undead or construct) this.setDamageRoll(await new Roll("0").evaluate())
Pseudo code the conditional, change it to be valid
disable all modules except for midiqol, dae, socketlib, and libwrapper
does it matter that when I first copy paste it onto my character sheet it has default values of 65 healing and 65 resource used?
should I be doing anything with those?
you mean drag and drop right?
that doesn't matter, just find the culprit you got a module conflict
?
disable all modules except for midiqol, dae, socketlib, and libwrapper
does it work with just those four
that's a lot of modules for me to turn off and on. hang on.
Find the Culprit module is a godsend to troubleshooting when one has alot of modules
okay I got Find the Culprit installed
enable it, its button to use it is bottom right corner of manage modules window
dae, midiqol, socketlib, libwrapper
if lay on hands works when it restarts with those on, then say NO to the popup, if it doesn't work say yes and we wait for bugbear to remember what causes that error
foundry build
dnd5e version number
midiqol version number
dae version number
at this point, the only thing I can suggest is taking someone elses settings import which wil nuke your setup in midi
do you fast forward your attacks?
no
Before you import these, export your own so you can revert if this doesn't fix things.
import/export of midi settings is in the misc tab in workflow button
thats gonna be one hell of a troubleshoot lol
change one setting at a time I guess
oh shit I think I know what it is
testing on my end once I fix my world
yeah I got no idea, thought maybe auto consume but nope
oh well. this has become prohobitively complicated for very little benefit
use my settings, tweak things as you see an issue with my settings /shrug
huzzah! it works. ```js
const { macroPass, targets, spellLevel, damageTotal, damageRoll, damageList, itemCardId, itemData, failedSaves } = args[ 0 ]; // destructuring the args[0] object to get relevant values
const effectLabel = "Blight-Disadvantage"; // a label can be what you want
const [ target ] = targets;
const isUndeadConstruct = target.actor.system?.details?.type?.value === "undead" || target.actor.system?.details?.type?.value === "construct";
const isPlant = target.actor.system?.details?.type?.value === "plant"
const diceAmount = spellLevel + 4;
if ( macroPass === "preSave" ) { // this macro is fired every pass of the midiqol workflow, this only runs in the presave part
if ( !isPlant ) return; // not a plant return and continue the workflow
const data = {
changes: [ {
key: "flags.midi-qol.disadvantage.ability.save.all",
mode: 0,
priority: 20,
value: "1"
} ],
flags: {
dae: {
specialDuration: [ "isDamaged" ]
}
},
icon: "icons/magic/unholy/strike-beam-blood-large-red-green.webp",
label: effectLabel
};
await target.actor.createEmbeddedDocuments( "ActiveEffect", [ data ] ); // create the above effect, all saves because lazy and i remove the effect later anyway
}
if ( macroPass === "postDamageRoll" ) {
if ( isPlant ) {
this.setDamageRoll( await new Roll( `${diceAmount}d8` ).evaluate( { maximize: isPlant } ) )
}
if ( isUndeadConstruct ) {
this.setDamageRoll( await new Roll( "0" ).evaluate( ) )
}
}```
A fully workin blight that accounts for plants and undead.
One issue. When you create the effect on tokens you don't own. So as a player it will fail to add the effect to an enemy
Either use a DFreds CE custom, or use a ```js
await MidiQOL.socket().executeAsGM("createEffects", {actorUuid:target.actor.uuid, effects:[data]});
@vast bane I remember setting up the emboldening bond at some point
What are you looking for?
it was a joke, the range finder for bond is too wonky to use, we manage it manually.
only part I need left for emboldening bond is to tweak the protective bond level 6 version where the player chooses an ally and damages them and then teleports them to them
Spent the last day making a way to work around midi-qol on use macros all executing at the same time.
So if I have multiple on use macros trying to modify damage, they'll actually catch changes from other macros that are getting executed.
🙂
I see a priority queue. I was discussing about that with a friend a couple of days ago!
The bigger problem I ran into was that workflow.damageDetail isn't updated after a workflow.setDamageRoll so I had to rework some features to read the damage roll for damage types instead of using the damage detail.
The queue system is also an exported function should anyone actually want to develop around it.
Or make their own personal automations respect the queue
Might be a good addition to MidiQOL itself 🤷
Well a proper fix for midi-qol would be for the stuff to just not all fire at the same time
my queue just has the scripts idle and wait for their turn
I guess that should be a foundry wide issue
Can one change the damage on a preDamageRoll call? Like changing all fire to healing, etc.
Post damage is where it's done
as weird as it sounds
workflow.setDamageRoll with your new damage roll
So armor of agathys type redirects would happen there as well?
type redirects?
actor doesn't take as much damage based on a resource setting, etc.
Depends on how your AoA is setup
what is AoA?
Armor of agathys
Ah. I've written about 13 times now. Every way seems terrible though.
So what are you trying to do? Just automate that spell?
Yes, but also trying to understand the mechanisms that are being exercised to implement it.
Sorry, i mean Arcane ward, not AoA...
arcane ward has a sample item I think? And the ddb importer also has it's own version of it
I tried both and they each fail in different ways.
yeah its pretty fubar I already tried fixing it
alot of the samples are too old cause midi just went through ike 9 versions
the ddb importer version was just added, it may work the least bad
lol I should try it again
the one that does temp hp is fine but then your temp hp is messed up
Yes, since arcane ward begs to be uses with AoA, tempHp hijinks are bad
The sample is closer, if I just get it to notice damage to temp. Then I have to deal with the weirdness and doubled update calls coming from the use of 'onTargetUpdate'
Arcane Ward seems like an ideal candidate for a world script honestly
But where can that script be hooked in to actually change damage?
midi-qol.damageApplied
Well I haven't tried that one yet so why not.
https://github.com/chrisk123999/foundry-macros/blob/main/Spells/Death Ward/Chris-DeathWardWorld.js
Here's an example with death ward
this hook gets called for all targets that are getting damage calculated
including damage taken from the midi-qol apply damage function
Might be the trick I need. thanks.
Already way better. Thanks.
how to automatically delete an effect with mid?
install the module times up and set a duration on it to expire or give it a condition to expire from
midi's bardic inspiration should already do that all you have to do is ensure you have the dnd5e bard class feature on the actor so it scales right
Technically all you need is the scale name to match
I'm wanting to make another effect, but in a similar way to Bardic Inspiration. That is, after using the roll with a bonus, the effect disappears.
probably should be an optional.name.macro like setup in midi and not a bab then
the simplest thing to do is just make an AR since you don't fast forward, why go through all this hastle of macros and automation if you aren't even full auto
leverage the human brain
This may be a better place for this:
I'm using midiqol and Dynamic effects using Active Effects, and I can only apply effects with the chat button while targetting. Is there any way to change that? Can't seem to find a setting in the menu
put a message on their attack popout
bab?
Wish there was an "Effects just don't god damn stack" option in the drop down cause I can never tell which ones the right one to use.
decision paralysis
I need an ability to affect all BUT demons. This work?
target.details.type?.value !=== "demon"
Demon is the sub type fwiw?
I did it based on "optional.name.macro" and it worked! I wanted to use build-a-bonus because it has a more "beautiful" card option, but thanks a lot for the help! With that, I managed to make my feature 100% usual for all the master friends of mine!
does it expire properly?
DE + MID, yes!
Build a bonus, I could not! 🥺
no matter what I do, I cannot get my icon to show for one of my macro.createitems, its a reaction item
It shows when I edit the item but it fails to show as the tiny icon in inventory and it fails to show in the reaction prompt:
is it because its a jpg?
is there a good way to add +2 to Ranged weapon attacks for the thrown weapon fighter fighting style?
yes if you don't mind it working on ranged weapons also
otherwise edit the items directly is the only real worthwhile way to be accurate
make an active effect that transfers on equip and use DAE to auto complete the key: .rwak.attack
it will work on all ranged weaponry so beware, otherwise edit the thrown items manually
sweet, thank you, i'll just do that, i dont even know if any of my players are going to be using thrown weapons, but figured better safe than sorry
how would i go about doing this?
this effect is one of three options whenever the player cast's a spell with one of their pact magic slots
nvm, i'll just do a Situational bonus whenever it comes up
Was looking into automating this today and I noticed that these Detection Modes no longer seem to exist 🤔 . Were these extra modes from Perfect Vision or from the 5e system at the time? Wondering if theres a way to add them back in Edit: Figured out what I was missing, needed the Adequate Vision module installed as well 😁
Guys, how do I implement a situational bonus?
don't fast forward and you will see the field in the popouts
I need the opposite though, theres no example for all but
Use ! before the sentence
!target...
Or !== not !=== when you try for equality or inequality
!target.details.type?.subtype?.toLocaleLowerCase().includes("demon")
How would i go about making the following as a Passive with AE?
"When the cleric hits a creature with a weapon attack, the he or she can cause the attack to deal an extra 1d8 radiant damage to the target as the weapon leaves a shine of silvern shine behind. When the cleric reaches 14th level, the extra damage increases to 2d8."
I know how to add the damage to a attackroll which is easy to do but how do i scale it with level?
Easiest is to make a scale value on the class and use that in the formula
That is something i dont know how to do tho
never seen that screen in my life
oh thats on the actor inventory, and then the class itself
Check these videos from Alaustin https://www.youtube.com/playlist?list=PLlfCqPVeZ1U7yKmV48kbhsRUsGtn04NsE
+@scale.lunar-domain-prestige-death-eldritch-knight-.earthshine-reflection[radiant]
how to do convoluted names am i right?
but why 😄
keeping track of special classes that you only get when doing specific things
like old prestiege classes from 3.5
Whatever works 💪
I would like to play some 3.5 at some point again.
My lunar cleric requires 3 lv eldritch knight and more then 3 in death cleric and being a follower of either Seluné or Shar as a faith and doing some biddings and travveling to a special place for a ritual
its fun
Also made a cracked healing wizzard
Requiring 2 lv necromancy wizzard and one level of Life cleric and a faith and alignment of CG LG or NG
Last feature is lv 17 btw
gíven the new tool in my posession now i can fasttrack making the rest of them in foundry thanks for that
Yeah no need for convoluted formulas anymore (well some of the time at least). Just take the time to get the scales down and done
Hi, I have been told to ask here, Would anyone be able to write a macro for me please that simply does 1d6 fire damage to a creature? I need it to take into account a creatures resistances and damage reductions. I am going to apply it to a Monks Active Tile Trigger to make an effect like thorns or Lava. (I do not like having to click damage buttons if its set to Attack and doing direct damage cant set it as a damage type). I would write the macro myself but I have no idea how to make macro's.
I posted earlier about an issue with Produce Flam always being rolled with advantage. I disabled all of my modules and re-enabled them one at a time, starting with MidiQOL to determine what module was casuing the error. It is Libwrapper, which is required by DAE for the affects. I cannot see a setting in that module to change advantage. Any thoughts?
libwrapper probably has nothing to do with this
when its disabled with everything else enabled the roll is fine
its only once I enable it that it defaults to advantage
Can you try with MidiQOL, DAE, libwrapper and socketlib only active?
sure one sec
So how do you "get" the Token that needs to be damaged?
targeting
I was just about to post a reply to myself... I found I had a macro for a while back written by someone that already does exactly what I need
with just those mods alone, it defaults to rolling with advantage
If people would like it I can post it here
const damage = (await new Roll('1d6').evaluate({async:true})).total;
await MidiQOL.applyTokenDamage([{damage, type:'fire'}], damage, new Set([token]), null, null,{forceApply:false});
Then you have something that gives advantage to the roll, either an effect or MidiQOL itself.
What is the roll?
what do you mean?
ranged spell attack
OK so the attacker has advantage on the attack.
Any actor using that spell?
Against all targets?
yes
I would turn on advantage attribution in the midi settings, makes it a lot easier to track down where its coming from 😅
true
wher is that setting?
I thought that was suggested already (might be misremembering the threads 😅 )
MidiQOL settings => Workflow settings => misc tab
I enabled it, but i dont see where it shows wehere advantage is coming from
Is there a way to make the following apply?
"When you cast a spell that deals necrotic damage, you can swing this blade in an instant."
(Attack with the weapon before spellattack)
Because things like toll the dead already have an item macro (which i would use for this) would this mess with that in unforeseeable ways if i just add the itemattackroll to it? Or is there an easier way?
Click on here
should I turn off fast forward rolls?
no it shows, just that its hidden behind the total highest number
No just click on the arrow to check what's up
then we can help more
Having multiple simultaneous workflows running is usually not a good idea (the sword stuff would be happening in the middle of the spell workflow). Any particular reason it can't happen after?
"On hit the creature takes 2d12 magical slashing damage before spell calculation"
thats why
So its a fixed amount of damage 🤔 Does it require an attack roll from the weapon or is it auto-hit if the spell hits?
well the attacker is hidden
Its
Cast spell
Detect necrotic damage type
swing weapon (deal its damge)
finish the spell
Hidden from the targets perspective. Most likely you have vision on on the target, but without giving it a range it can see in?
So no attack roll?
yes you deal no damage if you dont beat ac
you have to hit
which is why i struggle with it
So just to be clear its:
Cast spell (Lets say inflict wounds)
Roll 1d20 for sword to hit
Deal damage if hit
Roll 1d20 for spell to hit (assuming its an attack spell)
Deal damage for spell
yes
That runs into the problem I mentioned above about having multiple workflows running in tandem
previously check flanking was set to none. is flanking what is causing the issue?
yeah i know, thats why ask yall
make an extra pseudo attack roll and add a spell damage bonus AE if that "hits"
so that would require a itemcopy for each of the necrotic spells on each level tho
Could also do it with an onUseMacro, where you bypass the normal flow and just roll the correct dice
Yes but toll the dead is a special case (why i asked, if that messes with the current workflow of the spells damage calc due to it being different on non full hp targets)
Not the Flanking, the Hidden/Invisible attackers have advantage checkbox
If you don't have proper Vision set up, I would just disable that option
I could make a spellcopy for each necrotic spell with itemmacro
then Put the attackmacro first and then the spell?
but the attacker isnt hidden or invisible...?
ok
actor on Use checking if the spell is a necrotic one
how do I set vision up? I have 1 player than can go invisible, and I want him to still have advantage when he does
how would i do that then?
Because its a weapon it does have its own attack properties which is its on use case
(also has charges)
I would ask about the Vision settin up in #core-how-to
opn second though, it might be simpler to simply uncheck auto roll attack and have the player roll, then they can select advantage/normal/disadvantage as needed
Just a preference thing there (ask your players)
up to you, how you want to run it 🤷
Just make sure why/if you need MidiQOL in that case 😅
whats a brief description of what setting up vision means?
All my maps have light sources that I set up when I create the scene, and each actor already has a vision range set based on their race
is it more complicated than that?
ok a full description of the Item would help in that case.
I thought it was a generic feature on the actor
"This weapon has the following properties: Two handed, Reach, Finesse.
It also counts as a Spellcasting focus for the attuned user as well as a proficient weapon.
This magical weapon adds a +3 to attack and damage rolls.
Karma Strikes First. While being attuned to this weapon, you may roll and add 1d12 to your roll of initiative. This property can’t be used again until the next dawn.
Reap and Sow. When you cast a spell that deals necrotic damage, you can swing this blade in an instant. As part of the Casting you can roll an attack against that same creature within weapon range (15ft reach). On hit the creature takes 2d12 magical slashing damage before spell calculation. This effect can be used multiple times per turn as for casting another spell with Metamagic or other features is possible.
Mortal Tribute. While you are attuned to this weapon any necrotic damage you deal in damage to hostile creatures adds to your capabilities. You also ignore necrotic resistance and immunity, unless the creature has legendary resistances.
Reap and Sow On hit add 1 to the weapons charges up to 50 maximum. These charges can be spend as a bonus action to heal yourself or Allies within 60ft, each charge recovers a single hitpoint.
Anima Messis. Damage dealt by this weapon is incredibly lethal, if a creature is reduced to 0 hp by this weapon it automatically fails the first death saving throw regardless of its roll.
Requires attunement by a by a cleric, paladin or warlock of lawful or chaotic evil alignment"
is the target "able" to "see" the attacker in your scene?
If not, cause of the range of their Vision or lack of thereof, then the Hidden rule will kick in
its a pretty complicated item
i want to say "yes" but with those quotations im not sure. the map im testing in has a global light source, but I dont see where actors have vision set up. I see "senses" but thats only for darkvision. Does it matter which direction the token is facing? is it because the attacker is behind the target?
Do you want to be able to choose if you make the extra attack, or do it automatically any time a necrotic spell is cast?
Its on their Tokens
That's why I suggested to ask in #core-how-to
They can better help to set it up as this is not #1010273821401555087 specific
What am I missing when I can log args in a hooked Midi function, see the data points I need, but referencing them directly errors out? Console says neither castData nor item exists within args, but the logged args have them and I figure they all launch approximately the same time?
Hooks.on('midi-qol.RollComplete', (args) => {
console.log(args)
console.log("The cast level is: " + args[0].castData.castLevel);
console.log("The spell school is " + args[0].item.labels?.school);
});```
either is fine its better tho if you can choose (which you should be able to)
Not looking at args[0] anymore
ok. Thank you. I will take this conversation there. Thank you for your help
Better if you do ```js
Hooks.on('midi-qol.RollComplete', (workflow) => {
console.log(workflow)
console.log("The spell school is " + workflow.item.labels?.school);
});
Not sure where the console.log("The cast level is: " + args[0].castData.castLevel); is located off hand
Just for the proper Vision setting up. Anything that comes after that, related to MidiQOL, come back here 👍
👍
Ah feck, you're right, it's not showing an object, thanks
I figured it out. Her target doesnt have darkvision, and global illumination was turned off while Token Vision was on. The attacker was "invisible" only because the target couldnt see her in the dark.
I gave the target darkvision to 60 ft and the advantage went away
Nice! Makes sense now 😉
Is there a core troubleshooting channel? I have another issue that isn't a how to, but a bug on the core level.
ok so the necromancy spell cast needs to have an attack roll correct? Not any other spell
any spell with necrotic damage type
"When you cast a spell that deals necrotic damage"
If the target is in Reach
yes
Multiple targets or one?
both? the subclass stick is to taget more then one creature with spells
pff so you need to filter the targets that are not in range and attack the rest?
yes
that becomes less and less easy to do 😄
but thats currently done by the items 15ft range, it wont attack if its not in range. because of that limitation
i know i can do the simple things alone the difficult things i have to get help with
Yeah not injecting another workflow inside an already started one. I was trying to work around that
And more that one to be honest
hmm do you need to see the rolls?
DAE with flags.midi-qol.onUseMacroName | Custom | ItemMacro.Name of the Magic Item, preambleComplete ```js
if (args[0].macroPass === "preambleComplete") {
if (args[0].item.system.school !== "nec") return;
const itemToRoll = args[0].actor.items.getName("Name of the magic Item");
await MidiQOL.completeItemUse(itemToRoll, {}, {})
}
Try that and see where we land
@keen remnant
imma get back to that in a bit having a few things to do currently thanks tho will try and get back to you (1h or so)
If the magic Item and MidiQOL are set up correctly, it should make one attack per valid target
Otherwise we go a different route
I assume in the same vein, if I run an item with an itemMacro, can you spot me the new syntax for the "old" args[0] === "on" / off stuff? For running the macro when applying/removing an active effect?
args[0] === "on"/"off" will always be the on application or removal of the AE
Huh, that does not trigger.
Some more context is needed 😅
I must've slapped it on the wrong place, will double check
I had put the ItemMacro on the item only, the ActiveEffect never did anything with it >_> Thanks anyway!
OK So this is not gonna cut it 99% now that I think about what can go wrong 😄
My MidiQOL has started enforcing range and cover for attacks when it wasn't before. Does anyone know which settings those are off hand? I scanned over them, but the last time I touched Midi was nearly a year ago, and I've been known to miss things right in front of my face regardless of how many times I look.
Thank you. Yes, that does look very obvious. One time my boss got mad at me because I couldn't find a particular outlet cover he needed, and he walked over and grabbed it from right in front of me. 😦
@keen remnant Try this.
flags.midi-qol.onUseMacroName | CUSTOM | ItemMacro.MAGIC WEAPON NAME,preambleComplete ```js
const itemName = "MAGIC WEAPON NAME" // change this name to match the Magic Weapon.
if (args[0].macroPass === "preambleComplete") {
if (args[0].item.system.school !== "nec") return;
const itemToRoll = args[0].actor.items.getName(itemName);
let targets = args[0].targets;
let validTargets = [];
for (const t of targets) {
if (MidiQOL.getDistance(args[0].workflow.token,t,true,true) <= 10) validTargets.push(t)
}
if (!validTargets.length) return;
for (const v of validTargets) {
let roll = await itemToRoll.rollAttack({flavor:Attack against ${v.name} - AC: ${v.actor.system.attributes.ac.value}});
if (roll.total < v.actor.system.attributes.ac.value) validTargets = validTargets.filter(t=>t !== v);
}
const damage = await new Roll('2d12[slashing]').evaluate({async:true});
const msg = await damage.toMessage();
await game.dice3d?.waitFor3DAnimationByMessageID(msg.id)
MidiQOL.applyTokenDamage([{damage:damage.total, type:'slashing'}], damage.total, new Set(validTargets), itemToRoll, null, {forceApply:true});
}
Will not properly account for critical from the weapon attack as is now... 😩
Forgot about that
ChatGTP on the case: ```
Verse 1:
At first I was afraid, I was petrified
Kept thinking I could never play, with MidiQOL by my side
But then I spent so many nights, just trying to configure
And I grew strong and I learned how, to use this module sure
Chorus:
And now I'm back, to play the game
With MidiQOL, it's not the same
I've got macros, hotkeys, and more
I will survive, and conquer all
Verse 2:
It took all the strength I had, not to fall apart
Trying hard to understand, how to use this module smart
And I spent oh so many nights, just learning how to script
But now I know the shortcuts, and my game runs oh so slick
Chorus:
And now I'm back, to play the game
With MidiQOL, it's not the same
I've got macros, hotkeys, and more
I will survive, and conquer all
Bridge:
I should have known that I could do this all along
With MidiQOL, I've got the tools to be strong
And I learned how to automate, so much of what I do
Now I can focus on playing, and my fun will never be through
Chorus:
And now I'm back, to play the game
With MidiQOL, it's not the same
I've got macros, hotkeys, and more
I will survive, and conquer all
Outro:
I will survive, and conquer all
With MidiQOL, I will never fall
I will survive, and conquer all
With MidiQOL, I will never stall.