#MidiQOL
1 messages ยท Page 8 of 1
Anyone know, when ammunition is pulled through a weapon, does Midi Overtime effects carry through also?
So it expires after 10 rounds and then starts stacking up again even if he hits something in the meantime?
yup
Alright, lets see what I can do
Oh, V9 or V10? @static wind
V10
Youโre really doing it? Thank you so much ๐ญ
Yeah, its a fun little project ^^ Might need to have one of the guys in the polo channel look it over for V10, there are some changes, but hopefully it will be easy
Okay, so I got it generally working for V9, not sure how broken it will be on V10 ๐ค
Just to test it, here is how you do it for V9, most of it should be the same, code will be slightly different.
First add the following code as an ItemMacro on the item, using the little button at the top of the item sheet:
let item = args[0].item;
let macroPass = args[0].macroPass;
let actorD = args[0].actor;
let stackingEffectName = "Stacking";
const bonusDamageFlag = "bonusDamage";
async function createEffect() {
let effectData = {
"changes": [],
"disabled": false,
"icon": "icons/weapons/swords/greatsword-crossguard-blue.webp",
"label": stackingEffectName,
"tint": "",
"origin": item.uuid,
"transfer": false,
"flags": {
"world" : {
"bonusDamage" : 0
}
},
"duration": {
"seconds" : 60
}
};
await actorD.document.createEmbeddedDocuments("ActiveEffect", [effectData]);
}
async function incrementEffect() {
const currentValue = getEffect().getFlag("world", bonusDamageFlag);
if(currentValue < actorD.data.details.level)
{
await getEffect().setFlag("world", bonusDamageFlag, currentValue + 1)
}
}
function getEffect() {
return actorD.effects.filter(effect => effect.data.label === stackingEffectName)[0];
}
if(macroPass === "preAttackRoll") {
if(getEffect() === undefined) {
await createEffect();
}
await incrementEffect();
}
if(macroPass === "DamageBonus") {
const currentBonus = getEffect().getFlag("world", bonusDamageFlag);
return {damageRoll: "" + currentBonus, flavor: stackingEffectName};
}
Then go into the item details, and set the following near the bottom (image)
And I believe the V10 macro should be the following:
let item = args[0].item;
let macroPass = args[0].macroPass;
let actorD = args[0].actor;
let stackingEffectName = "Stacking";
const bonusDamageFlag = "bonusDamage";
async function createEffect() {
let effectData = {
"changes": [],
"disabled": false,
"icon": "icons/weapons/swords/greatsword-crossguard-blue.webp",
"label": stackingEffectName,
"tint": "",
"origin": item.uuid,
"transfer": false,
"flags": {
"world" : {
"bonusDamage" : 0
}
},
"duration": {
"seconds" : 60
}
};
await actorD.document.createEmbeddedDocuments("ActiveEffect", [effectData]);
}
async function incrementEffect() {
const currentValue = getEffect().getFlag("world", bonusDamageFlag);
if(currentValue < actorD.details.level)
{
await getEffect().setFlag("world", bonusDamageFlag, currentValue + 1)
}
}
function getEffect() {
return actorD.effects.filter(effect => effect.label === stackingEffectName)[0];
}
if(macroPass === "preAttackRoll") {
if(getEffect() === undefined) {
await createEffect();
}
await incrementEffect();
}
if(macroPass === "DamageBonus") {
const currentBonus = getEffect().getFlag("world", bonusDamageFlag);
return {damageRoll: "" + currentBonus, flavor: stackingEffectName};
}
But I will need you to test it @static wind
Is this a published item that is in a rule book? use its name so folks can find this when searching discord.
Don't think it is, Arth would know, he provided the description ๐
no, its a homebrew item
omg thank you so damn much, I will test it right now!
its getting this error
Hmm, did you use the second code block?
yup
Could you change line 3 from:
let actorD = args[0].actor;
to
let actorD = args[0].actorData;
and then try again
ok
Alsoo
This will only work when triggered from an attack roll, it will not work when triggered from the macro bar or the "execute macro" button
Gimme a hot minute, I will boot up my V10 instance and get this working! ๐ Thought I could get away without that
Its fine, I do a bunch of programming in my free time, don't worry ๐
thank you 
Try this one @static wind
let item = args[0].item;
let macroPass = args[0].macroPass;
let actorD = args[0].actor;
let stackingEffectName = "Stacking";
console.warn("Actor", actorD);
const bonusDamageFlag = "bonusDamage";
async function createEffect() {
let effectData = {
"changes": [],
"disabled": false,
"icon": "icons/weapons/swords/greatsword-crossguard-blue.webp",
"label": stackingEffectName,
"tint": "",
"origin": item.uuid,
"transfer": false,
"flags": {
"world" : {
"bonusDamage" : 0
}
},
"duration": {
"seconds" : 60
}
};
await actorD.createEmbeddedDocuments("ActiveEffect", [effectData]);
}
async function incrementEffect() {
const currentValue = getEffect().getFlag("world", bonusDamageFlag);
if(currentValue < actorD.system.details.level)
{
await getEffect().setFlag("world", bonusDamageFlag, currentValue + 1)
}
}
function getEffect() {
return actorD.effects.filter(effect => effect.label === stackingEffectName)[0];
}
if(macroPass === "preAttackRoll") {
if(getEffect() === undefined) {
await createEffect();
}
await incrementEffect();
}
if(macroPass === "DamageBonus") {
const currentBonus = getEffect().getFlag("world", bonusDamageFlag);
return {damageRoll: "" + currentBonus, flavor: stackingEffectName};
}
omg its working
Nice, just had to find the right replacements for V10 ๐
omg thank you so much
There are 2 things you might want to adjust:
"icon": "icons/weapons/swords/greatsword-crossguard-blue.webp", to set the image of the effect that is used for the stacking AE
let stackingEffectName = "Stacking"; to set the name of it
Is there a way to use an NPC ability that will automatically target only the NPC's enemies (ie player characters and their allies) within a 30 foot radius?
I've never got this to work in v9 but you can try this
Yeah, I'm using v9 right now, it's not working.
If that doesn't work and you don't auto apply damage, just do this and center it on the caster
Shouldn't it be 30 feet enemy?
You don't want enemy because the enemy of enemies is ally
If I understand it correctly
Only issue with the sphere is it winds up targeting its own allies and itself.
With that being said, make sure this is on @errant gull
The special below doesn't target itself
Otherwise it will definitely not work
Oh, interesting. You're right. It does target its own allies, but not itself. That's at least half-way there, I can dig it.
If I understand midi correctly for this case, the target ally is based off token disposition. So enemy == hostile, players and friendly npcs == ally (I could be completely wrong)
I think you're right.
Part of the reason I don't auto apply damage is to add flexibility on things like this
Might be you are right, can't be bothered testing that one right now as its just changing the dropdown if its opposite ๐
Yeah, plus the whole 30 | Feet | Enemy doesn't even work for Gambet and me on v9 anyways
Might be a v10 only thing
That's a bummer. I'm still waiting for like 30 modules to update to v10, haha.
Works for me on V9 ๐ค
Are you in combat? Can you export your item and dm it to me for me to try
strange. it was working for me too. Midi version?
Nope
I guess token's disposition is set up?
any modules that touch upon disposition of tokens? tried with only midi?
Not that I can recall. I'll test with just midi and dependencies
In combat or out
shouldn't matter tbh iirc
No dice
does Ally work?
Nope
Could you screenshot your workflow tab in the settings? The exported settings file is hard to quickly parse ๐
well damn, I am still away and just switched off my remote instance. I could check tomorrow too, if fotoply doesn't come up with a solution ๐
There's the issue! Auto target for ranged target needs to be on ๐
Ah there we go
For some reason I thought that was similar to late targeting
@errant gull ^^
Tbf, its not the best named one, I had it off for the longest time because I didn't understand it either ๐
I'm assuming the Special is the same with templates and doesn't target the source actor
Yup
Well that's gonna make thunderwave (or clap, idr) easier to manage, haha
You can undo the damage with a button, but I personally do not automate so much that I need to, I run advantage reminder for virtually all of the situational bonus' that usually fire incorrectly.
I automate everything and in game I have one headache less. Now before game its a different story, but that's expected ๐
Same here
True but then fudging is harder than I want, haha
I don't fudge.
The dice tell the story, not me.
If you want to automate damage AND fudge, just install DF manual rolls, theres a setting the DM can turn on that hides the rolls being manually entered for himself. It works with midi, has issues with a few other modules though.
I fudge in favor of the players. Balance is the hardest thing for me since I usually make up everything on the spot based off what the players choose. Sometimes the monsters are definitely too hard so I tick away more hp than what they deal
what is syntax to add more sizes in this?
"@target.traits.size".includes("sm")
for example ("sm","med") does not seem to work
activation condition btw
No clue if this will work but try ['sm', 'med'].includes('@target.traits.size')
will do
that absolutely did it. thank you sir.
so, I seem to have an issue with Toll the Dead. When I click the icon with a target selected, I get an exception:
not sure if this matters but spells were imported a few weeks ago from DBDBeyond importer if htat matters
I would ask in mr. primates discord if the macro was also made from there
is he in League, or does he have is own discord?
Foundry VTT's broader community is home to a number of awesome developers and content creators, many of which have their own communities to offer support for their modules, systems, and Foundry content. Check out their Discord servers below.
Development Partners
Module/System Developer Servers
Death Save
Foundry Twodsix
Grape Juice's Modules
Iron Monk's Modules
Iron Moose
KaKaRoTo's Modules
Kandashi's Module Madness
Moohammer - WFRP
Mr. Primate's Modules
Pathfinder 2e Game System
Sandbox Game System
TyphonJS' Modules
theripper93's Modules and scripts
Content Creator Servers
His own
yea thats the thing, im not sure what creates the various set ups since I have Midi, DAE, ItemMacro, etc installed as suggested by his importer
Well if the spell was gotten from the importer and it had the macro, there would be the best bet of getting help
You are playing on a dnd5e system version that was notoriously bugged and they released 1.6.3 to hurriedly fix it.
That is the version that had the dex tie breaker all screwed up
As for Toll the dead...bruh its Midiqol, trust in the Tposney.
well crap.. I can update it. says the version is undefined
is it safe to uninstall the game system and then reinstall?
back up your world before updating systems I believe
you can install over top with a manual manifest
but backup the world just incase
the foundryuserdata directory or below that?
no no no no no no
go to dnd5e's published system page on foundry, right click the 1.6.3 install manifest link and copy url
click install system inside foundry, paste the manifest into the bottom here:
backup your world
yes thats the part I was questiong
oh lol
this is installed on a remote server so..
I dunno how to backup remotely, but I bet if you asked @bold rock he'd have a tip or two about backing up your world.
I jsut need to know the dir as i THINK I used the defaults
Well when a moderator catches it he will answer lol
gratz
I always just backup the whole userdata folder minus the modules sub directory
I duplicate it, and delete the duplicates modules folder cause I don't need 1000 copies of jb2a's animation database
Hopefully simple midi-qol question. Can I set midi to show DSN rolls to me as a GM, but only display "hit or miss" to the players? I'm trying to avoid my players from "meta-ing" dice rolls from the creatures.
ok, I think I found the issue, or at least the root of the issue. When I compare the MidoQOL Sample Items/Spells version of Toll the Dead, I see BOTH versions have this On Use Macro but can't find the actual macro so I assume that's what is failing. Same with Spiritual Weapon, Flaming Sphere, etc. I assume none of those would work in that case if ItemMacro can't be found:
You lack Item Macro module but supposedly you do not need to have it installed, the data is there and midi is able to pull it, what is your problem with toll the dead?
are you on v10?
yeah whats your error/problem then it definitely works on v9
what isn't working about toll the dead?
when I click on the spell, it throws an exception as above #1010273821401555087 message
hang on, I tend to update modules frequently
you shouldn't unless something is broken imo
you want stability, they aren't offering 7 cupholders with every module update
Does the character in question have a class level? or is it an npc?
MidiQOL is 0.9.76
DAE is 0.10.28
ItemMacro is 1.6.0
character built and imported with the DNDBeyond importer
with Midi, I am going for a partial automation, leaning on the less automation side
drag out one of the dnd5e starter heroes that is a cleric or wizard and give them toll the dead and see if it works
sure.. hang on a sec
I bet your problem is the importer
but your midi is behind on version, should not be an issue
if the actor has a broken class setup that could be an issue
ok, that spell is not on the default actor cleric's list, so I pulled from DND Spells Compendium entry
if I need to, I can just as easily delete that one actor and reimport
It is suppose to be pre damage roll, not after effects
you likely have a version before it got fixed
cause your midi is 3 versions behind mine
fix?
the very first line of the macro says it needs to be done pre damage roll
so where you saw Item macro--- after active effects, change after active effects to um....
I dunno if your version has pre damage roll or before the damage roll
Its at the bottom of the details on toll the dead
you have a different sheet UI than me so mine looks different than yours
yeah at the bottom there, change after active effect to before damage roll or pre damage roll
should I upgrade the module as well?
he changed the wording of the drop downs around the time of your version so I dunno if its before or pre for your drop down
probably
I don't even know if I'm on the newest lol
but the only thing breaking toll the dead is that drop down
its firing too late in the workflow
in my version of midi it comes packaged as before, not after so he clearly fixed it between .76 and .79
well.. PERHAPS all the updating I SAID I was ddoing was on my local v10 testing version...lol
hmm no such luck
wait... hang on a sec.. seems midi did not actually update
yea still failing
can you show me your items detail page again?
the spell details?
cause I didn't say updating would fix it, I clearly said changing it to pre damage roll would
updating midi does not change any sample items already in play
you need to change toll the deads item macro to fire before damage roll, its literally a drop down right in that image
disable all but midi, dae, socketlib, and libwrapper and find the culprit
wait a minute
thats not midi's toll the dead
no way would tposney put flavor in the chat message
is that a beyond imported item?
delete it, navigate to Midi sample items, drag his toll the dead to the sheet
but taht was early on in troubleshooting
good news it's a different result.. bad news it's still an error
link the exact same thign you just did to me
find the culprit starting with midi, dae, socketlib, and libwrapper, and before you start this, make sure you dragged out the right toll the dead
do you have Better rolls, roll groups, Minimal rol enhancements, or Ready Set roll installed?
what are you using for saves in midi?
what comes up for a prompt?
the macro only works with automation so if its set to none...that'd do it
Monks Token Bar, LMRTFY or midi's built in prompt
I seem to think someone else was having an issue with this earlier today wit their settings
I have Monks and LMRTFY
and its using Monks
are you saving?
I would start find the culprit and try with just midi/socketlib/libwrapper and work from there ttill it breaks
having both lmrtfy and mtb installed is redundant, pick one, disable the other
thanks, I will likely come back to this later as so far as I know this is the only spell that breaks
and I hve a game Friday and lots to do in the little time i have left
I appreciate all the assistance
can you paste the item macro here thats in toll the dead? click item macro at the top of toll the deads entry
or snippet it
im not sure I underatant what you mean
OH
const target = await fromUuid(args[0].targetUuids[0]);
const needsD12 = target.actor.data.data.attributes.hp.value < target.actor.data.data.attributes.hp.max;
const theItem = await fromUuid(args[0].uuid);
let formula = theItem.data.data.damage.parts[0][0];
if (needsD12)
formula = formula.replace("d8", "d12")
else
formula = formula.replace("d12", "d8");
theItem.data.data.damage.parts[0][0] = formula;
}```
I had no idea tht was up there.. thanks
are you targetting someone when you roll?
yes
what are you targetting?
I do have fast forwward rolls turned on though
just in case
a goblin
so normal npc
srd goblin or an imported goblin?
Which to me screams you are using another roller
Better Rolls for 5e, Minimal Roll Enhancements for v9
or you have roll automation OFF for midi
show us your actual attack workflow
I don't have either of the roll ehancements
do you even have midi automation on?
I do NOT have roll's on.. buttons to the chat cart and the users click thos
that is probably it
you aren't even using midi
You are crossing the stream with vanilla dnd5e lol
Thats a first
When you write this, have you checked if it is empty in console? I don't even think I can intentionally get args to be empty with midi qol turned on
yes it's empty I did a console.log(args)
if roll automation is off, then midi is not overriding the roll
therefore theres no args
at the beginning of the item macro script
What do you have here:
yeah you gotta have a roller installed
They also said they fast forwarded rolls earlier, figured that was a prerequisite. Let me just find out which module actually populates args...
there are a few other rare ones out there too, just br and mre are the two most noteable conflicts
midi does args
Joe, show us your attack in chat
for an attack spell? the chat card?
for toll the dead
nothing gets to the chat
nope
Is there a red console error message when you roll the item?
yes hes linked it
Oh right, mb
change your midi setting for saves to
and what version of monk's token bar do you have installed
oh actually, do you even have monk's token bar installed? cause that would throw THAT exact error I think
if your midi settings was pointing to a save module that wasn't installed or enabled
yes I do have Monks
Monk's Token bar right? cause he has like 15 modules named monks
yes
what is the version of it, and then try to change it to chat message instead like my image above and try to throw the save
or rather roll the tolll the dead
yes, set to Chat message, same thing
you have a bad install, find the culprit till you find the module screwing up midi
have you tried sacred flame?
hmm I don't see sacred flame in midi
For a quick check if it's Midi, you can also just enable Midi QoL, socketlib and libwrapper. I did note you had an error message from blood n' guts which is way old
or you do mean SRD?
sacred flame sends to chat, I roll the damage, I roll the save on the chat card, and the damage is applied
can you show us the chat entries?
I have require target turned on, and late targetting on
but in all these cases, I do have a single target selected withhin range
only thing I got left is install find the culprit and follow it till it breaks with all modules, toll the dead definitely works from midi sample items
you got something messing with it
yep... will just end up messing with it after the weekend
fortunately, the sorcerer spells all seem to work and a quick check of the other spells for the cleric appear to work fine
I think what will break is any automated macro item like somethign from midi srd or midi sample items
but also, find the culprit is pretty fast
you can immediately find out if its a module by disabling all but midi and its dependencies and firing the spell
Are you rolling it off token action hud?
no, off of the char sheet
vanilla sheet?
no you have a sheet module I remember
yeah all signs point to module conflict, thats your next step to solving it
soooo ummm the main reason why I am delaying Find the Culprit is I need to take time to remove all the modules I tried and disabled but did not remove
thanks
find the culprit streamlines turning on and off everything and it remembers what you had on/off before you started
when you activate it, it asks you what you want to turn on for initial test, then you get refreshed page, try the spell, if it succeeds, say no, and it slowly adds things in till it breaks, when you finally say yes, it will then revert you to the modules you had enabled before you ran find the culprit
if it breaks with just midi, socketlib, and libwrapper then you are in unknown territory
Find the culprit is a module btw, incase you aren't connecting the dots
its sleepy time for me. thaks for all the help Moto
What would I put in an activation condition if I wanted it to roll other damage if the source actors health is above 50%?
Trying to setup a swarm creature
Did you resolve this?
If not can you make sure you don't have options 2 and 3 selected in itemMacro settings?
@violet meadow I wanna pull off the swarm mechanic where they do 4d4 at full health, but 2d4 at half, by making their main attack do 2d4, and if their activation condition is true, do an additional 2d4 in other damage, is that possible? Have activation condition be something like full health?
does midi's wounded status icon apply a flag?
Try "@attributes.hp.value">="@attributes.hp.max"/2
I think that it doesn't apply a flag.
You could use effect macro however, to make the wounded DFreds CE condition set a flag when it is created and unset it after
I just wanna say I was almost there, but since you chimed in I had to cheat and ask lol
Did midi change a flag?
Uncaught (in promise) TypeError: Cannot read properties of undefined (reading 'total')
[Detected 1 package: midi-qol]
at eval (eval at callMacro (workflow.js:1446:15), <anonymous>:113:27)
at async Promise.all (index 0)
at async Workflow.callMacros (workflow.js:1375:13)
at async Workflow._next (workflow.js:893:7)
at async Workflow.next (workflow.js:261:10)
at async Workflow.next (workflow.js:261:10)
at async Workflow.next (workflow.js:261:10)
at async Workflow.next (workflow.js:261:10)
at async Workflow.next (workflow.js:261:10)
at async Workflow.next (workflow.js:261:10)
at async Workflow.next (workflow.js:261:10)
at async Workflow.next (workflow.js:261:10)
at async Workflow.next (workflow.js:261:10)
at async Workflow.next (workflow.js:261:10)
at async Workflow.next (workflow.js:261:10)
Is there a way to manage feats like Lucky where a second roll is made only if the player wants, but has to decide prior to the result of the first roll?
Here's the section of Midi's readme about Optional Bonus Effects
https://gitlab.com/tposney/midi-qol#optional-bonus-effects
If you use that, it can pop up a dialog on each d20 roll that it applies to. The pop up will show you the result of the roll and ask you if you want to use Lucky. Might get annoying for the player since they'll get a pop up so often, but it's doable
OK, thanks I will play with it and see how it works
The MidiQOL Sample Items compendium has two copies of Lucky. You can probably use one of those
Is this horrendous alignment coming from core Foundry or something Tim would need to fix ๐ค
Foundry. It's grabbing the module's title and showing it in that sidebar
although... the title could probably be shortened if we're being honest
always bothered me why it was so "wordy"
Well it was literally just DAE, but then I think the intention was to not confused it with core Active Effects
But frankly, DAE would be fine.
Thanks
or Dynamic Active Effects
The title seems to just be the name. Even if it was dropped onto a second line - why the centre alignment?!
looks like some tab styling CSS is poking through
.tabs .item {
text-align: center;
}
something should be added to this CSS selector so the text isn't centered
.package-configuration aside.sidebar nav.tabs .category-tab
Reported as a bug. Kim can figure it out.
In the meantime I will live with my manual adjustment. Until DAE updates lol
I added it, but it does not seem to do anything. I have looked through midi-qol settings as well and I don't see a way to activate the chance to have the player roll another die
That sounds like you are not awaiting a roll and asking for the .total
It used to work, though it has been a month since the player tried to summon their fire spirit.
Macro?
V10?
No, V9
I wont upgrade to V10 until all my macro makers, (yourself included) have V10 macros lol
Oh that's a big one.
I will take a look when I am on my pc
There is an id in a canvas.tokens.get(id) call that seems not defined but I cannot check it better now
YES. that corrected the issue with the js error
I had item 3 checked(at the time. off now): "Character Sheet Hook"
unfortunately, there is now a non error scenario in Toll the Dead where the damage is not accurate. when I ckick the "Damage" button in the chat card, it always rolls d12 regardless of the target's health total
Is this happening with the MidiQOL sample item Toll the dead or an imported one?
The Midi sample one IIRC.. Moto was helping me last night and we did a lot of things
deleted old copy and pulled from the midi samples.. I don't have time to test in depth, but I THINK it looked right.. will mess with later
I will take a look too later
yep, works now. That change seemed to fix it. So what is the Character Sheet hook used for if it could break things?
How can i disable this reaction pop up in Midi?
When you use Item macro module for MidiQol purposes (think about it as a storage place for macros) you want them off as per readme's instructions.
You can check how they are otherwise used in Item Macros page
Turn reactions off in midi, workflow then optional.
However I too change all my reactions to manual.
Or change the details tab action type to reaction manual or damaged, whatever is relevant
I personally would do reaction manual and tell the player to remember they have it
So to OFF to disable it?
Yes
Or manually change all your reactions abilities to Reaction Manual instead of Reaction.
IE go to absorb elements, and edit the item > details > activation cost > Reaction manual
I see. Is there a way to allow to roll damage even if the attack wasn't rolled?
I'm trying to code a feature in 5e for Inspiring Leadership. My first pass was to add an item macro that I hoped would add temp hps to all targeted tokens (I'll add the correct calc for determining the amount of hps later). However this only applies the hps to the owned token. I originally posted this in the 5e board, but was told it couldn't be done. So I'm now thinking it will need to be done through midi qol. Can someone point me towards a couple of samples where 1. an action is being applied to all targeted tokens. 2. Temp hps are being applied? I'm very new to foundry and appreciate all the help being provided for me to learn. for(let tok of canvas.tokens.controlled){
await tok.actor.update({"data.attributes.hp.temp": 10});
}
Yeah
Instead of a macro, turn it into a spell of range (what ever like 30ft) healing temp HP.
And this
I don't auto add damage so you can manually decide who not to give the temp hp for if you have more than 6 people there
Let me test
@torpid kestrel See our comments above โ๏ธ
Yours didn't work for me
Can you export and dm the item to me?
Are you manually targeting?
Yes
Ah that's why
I was using the auto target thing
Targeting for me worked too, but wanted to speed that up
But what if there are too many allies nearby?!?!?
Fair enough
TBH that is a really strong feat. My players are level 3, and it adds a free 6 temp HP to the entire party after every short or long rest.
No one has it in my game so I don't have to worry about that
I make my players actually give a speech lol.
Hello party people... im trying midi qol for the first time and i am having a weird issue where the HP update card, which shows as the whitish "only for gm eye" card, is actually visible for all players. If i delete it with my all powerful gm ability, it disappears from the gm chat bar, but stays in the player chat bar. Help? my players screen currently looks like this ๐ฅบ
So you want this (left player, right gm)
yup
Switch your chat roll to Private GM Roll
Players will still see the apply damage section if they are attacked
Or rather any actor they own
oh this is happening when i am rolling as the GM and i have private GM roll activated
but it is showing up in the player screen regardless
v9 or v10
Can you export your midi settings and dm them to me
2 secs
And just to make sure I'm on the same page. If the token on the right (has no player ownership) attacks the zombie (also no player ownership), the barb (is player) will see damage application option in chat?
Many thanks! It works great!
sent
What about this
and yes
i have an enemy npc attack a pc. the damage breakdown/assign card shows up on both screens
That's supposed to happen
Players will see the damage application card show up for any token they own
but for all players?
Do they have some permissions for other PCs?
Same happens for my game but it's not an issue. As long as they don't have permissions, they can't apply the damage
its more a tidy issue i suppose lol
But if no players are involved, they won't see anything
I just don't use player damage cards tbh
Same with if players are attacking npcs
yeah see for me when i have logged into other players screens, they would see naafeh's damage calc
going by your example
So for you, player attacks npc and they still see damage application card?
yup
f-ing weird...
Disable all modules except midi and the dependencies and try
yay... i hate this bit of foundry ๐
i know, ok. i'll have a look into that
as you've been really helpful, can you help a newb with 1 final thing i just realised?
Sure
Chances are you had skipped resource consumption option I'm guessing
yup
so i have only midi, lib and socket lib active. i'm still getting that damage output card appearing and getting stuck
I asked this question last night and it kinda got buried. Wondering if someone can help with hopefully a simple midi-qol question. Can I set midi to show DSN rolls to me as a GM, but only display "hit or miss" to the players? I'm trying to avoid my players from "meta-ing" dice rolls from the creatures. Picture of GM workflow, rolls are done as public from dice tray.
What you have looks right. Show Hit/Miss to players then damage total on hit.
yup, and it shows that to the players...but it also shows the 3D dice roll. I don't want them to see that
Then I think you want to check the box just under the hide details
"Hide GM attack/damage/saving throw 3D dice rolls"
As long as you merge your cards that is
I will try that again. I tried that route first and I do merge cards
So, selecting hide does in fact hide the dice..but hides it from me too. I still like seeing the virtual clickity clacks....(dice goblin - yes)
Is there a way for it to hide the dice from just players?
You can turn off dice from the DM, worst case scenario.
Ok, so Iโm guessing midi doesnโt facilitate what Iโm looking for-die rolls initiated by GM, visible to GM, not visible to players, but still displays the card indicating hit/miss to the player.
Is there a way to use DFreds/MIDI/MonksTokenBar or similar to request a saving throw from an unowned token? I have a macro that works great when I use it, but when my player uses it it does not trigger the saving throw. I suspect its due to permission issues ๐ค
Case: My player has a weapon that on hit triggers a saving throw on the target.
In monks, make sure the check box is check to allow players to initiate checks
Hmm, not sure I see that setting? ๐ค
I missed it too lol, let me get to my computer.
I think I found it, sneaky setting!
Let me just test first, but on my first read over I did not see it ๐
Yep that fixed it, thanks! ๐
someone here had to screen shot it for me, so I feel ya lol!
Now to make the effect from DFreds apply ๐ค
freeze has a macro in macro polo which does contested rolls and on failure applies dfreds.
you may be able to edit that for yourself.
Hmm, seems like a good starting point
V9 anyway, not sure about V10
Most automation is on V9, me included ๐
I don't understand this, looking at the code for DFReds this should work, but it doesn't ๐ญ
Hmm, I think I figured out why, the macro is not calling my callback function for some reason ๐ข Even though it is on the DM
midi does this all the time
what on earth are you doing in the macro to break one of the most basic parts midi does
saving throw on hit? Look at the giant spider stat block
Are you trying to run a mtb macro via dae on hit? If so make sure the players have permissions to the macro
Case: My player has a weapon that on hit triggers a saving throw on the target.
This, but only in some cases, depending on the ammo used
give them multiple attacks, I do this with an arcane archer all the time, they just choose their attacks, not their ammunition
Currently trying to figure out what kinda item I need to pass to MidiQOL.completeItemRoll, and wether I can use a JSON item, so that I can just create it dynamically and use the exisiting MIDI flow
But my macro already works, just for GM only ๐ข
If you need contested rolls, this is what I use as an item macro for contested automation:
Shield Bash
let results;
const attacker = canvas.tokens.get(args[0].tokenId);
const {object: target} = await fromUuid(args[0].hitTargetUuids[0]);
const skilltoberolled = target.actor.data.data.skills.ath.total < target.actor.data.data.skills.acr.total ? "acr" : "ath";
results = await game.MonksTokenBar.requestContestedRoll({
token:attacker,
request:'skill:ath'
},{
token: target,
request: `skill:${skilltoberolled}`
},{
silent:true,
fastForward:false,
flavor: `${target.name} tries to resist ${attacker.name}'s shove attempt`,
callback: async () => {
const attackerTotal = results.getFlag("monks-tokenbar", `token${attacker.id}`).total;
const targetTotal = results.getFlag("monks-tokenbar", `token${target.id}`).total;
if (attackerTotal >= targetTotal) {
if(!game.dfreds.effectInterface.hasEffectApplied('Prone', target.actor.uuid)) {
await game.dfreds.effectInterface.addEffect({ effectName: 'Prone', uuid: target.actor.uuid});
ui.notifications.info(`${attacker.name} shoves ${target.name} to the ground`)
}
}
else ui.notifications.info(`${target.name} resists the shove attempt from ${attacker.name}`)
}
});
is the macro an item macro?
Well it used to be, moved it into a dedicated macro to try the "run as GM" option
do the players have permission to the macro?
Also the above is basically what I did, but the callback in the request was never getting called
Yes, 99% of the macro executes, just not the callback from MTB requestRoll
Is the setting for MTB set to allow players?
yes, that was my first issue, which is fixed now
Well you could, especially if you don't need upcasting a spell
What's the macro that is not firing?
Just gonna paste part of it, but basically this part is not working (should be able to be run on its own, as a weapon on use macro):
let target = canvas.tokens.get(args[0].targets[0].id);
let result = await game.MonksTokenBar.requestRoll([target], {request:'save:con', dc:16, silent:true, fastForward:false, rollMode:'request', callback: async () =>{
let total = result.data.flags["monks-tokenbar"][`token${target.data._id}`].total;
if(total < 6) {
game.dfreds.effectInterface.toggleEffect("Lightning Inhibition", {uuids:args[0].targetUuids});
} else if (total < 16) {
game.dfreds.effectInterface.toggleEffect("Reaction", {uuids:args[0].targetUuids});
}
}});
So it asks for the save, and when run on the GM it works, but on a player it seems to never trigger the callback
<#macro-polo message>
A small sample of a complete item roll
(how are you testing? do you have a GM account logged in, when testing as a player?)
Hmm, interresting, doesn't fix my above case though, but does fix my simpler cases (where there is only 1 save DC)
Yes, 1 GM and 1 normal account logged in at the same time ^^
Put some console.logs in the call back function to check what runs and what does not
Doesn't run, already tried console.log at the root of it ๐
let target = canvas.tokens.get(args[0].targets[0].id); //Runs
let result = await game.MonksTokenBar.requestRoll([target], /*runs*/ {request:'save:con', dc:16, silent:true, fastForward:false, rollMode:'request', callback: async () =>{
let total = result.data.flags["monks-tokenbar"][`token${target.data._id}`].total; // Does not run
if(total < 6) {
game.dfreds.effectInterface.toggleEffect("Lightning Inhibition", {uuids:args[0].targetUuids});
} else if (total < 16) {
game.dfreds.effectInterface.toggleEffect("Reaction", {uuids:args[0].targetUuids});
}
}});
no console errors?
Working fine for me ๐ค
I'm looking to automate this healing/damage effect via the OverTime active effect flag. Is anyone willing to help me out with this? :>
The Risen Reaper chooses a target it can see within 60ft of it. The target must succeed on a DC 18 Constitution saving throw or be cursed for 1 minute. While cursed, the target suffers 2d8 necrotic damage at the start of each of its turns. The Risen Reaper regains hit points equal to the amount of necrotic damage dealt. The target can repeat the saving throw at the end of each of its turns, ending the curse on a success.
I can write something for that on Monday that I will be back home! If noone else offers a solution until then, feel free to DM me Monday morning to remind me ๐
Awesome! ๐
Thank you so much
Oh, I made a little alteration to the effect. ๐
The Risen Reaper chooses a target it can see within 60ft of it. The target must succeed on a DC 18 Constitution saving throw or be cursed for 1 minute. While cursed, the target suffers [[/r 2d8]] necrotic damage at the start of each of its turns. A creature of the Reaper's choosing within 60ft of it that it can see regains hit points equal to the amount of necrotic damage dealt. The target can repeat the saving throw at the start of each of its turns, ending the curse on a success and taking no damage.
A creature of its choosing.
Hey there, Is it a Midi setting that stopping my spell descriptions from showing up in chat? Nothing happens when i click the name in the chat card either.
could be, there is a setting in midi to collapse the chat cards. also one in system settings. check both
ahh thank you!!
I actually don't think the midi setting collapses, it just flat out doesn't let it draw in the chat. You can't expand it as a DM I don't think.
is there any other patreon like jb2a for animations?
Better asked in #513918036919713802
roger will move there
Is there a setting for removing the attack button after having made the attack? I'm sure that's how it used to be
Are you sure you aren't crossing the streams?
I don't even see my versatile buttons and I have my setting where it doesn't delete the buttons
Did you at any time have MRE installed?
Oh wait, wrong tab bud, your the GM, your settings are in GM tab
It's set for both, and I tried turning off all the autorolling for both PC and GM too
Will try FTC just in case it's a mod interaction ๐คทโโ๏ธ
? They show for any versatile weapon with versatile damage
Assuming no autorolling damage
I host for a paladin who uses a longsword, hes never had that button show up, I'm checking to see if I deleted his versatile field
did you hit save in the workflow button and save outside, or just x out
save, save and save some more
Do you not see the attack button?
I tried FTC and seemed to be present with only midi
try refreshing maybe its a cache issue
I removed the versatile field on my pally players longsword, when I refilled it in proper hes got the button again, but I actually use that setting, I prefer buttons to remain
versions?
FVTT 9.280
DnD5e 1.6.3
MidiQoL 0.9.81
I haven't updated to 81 or newest v9 foundry yet but mine are poofing when I toggle
I matched everything but your foundry version and am not experiencing your issue
I'm on build 269 of v9
Send me your midi settings
I just launched a sandbox world with nothing but Midi, Socketlib, and TidyUI and it still happens
And I'm fairly sure it's been happening before now
Seems to always happen if not autorolling/autoforcing damage roll
wtf is "misses (6/4)"
rolled 6, ac was probably 10
Gross
Drow poison applies poisoned conditionif you fail a DC 13 con save. If you fail by more than 5, you are also rendered unconscious. Is there a way to automate this? Right now I have the excess unconscious handled manually and have a reminder in the chat flavor text box to track saves.
I'm thinking an item macro that mimicks a save or unconscious item, where the DC is 5 lower? Unless somehow I can put it in an activation condition?
but it would need to reference the same save as the weapon?
Is it only ever going to hit 1 target? Could activation condition the workflow, there's a failed saves set that you could check the total of
Oh nevermind, it does not show the roll there, hmmmm, wonder where that is saved then
I am still trying to figure out if there is a way to make the Lucky feat work. I have pulled in one of the midi-qol Lucky options, but when the player rolls, they do not get the chance to reroll prior to knowing the outcome. Is there no way to do this?
I actually think that is rules as written
just alot of tables don't follow it
It's before knowing the outcome, I don't think midi qol automatically stalls for that
The way I understand the rule is the player can see the die roll, but not if the roll succeeded or not. The player can then opt to roll a new die
there is because legendary resistance does it that way from midi sample items
which is especially weird cause the DM knows, but it hides our save result till we choose
Testing that and it is working the same way. Player is not given the option for reroll
Yeah, I don't get that with the legendary resistance thing either. Foundry v9.269, Midi 0.9.79. Unless the stuff's coded into Midi, I also don't really see a macro or an item flow that would suggest it does anything automatically either
Aaah it's effect flags
Still don't do it none but it's supposed to looking at the effects
I was hoping it would be like the shield spell and automatically ask to be used or not
Maybe there is no way to do this, making Lucky useless online
Ah, no, there we go. The Lucky (Resource Usaage) 0.9.26 works for me
I am V 10 of foundry
did you set a resource for lucky Kabkal?
If you drag that particular item onto the sheet, it makes your third resource field into a Luck Points resource, and I also shamefully needed to refill it before it worked >_>
OK, I did not reset the resources last time I tried that one
Ok, it is asking to use the roll, but it is not subtracting the resource
Edit the feature to make it use that resource box, you can't have that preselected in features in core DnD
It currently just has a limited use of 1/1, you want resource consumption attribute resources.tertiary.value 1
So you have to click on the box to use the feat, and then click on the feature to remove the count?
No, does it automatically here
Just has to edit the feature to use that resource first
Then I have something set incorrectly here
Actually subtracts it without even setting it, now that I double test. Feature's supposed to overwrite everything and work "out of the box" as long as you have at least 1 in your third resource box.
Do you get a console error when it triggers? I'm not on v10 so I can't test along ya
Triggers as in, you opt to use the resource by way of the dialogue prompt
No errors
I get the prompt, I see both rolls, and it is taking the higher of the two rolls
Out of ideas, throw an issue on the github. :p It looks definitely possible and there's presumably a snafu, remember to include your midi qol settings
OK I will see if I can figure out how to do that. Thanks for your help
@gilded yacht Can I refer to all steps of the workflow in activation condition with midi qol? I can't seem to compare @workflow.saveResults[0].total so I can do something like deal extra damage if the target's save is less than a set value, e.g. @workflow.saveResults[0].total > 10. It seems to work with other things like @workflow.attackRoll._total so wondering if I'm looking at the wrong workflow
That looks to be a bug. I'll investigate
This is basically the use case I described yesterday that I had trouble getting my macro to work for when players were the ones triggering it ๐ญ so if you figure something out I'm all ears
Actually, that message above by Krig just gave me an idea for how to do it..
But am not at home right now and will require an item macro ๐ค
Can you dm me the item that you are playing with? Makes it easier to test, my first guess is that it should work, but I've not tried it.
tposney - any way of having this "attack" button go away?
Settings are set to remove attack and damage but they only disappear once damage is rolled
Yeah, it's a bug. I'll push a fix in the next v10 release (10.0.12 from recollection)
Had a quick look and at the moment it seems the answer is no. I can't (without thinking about it some more) come up with a good reason why it is done that way (other than laziness on my part) so I'll have a look at separating the attack/damage button removal.
Hi all. I am using midi QOL for targeting during combat. Speeds things up. Wanted an easy way to give the +2/+5 for various covers, but the manual system from DnD 5e helpers seems independent, and not playing with the midi system
Assuming v9? I think there are settings in midi for which cover system to use
Midi should (at least in v9 - not tested in v10) allow you to specify the dnd5e helpers cover calculations (in optional settings) and pick up the cover calculations from dnd5e helpers - the 4 point check setting.
It's the Walls block ranged attacks setting
So only for automatic cover yeah?
No way to do it manually?
If you are using dnd5e helpers and it upgrades the AC of the target, then that should be reflected in midi's hit/miss calculations (at least as far as my hazy memory of the workflow) - I think dnd5e helpers will add an effect to the target to give it a bonus to AC. Top be honest it's been months since I looked at this so could all be nonsense on my part.
Effect on the attacker
But only for v9 I believe cause there isn't a v10 version of helpers
Cover on target can be turned off and use can use the R key for manual checks
And likely won't be
I'll keep trying. Wasn't working for me so far. Thanks
Love yours and Kand's work and passion. Sad day I hate being reminded of ๐ฅบ
Another reason I'm glad I'm still on v9 and will be for some time
Since it's MIT. Our cover calculator could be integrated directly into midi. I really like it, maybe it will come back in the future in some form
Hey all! Would it be terribly complex to have a 'Cover' condition that only applied to ranged attacks?
Ideally it would somehow detect the angle (which I doubt is possible) but the first option should be!
example
Iff v9. 5e helpers
Oh neat, I'll try to find out if it we works with sw5e, thanks!
Is it a full system or a mod?
It it it's own system. But so far most 5e stuff works with it that I've tried
Ah. Helpers won't, sorry
Bummer. Then back to the OG question! I'm sure midiqol has a way to differentiate between Melee and ranged, right? I'm just unsure how to do that part
I want to use Spiritual Weapon every turn using Midi QOL. Was recommended to pop out the spellcard. How do you guys handle such spell effects which last through multiple rounds?
Warp Gate to spawn an actor IMO
Isn't that in the sample module already?
What is the end goal here? Just to apply -2/5 to attacks that are ranged always?
warp gate?
A mod for spawning stuff basically
Triggering an actor + consuming the spell slot does sound the most reasonable. I will look into the Warp Gate module, thanks!
@mellow atlas Are you on V9 or V10?
End goal I think it to create a 'cover' condition that grants additional ac against ranged attacks, as well as the usual dex bonus to saves.
I figure ac only from ranged since is someone is within melee range you rarely have cover imo
Once I get a template I can tweak it for my 4 layers of cover within sw5e
Reason being is I use alot of automation so ideally I don't want Things to hit that shouldn't
Well, easiest way, since you will have to apply the condition manually anyway, is just to give the person +2 AC. But if you really want it to reduce the attack instead then you will want to use flags.midi-qol.grants.attack.bonus.rwak with a negative add, eg.
Of course all of this assumes you want to apply a condition to the target, if you instead want to apply it to the attacker you will want to use data.bonuses.rwak.attack
I'd apply the condition to the target for this
Keep in mind permission issues with unowned tokens
Helpers applied it to the attacker for this reason
v9
DFred's Convenient Effects works with sw5e if that's anything, it has status effects for covers already implemented per dnd5e rules, can adjust those if you want.
@mellow atlas Then take a look at https://foundryvtt.com/packages/midi-srd it has a premade item for Spiritual Weapon that works
Midi SRD, a Module for Foundry Virtual Tabletop
Oh sick, I will check It out- thanks everyone
@vast bane Here is a setup for having additional effects applied if they fail an additional DC:
Any initial effects that always happen if the save is failed can go directly on the item.
Set an onUse to happen "After Active Effects".
Call a macro, here is the code, should be easy to modify:
const workflow = MidiQOL.Workflow.getWorkflow(args[0].uuid);
let saveResult = workflow.saveResults[0].total;
if(saveResult < 5) {
await game.dfreds.effectInterface.addEffect({ effectName: "Lightning Inhibition", uuid: args[0].targets[0].actor.uuid });
}
(This is an example of a DC 16 item with an additional effect at DC 5)
I think you can do that with activation conditions too. Or does the activation condition resolve before this can be evaluated?
I don't think you can tie different activation conditions to two effects on the same item?
Yeah that doesn't sound doable. I was talking about your shared macro example
Well thats what that macro was for ๐ But with 1 effect always applied and 1 conditionally based on save
(Always if the save is failed)
Ah I just checked the macro not the premise of it ๐
Makes sense ^^
I showed a likewise feature to tposney and yes, resolved before it can be evaluated
Maybe I am not getting this, but doesn't that code mean that the thing only applies if the save result is 4 or lower? Not failed by 5 or more?
So for my item, it would read if(saveResult < 8)
Yeah, that is correct, my case was a DC 16 and DC 5 ^^
k, so it needs to change for various effects if the DC changes, just makin sure cause the 5 had me almost there just cause my qualifier was also a 5
Ah yeah ๐
It should be possible to fetch the DC and set the extra DC based on the primary one thoug
does anyone have a way to build some automation for "upgradeable" conditions, like Exhaustion? So that the first time it is applied it's Condition Tier1, then Tier2 and so on. I have a script for that but it's a large unwieldy beast that leverages dfreds macros to remove the existing one and adding the new one, but maybe there's a simpler way with midi/dae/item macros
I never have had to deal with it without being able to just apply dfreds manually
Tidy has it built-in as well
Just enable it in the settings and it will apply the correct ones from DFreds
Yeah but I want to build a custom condition that does the same thing dfreds does for exhaustion.
AFAIK CE will prioritize custom effects over inbuilt
Hey, your macro you gave me above works perfectly except that the Unconscious status effect applies inactive?
So as long as you have the same amount of levels you can just duplicate and modify
This is the relevant part from the scaling morale condition I wrote, but there may be an easier way. I was wondering if there was some built in logic to do the same given a set of conditions with the same name
let hasWaveringApplied = await game.dfreds.effectInterface.hasEffectApplied('Morale: Wavering', uuid);
let hasBreakingApplied = await game.dfreds.effectInterface.hasEffectApplied('Morale: Breaking', uuid);
let hasFleeingApplied = await game.dfreds.effectInterface.hasEffectApplied('Morale: Fleeing', uuid);
if (!hasWaveringApplied) {
await game.dfreds.effectInterface.addEffect({ effectName: 'Morale: Wavering', uuid });
} else if (!hasBreakingApplied) {
await game.dfreds.effectInterface.addEffect({ effectName: 'Morale: Breaking', uuid });
} else if (!hasFleeingApplied) {
await game.dfreds.effectInterface.addEffect({ effectName: 'Morale: Fleeing', uuid });
} else {
console.log('Nothing to do!');
}
Hmm, huh, that sounds weird ๐ค
I think that might be a DFreds quirk
Can someone else test this with dfreds CE please? It appears that vanilla unconscious with dfreds CE is setup wrong:
just apply unconscious to a token
Duplicate it and fix it, then try again
I've tried and it didn't work; I've check with dfreds and they said there is some background automation for Exhaustion, so simply copying the effect and renaming it won't work
unless something has changed in the later versions ofc, this was a couple of months ago
pretty sure theres a bunch of modules that automate exhaustion, like rest/recovery
does anyone else see unconscious as applying inactive from dfreds panel?
yeah but I don't need to automate exhaustion ๐ I want to do something like what dfreds does for exhaustion for other scaling conditions
Hmm, no yeah way to do it then yeah
Nope, neither when I copy it nor apply it is it suspended ๐ค
this is what it does for me, but I'm on v9 so maybe older dfreds version
what version are you on?
V9
This is what I wanna know:
and I need to know dfreds ce version
ah no it's temporary for me
what version of dfreds ce you two got?
2.7.3
well shit now I'm worried
CE 2.6.1
I have 2.7.3
panel 1.5.1
I know I can duplicate it but that shouldn't be the actual problem if yours is fine and mineisn't
That's really odd, maybe a quick reinstall of CE is a good idea
๐
Thats what I get for testing a drow ability on a drow
Interesting way of stopping it from applying though
Ci stands for condition immunity
heres the even funnier part, I dragged outa player to test it on too and they had fey ancestry
It just modifies the standard traits
So first I tried a drow, then I tried the bugbear player, both having fey ancestry lol
This is why I have a test target with 1 ac, 10 in all stats and no special stuff ๐
I didn't wanna shift my page, I normally hadv 3 dummies on the landing page
๐
Ok I wrote the macro to add or remove levels of the condition from a token. How can I make it run so that it gets applied when I hit an enemy with a spell? This is the current code:
let uuid = token.actor.uuid;
let hasLvl1Applied = await game.dfreds.effectInterface.hasEffectApplied('Contamination I', uuid);
let hasLvl2Applied = await game.dfreds.effectInterface.hasEffectApplied('Contamination II', uuid);
let hasLvl3Applied = await game.dfreds.effectInterface.hasEffectApplied('Contamination III', uuid);
let hasLvl4Applied = await game.dfreds.effectInterface.hasEffectApplied('Contamination IV', uuid);
let hasLvl5Applied = await game.dfreds.effectInterface.hasEffectApplied('Contamination V', uuid);
let hasLvl6Applied = await game.dfreds.effectInterface.hasEffectApplied('Contamination VI', uuid);
if (!hasLvl1Applied) {
await game.dfreds.effectInterface.addEffect({ effectName: 'Contamination I', uuid });
} else if (!hasLvl2Applied) {
await game.dfreds.effectInterface.addEffect({ effectName: 'Contamination II', uuid });
} else if (!hasLvl3Applied) {
await game.dfreds.effectInterface.addEffect({ effectName: 'Contamination III', uuid });
} else if (!hasLvl4Applied) {
await game.dfreds.effectInterface.addEffect({ effectName: 'Contamination IV', uuid });
} else if (!hasLvl5Applied) {
await game.dfreds.effectInterface.addEffect({ effectName: 'Contamination V', uuid });
} else if (!hasLvl6Applied) {
await game.dfreds.effectInterface.addEffect({ effectName: 'Contamination VI', uuid });
} else {
console.log('Nothing to do!');
}
A specific spell or any spell from a specific character?
several spells/attacks would use the same logic to add levels of contamination. No specific caster
It that case you will have to add it to each of the spells in the details tab, near the bottom
Click the โ, type the macro name in the box, and use the dropdown to select when it should be run
gotcha...I guess it would have to be the uuid of the target instead of the caster though? Unless of course is the caster that's getting contaminated by casting the spell ๐คฃ
That + is nonexistent in darkmode, haha
It really is ๐
Yeah I had to mouse over it to see what it was ๐คฃ
Yeah, it should be ๐
mm it doesn't like my uuid declaration
let uuid = token.actor.uuid; I guess even if I have a token selected (this spell contaminates the caster) I would have to write it differently if it's ran from the item
@vast bane
const workflow = MidiQOL.Workflow.getWorkflow(args[0].uuid);
let saveResult = workflow.saveResults[0].total;
if(saveResult < args[0].item.data.save.dc) {
await game.dfreds.effectInterface.addEffect({ effectName: "Lightning Inhibition", uuid: args[0].targets[0].actor.uuid });
}
This should scale on the DC set on the item, untested though ๐
Try let uuid = args[0].targetUuids[0]
this is if I want to "contaminate" the target, right? What if I want to do it to the caster instead? ๐
let uuid = args[0].actorUuid
I think there needs to be math in there. args[0].item.data.save.dc - 5
otherwise you are just defining the standard method of a save
Fair point, was mostly an example of getting the DC, untested as I said ๐
it works now, thanks!
what if I'm shooting a contaminated fireball? should I leave an empty array after targetUuids? targetUuids[]?
or should I leave the first array blank instead?
You want to apply it to all targets for AoE?
yeah
not this one specifically, but for future use ๐
do I need to add a loop?
for(const targUuid of args[0].targetUuids) {
//Do stuff here that you would do to the individual ones
// targUuid is the UUID of the individual ones
}
thanks again!
Np ^^
final question: let's say I want to have a failed saving throw as a condition to start the contamination logic - so that it breaks out of it early if the save is passed. How would I do that with this kind of syntax?
So you want to force the user to roll a saving throw and then if they fail that then it advances the contamination?
Also is that both the caster and the target?
yes to the first question, only the target for the second question
I don't think I have saves on the user's end
Hmm, okay, so.. This is slightly more complex, but doable
don't want to take too much of your time if it's a mess ๐
worst case scenario I can do it manually
Just trying to make sure I got it right
I would move the contamination logic into an item on its own, with the saving throw attached. Then when you roll another spell you can have the macro on the spells call MidiQOL.completeItemRoll(args[0].actor.items.getName("Contamination Item Name")) to have Midi process the item and trigger the saving throws on all the currently selected targets.
Then you will want to modify the macro on the contamination item to start with if(args[0].failedSaves.length === 0) return;
And you will want to modify the loop to be
for(const targUuid of args[0].failedSaveUuids)
Biggest annoyance about this is that the contamination item needs to be on the actor to be valid.. There is supposedly a way to bypass that, but I haven't looked into it
Valid?
Valid as in will process, causes an error because actor is undefined for some flow somewhere ๐
will give it a go, thanks!
Is it possible to execute a macro from a compendium via DAE/MIDI? Trying to run it with Compendium.compendium-name.macro-name fails to locate the macro.
Don't think so. Why not just import it?
It's not viable for what I am doing.
It's all automated and using Sequencer and AA for a lot of it, and it supports this format. I'll have to look at my other options I guess.
I see zero reason you couldn't. Just retrieve the macro document, and run it.
Only obstacle is probably player permissions.
If you have the full uuid, then... use fromUuid.
Since I made the compendium, I have the name, the ID, and the compendium its part of. How do I get the UUID from this?
The full name for reference: Compendium.dnd5e-spell-automation.Macros.Tasha's Caustic Brew - you can guess what that refers to ^^
You can already do with on use flags
Isn't that spell a simple OT effect?
Tposney wanted this to be possible where you'd have 1 master item, then have all copies run off of it.
Nah, it's the same as ItemMacro.item name
Then you just state when it runs
Would this not work for that spell though?
If you want to get mechanical about it, it's better not use ot but a Dae each script
Why is that?
They do get a choice, but I suppose you could also wrap that into an ot but will require another macro.
They take damage then choose to remove it or not
True, that's why for this one I didn't have a save there and just manually remove the AE with Effects Panel
This does bring up a question though, can you put 2 different types of saves in an AE?
I should've been more clear, that's on me. Can you do 2 different saves in an OT effect value
Something like saveAbility={dex|con}
doubt it, you'd be better off making a secondary effect to do it
You can however write small logic for conditons
what does the flavor look like for no damage? and to be clear, it would definitely NEVER damage anything if I used it right? I'm trying to automate color spray and sleep
just define the damage type
can look at my gitlab
probably needs to be updated for v10
I wonder if it'd work if my cub doesn't do conditions, like its there, its just not the one handling them
You wouldnโt have any issues. The conditions are created programmatically and added by MidiQOL using sockets, not CUB (if I didnโt miss something). Just change the icon paths to the ones you want
yeah but since I have cub installed for its other features, I didn't even have to change that hehe. Cause Cub exists, just not managing the conditions.
const {uuid} = await game.packs.get("pack key here").getDocument("macro id here");
Of course, if you have all this, just get the actual document and just run the macro lol
(if your modules allow)
can I use a formula or references in an Effect Value field instead of a simple value? IE: I'd like to create an effect that sets the data.attributes.movement.swim value to match the existing data.attributes.movement.walk value, if the walk value is higher than the swim one.
I've tried to use Upgrade as the Change Mode and several variations of [[data.attributes.movement.walk]] for the Effect Value, but it fails
you might have to wrap it in brackets but I'm pretty sure theres a midi srd or sample item that already shows you we can do it
I'm getting a Unresolved StringTerm token.actor.data.attributes.movement.walk requested for evaluation error, so maybe I need to turn it into an integer?
v9, tried custom and I get a different error
dae.js:427 dae | evaluate args error: rolling data.attributes.movement.walk failed this is what I get with custom
my server just rebooted so I can't test it for ya lol
its not data
I think you can @attributes.movement.swim
or whatever
Heya, I am running a macro that uses MidiQOL.DamageOnlyWorkflow to apply damage to a token. However, every time I apply the damage, it is applying concentration to the target when I print the item card. Is there a way to prevent this? For context I am automating caustic brew with a DAE effect like so:
const itemData = args[1].efData.flags.dae.itemData;
const level = itemData.data.level;
const damageRoll = await new Roll(`${level * 2}d4`).roll({async:true});
new MidiQOL.DamageOnlyWorkflow(target.actor, target, damageRoll.total, "acid", [target], damageRoll, {flavor: "(Acid)", itemData: itemData , itemCardId: "new"});
Midi, like most modules that do this in v9, likely applies concentration by scanning chat messages. It might work if you simply removed concentration from the fake item.
does anyone know if there is a way to interact with the Sight Radius / Vision Limitation field added by the Perfect Vision mod from an Effect?
itemData.data.components.concentration = false; actually stops it from happening - cheers.
They are flags on either the token document or in the scene document.
flags.perfect-vision.light.visionLimitation.sight should be the one I'm looking for, can I just use that even if it isn't recognized by the interface when I add it as an Attribute Key?
I think the token
Effects can only modify actors.
having a look at this, not sure I see an actor flag :/ https://github.com/dev7355608/perfect-vision/blob/main/templates/vision-limitation-config.hbs
Yeah I see no reason it would save that in the actor document.
Sight is a property of a token document.
ok so no direct way to interact with it from an effect, right?
Not without a macro or module. No.
I guess I could run a macro from the effect to toggle it?
but then it would stay toggled even if the effect is removed
Just slap two one-liners into Effect Macro and call it a day.
and this is where I discover that this is a thing https://github.com/krbz999/effectmacro :v
thanks for doing this ๐คฃ
Is there a way to create an item that will give a player +2 on saves versus spells that are thrown at them? In other words, +2 on DEX save for fireball, but not on DEX save for falling in a pit?
@upbeat wedge
I donโt think there is anything that allows that, there is not enough context when a save is rolled to automate that easily.
I think you could use Advantage Reminder module to at least show this to the player. The only drawback is you cannot fast forward rolls, because the reminders are displayed in the core dialog box when you use/roll an item or save
well midi does distinguage magic vs non magic for magic resistance flag, so maybe theres a way with macros?
Problem is that MIDI doesn't have a way to trigger a macro when being hit, only when hitting something else
Maybe it would be doable if midi offered something like flags.midi-qol.advantage.ability.save.all that allows to evaluate a condition but for bonuses instead of just advantage. It could be tricky because it would need two values, one for the bonus and one for the conditionโฆ
reactions that fire macros?
You can totally pulll it off with advantage reminder
I already do it with shield master feat
It would be really cool if we could register macro being called during the workflow of other actors beside the existing reaction mechanism
Advantage Reminder
If the player is clicking the button in the chat, you can get the item that prompted the save from the click Event.
then use a dnd5e.preRollAbilitySave hook to add a bonus or whatever
What are the odds that works with midi's full chat overhaul?
Would be silly if Midi removed some core system behaviour. ๐
How would you register the hook? In a world script?
Why would a hook go anywhere else?
A simple world script:
- does the actor have this particular flag (and if so, what's the bonus)
- is there a click Event associated with the
rollAbilitySave, and is the event target chat card's item a spell? - ???
- profit
of course if you are completely wrecking the chat log (or not using it at all, depending on your module settings I bet), then ๐คท
hello all midi big brains! im having an issue with the midi sample spirit guardians. it is not forcing saving throws/damage on enemy combatants
i have ALL the required modules installed, not sure whats going on here
having a look into the effects tab, when i cast the spell the full effects are not being transfered to the token
on the left is the prepared spell, on the right is what appears once it had been cast
You have MIDI set to only apply effects if there is no CE effect, its the CE effect you are seeing
where would that be? in the workflow config?
In the DFreds convinient effects panel
im guess this?
My recommendation would be to set up the effect on the CE one instead but if you don't use CEs much then the second one
yeah im much more of a point and click DM, i am lost when it comes to most of the nuanced set up of these things
You do not need to change that setting that way if you do not want to, at the bottom of the right spirit guardians, there will be a checkbox to override dfreds and apply the actual AE on a per item basis if you prefer dfreds first for most things.
really? where would that checkbox be? i cant see it anywhere
it will only show up if the items name is identical to the dfreds CE
huh, ok. well i cant see it in spirit guardians
you already swapped the settings ๐
note the check at the bottom
I think there is also something else we're suppose to do as it doesn't work out of the box
I remember it being at the bottom of one of the effects tabs
y'know im loving this module, but my god sometimes the amount of options is confusing lol
I think he fixed it, I had told him about it and I think he actually patched it.
Hey! Do anyone know how "Flaming Sphere MQ0.8.85 + warpgate" works? MIDI QOL has a flag called "flags.midi-qol.OverTime" which is supposed to do whatever action you want overtime.
But it looks like Falming Sphere is not working because I'm able to spawn it but it doesn't do any damage to nearby enemies.... Any clues?
I will answer myself -> INSTALL ACTIVE AURAS 
How would I go about setting a feature / attack to apply an effect even if the target succeeds on the save with mid-qol?
A world script is only way to do this
Depending on what it is, an on use macro would be a way to pull this off.
You would just need to define it to run only on a successful save. Then let Dae handle a failed save
So I have a monster feature that does a save for half damage, but no matter what an effect should be applied.
Should I just have a itemMacro apply the effect manually?
Or you can define them both in the same macro
half save is default for any saving throw if you don't define it to deal no damage
it will always deal half damage on success
Yea that's fine
I'm just trying to add a rider effect that happens whether you save or not
It's just I can't figure out an easy way to always apply the DAE effect even if it's saved
If you want a different effect for on success, you'd need to a macro
that's what I kinda thought
have the item do the saving throw. DAE only handles failed saves
game.dfreds.effectInterface.addEffect seems to be what I want to use I think
and just make the effect as a custom DAE
this a single hit spell or an aoe spell?
single hit
My plan is to just use the targeted creature with game.dfreds.effectInterface.addEffect({ effectName: 'Bane', uuid });
well
not bane
but my custom effect that's setup in DAE
args[0].hitTargetUuids[0] should be the uuid I think?
const lastArg = args[args.length - 1];
const target = canvas.tokens.get(lastArg.tokenId):
if(lastArg.saves.length === 0) return {};
await game.dfreds.effectInterface.addEffect({ effectName: 'Bane', uuid: target.actor.uuid });
You could do something as simple as
๐
Make sure this setting is on
It will still not cause a template to appear, but it should target them correctly
Oh! Let me try!
Unless the spell is not cast on top of the caster? What spell in particular is this?
this would not work in there case, as they are looking for a template, not just a single target
and it has a range. so, it is not centered on the caster
which one? dfreds? I personally don't use it in active game play, but I do use it for testing purposes
mostly to make sure my active effects are compatible with modules like monks
You can do that with DAE
as a flag right?
I guess there'd be an advantage to that if you're new.. but not needed
It is Spirit Totem (class feature)
nah it has macro.execute built in or you can wrap it into item macro
Hey guys does anyone use the module: LootsheetNPC5e?
Ah, yeah then thats a bit more complex
I am trying to automatise the whole process of the spirit totem thing with this macro -> (plus aura effects)
console.log("comienza la fiesta")
console.log(args);
if (args[0].tag === "OnUse") {
const casterToken = await fromUuid(args[0].tokenUuid);
const caster = casterToken.actor;
let dialog = new Promise((resolve, reject) => {
new Dialog({
title: 'Choose a totem: ',
content: `
<form class="flexcol">
<div class="form-group">
<select id="element">
<option value="bear">Bear Totem</option>
<option value="hawk">Hawk Totem</option>
<option value="unicorn">Unicorn Totem</option>
</select>
</div>
</form>
`,
//select element type
buttons: {
yes: {
icon: '<i class="fas fa-bolt"></i>',
label: 'Select',
callback: async (html) => {
let element = html.find('#element').val();
let totemActor;
if(element === "bear") {
totemActor = game.actors.getName("Bear Totem Actor");
let effect = totemActor.effects.find(i => i.data.label === "Totem Effect");
let changes = duplicate(effect.data.changes);
changes[0].value = `${5 + args[0].rollData.classes.druid.levels}`;
await effect.update({changes});
resolve();
} else if(element === "hawk") {
totemActor = game.actors.getName("Hawk Totem Actor");
} else if(element === "unicorn") {
totemActor = game.actors.getName("Unicorn Totem Actor");
}
const summoned = await warpgate.spawn(totemActor.name, {}, {}, {});
if (summoned.length !== 1) return;
const summonedUuid = `Scene.${canvas.scene.id}.Token.${summoned[0]}`;
await caster.createEmbeddedDocuments("ActiveEffect", [{
"changes": [{"key":"flags.dae.deleteUuid","mode":5,"value": summonedUuid,"priority":"30"}],
"label": "Totem Summon",
"duration": {seconds: 60, rounds: 10},
"origin": args[0].itemUuid,
"icon": "icons/magic/fire/orb-vortex.webp",
}]);
},
},
}
}).render(true);
})
await dialog;
}
It's almost done just fixing a couple of things
that's awesome O_O
Effect Macro can do a couple of fancy things, like on combat start, turn start etc, and its a bit easier to use for new people ^^
That's why I started using it lol
You can layer multiple macros on top of each in item macro, if you need to be careful about your variables and where you define them
Seems way less complicated
at any rate, I have an onCreation macro tied to the effect
let damageTaken = 0;
for (let i = gameMessages.length - 1; i >= 0; i--) {
let flavor = gameMessages[i].data.flavor || '';
if (flavor === 'Draining Kiss') {
const workflow = MidiQOL.Workflow.getWorkflow(gameMessages[i].data.flags['midi-qol'].workflowId);
damageTaken = workflow.damageList[0].appliedDamage;
break;
}
}
if (damageTaken > 0) {
let changes = duplicate(effect.data.changes);
changes[0].value = -damageTaken;
await effect.update({changes});
}```
the only problem right now is that the aura effect of the bear totem (+7 of tmp hp) is now persistant when you go in and out of the zone so I'm trying to combine this macro with a normal spell execution:
1- First just cast a +7 hp life spell on every ally on a 30 feet range
2- just do the macro thing
Pretty much on creation of the effect, it runs the macro to update the value of a flag to be the last damage from a specific feature
Might be something that should be in #macro-polo
But figured I'd ask since it's tied to what I was doing before
personally I would have 1 actor with all effects on it, then have it remove items that don't belong. You can have it rename the actor too.
You are using Active Auras too?
yes!
active auras are amazing so of course I am using it for this spell hehehe
but the spell has 2 parts
I've done this with Summon Fey and Aberrant
1- Plus "x" hp to allies in a range of 30ft
2- An aura around of the totem with advantage rolls on several thingys
but effect 1 should only be applied once not every time you go in and out of the aura (because then you are inmortal xD)
but those are just evocations right?
without any secondary effects
wouldn't matter, it's just an actor
yea yea my totem is an actor
my real problem is that I need to cast a normal spell with 30ft range which targets allies (plus template, that would be nice) before applying the macro
And I don't know if it's possible xD
let abilityList = ["Fuming", "Mirthful", "Tricksy"].filter(i => i !== mood);
for (ability of abilityList) {
creatureLayout.Item[ability] = warpgate.CONST.DELETE;
}
(sorry if I am asking stupid things I am a newbie)
I think we are talking about different things haha
It might be easier to add the temp hp just as start of the macro instead of having it as part of the actual aura, like, just code it, because it only happens when the spell is placed
Yeah I think you are talking past each other ๐
I'm talking about you only needing 1 actor instead of 3
Get all your targets within the template, programmatically adding the temp HP, then just have an active-aura with the advantage stuff
Ah!! Yes yes! Totally agree on that, this is just a first iteration, next iteration I will reuse a generic Totem Actor.
OH OH OH That sounds like what I need! How can get all the targets within the template programmatically? Do you have an example?
Well if you are running a MIDI on-use macro the targets should be available in args[0].targets IIRC
oh!!!!!! And I can filter them like friendly / enemies somehow right?!
I can't remember if args[0].targets is tokens or actors, but yes, they have a disposition value somewhere
you'd use active auras for something like this as already pointed out
it's an array of 5e token actors
Hawk spirit would require a world script to work 100%
or you could create a reaction item on them to cheat it.
but active auras AFAIK it's used to propagate effects to other actors (persistent effects while you are in the aura) I just want to apply add +x temporal hp to allies in a 30ft range before applying the macro which actives the active aura. That's why I (think) need first to just add +xhp just once
"world script" sounds like an interesting thing that I should read more about it xD
key concept!
Actually you might be able to cheat the whole process, if you create an item on the target and the caster
!! how is that?! ๐ฎ
World Scripter, a Module for Foundry Virtual Tabletop