#MidiQOL
1 messages ยท Page 53 of 1
I'm just gonna use mr. primates version
gonna delete mine above so people searching don't try to use it
test it quickly to make sure ๐
For Active Effects module, I'm trying to make an effect deal damage every round like poison or something, but the code below is not working, what am I doing wrong?
flags.midi-qol.OverTime
turn=start,
damageRoll=1d4,
damageType=acid,
condition=@attributes.hp.value > 0 && @digital lagoontributes.hp.value < @digital lagoontributes.hp.max
yeah his isn't working for me either going back to your change
I think its cause I don't fast forward
well that's a new one @at ๐
I bet you AT is so that atropos doesn't get auto completed muahahaha lol
Change Add to Override
Thank you!
in my original macro, the second line seems redundant?
yeah delete the targets.push...
the animation hits them all, but the save is only prompted to one actor
the one I have actually targetted is the only one prompted
hmmm also just js game.user.updateTokenTargets(targets.map(i=>i.id)) instead of ```js
const currentTargets = game.user.targets;
currentTargets.forEach(t => t.setTarget(false, { user: game.user, releaseOthers: false }));
const newTargets = targets.forEach(t => t.setTarget(true, { user: game.user, releaseOthers: false }));
noone saw the edit(s)...
still only prompting the one hit with the first part, but the automated animations hits them all
I have updated the macro with what I'm using
when should the macro fire on use? after active effects?
I just logged args, and I get this: I feel like its using the caster instead of the target here?
share the macro to see what are you working with
Use Mr.Primates macro on his github.
instead of console.log(args), use console.log(targets) to see what's up
ok you've got 6 targets
yeah the sixth shouldn't be there I dunno why its counting this one...
the animations play right, and the animation is hitting that far left one
the one not shown fully?
I wonder if this is cause of my worldscript for movement animation
no the one in the image that has no tmfx bevel
ok who is the initial target?
that one?
Measure the distance to the one you say it shouldn't. It will be 10 no?
its ten with measuring stick yeah
but its suppose to only be creatures within 5
fyi I am now running ftc and only using midi, socketlib, libwrapper, dae, advanced macros, and MTB
I'm still only prompting the one I have targetted
could there be a midi setting interfering? I'm gonna turn on fast forward
still no luck
I'm trying to use Effect Macro to reverse a mutation on deletion.
if(mutation) {
return await warpgate.revert(token.document, "Prismatic Shield")
};```
Is this correct?
the 7.5 thing solved the extra target but the damage is only applying to the first guy
yeah something is off in this implementation. I will take a look in a bit
k gonna try mr primates again not sure what causes the yellow error with it
omg I think I figured it out @violet meadow I have no fucking clue how this import got into my shit....:
is the mutationName Prismatic Shield?
Yup. Here's the on-creation effect macro.
await warpgate.mutate(token.document, {token: {light: {color: "#ffffff", dim: 8, bright: 0, alpha: 0.3, animation: {type: "fairy", speed: 3, intensity: 1}}}},{},{name:"Prismatic Shield"});```
It seems fine, if you got the mutation correctly defined in the if (mutation) {}
@violet meadow editing out that weird damage type didn't help the macro we been working on, testing mr primates now
yeah editing that rogue damage type fixes Mr.Primates Ice Knife
I'm just gonna edit my macro entries above to be messages to use mr. primates
ok new issue, the sound effect in automated animations plays for each target in the secondary explosion
nm I know how to fix this, I will just turn off global
So the On-Effect macro works, but I don't understand why this isn't reverting the mutation.
const mutation = warpgate.mutationStack(token.document).getName("Prismatic Shield");
if(mutation) {return await warpgate.revert(token.document, "Prismatic Shield")};```
You are checking if mutation exists and if yes then it will revert.
What is defined as mutation?
I've done worse Janner
I shared a macro where the main function was commented out and asked why it wasn't working
We've all been there
DAE macro.itemMacro | CUSTOM | or macro.execute | CUSTOM | "macro name" ```js
const lastArg = args.at(-1);
const tokenDoc = fromUuidSync(lastArg.tokenUuid)
if (args[0]==="on") await tokenDoc.update({hidden:true})
if (args[0] === "off") await tokenDoc.update({hidden:false})
@scarlet echo
actually try it quickly cause I am going off memory ๐
wait a minute, banishment is already midi srd'ed
@vast bane the MidiSRD Banishment should be good right? Did you have a previous version? ๐ค
I might have let me look
oh yeah, that would change wouldn't it, usually the midi srd's don't actually have the macros in them, instead they reference the file, but banishment seems to have a macro
yeah should have been a really early version
I already updated it with my effect macro version, but looking at midi srd's official compendium one, it has a midi srd entry instead of the full macro so it should be working
I had an old one
god I really miss tidy's search function
Moving conversation RE: Unicorn Totem feature
The Healing Formula relies on Arbron's Summoning
change the target to 30 | ft | Ally
honestly I'd just make the range endless so that you guys don't have to knitpick the location of the totem when 99% of the time it just doesn't matter
can't they also do an actor on use whenever they cast a healing spell?
to roll that item
oh but they'd need a flag to say its up
That did it - thanks
Weird that it would work if you unselect anyone who was fully healed
And if I'm not mistaken - setting the Actor's type to "NoTarget" will make it no longer targetable by Midi based automations right?
I cannot parse this right now.
Actor's type to "No Target"?
Yes. I remember seeing that recently when someone noted that ItemPiles would accidentally get slept
ah no idea about Item Piles API unfortunately
another thing to put in the plus column for Monk's Enhanced Journal vs Item Piles lol
MEJ's are journal entries on the map so they don't get targetted
Effectively, code from midi-qol:
if (token.actor.system.details.type?.custom === "NoTarget") continue;
I don't think it was specifically Item Piles related... there was talk around of changing the creature type from Humanoid etc to 'NoTarget', meaning it wouldn't get targeted by midi. I've never heard of it actually working though lol... maybe using Template Enhancements etc screws it up
trying to get Armor of Agathys to work using Convient Effects, Midi... i found this unsure how to implement this: #1010273821401555087 message
That's (an old version) of mine. Here's a more recent version: https://github.com/chrisk123999/foundry-macros/blob/main/Spells/Armor Of Agathys/Chris-ArmorOfAgathysWorld.js
You'll need world scripter.
Then have the spell DAE look like the above.
Correct.
Rain check on that one. Off to bed ๐
No rush or need. I just have been using situational
is there a value like DR that makes them take more damage? increased damge can be finicky for what i want
like if i wanted to make an enemy take more radiant damage
Use a negative value in the relevant DR flag
not supported
specified in the midi readme
thats what i was GONNA try but i wasnt sure
It is supported ๐คทโโ๏ธ
oh, the readme is out of date?
Changed at some point
Yeah probably
Change logs are a better source of info sometimes
Or not better but rather a good source of additional information
Oddly it seems to be adding double the negative DR to catrips vs spells
Use Custom instead of add
That's got it
the things you learn when thatawesomebugbear fails at going to bed when they said they were
the DR healing and healing temp flags are the ones that don't have negative support
So I don't have it working... I set the Script "Chris-ArmorOfAgathysWorld.js" as a global macro (Is that right?)
Then I set AE: Armor of Agathys up like you screen shot. But it's not adding temp hp and it's not dealing damage. Can't figure out what I'm doing wrong. (Sorry to bother you!)
Googling.
Bit different then a hotbar macro
Gotcha.
Do I just drag it off hotbar into compendium?
Not sure whats wrong... sorry again.
I got it on. It did 313 damage to the test dummy when it hit the PC
CRAP sorry i meant for it not to ping you
So I have now managed to get that 'on death' macro working that I was working on today/yesterday... but I've noticed an issue. It only triggerrs when the creatures dies in combat
if it dies outside of combat, it doesn't trigger
what is your trigger?
just add a dae for 0 hp?
times up special duration for 0 hp
and then put the same macro on defeated in on deletion
effect macro triggers on defeated
cut and paste the defeated into on deletion, keep it in defeated, and set a special duration to 0 hp
need to keep defeated if you ever dead status a monster with hp left or a power word kill
or a wildshape
if I keep both, wont the macro trigger twice
I don't think I'd ever dead status a monster with hp left (I have alwaysHP so I'd just kill it to zero)
same with power word
wild shape / polymorph might cause it to be a bit odd but I think that's niche enough to forget about
you could have put an if something return state to stop double but no biggy
yeh I may do down the road
but for now
this will -do- haha
thanks
I already have an on-hit version of this that works for a single hit, I'm just curious if I can just have one version for all occasions instead of having two completely different setups.
I'm trying to get an overtime effect to roll thp, I've already got it set and working for healing using damage type=healing just need to know the damage code for thp
Cheers
It's all in the readme
that overtime section in midi was such a great addition. It's a shame there's not a midiqol for pf2e
This seems to say the effect should be applied after the hit, but instead it seems to be applied after the damage roll? Is there a way around this?
Hey, i have a weapon which does additional 1d6 damage against a creature type. How can i configure the item so we can roll the 1d6 only if needet with midiqol
'activation conditions' I think might be a solution. I know they're mentioned in the doc
What type of creature?
You probably need to set the formula like in this screenshot.
That's likely the reason it's getting "not a number" as the damage.
if you want effects to apply earlier make it an on use macro and use dfreds to apply a ce
on use macros can fire earlier
look at the mace of disruption in midi sample items for reference
Thy
Do I just do that by putting "OnUse" in the activation field where I'd normally put "ItemMacro"
oh or do you mean ItemMacro is an on use macro
why do you need the ae to apply before damage?
because the effect triggers when the creature drops to 0hp
at the moment it deals the damage first, so the effect never triggers
this also doesn't work, because it seems using dfreds means the effect does not show the player as the source of the effect
what does the ability do, if its published whats it called so I can look it up
whats it do, I'm about to head to bed don't make me read code
it adds an effect on a creature for 1 round. If the creature dies (from any source) during that round, the original player gains a resource
ok make the ae dfreds ce, apply it via a pre item roll item macro
need to use the item macro method of origin since origin is an effect macro thing
you should have a stored item macro version here before we changed it on you
no wait I'm a dufus
the item macro is just going to be the application of the active effect with the EM on it
I don't really wanna login to my world, dfreds CE gives you sample macros, you want the one that applies a CE
yeh I've used the CE macro
in an item macro
but it doesn't apply tthe source
it leaves it blank
if origin isn't working then just define the actor a different way
what is the error
you should be able to swap origin for the args stuff but you'll need someone like chris or bugbear for that
Honestly, the initial macro is kinda messy
I don't even get what its doing lol
can't this just be handled with an item macro after effects, have it check args -1 if its at 0 hp
then add shit
args dont work on effect macros
we wouldn't even be touching ae's
Could you give us the description of the ability or feature?
it adds an effect on a creature for 1 round. If the creature dies (from any source) during that round, the original player gains a resource
is it grogs sword?
don't tell us the foundry way of doing it, tell us what it does in dnd
no, its custom. The player is harvesting souls
if its custom share its description here
The player gains a soul whenever a worthy creature dies
Gotcha
what is a worthy creature
Looks like a certain CR level
as long as he either makes the killing blow, or he applies that effect on the same round as another player kills it
no, only creatures he makes a killing blow on, or a creature he hits with this effect
this is currently two separate macros. One which is an itemmacro which works by killing blow, and a different one which applies an effect that lasts 1 round
both work fine
Is this an item that has it?
yes
I would not give this item to my players lol, too complicated to automate
So they gain the effect when hit by this item?
just give them a sword of sharpness lol
I'm just tring to see if I can do both things with just one macro, instead of needing both
it already works. sword of sharpness is... completely irrelevant and unrelated? lol. And also no idea how you'd automate chopping off limbs in foundry
the enemy does yes
And only by this sword or anything that person has?
as I say, both macros work, the only thing im trying to do it turn them into one macro
only this weapon
atm the player has the same weapon twice, depending on how he plans to use it that turn. each version with the different macro
let findResourceSlot = resourceTable.find(i => i.label.toLowerCase() === resourceName.toLowerCase());```
This line is confusing me
Is it just looking for the resource call souls?
Last question
The attack needs to hit to be effected?
Is there any save involved?
Gimme a few moments and I can whip something up that should work for both instances for you
I'd appreciate that thankyou
One thing I'm struggling with is it also needs to only work when the creature dies. It works fine with the effect macro 'on deletion' and the special duration of 'when 0hp'
but
it also means that if the effect expires because of the round ending, it also triggers because that counts as being deleted too
I have a line which is meant to interrupt the macro (return {}) if the creatures hp != 0
but it's... only working for one macro, and not the other
can't figure out why, no errors in the log, it just doesn't work
whats the if line
(can't use the effectmacro "on defeated" because that doesn't work all the time)
I can't see ever having combat without initiative
if (actor.system.attributes.hp.value != 0) return;```
This should be what's needed for the effect macro.
let target = actor;
if (target.system.attributes.hp.value !== 0) return {};
let resourceList = [{ name: "primary" }, { name: "secondary"
that seems naughty
it seems to always stop the macro no matter what, even though the enemy is on 0hp
you don't have args
Try my code I just posted
you were using origin
Effect macros doesn't have args
actor is already defined for you in an effect macro too
yeh those are leftover from the original macro I converted
your code does the same as mine
which is no surprise as they're functionally identical
Not really
oh sorry, mine was also !=
not !==
but anyway both do the same thing, in that the macro doesn't seem to run and no errors pop in console
thats after I kill the creature with alwayshp (which works when I have that line commented out)
Is the target supposed to have a resource with souls on them?
or just the player?
or both?
only the player
I may have to come back to this after I've had some sleep, but I appreciate you tinkering with it for me. If you could just leave a message or DM me or something if you come up with a solution I'd really appreciate it
Yep, I'll have something working for you in a little bit
I'd stay but I wrecked my back last week and I have to keep taking breaks and painkillers -.- aha
thankyou
I assume you looked at the original macro so you know about the undead/fiend not working and the CR range etc
Yep, basing it on that
Is there a way to have the ruler with Euclidean geometry but allow diagonal melee 5 ft attacks
Ok, try this out. I made it on a dummy shortsword and appears to be working well.
Had to embed the effect macro into the item macro. The only issue is that it won't work if the effect is used on an actor that isn't controlled by the gm. May need to swap the actor.update with a warpgate mutation if so.
But oh well
What happens if you use touch instead of 5ft range?
Otherwise I imagine you would need to change the 5ft to something like 8 ๐ค
To make it more readable in a script, you can add an effectmacro as a flag like this:
const onDelete = async function(){
/* do stuff */
}
const effectData = {
/* ... */,
"flags.effectmacro.onDelete.script": `(${onDelete.toString()})()`
}
I'll have to keep that in mind
where is this setting
I meant on the weapon details tab. Under Range
remove the 5 / | Feet and choose just Touch. Does this account for the adjacent squares or not?
doesnt work diagonally
would be the same effort as changing all weapons to 8 feet as well i think
Does changing weapons to 8 work?
If it works, the change could be performed by a single macro for all items on your world
yea changing to 8 feet works
Does anyone happen to have a full Shadowblade macro? Been looking through previous posts, but most indicate there were issues with them and I'm codeblind ๐
someone just tackled the scaling
I've been moving away from warpgates and using macro.createitem, but the downside to createitem is they aren't easily shared
crymic does have a v10 shadowblade in his patreon stash
oh apparently shadow blade is here on discord somewhere
cause I have one
//DAE Item Macro, no arguments passed
if (!game.modules.get("advanced-macros")?.active) ui.notifications.error("Please enable the Advanced Macros module")
const lastArg = args[args.length-1]
let tactor;
if (lastArg.tokenId) tactor = canvas.tokens.get(lastArg.tokenId).actor;
else tactor = game.actors.get(lastArg.actorId);
const DAEItem = lastArg.efData.flags.dae.itemData
/**
* Create Shadow Blade item in inventory
*/
if (args[0] === "on") {
let weaponDamge = 2 + Math.floor(DAEItem.system.level / 2);
await tactor.createEmbeddedDocuments("Item",[
{
"name": "Summoned Shadow Blade",
"type": "weapon",
"system": {
"quantity": 1,
"activation": {
"type": "action",
"cost": 1,
"condition": ""
},
"properties": {
"lgt": true,
"fin": true,
"thr": true
},
"target": {
"value": 1,
"width": null,
"units": "",
"type": "creature"
},
"range": {
"value": 5,
},
"actionType": "mwak",
"damage": {
"parts": [
[
`${weaponDamge}d8`,
"psychic"
]
],
},
"weaponType": "simpleM",
"proficient": true,
},
"img": DAEItem.img,
"effects" : []
}
]
);
ui.notifications.notify("A Shadow Blade appears in your inventory")
}
// Delete Shadow Blade
if (args[0] === "off") {
let castItem = tactor.items.find(i => i.name === "Summoned Shadow Blade" && i.type === "weapon")
if(castItem) await tactor.deleteEmbeddedDocuments("Item",[castItem.id])
}```
Thanks! ๐
Thanks, will try that out!
@gilded yacht the midi or dae key system.attributes.movement.all only lets us pick custom when most of the time we'd need it to be override. system.attributes.movement.hover also seems to only take custom
Yeah this kind of code is essentially reused in lots of spells.
MidiMacros.flameBlade is pretty much the same from Midi-SRD
Why do you need it to override?
Ray of Frost
so that I don't have to make a wall of ae keys
also Rime's Binding Ice
rimes would be override, ray of frost would be subtract/add
tempted to just use the grappled condition on rimes to clean this up
technically grappled needs it too though
Use system.attributes.movement.all | CUSTOM | -10
that would work for ray of frost but not the others
I think hover is just a boolean right, its not a movement type
I am right in assuming the all is a midi key right?
it has to be a module cause it only accepts custom so I assumed midi
I gotta take my daughter to school but I'll resume whereever this convo goes when I return in 20
Oh nice.
If you want a macro to change all Items, which have a range.value of 5 to be 8, on the sidebar and on actors, ask about it in #macro-polo.
It's doable.
I can check later too when I am back on my PC
probably worth while to use that notarget creature type on all our warpgate summons now eh?
like healing badger/spirit, spiritual weapon, and the druid totems
do we have to worldscript it or can we just put a custom creature type?
Is it possible to turn this into something similar, but for damage resistances? I'm trying to automate the Draconic Spirit's "shared resistances" where it grants its summoner a damage-type resistance based on the resistances it already has.
const options = Object.entries(actor.system.traits.dr).reduce((acc, [key, {value}]) => {
if(value > 0) return acc;
return acc + `<option value="${key}">${CONFIG.DND5E.traits.dr[key].label}</option>`;
}, "");
const content = `
<form>
<div class="form-group">
<label>Skill</label>
<div class="form-fields">
<select>${options}</select>
</div>
</div>
</form>`;
const key = await Dialog.prompt({
title: "Shared Resistances",
content,
rejectClose: false,
label: "Gain Resistance",
callback: (html) => html[0].querySelector("select").value
});
if(!key) return;
const effect = actor.effects.find(e => e.getFlag("world", "shared-resistances"));
const mode = CONST.ACTIVE_EFFECT_MODES.UPGRADE;
const changes = [{key: `system.traits.dr.${key}.value`, value: 1, mode}];
if(effect) return effect.update({changes});
return actor.createEmbeddedDocuments("ActiveEffect", [{
icon: "/Icons/Spell_Icons/Arcane/T_Icon_Arcane_86.webp",
label: "Shared Resistances",
duration: {seconds: 600},
"flags.world.shared-resistances": true,
changes
}]);```
I put an ability on the spirit that the druid or caster rolls to apply the resistance flag to both actors
Oh, neat! Do you have an example?
For Active Effects module, I'm trying to make an effect heal every round but it's not doing it right, what am I doing wrong?
flags.midi-qol.OverTime
turn=start,
damageRoll=5,
damageType=healing,
condition=@attributes.hp.value > 0 && @digital lagoontributes.hp.value < @digital lagoontributes.hp.max
I've set it to override, add, and custom.
I'm on 5E, Foundry VTT Ver 10.
don't reinvent the wheel, drag the midi sample item for regeneration and edit it accordingly.
ah, my b, thank you!
however you are on 2.1.2 dnd5e so all bets are off
ahhhh, yeah lot of modules happen to be that way, idk why?
I'm trying to setup Spirit shroud, its an ability that adds situational bonus damage, a situational active effect applied to the target. I think this needs to be an optional.name macro but I just can't wrap my head around this.
Yeah, I had it working correctly before, but that was aggggggges ago. Or maybe I was high lol.
either that or I need to be able to edit their attacks to add the active effect damage bonus/ae application but also edit the activation condition with a range check of 10ft.
I got all these ideas on how to pull it off but they all come up short
I thought maybe an active aura with a reverse damage reduction, but the problem with that is it'd work on other peopels damage
then I thought an advantage reminder and put a document link to the temp item
thats my best idea I got
reminder to do X more damage in the roll, and a document link to roll a temp item that applies the health blockage
100%, I hate to have to do thing manually or remember them cuz I have a ton of other things to worry about lol. I'll def try those ideas tho, thank you again!
nah I don't fast forward, the reminders actually work with this setup
I just hate making temp items
can you make a document link of an item macro?
This is how mine is setup. Appreciate the help BTW. Now it's calculating the Temp HP correctly but damage is still NaN.
I am trying to make an active effect remove when the creature takes acid damage and it is not working and I do not know why? No errors
@violet meadow the fireshield in midi SRD, I feel like the item created should be set to 0 Reaction damaged instead of 0 Special
Could you edit the worldscript macro and add the following line under line 11:
console.log(damage);```
Refresh your page after doing so and screenshot your console after making an attack and getting the NaN issue.
Actually, check the box that says "Don't apply convenient effect" and see if that fixes it first.
edited, released, update and check again
do you know if theres an issue with the times up damage type special durations, I can't get any of them to end the ae?
Trying to automate Elemental Bane in my usual Janky fashion but It all hinges on controlling the once per turn by ending the ae when damaged by the type
and it just doesn't end
unless someones got their own proper elemental bane automation
Dnd5e 2.1.2 or not?
not
I'm rocking 2.0.3, dae 14, midi 24
I will say, I do have damage reduction of the same type, but its reverse, I'm putting bonus damage of the type on the target
thats why the damage equation in the image is weird
it recieves 7 bonus acid damage due to an active effect on it with a DR.Acid flag
I just tested with a very simple test and it still failed to remove I will find the culprit I guess
did you test with dnd5e 2.0.3/midi 24/dae 14?
nope but I would suggest to try ff/auto rolling the damage to test it out
I am on dnd5e 2.1.2 so no turning back now ๐
Yeah it works even when not autorolling damage ๐คท
My issue is though that it doesn't wait for the GM to accept and Apply damage when using NO + Damage Card.
Instead when the Acid damage is rolled, it deletes instantly
I auto apply damage
how else could I define the special duration I wonder
I could go full janky and just do the generic is damaged
it refreshes every combat turn via effect macro and has a duration of 1 turn, but fades after the first damage instance temporarily
to mimic once per turn bonus damage of a type
Hey @violet meadow do you remember this issue I had that you solved? I'm having the same issue (it's the same exact macro too) but now I have to do the same thing for the ability mod which I need to switch from lastArg.item.system.ability === "" to "int"
@vast bane My ATL QRG is now on the ATL Git's wiki! theres a link in this issue and if you have any feedback feel free to drop it there https://github.com/kandashi/Active-Token-Lighting/issues/115
Paste the macro you are using now for a reminder ๐
Yes just a second
Here it is
I thought of doing something of the like of:
if (args[0].macroPass === "preAttackRoll") {
if (lastArg.item.system.ability === "" && (lastArg.actor.system.abilities.dex.mod <= lastArg.actor.system.abilities.int.mod)) {
lastArg.item.system.ability = "int";
}
if (!lastArg.item.system.attackBonus.includes("@prof")) {
lastArg.item.system.attackBonus = lastArg.item.system.attackBonus === "" ? "@prof" : `${lastArg.item.system.attackBonus} + @prof`;
}
//setProperty(actor, "flags.midi-qol.ignoreNearbyFoes", true);
}
Like for the DC solution you gave me time ago, but in the case of the item consumption the ability mod for the damage doesn't change to "int" (it does for the attack)
Test quickly replacing the lastArg with this in the attached script
okay just a sec
nope, again it work (on consumption) with the attack but not for the damage
without consuming the item it works with both
Idk why it works for DC but not for damage?
you will need to update the damage before the item is consumed in order to have its data stored properly in the chat message. Its the chat message item data that is used for rolling damage on consumed (i.e. deleted) items
assigning values to the item directly, as in the script above, will not suffice
the DC is produced from the in-memory item data, as it still exists at the time of chat message creation
Ohh okay I see thanks
Is there a reason why the DC set by the macro is actually overwritten in the item itself then?
Because it doesn't do so with ability = "int", is it for the reason you just told me?
i dont quite follow...
where is the item being updated in the above script?
oh, DC computation -- you are giving it conflicting information -- you are saying "use DC from int", but then also trying to give it a flat DC
its one or the other, the DC is derived from a flat value, or your abilities
if (args[0].macroPass === "preSave") {
if (item.hasSave && item.getSaveDC() < actor.flags.dae?.alchemyDC) {
item.system.save.scaling = "flat";
item.system.save.dc = actor.flags.dae.alchemyDC;
}
return;
}
this overwrites the item DC but the linked macro doesn't overwrite the ability mod for the item to int, when checking the item after the roll the ability mod is still set to default
Assigning values without actually performing an update will never persist the data
Which is what I want in this case, but why it does persist with the DC
Could be any number of things, really
If you need to modify an item, you want to use 'update' with the data to change
However, you don't want to update item data inside a hook
Unless midi controls hook execution directly somehow
Because when the item is updated the data inside the workflow is discarded right?
It's an order of operations thing. Hooks don't wait for the operation to complete
So it may get latched properly, but maybe not
p.s. I tried using "preItemRoll" for this and now when the item is consumed it doesn't even change the attack
got it
doesn't work even if I update it
Actually, check the box that says "Don't apply convenient effect" and see if that fixes it first.
I did this and it didn't affect. The macro didn't execute. The dragon didn't take any damage and there was nothing in my "chat".
Hooks.on('midi-qol.RollComplete', async workflow => {
if (workflow.hitTargets.size != 1) return;
let targetToken = workflow.targets.first();
if (!targetToken) return;
let targetActor = targetToken.actor;
if (!targetActor) return;
let attackType = workflow.item.system.actionType;
if (!(attackType === 'mwak' || attackType === 'msak')) return;
let targetEffect = targetActor.effects.find(eff => eff.label === 'Armor of Agathys');
if (!targetEffect) return;
let damage = targetActor.flags.world?.spell?.aoa;
console.log(damage);
if (!damage) return;
let tempHP = targetActor.system.attributes.hp.temp;
if (tempHP === 0) await MidiQOL.socket().executeAsGM("removeEffects", {'actorUuid': targetActor.uuid, 'effects': [targetEffect.id]});
await MidiQOL.applyTokenDamage(
[
{
damage: damage,
type: 'cold'
}
],
damage,
new Set([workflow.token]),
null,
null
);
});```
Updated code (sorry didn't mean to send).
Here is console output: [#1010273821401555087 message](/guild/170995199584108546/channel/1010273821401555087/)
Also with the new macros I'm not using hooks, because they act weird as you said
well, the first line contradicts that ๐ , but also, i feel like im not actually that helpful due to this complex midi workflow going on
The way you use this, is by hooking at different phases onto the MidiQOL workflow and updating some variables of that.
No updates on the item take place
The first line is because the macro is called by flags.midi-qol.onUseMacroName idk if those are hooks too
I tried using setProperty too, but nothing changes
Foundry VTT | Retrieved and compiled template systems/dnd5e/templates/apps/ability-use.hbs foundry.js:6887:17
Foundry VTT | Rendering AbilityUseDialog foundry.js:5099:15
DEBUG | | _preUpdateActor | Logic (e/s) | <empty string> logger.js:4:17
Foundry VTT | Created ChatMessage with id [jTzg8Xrv6yX5ZnE2] commons.js:6946:20
Foundry VTT | Retrieved and compiled template templates/dice/tooltip.html foundry.js:6887:17
Foundry VTT | Retrieved and compiled template templates/dice/roll.html foundry.js:6887:17
HexBlade => Checking for Valid Attack Roll workflow.js line 1628 > Function:75:13
HexBlade => Armor of Agathys Invalid Attack Roll workflow.js line 1628 > Function:76:92
midi-qol | DmageRollComplete elapsed 22ms midi-qol.js:21:39
midi-qol | Ozadius Vanan 45 takes 0 reduced from 15 Temp HP 0 HP 45 midi-qol.js:21:39
DEBUG | | _preUpdateActor | Logic (e/s) | <empty string> logger.js:4:17
midi-qol | createGMReverseDamageCard elapsed: 92ms midi-qol.js:21:39
Foundry VTT | Created ChatMessage with id [cQzm0rBiSBFbYEkF] commons.js:6946:20
Foundry VTT | Created ChatMessage with id [9HTJFibAQNBcKNJa] commons.js:6946:20
Foundry VTT | Created ActiveEffect with id [yr876JAoG27CR07h] in parent Actor [0Uz5IQz6kjYxNbX6] commons.js:6946:20
dfreds-convenient-effects | Added effect Armor of Agathys to Ozadius Vanan - 0Uz5IQz6kjYxNbX6 logger.js:8:13
Foundry VTT | Unregistered callback for createMeasuredTemplate hook foundry.js:661:13
Foundry VTT | Registered callback for createMeasuredTemplate hook 2 foundry.js:610:13
Foundry VTT | Created ChatMessage with id [wBAQfqlOvRyuMaA1] commons.js:6946:20
Foundry VTT | Rendering ReactionDialog foundry.js:5099:15
Foundry VTT | Retrieved and compiled template modules/midi-qol/templates/dialog.html foundry.js:6887:17
midi-qol | Elder Brain Dragon Rolled a 31 to hit Ozadius's AC of 17 hitting midi-qol.js:21:39
midi-qol | Hidden removed for Elder Brain Dragon due to attack midi-qol.js:21:39
midi-qol | DmageRollComplete elapsed 17ms midi-qol.js:21:39
midi-qol | Ozadius Vanan 45 takes 14 reduced from 14 Temp HP 1 HP 45 midi-qol.js:21:39
DEBUG | | _preUpdateActor | Logic (e/s) | <empty string> logger.js:4:17
midi-qol | createGMReverseDamageCard elapsed: 53ms midi-qol.js:21:39
Foundry VTT | Unregistered callback for createMeasuredTemplate hook foundry.js:661:13
Foundry VTT | Created ChatMessage with id [73vTWzM9i3kVgcqy] commons.js:6946:20
@damage scripter.js line 29 > eval:12:13
midi-qol | Elder Brain Dragon 350 takes NaN reduced from NaN Temp HP 0 HP NaN midi-qol.js:21:39
DEBUG | | _preUpdateActor | Logic (e/s) | <empty string> logger.js:4:17
midi-qol | createGMReverseDamageCard elapsed: 28ms midi-qol.js:21:39
Foundry VTT | Created ChatMessage with id [xCOmPFRSKPro7KAy] commons.js:6946:20
Foundry VTT | Synchronized official game time in 14ms foundry.js:3133:13
Foundry VTT | Synchronized official game time in 11ms foundry.js:3133:13```
Can you send me over an export of the item with the macro on it (itemMacro?) so that I can take a look when I have time?
Yes just a minute
Hard to tell where the console.log is in there. I think it's showing up as @damage.
Acid, Basic is the item to test Potency with, and Potency is the feature with the ItemMacro in question
And if that's the case, I'm very confused.
@low trench Just to confirm, this is setup as a DAE on the item and not a convenient effect correct?
It won't work as a name matched CE.
thankyou, just testing it now but it does seem to work!
if (this.hitTargets.size != 1) return;
what does this mean though? Just curious why the size reference
Itโs the size if the array hitTargets, which represents the number of targets that were hit, because the array contains the list token of the targets that were hit
In this case there must be only one target hit otherwise it does nothing
Yep
I normally check that the set has only 1 target. 0 means nobody was hit and anything more than 1 means you accidently had too many people targeted with your attack
setProperty is just a helper for setting nested values in an object.
It isn't an asynchronous update.
ahh, I'd hoped that because this was being done using effects, it could be applied to multiple targets. I tried just removing that line but seems it only applies to one target (I assume the first in the 'list')
is it me or update doesn't work on items?
Your sword can hit multiple people with only one attack roll?
Uh... it's you.
it's a scythe, he has a sweep attack. It works like sword burst (its a dex save). Was just experimenting
Items are documents.
update is a method on documents.
If update is not a method on what you are attempting it on, then it is not a document.
Would need to rework part of it to work with dex saves, I was under the assumption it was an attack roll
I don't even know if Id allow him to use this ability while sweeping, I was just tinkering with the new macro
weird, maybe I have a syntax error somewhere then
Wouldn't be too hard of a change, just need to change it to use the failedSaves set and make sure the size isn't 0.
As well as change the effect application part to account for multiple targets
if its easy then it might be cool to have the option, but if its awkward then its already very good
I'll take a look at it again when I get a chance. About to head off to work so it'll be a bit
no rush, thankyou ๐
Just to clarify - The normal single-target attack is a normal attack roll (which works with the current macro great). I have a second copy of the item which is the 'sweep' attack, which works using dex save (its basically sword burst). I don't know if its possible to cover both variations in one macro, may need to be two different versions.
It could be done with one macro technically, just a check or two to see how the item is setup.
I'll leave it up to you, I hate to impose but I also want this feature to work smoothly as it'll hopefully be with the character for the rest of the game haha. But if its a pain then I can certainly live with the version I have now
Well, again, questions about the basic foundry are redirected to this module, because it turns out that this is the MidiQoL mechanics (I hope this is the right module). I'll just copy the question:
In the settings of the item / action in the "Target" field, you can set "5 feet - creatures", but then the effect will also affect the creature itself that caused it. Is there a way I can make it so that EVERYONE (not only enemies) around the creature that causes the effect, but not on itself, must make the saving throw? I mean, if you chose "creatures - 5 feet" on the Actor, and a saving throw, it will have to be roll by all the creatures around the Actor, and himself. And I want only the creatures around the Actor to make a saving throw, not him.
range = special
(this has tripped me up on many occasions)
(I've even asked this same question here before lol)
Okay this is really weird. Thank you!
glad I could help ๐
"Foundry" is the software, "dnd5e" is the system. Rider-interactions such as the one you were hoping for is from a module.
It's good to get a firm grip on what each of the former two components do before diving into modules that change the behaviour drastically.
I think most of us really just need for ATL keys to fix in dae
Is there an issue for it?
I'd make it, but I don't actually know how that magic is done
I think its complicated cause of how ATL's keys changed?
sure, wouldnt TPosney just need to be pointed to the new ones and update whatever does the autocomplete?
Yeah so probably like a document like your quick guide but with the highlighted changed keys
Hi, I am getting midiqol errors since the lates DnD5e Version update:
utils.js:359 Uncaught (in promise) TypeError: trait.concat is not a function
[Detected 1 package: midi-qol]
at getTraitMult (utils.js:359)
at applyTokenDamageMany (utils.js:671)
....
IIRC known issue, it's been reported
hm alright thanks :/ got multiple issues since the last update. had to stop our session tonight because the players kept crashing
MidiQOL version? Did you update to latest version? 10.0.25? And DAE 10.0.15?
midiqol version 10.0.25, dae version 10.0.15 yes
dnd5e version 2.1.2 and foundry version 10 Build 291
Is there a DAE effect flag to give strength proficiency? I didn't see anything obvious in midi qol flags in the dropdown
which is the option to see the AC in the chat message as GM? I cannot find it anymore and I remember that I could see the AC in the past.
As far as I know it's generally not recommended to use Active Effects for stuff that is essentially permanent.
well it's an item effect, while equiped they have proficiency. i found a way though, it just add's prof to strength saves
Pretty sure it's down as something like "check for hits" and then the option is "Players and GM" etc. It'll be workflow tab I imagine.
feature idea, the way he lets us drag items into the effect value of macro.createitem, make another one that lets you drag an item into item macro/folder macros and it creates the syntax needed for create synthetic items in it
I hope there isn't a DAE flag for this. Because there is a system flag for it.
Check the pins in #dnd5e
I had tried something for that which would make the JSON content of a dialog message ๐ฉ
๐
Problem there is that you get a lot of junk data along with it.
In the end you might as well just do toObject()
I'd settle for just a nice yummy example of what to put in a create item item macro full options of the item including an ae
sorta how wg wiki does it
or better yet, have the macro take the uuid of a createitem just ;like the dae does
You can just do that
so we can just literally make the faux item
That's 2 lines of code
I was looking into using ATE for some basic lighting stuff and I feel like there needs to be a big caveat attached to the documentation for this module. ATE will "revert" the instance of the token under an ATE effect to the prototype token. ATE will NOT revert a token instance to the token instance's settings it had pre-effect
2 lines I don't know ๐
you might as well be speaking french to me, I copy paste I don't know what all the stuff does
(1) get and declare item as variable
(2) create object of data from item
That last part is what you're saying you want
exactly that's why I dropped the experiment ๐คท
Implementing some drag-and-drop functionality, however, should not be too difficult.
Pointless
but not difficult
yeah but to what... --
Think anyone noticed you can drag and drop a banabi yet?
lol I think most have just scratched the surface ๐
Peasants ):<
and it was an "I will not fix" in the beginning ๐
It's true
but the DataModel I implemented made it a lot safer
Otherwise you could take an item babuna and drag it to an actor or effect or something, and things could get fucky
Now you can do that, and there's no reason to worry
I will take a look behind the scenes ๐
OK do you need steps for what exactly?
Getting an item, copying and giving it to another?
I have a homebrew paladin subclass with a channel divinity feature where you can select a weapon to get +CHA fire damage for the duration. Just the single weapon. I avoided Warp Gate for it by having the item (item macro) create an effect that has a bababi attached with a Custom Script filter to match item id. ๐คฃ
... with a VAE description. ๐
const item = await fromUuid("uuid");
const itemData = item.toObject();
await actor.createEmbeddedDocuments("Item", [itemData]);
cause without VAE one feels ... like that bugbear!
All my effects must have a description. That is the rule.
@vast bane
Any embedded item examples in there were almost certainly done by copying out the toObject data into the script and deleting unneeded lines
Sometimes I'll get fancy and diff it against an empty type to help with that
But meh
Hey all, I have been trouble with my rolling in foundry vtt. For some reason all my npc's are rolling disadvantage automatically and I do not know why. I asked this a couple of days ago but I do not think anyone was able to answer it so I figured I would try again
You got Better Rolls?
Nope just midi quol
Is it auto detecting range or something?
do you have any of these:
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
Advanced Spell Effects module is just dead in v10 and often the culprit of things..
none of those
Attacking long range.
Attacking with ranged weapons with enemies adjacent.
Effects that grant disadvantage on attacks.
Some ideas
or just a subtle effect flag with disadvantage on the actor
When I finish the session with my guys I will hop back on. I will double check but I think all the ranges are correct and lighting
can you show us what the attack looks like in chat, and then the actor who is rolling dis, show us their effects tab
oh also the player could have a sticky ctrl/alt key
Anyone with 2.0.3 dnd5e, midi 24, and dae 14 feel like quickly testing something for me?
*and times up
embedded: {
Item: {
"Multiattack": {name: `Multiattack (${Math.floor(level / 2)} attacks)`},
"Maul": {"system.attackBonus": `${msattack} + ${mod} - 4`, "system.damage.parts": [[`1d8 + 4 + ${level}`, "piercing"]]},
"Breath Weapon": {"save": { "ability": "dex", "dc": spelldc, "scaling": "flat"}```
I'm trying to change an item that has a flat saving throw that uses the spell save DC defined as
```js
const spelldc = actor.system.attributes.spelldc;```
How would I format that?
You can look at an item in console to help figure out the formatting
How do I do thhat?
make an item how you want it then:
console.log(game.items.getName('Name Here'))```
or export the the item, it's the same structure
and the spiritual badger has an example of this: https://github.com/trioderegion/warpgate/wiki/Summon-Spiritual-Badger - note: data -> system
(at the bottom, the Intimidate item)
Updated the original code.
does args[0].workflow have a field where the data about whether or not the consume option was toggled? (if the item is a consumable)
You can check how many uses it has left
If it's 0 and it has a limit of 1 you would know.
does it change to zero when it's about to get deleted? (I'm using destroy on empty)
Not sure actually, the item should exist at least until the workflow is done
You could have the macro delete the item instead of relying on destroy on empty if it's not working
this.item.delete()
Yeah I'm having problems because if you update the item while in the workflow the data in the workflow gets overwritten and it's a bit of a mess
I really prefer leaving the choice to the user
yea, makes sense
Yes! quantity is set to 0! That's super useful! Thank you so much
omg it works you have no idea how much it changed everything having quantity 0
Any idea why the ddb booming blade macro would wear off after 6 real-time seconds or so?
It's all working well otherwise
Does anyone know of a way to execute an ItemMacro when an item is rolled before the midi workflow starts?
In combat, it's happening about 6 real seconds and wears off the enemy before I can even end turn
If the enemy quickly moves they proc the damage successfully, it's just the effect duration is weird.
Check your time settings
sounds like your game clock is moving in combat when it shouldn't be
also they probably should consider installing times up/sc
cause doesn't DAE stop this from happening when those modules exist?
Makes sense
times up module adds a plethora of special durations in DAE that you really want
5E needs many more modules to have parity with PF2E
they are really yummy for automation
I'll install it, I've been using combat ready for timer and it sounds like it handles similar aspects?
thats cause the creators of the two different systems have very radical design paths for them
dnd5e is low automation, PF is high automation
times up is I think what causes ae's to expire and delete?
but we all use it for those special durations most of all
I installed it, cheers
If the modules existed, I'd probably switch to Pf2e instead. Seems like a good system. I'm not sure I could do without midi though
My world module list for PF2E is tiny compared to 5e
Amen, all hail Tposney our lord and savior 8)
is that because you don't need any modules, or is it because the modules you'd want don't exist? That's the burning question
The former, the design choice for PF2E is to bake it all in it seems
interesting. I'll keep it in mind. The next non-dnd game I plan to try and GM is scum&villainy but I'll do a pf2e one day
I'm getting this error, but I'm not seeing any differences between the items in the actor and the code. Is anyone willing to help take a look at this with a fresher pair of eyes than mine? ๐
It's also not deleting/modifying any items.
I'm doing a dnd5e conversion of battletech but its a slow go, I need dnd5e 2.1.2 to fix its issues iwth all the fun modules
well vice versa, I need the fun modules to fix
is the actor linked
Nope
then you misspelled a feature
I've gone through all the features. They all seem to be spelled correctly
Unrelated, but you should avoid using anything starting with _ when you can.
Your first line is getting an ID weirdly
there is no multiattack on the sheet
You can just get the actor with this.actor or args[0].actor
THAT was it
We could really use this pinned here Moderators?
Tim does not put his old packages out as normal, and right now midi users have to constantly go dig out the 24 zip here
v10 compatible MIDI-QOL back versions
https://gitlab.com/tposney/midi-qol/-/tree/v10/package
I have a "to hit" attack that has a saving throw to avoid additional effects
On hit, the saving throw is checked as usual and the effect is not applied on a save and is applied on fail.
however, the effect is also applied on a miss with no save.
Checking "Full Dam Save" is what changes the behavior and I'd prefer to have it on since I want the attack to deal full damage on hit.
Is there a way to not apply the effect on miss with this option checked?
oop, asked too soon maybe. Activation Condition true required for effect activation sounds like the right direction, but I have no idea what to put in activation condition
Can I post Midi troubleeshooting in here?
we devour such things as we live for that ๐
I was about to say I just did without asking my b
Ok I'm using the Midi spells and faerie fire is one of them. When I go to cast the spell everything works as intend except for this:
I keep getting this error. I think it is in the Effects in the spell and I tried to modify them but no luck
do you have any modules with yellow triangles that have a number less than 10 or no number at all in the manage modules window?
sorry to interrupt the above.
The solution was just "onHit" in activation condition if this comes up again.
a blank activiation field evaluates true
onHit I think would only evaluate true on hit, but thats not really needed I don't think
I didn't think it would be, but the effect is applying on miss without it
that does not sound like midi at all
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
Advanced Spell Effects module is just dead in v10 and often the culprit of things...
it's only when "Full Dam Save" is checked
I have none of those modules
would not be surprised it it's compatibility issues with other things though, I run a lot of modules and I'm aware of the issues it causes, working around them is something I welcome
but It's 100% functional as is
I'm using dnd 2.0.3 and yes from midi srd.
I think the issue is in here:
I can replicate this, confirming for now before I patch bugbear into this
not sure if this is a midi srd bug or an ATE bug
Ok when I use ATL the effect applies properly.
When I use the spell (which is what my player will be doing) it doesn't. How do I put an ATL effect into a spell?
I have the spell in my Items list from the import
Sorry not ATL
@violet meadow Tested with the v9 and v10 versions of midi srd's faerie fire, it seems something is wrong with it
the macro needs to be v10 ified and its not a stored macro in his module
I think this is a simple fix but its gonna need bugbear, normally midi srd macros are centrally located in midi srd's files, but faerie fire seems to have its macro outside and wasn't updated for v10 yet, and the errors don't have shims, so thats why we see the red errors.
we actually should see shims for this spell when we cast it, I'm guessing the red errors stop the macro from launching
cause t heres a bunch of datas in the macro that should be systems or yeeted
Here is what Convinent effects Faerie Fire effects look like.
macro is too large to share here efficiently but I'm sure he'll take a look when he can
Could I just copy that into the spell
I would grab the dnd5e version
not the midi srd one
and then drag and drop the CE onto it
but it won't be as good as midi srds
it looks like midi srd queries for the color of the light for the caster
yeah i'd normally yeet and fix a macro like this but this ones got some weird stuff in it
Oh that one is a blast from the past. Quite the old macro included in that Faerie Fire spell from the Midi-SRD Spells compendium!
I was tempted to start replacing datas but theres a few I've never seen before in that one
For now I'm going to use what I did because it works, but let me know when you fix and then I can apply that to my game. Thanks for the help and support! ๐
Ok I think I will work on the midi srd included items to update them for v10 MidiQOL, in small batches
p.s. I found the solution in the end
is there an effect flag for increasing the size of a token temporarily? I found system.traits.dimensions but it seems to be broken as it disappears when its on a character
I saw something earlier with the quantities
Do you have the ATL\ATE module?
i do
ahha
though... that seems not to work
ah my bad, I was using 'custom' not 'override'
thanks, works a treat
Soโฆ
I am starting a new Dragonlance campaign. And in it the draconianโs uniquely explode when they die. Is there a way to do that with tokens? I know there is with tiles.
Depends on how automated you want
I would just do a feature for it and roll it when they hit 0 hp
But you could have an effect that is set to get removed upon reaching 0 hp then have an effect macro roll the feature
give it a fancy sequencer effect and call it a day
I was looking for a spike growth macro, is this actually part of a module or in a compendium somehwere?
https://github.com/chrisk123999/foundry-macros/tree/main/Spells/Spike Growth
Pretty much most of my stuff is on my GitHub. I've been slacking on documentation however.
I see the "hit or miss" in the chatmessage but the target's AC is gone. I remember that the target AC was there in the past.
I swear I'm slowly but surely alerting you to them lol
Yeah that was part of it yes
Anybody happen to have a Defensive Flourish macro on hand? Tried a few ones I found, but none seem updated to current version of 5e and throw errors
swords bard feature?
Its basically smite using bardic resources
that is going to depend entirely on if the group fast forwards, and if the bard loves having "Do you want to defensive flourish?" on every.single.attack.they.make
I just want it as a separate feature he can roll when needed that rolls bardic inspiration die + applies AC bonus ๐
I would personally handle it in an advantage reminder cause I don't fast forward, cause you choose the feature after you see you hit, before you see you roll damage.
if you fast forward, you will have to use optional.name.macro
that is doable, what is the issue?
movement.all has to be custom or dae won't pick it up. Putting a simple value in the all field should override the current value and +value/-value will add/subtract from the current non-zero value. movement.hover is a boolean value and so to make sure it is true/false its a custom field.
That doesn't even need midi to do
I'm just sure how to set it up with rolling a scale dice + applying the AC number from the roll
yeah bugbear gave me the run down on how to override with a custom a lil later on, I appreciate your response too though.
put the scale formula as damage.
Create a DAE (apply effect to self when Item is rolled) that will give a system.attributes.ac.bonus | ADD | @damage
I feel like the term "When in rome" should apply here
What you have looks ok to me (and seems the same as the regenerate sample item) - I just tested the midi regen in 2.1.2 and it seems to be working ok. Make sure the regenerating actor is in combat
So, it works, sort of, when an actor casts that item effect onto another actor it does not work, UNLESS the caster themself is damaged and also effected by the same effect. Not sure why, they are in combat as well.
idk if you could send a screenshot or something, I would love copy lol.
Ok, if being applied to a different actor, replace the @ with ##. When you use @ it is evaluated when the effect is applied using the values from the actor applying the effect, ## means defer the evaluation until checking on the target actor.
That worked wonders, thank you! ๐
Midi not required, but dae is for movement.all
Different conversation
(probably Zhell's comment was directed to Arteroc's comment)
I keep forgetting this very specific mechanic with dae constantly
I happily admit to not knowing what exactly interacts with what! Will need to sit down and look at it some day I don't have a 60h workweek :/
Your right! It works! Thank you so much for the help! @gilded yacht @vast bane !!
did we actually solve the defensive flourish question yet?
I can think of like 5 ways to do it all depending on the various levels of automation the user wants
Also I think MASIF has the maneuver version in it
I'm keeping it simple, otherwise the risk is I'll have to come screaming for help when I inevitably break it ^^
that's the spirit ๐ช
I do want to learn more of how to do things, but life keeps annoyingly getting in my way
if you don't fast forward, you could put the DAE ac active effect as a document link in the advantage reminder, and then if dae's inline rolls is on, the dm can just right click the inline roll and apply damage to the victim
ever since MASIF got the v10 update I've been badly wanting to use a battlemaster in dnd5e, so I am totally inserting one into the players campaign as a ride along npc lol
Okay, So i have spent the better part of six hours trying to make an automated rage for one of my player's barbarians. I've watched tons of videos and looked through threads and so far, I just cannot figure it out. would anyone be able to give some advice?
Midi should have a compendium with a rage feature, you can use that or if you want you can use it as reference
man you are not going to like how simple the answer is for you
generic rage is in midi sample items just drag it to the sheet
I've tried that but still haven't been really able to get it to work. So i'm guessing there are some other problems in play
it wil work perfectly if your barbarian is setup right
you need to clarify "still haven't been reall able to get it to work"
what wouldn't be working about the midi sample item
is the barbarian rage efect on them?
Adding bonus damage to rolls and automatic advantage to str checks and saving throws
I see in another channel that you are playtesting dnd5e 2.1.2 for the rest of us, make sure you are on midi 10.0.25 and dae 10.0.15
show us what an attack looks like in chat for the barbarian while hes raging
also confirm that you do not have the vanilla dnd5e rage still on the sheet that you are confusing with the midi sample item
and finally, do you have dfreds CE installed?
I think we need to confirm that you are actually using the midi sample item and not the gifted dnd5e advancement one
well shite. I might just be a dumbass lmao one sec
I actually think the dnd5e one should do the damage bonus
cause isn't the damge bonus a system key guys?
yep it does do the bous damage but not the same way midi's does
you also need to make sure your barbarian has a proper barbarian class so that the scale modifier works
Hmmm, still not getting that extra damage I think. Any specific settings I need to do for the class? I'm guessing I might have some conflicting mods
or wrong settings
startmenu key+shift+S should pull up the snippet tool in windows 8.1+ OS
then you can ctrl V the image made with it into here
show us what the attack looks like in chat, and also show us the effect tab of the Actor that is the barbarian, as well as the effect tab of the Rage Feature
Wait, I think i got it. There was a mod conflict
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
Advanced Spell Effects module is just dead in v10 and often the culprit of things...
I was contemplating leading with this copy and paste but I gave you the benefit of doubt lol
haha, whelp, I appreciate it ๐คฃ I can't believe I missed that
I had caught WIRE earlier. I think I had just been looking into it so much that I completely forgot to re-check compatibility
so you had wire, midi and ready set roll enabled together oof
I now understand why my brain was breaking
most rollers do not like each other, they are quite divas, a few in my list though are designed to work together(Roll groups/fast rolling by default)
I don't recall if roll groups/FRD are ok with retroactive advantage @molten solar ?
Same dev dude
I wonder if there is a case where a dev made modules that don't work with each other hehe
@gilded yacht in your change log do you mean that you fixed 26 so it is ok with 2.0.3 users?
or is it still advised to stay on 24 for 2.0.3 users?
Update it Moto! I think it should be fine now. Just a quick test ๐
I can't update 2.0.3 yet, too many breakages still
I might have to live for a while on 2.0.3 as my players really really really like inventory+
resources+ and MTB I think might still have issues, just waiting on the next MTB release, he releases on schedules
Putting this here. I think this could be a good case for these effects triggering a generic Item creation macro which when used will just clear the effect.
Like Effect "Your pants are on Fire", which when applied will also create an action which will be "I drop my pants" to end the effect!
whoa....I kinda love this idea
I mean just update MidiQOL to try it it out.
Not the dnd5e
v9 unfortunately but still
I doubt dae in v9 works with macro.create right?
Have you checked out Custom Character Sheet Sections Moto?
nope
I'm trying to make a similar thing - a Burning condition, character is burning until they spend an action to roll on the ground or something.
so would have to go warpgate or createdocument
briefly I have, I had issues following its readme at the time, and when I did check it out I was still on v9 at the time, I should revisit it now though honestly now that I have a much stronger grasp of stuff
but ultimately I think tim has fixed all my gripes with item collection so its probably a better solution
just cause my players have already used it
Fair enough
I got a table thats pretty badly scarred from roll20 disasters so I wanna try and avoid drastic changes
CCSS is very user friendly, similar to Inv+ IMO. Item Collection is a bit... different.
But if they already know it, play on.
So the issue I got with this is that I am not using v9 any more and my memory of it gets more hazy by the minute
the only issues we had with item collection was how it didn't play well with item piles for trading, and also the wonkiness of splitting out items. I think he fixed the latter, but not the former
I'm trying to do it right now but I can't seem to find OverTime in Attribute Keys.
it won't be in calego's post it will however be in the readme for midiqol
and honestly, the readme for midi is the best source for overtime
actionSave is only available in v10 fyi
I'm totally making a template item for action removals now bugbear
You can basically use the same action for them all
just keep attaching more "remove X" to them
flags.midi-qol.OverTime | Override | turn=end, damageRoll=1d4[fire]
At the end of the turn do 1d4 fire damage
if they declare usign their action, just remove the effect before the end of their turn
If they "take" an action, just delete it manually
if you had actionSave in v10 on it, it would auto detect that no action was rolled and remove the effect
It works, thanks!
or am I mistaken how that works, I forget now, does it prompt and you say yes and its removed?
If true, Midi just waits for the player to roll a Save of the correct type and then potentially remove it
If false, it will autoRoll the save part of the OT
Is there a way using DAE or whatnot to call a macro when an ActiveEffect is deleted?
maybe with args[0] === "off" or something I guess
Either inside the if (args[0]==="off") {//do macro stuff with const lastArg = args.at(-1) available} or by using Effect Macro module, to add a script on the On Effect Deletion trigger
if I use macro.itemMacro and inside the item macro I put if (args[0]==="off") does that work?
indeed it does
Okay ty!
a few midi srd items do this btw
look to items in midi srd that create items
you can also use effect macro to do this too with his on delete/on creation triggers.
thanks!
from a Active Effect macro.execute can I execute an ItemMacro?
I think its wise to use macro.itemmacro or whatever can't remember if two or one M's
The problem is that the active effect is created by another macro and when I try to do that it says that it could find it
Effect macro might be a good method to accomplish what you are doing
Look at Item Macro's readme for how to call an item macro explicitly.
okay ty
I'll look into it
I have a use case for an effect macro that applies another effect fwiw
I utilize dfreds CE to pull it off
I use this in an effort to pull off once per turn stuff cause Effect macro has a trigger for each turn while dae only has owners turn
it's just that the less module dependant I am the better
So if there's a way without using another module it's worth a try
EM is a very strong module for midi shenanigans, highly recommend, plus you can avoid reinventing the wheel if you yoink premade stuff others have made here, often using both dae/EM
I'll think about it
You know, now that all the usual modules are utilizing castData I'm wondering if its possible to automate dispel magic when targetting a token now
Though I think dfreds may not be utilizing it properly yet
You didn't do that yet?
That was literally what got that whole conversation started
No I have a skill challenge version but nothing that pulls the data
Yeah I know, I haven't gotten around to it but I'm currently making a few caster npcs and its finally gotten my attention
at the time, nobody was doing it yet so I couldn't just make the item on future knowledge, but I think we still need Dfred to buy into it
I don't think CE's have castData
or atleast they don't have the level
actually I think...I have a conflict OR a rules question about this
if you upcast a spell that just changes target count, is the spell still level 1 for a dispel check?
If I upcast Bane to 5 to bane many targets, is it a dc 15 check or is it still auto dispelled?
Can warpgate.mutate return the reference of the item it created in anyway?
Also Dfred is all set, I have confirmed that Midi handles the castData on a dfreds CE:
or the uuid anything
I would argue that it is a 5th level spell
me too, now its just a matter of making the macro for dispel magic
hmmm, wonder if all effects have castData though
judging by the concentration status marker, they do not
You can search the effects for the ones with castData in the MidiQOL flags and go from there.
hmmm this would require smarter people than I, first you'd have to auto dispel the level 3 or lesses, and then check the rest against the result of a spellcasting check of (Result - 10)
https://trioderegion.github.io/warpgate/warpgate.html
Check the API documentation. It returns the mutationData
Returns:
The mutation stack entry produced by this mutation, if they are tracked (i.e. not permanent).Type Promise.<(MutationData|false)>
So probably an If statement for castLevel and do one task for 3 or less, and another task for 4 or higher
ugh but then if you upcast.....yeah this is beyond me
And from mutationData can I get some info of the item?
Using console.log it says that it returns a promise
const effectLevel = /* declare targeted actor's effect's level somehow */;
const use = await item.use();
if(!use) return;
const dispelLevel = use.flags.dnd5e?.use?.spellLevel; // requires dnd5e 2.1.x
if(effectLevel <= dispelLevel) /* delete the effect */
else /* roll ability check */
await
does it mutate something?
๐ญ 2.1.x Soon!
Random Question How do I make someone take half healing?
I think I can use midi for dispellevel
try something ez like ```js
let mutation = await warpgate.mutate(token.document, {token: {name:"LOLOL"}})
console.log(mutation)
I think it's undefined yes
sall right, you can do it before 2.1.x, too. Just create an html element, add the card's html as innerHTML and--
You think?
Sorry no I meant "I don't think it's undefined"
Well you gotta confirm it then
there is one catch to your macro zhell, if you dispel magic on a creature, no matter what your roll is, anything 3 or less dispells regardless of the roll. The roll is only made against any spell above the level of the dispel cast
It does print something in this case
It's pseudocode, and that looks like what it does?
I am out... I started refactoring the code for the module I am working on, but now ended up re-writing everything... ๐ญ
I blame Moto and Zhell
not MidiSRD
not directly, but how are you creating the item with mutate in the first place? likely its just a actor.items.getName('the name you used to create')
Hey, I am working on a Status effect and I am trying to make that Status effect have half healing done to that creature. What's the thing I need to put to make that happen?
I do this btw:
const updates = {embedded: {Item: {[itemEffect.name]: itemEffect}}};
return_of_warpgate = await warpgate.mutate(target.document, updates, {}, {
'permanent': false,
'name': effectInfo.mutationName,
'description': 'D.O.T.',
'overrides': {
'alwaysAccept': true
}
});
yea, grabbing the result with target.actor.items.getName(itemEffect.name) should do it
oh, and you dont need to store the return:
await warpgate.mutate(target.document,
Makes sense that it cannot return the created items, due to sockets.
serializable data only, unfortunately, due to the indeterminate execution client
Ah I've remembered, idk if I can, because the item it's inside the target
Now how I can I make it that status effect make hits auto crit?
yea, its no problem -- anyone can read basically anything
Okay great thx!
pretty sure I made this let me go look at my beacon of hope
Oh I went cheap with that, sorry I can't help you unless you settle for an advantage reminder lol:
theres a circle of Mortality premade here that auto maximizes heals made on targets with 0 hp, its really wonky but if you wanted it, thats probably where you'd find it
No No
That is my bad for not explaining
I am making a status effect Called Scorched
all damage applied while under its effects is maximized?
Since they are onfire I made it that they take reduced healing and whenever they get hit they take crits
oh
thats easy
theres a midi flag for grant critical
hmmm, now you got me pondering reworking Beacon of Hope with that flag instead lol
instead of max heals, double the dice...tempting
Yeah, it never ends
But that is what makes this fun
Oh crap! That works
This place makes things soooo much easier
Now that's a good question. What's the reason for double dice for crits instead of Full damage like before?
When I try to get it, it says that's undefined
pretty sure rules as written, crits double the dice not max the dice
I've tried to place all the await I can but it's still undefined
yes, But it used to be in 4 e that crits did max the dice. So they changed it to double the dice which is still cool but sucks if that double dice is well
lol
I doubt just slapping in await waits for the actual item to be created ๐ค
2 ones
you may need to put the item retrieval in the post callback for mutate, that way warpgate will wait for the confirmation event before executing your lookup
Missed opportunity to say, "just do it in post."
normaly one could suggest the alternate crit rules in system/midi, but I think when it comes to those, they max the wrong dice
And how do I set that up sorry? Just PostMutate (same stuff I had in mutate) ?
Ohh okay ty so much
its true that I can do that, but I was wondering what the logic was. I haven't done Dming in a while and these are questions so I can understand game design
Like I am building a bird race in the future that will fly and I want them to fly. But this is a species of metal workers. So I don't know mechanically how to make them fly and still wear metal without it being broken
Stuff like that So I can make the thing do the thing and feel cool without breaking the game
I know DMs are scared of flight, but I accept the challenge
lol
#tabletop-discussion is a great place for such queries
Oh thanks. I will add that to my list. That is a future thing, but that helps to know now
Sorry I really don't understand how to set it up, like await warpgate.mutate(target.document, updates, {post: PostMutate(target.document, updates)}, {}); ?
the PostMutate name is just a data type that represents a function of the form
async (tokenDoc, updates) => { return /* Promise|undefined */ }
so create an async function that takes at least the tokenDoc argument
then inside the function, look up your item with tokenDoc.actor.items.getName
does that PostMutate entry in the API docs make more sense now?
its a very common pattern for all of warpgate's callbacks
Yes a bit, I just wasn't expecting it to be intended as you put your awaited function here
But now I do see it
๐ great, it'll take some practice, but warpgate really loves passing around arbitrary functions
allows you to get really deep inside warpgate's workflow
can the function be an actual function myFunction() {} ?
Yeah warpgate is very powerful, a bit scary at first but I'll learn bit by bit
also how do I return a promise?
you generally dont have to concern yourself with it if you are awaiting your calls inside the callback
Now the Next part of my Challenge of Riddles. I am making a status effect called Weaknen. It has to parts. The first part is creatures that are Weakened deal half damage. How do I do that?
(i.e. javascript will return an empty promise from all async functions by default)
I mean what's the code for that?
I would just make the targets strength and/or dex mods -1
I did this but function_creatingEffect doesn't get called
await warpgate.mutate(target.document, updates, async (tokenDoc, updates) => {
await function_creatingEffect(tokenDoc.actor.uuid, searchString, effectInfo);
return /* Promise|undefined */
}, {});
I am reading and I am assuming that damage bonus only effects the bonus and not the damage itself
Okay it works, ty for your patience, sorry if I'm a bit dense at times
and max is only the max damage that can happen
you just worked through some of the more complicated stuff in WG, so pat yourself on the back ๐
You're very nice ty ๐ฅบ
could you use OVERRIDE to override the damage of the weapon with the damage bonus key?
How does that work?
Sorry, my brain really doesn't understand code which sucks for our code based world
it doesn't trigger when the effect is deleted for some reason
Are you using DAE or EM?
DAE
What is the exact creature type you do to cause a creature to be ignored by midi? notarget?
found it:
#1010273821401555087 message
Hey all, This is for 5e - I got my hands on an older macro that works with the magic items module. It should allow the player to click the item and be given the list of spells that are attached to the magic item (instead of having to go to the spell book). I'm a total newb at macros, so I'm in need of some direction. I need to understand what is missing (like entering the name of the item, or the attaches spells) or if this macro is out of date and simply won't work for my purposes.
"'// Midi-qol On use
let itemD = args[0].item;
let spellList = "";
let spell_items = Object.values(itemD.flags.magicitems.spells).sort((a,b) => a.name < b.name ? -1 : 1);
for(let i = 0; i < spell_items.length; i++) {
let item = spell_items[i];
spellList += <option value="${item.name}">${item.name}</option>;
}
new Dialog({
title: ${itemD.name},
content: <form><p>Pick a spell to cast</p><div class="form-group"><label for="weapons">Listed Spells</label><select id="spells">${spellList}</select></div></form>,
buttons: {
cast: { label: "Cast", callback: async (html) => {
let get_spell = await html.find('#spells')[0].value;
await MagicItems.roll(itemD.name, get_spell);
}}
}
}).render(true);'"
sigh, sorry about the formatting
first offf when sharing macros do this:
```js
code here
```
Secondly, Magic Items Module is pretty much dead in v10 at this point, specially with dnd5e 2.1.2,
Items With Spells module is the go to module now. And ditch the actual MIM items before you swap over as they have nasty data in them that break in dnd5e 2.1.2 I think.
Items with Spells will do stuff like this:(the moss green stuff)
