#MidiQOL

1 messages · Page 109 of 1

scarlet stump
#

ah that should be enough, thanks

vast bane
#

If that doesn't work I can check in about 20 minutes for a solution otherwise but I'm hoping thats it

scarlet stump
#

thanks, it works now!

oak mulch
#

Question: Where should I go into the settings to apply one Active Effect automatically instead of having to press the "Apply Active Effects" in chat?
Also Is there a way to make one Effect to force a restriction on, let's say, player movement?
The thing is that I'm trying to cast Hold Person, but unless I press Apply Active Effects on chat it doesn't pop the status on enemy token, and even if that goes on the objective (a player) can still move with the condition.
I'm working with dfred, midi, and DAE.

vast bane
opaque current
#

It's in the Workflow tab

oak mulch
#

If those are modules, no one of those on

opaque current
vast bane
oak mulch
#

yeah, that's what I'm using

vast bane
#

when you apply grappled and restrained with a properly setup dfreds CE, the drag ruler will alert the user to a red movement bar

oak mulch
#

but even if the AE on MIDI SRD restricts the movement, player still can move

opaque current
#

You can have it set their movement to 0, but it doesn't physically prevent movement

vast bane
#

show me the actors effect tab who has it on them

oak mulch
vast bane
#

oh...good point

#

edit the paralyzed and show us the effect tab

#

does paralyzed really not have a movement key in it?

oak mulch
vast bane
oak mulch
vast bane
#

also fyi that second drop down is bad, set it to ae before ce

#

change the second drop down to ae before ce

#

in the previous image

#

If you always get the button in chat with the setting you just showed us, you don't have late targetting enabled and are not targetting anyone. And if that is not the case, you got a module I told you to check for

oak mulch
vast bane
#

you aren't targetting anyone when you cast spells

oak mulch
#

which option should I go with

vast bane
#

that doesn't matter

#

you are seeing the button in chat because you have no target

oak mulch
vast bane
#

do you fast forward or do you like having the advantage/normal/disadvantage popout and crit/normal popout for damage?

oak mulch
#

I like having the advantage option

vast bane
#

you see both popouts during the attack workflow?

oak mulch
#

Yep, attack and damage

vast bane
#

go to workflow button, misc tab, and export your midi settings and keep them somewhere safe

#

If those work then you had your settings too loose for automation. Work backwards from my settings undoing the things you don't like one at a time

#

though my settings are similar to yours.

#

Drag ruler should be red when that actor is paralyzed btw, it doesn't stop them from moving but the measure tool should be red to alert everyone they shouldn't be moving

oak mulch
#

Ok, i've loaded yours, but now it does not display chat message to apply active effects but it doesn't apply effects

#

Manually aplying paralyzed, ruler is red. But hold person does not apply it 🤔

#

I've sent you a Video on DM

vast bane
#

Very weird. Its not a problem for you, its a problem for tposney. I just confirmed now, infact midi 41 the button is no longer clearing, not sure if this is a new design choice, but either way the setting in specials is now misleading as midi never removes the button now.

oak mulch
#

SO the only way is to press that button in chat? Can't do automatically?

vast bane
oak mulch
#

No worries ^^ You are helping so much, I don't complain at all ^^

#

And i've been taking a look at your settings and i'm gonna take those for me 🙂

#

So if at the end of the day i have to press the button on chat to apply the effect, and cant do automatically, it has been totally worth

vast bane
#

show me the spell hold persons, effect tab on the caster

#

edit the spell, effct tab, edit effect, show me the third tab of the effect

#

no you don't have to press apply active effect, its only there due to a bug, your spells aren't transferring and I suspect its because dfreds is bad/not setup

oak mulch
vast bane
#

press f12 and pull up the console and then cast the spell again and share any red errors here

oak mulch
vast bane
#

show me the specials section in workflow tab/workflow button, I assume you have my settings but lets just make sure

oak mulch
oak mulch
#

not sure if that's what you asked for

vast bane
oak mulch
violet meadow
#

I ll take a look tomorrow cause I am away till late tonight 😅

#

Thought the origin would take care of it

vast bane
#

You guys aren't gonna believe what the problem was for Lyss lol, its a good'n

#

Apparently Hold Person only works on persons

#

and I made them test against starter heroes who are not persons

#

I'm guessing midi srd's hold person has a better check for player character races? if not thats probably an issue

violet meadow
#

Persons you mean player characters?

#

Vs NPCs? Or something else?

vast bane
coarse mesa
#

They’re not humanoids?

opaque current
#

Hold Person wouldn't work on ye mum, because she's not a humanoid

#

Burn

vast bane
weak quest
oak mulch
violet meadow
short aurora
#

The proper activation condition for that is a filter nightmare in dnd5e

vast bane
#

let me guess, every race?

short aurora
#

Yeah, I can't think of a better way that catches all edge cases - all of them being player related tbh, maybe just always affect players and reinforce anti-player bias™

vast bane
#

can the condition check for player character sheet?

#

My thought was to just not give monsters the player version

#

let dfreds CE apply

static sparrow
#

The “correct” thing is probably for the 5e system to give player characters a creature type.

torpid kestrel
#

I am using the midiqol house rule for disadvantage when shooting into combat. I have a feat which would remove this penalty. Does anyone know if there is a way to turn this penalty off for a given token without the player needing to manually turn on advantage to offset the disadvantage?

opaque current
#

Wait that actually is for ignoring range penalty

#

You need flags.midi-qol.ignoreNearbyFoes

torpid kestrel
#

I saw that, but I guess I assumed that was for shooting out of combat, not shooting into combat

opaque current
#

It's not so much about out or in - normally you get disadvantage on ranged attacks if an enemy is next to you, regardless of if you shoot someone nearby or far away

#

However if your scenario is for shooting into a melee, when the shooter is far away on their own, then IDK

torpid kestrel
#

fair enough

opaque current
#

But the 2nd flag I posted is the standard for "Crossbow Expert" and the like

vast bane
#

theres cover, I wasn't aware of disadvantage when your allies are engaged with stuff

#

ooooh ok I get the comment now

#

reading is fundamental man

opaque current
#

And yet, so hard

vast bane
#

For me what they typed sounded like the cover rules to me

opaque current
#

Well there is certainly flags for ignoring cover

vast bane
#

isn't there also a variant rule for shooting someone engaged with an ally?

short aurora
#

Midi has that house rule? I thought it only had what monkeyy wrote how to against

torpid kestrel
#

I was fairly pumped to see it, because it duplicated a house rule we've used with pnp for decades, but not being able to shut off the automation is troublesome

vast bane
#

I think I saw it in the dmg or something, I don't know how midi would implement it

torpid kestrel
#

yes in house rule section.

vast bane
#

I'm sure you can automate this in midi, we already do the opposite

torpid kestrel
#

Seems to work perfectly - just stuck on how to shut it off situationally

opaque current
#

This is the kind of stuff that personally I don't have automated, and do manually

vast bane
#

pack tactics is the opposite

#

if I'm taking about what you guys are atleast lol

opaque current
#

Yeah here it is in the readme (House Rule) Ranged attacks at foes with nearby allies have disadvantage If making a ranged attack at a target whose size is less than that specified and there is an ally within 5 feet of the target the ranged attack is made with disadvantage. (You want to avoid hitting your friends but really big targets can still be hit safely).

torpid kestrel
#

Was hoping there was a flag for that which I just hadn't found

#

BTW I really really like that rule

vast bane
#

I was thinkin of this house rule:

opaque current
#

Well if you ask tposney nicely he might add a flag for it.

torpid kestrel
#

🙂

vast bane
#

am I going crazy or what, I swear to god there was a published variant rule for disadvantage if an ally is within 5ft of a target

#

oh jeez, its an actual midi optional lol

#

Here I am digging through the books

fast thistle
#

Hi all! Using MidiQoL with 5e rules. For some reason when clicking on spell names like attached, no one, including DM, gets an expanded description of the spell on the chat card. Any ideas which settings in MidiQoL I can tweak to fix this?

opaque current
vast bane
fast thistle
#

Nope, nothing happens on click.

vast bane
#

that image is triggering me though. How do you have advanced hide settings but all automation off?

#

monkeyy's setting is your solution

fast thistle
opaque current
#

Indeed, no backdating.

fast thistle
#

Perfect, thanks so much!

violet meadow
#

If I remember correctly you can check that in the args inside conditionData

#

I will double check tomorrow that I ll have access again

vast bane
#

Aoth is the only starter hero who can be hit by it

#

In theory Randall should have:

#

maybe a byproduct of the changes for v11

#

Randal didn't get it because the Activation condtion is looking for the exact match

hot flower
#

Is there a bookmarking bot on this server?

dark canopy
#

there is not

hot flower
#

gah. why this isn't a default feature of discord I don't know.

#

@vast bane you had a screenshot of your modules that you posted -- SOMEWHERE -- and now I can't find it again. Can you repost that when you get the chance.

#

please?

vast bane
#

general discussion

#

I'd be roasted here

hot flower
#

found it!

#

thanks

#

between this thread and CPR's discussions, there's a lot to keep up with

vast bane
#

I'm really happy where my dm client and server are with performance, very reliable now and combat is not that bad either. I'm about to trim down cub and go anonymous and a world script prolly tomorrow too should improve performance a smidge as cub is a lot larger module than anonymous is

hot flower
#

i'd love to get that HP rollling worldscript if you don't mind.

vast bane
#

I haven't actually put it in my world

#

I think its basically just the tokenmold hook

violet meadow
hot flower
proper siren
#

Hey all, was trying to get this macro I found here working for Cleric's Balm of Peace, but it appears completeItemRoll is deprecated and completeItemUse is recommended but requires an additional argument for config. Can anyone assist with updating this macro with completeItemUse?

let areaSpellData = duplicate(this.item);
delete(areaSpellData.effects);
delete(areaSpellData.id);
delete(areaSpellData.flags['midi-qol'].onUseMacroName);
delete(areaSpellData.flags['midi-qol'].onUseMacroParts);
delete(areaSpellData.flags.itemacro);
areaSpellData.name = 'Balm of Peace - Healing';
areaSpellData.system.damage.parts = [['2d6[healing] + ' + this.actor.system.abilities.wis.mod, 'healing']];
areaSpellData.system.consume.amount = 0;
let areaSpell = new CONFIG.Item.documentClass(areaSpellData, {parent: this.actor});
for (let targetToken of this.targets.values()) {
    let options = {
        'showFullCard': false,
        'createWorkflow': true,
        'targetUuids': [targetToken.document.uuid],
        'configureDialog': false,
        'versatile': false,
        'consumeResource': false,
        'consumeSlot': false,
    };
    await MidiQOL.completeItemRoll(areaSpell, options);
}```
vast bane
proper siren
proper siren
vast bane
proper siren
vast bane
#

what is the error with the macro then?

proper siren
#

The error is that completeItemRoll is deprecated

vast bane
#

thats not an error

#

thats just a warning for when foundry releases v12

proper siren
#

Ah, maybe I didn't apply it correctly then, I'll try it again

vast bane
#

I don't know for sure, but that kinda looks like my requested item from Chris that he then put into CPR

#

specially with all those this's

#

That item is meant for you to select all the targets in the peace clerics path and then just fire the item, it shouldn't have a heal or anything in it, it should just be an item macro on use with utility or other and no damage formulas or other formulas.

#

If its the one I'm thinking of it will then roll the item for each target

steady estuary
vast bane
#

Exactly like CPR's

steady estuary
#

I'm trying to reproduce the +2 bonus given by Fighting Style: Archery in a passive effect. Even applying this to an actor, the +2 bonus is not considered in the roll automatically. Am I doing something wrong?

vast bane
vast bane
steady estuary
#

Custom.

vast bane
#

Change it to whatever ADD would be

steady estuary
#

Also, i thought of that, but it shows like this in the roll formula:

#

And nothing is considered.

vast bane
#

and change the 2 to +2

steady estuary
#

+3 is from DEX and +2 is proficiency.

vast bane
#

what level is the actor?

steady estuary
#

Without ''+'':

#

Level 2.

vast bane
#

too many pluses is not a problem, it looks ugly but wait till you start stacking a bunch of non pluses

#

you will start to see +22

#

ADD is not +, its append

#

you have to lead with a + because theres no way of knowing which active effect gets slotted first, the rest won't have pluses added

steady estuary
#

While selecting add and +2 it goes like this and nothing is considered besides the DEX modifier and proficiency.

steady estuary
vast bane
#

that is not proficiency

#

what is the level of the actor

#

OR, what is the actors dex

steady estuary
vast bane
#

because either he has no dex mod, or he has no prof

steady estuary
#

17 DEX.

vast bane
#

dex and prof are always before the double ++

steady estuary
#

Level 2, +2 prof. bonus.

vast bane
#

hes not proficient in the weapon

#

bad importer or you forgot to set proficiencies

steady estuary
#

I don't get it, he is a ranger, was supposed to. I thought that by setting the proficiency on the front page it would detect longbow automatically.

vast bane
#

how did he get the weapon?

#

is it the roll20 importer?

steady estuary
#

It's vanilla, from the DnD5e compedium.

vast bane
#

did he have the weapon before the profs got changed?

steady estuary
#

Unless the player changed it by mistake?

vast bane
#

dnd5e reads the sheet on item drop

#

but doesn't update it after that

steady estuary
vast bane
#

yeah to prof it, just check the box on the bow

steady estuary
#

In any case you were right, that explains everything.

#

Just did thxblob

vast bane
#

FYI, its technically not raw what you did. That will cause darts and other dex ranged thrown items to also get the bonus

#

that feature is short and longbows only

#

but honestly....I never knitpick it in my campaigns

steady estuary
#

Yes. It's worth disabling it if he comes across another weapon type, but i don't think it will happen soon. It's worth the QoL.

#

Thanks Moto, you're always backing me up here. thxblob ❤️

strong yew
#

Yeah if you've already adapted it, would appreciate the share

#

Keep meaning to work on macro stuff but work is death

#

well, work at my dayjob I mean lol

inland vortex
#

Ok, I have Aid, Gift of Alacrity, and Bladesong all working now without using CE. Thanks for the help! I think I may have been on the wrong version of midi qol and updating it may have fixed Aid. That was te only thing I changed on that one. One way or the other, they are all working now. Except Gift of Alacrity does tend to give the same bonus for each use per casting. I noticed other people had that problem too.

wooden herald
#

Greetings, looking for some help with an item I imported from JSON, it contains an Item Macro, and I have the Item Macro and MidiQOL modules installed and active, but I cannot figure out how to activate the macro on this item successfully. I tried dragging to the Macro bar, but that gives me an error.

short aurora
short aurora
# wooden herald

Looks like the item is trying to run a macro named Pacto and not (just) the item Macro, how does the item detail page look?

wooden herald
#

Not in front of my PC anymore. I appreciate the help and will reply later. Thanks!

proper siren
#

Hey completely forgot to reply to you, but you can do this with the following code as a rough example:

let tactor;
if (lastArg.tokenId) tactor = canvas.tokens.get(lastArg.tokenId).actor;
else tactor = game.actors.get(lastArg.actorId);
let originActor = await canvas.tokens.get(getProperty((tactor.flags), "midi-qol.enemiesAbound.tokenId"))?.actor;
const immunity = tactor.system.traits.ci.value.has("frightened");

if (args[0] === "on") {
await wait(2000);
    if (immunity === true) {
        ui.notifications.notify(`${tactor.name} is immune to Enemies Abound because it cannot be Frightened.`); 
        let conc = originActor.effects.find(i => (i.label) === "Concentrating");
        return await MidiQOL.socket().executeAsGM("removeEffects", { actorUuid: originActor.uuid, effects: [conc.id] });
    }}```
short aurora
celest bluff
#

usually around 1000 depending on server latency

proper siren
celest bluff
#

I would add the immunity a bit differently..
You can also add the immunity into the on clause.

if((args[0] === "on") && (immunity)){
// await then remove
} else if((args[0] === "on") && (!immunity)){
// else apply whatever else is needed
}

Or you can do

if(args[0] === "on"){
// add in what should be added normally
if(!immunity) return;
// add in the await and removal here
}
#

so if you wanted to add more to it

#

like jb2a effects or whatever

proper siren
celest bluff
#

it probably needs to be rewritten anyway

hasty jackal
#

and what if is i one that macro but for "Frightful Presence" same effect

proper siren
covert mason
#

I'm using Effect Macro for this on effect creation, and on combat turn starting. How would I go about turning this into something that rolls to save against damage, or apply half on a save, instead of just applying a restrained effect?

let spellDC = actor.flags.world?.spell?.web?.dc;
if (!spellDC) return;
let save = await actor.rollAbilitySave('dex');
if (save.total < spellDC) {
    await game.dfreds.effectInterface.addEffect(
        {
            'effectName': 'Restrained',
            'uuid': actor.uuid,
            'origin': null,
            'overlay': false
        }
    );
}```
covert mason
#

When entering on the first time on a turn or if it starts its turn there.

vast bane
covert mason
#

Overtime doesn't detect if a creature enters the template on its turn, and doesn't make the save

vast bane
#

I think you want template macro not effect macro though

covert mason
#

I'm trying to make an aura using AA, not a template. I'm trying to use the web macro as a basis for what I'm trying to achieve.

#

When a creature enters or starts its turn within 10 feet of the golem, it must succeed a DC 15 Constitution saving throw, taking [[/r 2d10]] fire damage on a failed save, or half on a success.

vast bane
#

what creature is that?

#

If I had to make this myself, I'd throw a red token aura only I see on the golem and make a free action for fire damage

vast bane
#

Where is your macro?

wooden herald
#

I see a macro under "Item Macro" in the JSON file, I don't see a macro section in the GUI though.

vast bane
#

Well that item is meant to seek out a macro called "Pacto" in your macro directory

#

and the warning is telling you that you don't have that

#

did you export the actor from another world?

wooden herald
#

No, I was simply given the JSON file to import into an item.

vast bane
#

this is why its generally unwise to call world macros on items in midi as the item becomes connected to that world only

#

You need to contact whoever gave you that item import and get them to share the Pacto macro in their system macro folder

wooden herald
#

Got it. I'll reach out.

vast bane
#

Also I think midi's latest changes did something to macro.execute so the macro may need tweaks

wooden herald
#

This is in the JSON file:

#

Pretty sure that's the macro it wants to call, but it's not named "Pacto.

short aurora
#

That doesn't quite look like a proper macro for Midi, but you can always replace that effect value with macro.itemMacro and give that a go instead

#

I do expect it to behave a little oddly tying it to an effect without an on/off though

vast bane
#

no way that macro fires with midi's item macro

#

what is the feature?

#

I'lll look it up

short aurora
#

It looks like a macro to form your hexblade as a hexblade, I forget the feature name

wooden herald
#

Yes, it's the Pact of the Blade feature.

#

The idea was to allow the player to change the nature of their Pact weapon as per the rules.

vast bane
#

I don't really see a reason to automate this feature

short aurora
#

You got ItemMacro as a module, right?

vast bane
#

just slap magic on a non magic weapon and call it a day

wooden herald
short aurora
#

Open that item's ItemMacro, copy paste it into a new script macro on the hotbar and run that

#

If that runs as expected, we can change it to run on the feature click instead, it's just the tying to an effect that's a bit odd

wooden herald
vast bane
short aurora
#

This macro demands a token's selected from the looks of it, too, or it was an ItemMacro and not a midi macro

wooden herald
vast bane
#

yeah it was a macro polo macro

wooden herald
#

Yeah, just copy-pasting the macro into the hot bar, selecting a token and hitting execute doesn't work.

vast bane
#

its designed for that specific world

#

the pack key is probably off

#

its trying to point to a compendium where all the items were

wooden herald
#

Ahhh. Dang it.

short aurora
#

Copy paste the macro that you copied in here, put it like so;
```js
macro here
```

vast bane
#

what version are you in?

short aurora
#

It looks like it's copying the source SRD items from dnd5e

vast bane
#

why is item macro failing to show for them?

static sparrow
vast bane
#

I don't think Pacto was ever the item macro, I think this premade was two macros

wooden herald
#

Need to break this up into multiple posts. One sec.

vast bane
#

I think the user had dae only

wooden herald
#
    "itemacro": {
      "macro": {
        "name": "Pact Boon: Pact of the Blade",
        "type": "script",
        "scope": "global",
        "command": "async function getBaseItem(identifier, fullItem = false) {\n  const packName = CONFIG.DND5E.sourcePacks.ITEMS;\n  const pack = game.packs.get(packName);\n\n  if (fullItem) return pack.getDocument(identifier);\n\n  return pack\n    .getIndex({ fields: [\"data.weaponType\"] })\n    .then((index) => index.get(identifier));\n}\n\nasync function getWeaponBaseTypes() {\n  const ids = CONFIG.DND5E.weaponIds;\n  const typeProperty = \"weaponType\";\n  const baseTypes = [\"simpleM\", \"martialM\"];\n\n  const items = await Object.entries(ids).reduce(async (acc, [name, id]) => {\n    const baseItem = await getBaseItem(id);\n    const obj = await acc;\n    if (!baseTypes.includes(getProperty(baseItem.data, typeProperty)))\n      return obj;\n    obj[baseItem.name] = name;\n    return obj;\n  }, {});\n\n  return Object.fromEntries(\n    Object.entries(items).sort((lhs, rhs) => lhs[0].localeCompare(rhs[0]))\n  );\n}\n\nasync function chooseWeapon() {\n  const 
#
baseWeapons = await getWeaponBaseTypes();\n  //console.log(baseWeapons);\n\n  const choice = await warpgate.dialog(\n    [{ type: \"select\", label: \"Weapon\", options: Object.keys(baseWeapons) }],\n    \"Pact Weapon Form\"\n  );\n  //console.log(choice);\n\n  if (choice && choice[0]) {\n    const label = choice[0];\n    const name = baseWeapons[label];\n    const identifier = CONFIG.DND5E.weaponIds[name];\n    //console.log(choiceId);\n\n    return getBaseItem(identifier, true);\n  }\n}\n\nconst item = await chooseWeapon();\nif (item) {\n  const itemData = duplicate(item.data);\n  // couple changes\n  delete itemData._id;\n  itemData.name = `Pact ${itemData.name}`;\n  itemData.data.proficient = true;\n  itemData.data.equipped = true;\n  itemData.data.properties.mgc = true;\n  // temp change, newer versions of DAE has a fix\n  delete itemData.effects;\n  // Hex Warrior\n  if (token.actor.items.getName(\"Hex Warrior\")) {\n    itemData.data.ability = \"cha\";\n  }\n  //console.log(\"itemData\", itemData);\n\n  const updates = {\n    embedded: {\n      Item: {\n        [itemData.name]: itemData,\n      },\n    },\n  };\n  await warpgate.mutate(token.document, updates);\n}",
short aurora
#

Yeah, that's what I figured

vast bane
#

that would do it for why its not working

short aurora
#

From in Foundry, copy the ItemMacro from the item

vast bane
#

thats just it, there is no item macro thats why I asked for versions, he doesn't see it

#

I suspect they are on v9 foundry

#

and they took a v10 import

wooden herald
#

I am in v10.

short aurora
#

In this picture

#

At the top of the title bar that says Item Macro

vast bane
#

versions of foundry, dnd5e, item macro, midiqol

short aurora
#

Copy the contents of that for me

#

Please stop disregarding what they already posted lmao

vast bane
short aurora
#

That is not what they said

#

They said they see no item macro field in the GUI

wooden herald
short aurora
#

I copy pasted that picture from the pictures you sent

vast bane
wooden herald
#

Ok, I am a dummy. I didn't see that.

vast bane
#

the real question is what were you pasting that into then 0_o

short aurora
#

's all good. If you copy paste that into a new script macro and run it, that runs just as expected, right?

wooden herald
#

I was copying direct from the JSON file I used to import the item. Here comes the nicely formatted text from the item. One sec.

vast bane
#

if you paste it into ah otbar button macro, change it to script, and select the warlock, it might run, but the premade looks like it was a dae user running a macro in an ae and also an itemacro as well

wooden herald
#

Yes, runnin git from the macro bar runs as expected now.

#

I need to create my compendium of weapons, but other than that it appears to work from there.

short aurora
#

I don't see any "off" part of this macro, maybe I'm just unfamiliar with Warpgate and they do a named mutation. Can you paste the macro here, too?

#

To me it looks like it will let you create infinite magical weapons

vast bane
#

its not the macro that runs in the dae

#

its a dae only user, probably ready set roller, and then theres a system macro that runs off the dae

wooden herald
#

I just got contacted by the guy I got it from. He confirms that it was DAE, and he's adjusted it for me. I need to try his update.

vast bane
#

just have them send you pacto macro

#

the dae is probably a warpgate or something

static sparrow
#

Warp Gate is certainly how I’d do Pact Weapon.

vast bane
#

yeah, its probably either a warpgate or an item update dae args on/off in whatever pacto was and apparently the itemacro was getting the base item from a compendium. I'm pretty certain its a ready set roller

short aurora
#

you hurt me when you say things like this

#

the macro has the word warpgate in the very last line we saw

#

how can you say probably

#

;_;

vast bane
#

you didn't see the macro we're talking about

#

the premade has 2 macros

#

we can't see the other one

plain bane
#

and just put the macro in the macro item and indicate no on use macro to work

short aurora
#

Are you on v9 baraki?

vast bane
#

are you on v9 foundry?

#

lol

short aurora
#

🚤

plain bane
#

v10

marsh crescent
#

jinx

vast bane
#

I think the breakage is in the datas, the filter is failing

short aurora
#

This works for you on v10? suspicious

#

Replacing data with system in the macro makes it work just fine

#
async function getBaseItem(identifier, fullItem = false) {
  const packName = CONFIG.DND5E.sourcePacks.ITEMS;
  const pack = game.packs.get(packName);

  if (fullItem) return pack.getDocument(identifier);

  return pack
    .getIndex({ fields: ["system.weaponType"] })
    .then((index) => index.get(identifier));
}

async function getWeaponBaseTypes() {
  const ids = CONFIG.DND5E.weaponIds;
  const typeProperty = "weaponType";
  const baseTypes = ["simpleM", "martialM"];

  const items = await Object.entries(ids).reduce(async (acc, [name, id]) => {
    const baseItem = await getBaseItem(id);
    const obj = await acc;
    if (!baseTypes.includes(getProperty(baseItem.system, typeProperty)))
      return obj;
    obj[baseItem.name] = name;
    return obj;
  }, {});

  return Object.fromEntries(
    Object.entries(items).sort((lhs, rhs) => lhs[0].localeCompare(rhs[0]))
  );
}

async function chooseWeapon() {
  const baseWeapons = await getWeaponBaseTypes();
  //console.log(baseWeapons);

  const choice = await warpgate.dialog(
    [{ type: "select", label: "Weapon", options: Object.keys(baseWeapons) }],
    "Pact Weapon Form"
  );
  //console.log(choice);

  if (choice && choice[0]) {
    const label = choice[0];
    const name = baseWeapons[label];
    const identifier = CONFIG.DND5E.weaponIds[name];
    return getBaseItem(identifier, true);
  }
}

const item = await chooseWeapon();
if (item) {
  const itemData = duplicate(item.data);
  // couple changes
  delete itemData._id;
  itemData.name = `Pact ${itemData.name}`;
  itemData.system.proficient = true;
  itemData.system.equipped = true;
  itemData.system.properties.mgc = true;
  // temp change, newer versions of DAE has a fix
  delete itemData.effects;
  // Hex Warrior
  if (token.actor.items.getName("Hex Warrior")) {
    itemData.data.ability = "cha";
  }
  //console.log("itemData", itemData);

  const updates = {
    embedded: {
      Item: {
        [itemData.name]: itemData,
      },
    },
  };
  await warpgate.mutate(token.document, updates);
}```
plain bane
#

I think I wasn't clear, the macro I put itrem macro and in the detail I point to the on use macro for it to call the item macro and it works normally

vast bane
plain bane
vast bane
#

they weren't ever using that macro then heh, pacto is what they use

#

its probably a v10 compliant args on/off warpgate

vast bane
#

or pacto is an args off warpgate dismiss function

short aurora
#

I'm calling kap

vast bane
#

I'm pretty certain they never touched that item macro, it was probably just there from before they installed midiqol lol

#

when they roll the item the dae applies to the actor and "Pacto" is what they see come out of the item roll instead of that itemacro

plain bane
plain bane
vast bane
#

Its not though, your item macro is designed for non midi users it would never run in midi. It can run as a hotbar macro if you edit it and change it to v10 stuff

wooden herald
#

So strange. I'm trying to follow along, but I fear I know so little of how macros work in Foundry that I am totally lost... And I'm a Network Engineer with a background in coding and database management!

vast bane
plain bane
#

i am using mine direct on item

wooden herald
vast bane
#

you may have a functional pact of the blade but you are blocking on use macros in the rest of midiqol

plain bane
plain bane
vast bane
plain bane
#

and the same one I posted

vast bane
#

those are both snippets of your posts

plain bane
#

I think that when copying and pasting I got it wrong, sorry for the confusion

#

I will post the file of the item

#

there you can see better

frail osprey
#

what we doing?

plain bane
vast bane
#

@wooden herald paste this macro above directly into item macro, then at the bottom of pact items details, hit the plus symbol to add an on use macro and type in ItemMacro and choose after active effects

#

Make it look like this:

#

oops

#

forgot to capitalize the Macro in ItemMacro, edited now

wooden herald
#

Well, that freaking works!!!

#

Out of curiosity for completeness.... Is there any way to get it to "clean up" previous Pact Weapons it makes?

#

Since you can only have 1 at a time.

vast bane
#

would be args on> your macro, and then args off > dismiss it

wooden herald
#

Ah

vast bane
#

and then the on use macro would be cleared and instead you roriginal item setup, a dae that runs macro.itemmacro

wooden herald
#

For now I think I'm happy enough allowing my player to manage cleaning up her inventory.

vast bane
#

(instead of execute)

#

you should see a dismiss button on the top bar while they have the pact weapon

#

if the user or you click that, it should delete the item

wooden herald
#

I only vaguely understood that, but enough to grasp the concept.

vast bane
#

Well...I didn't look at the new macro but I assume its a warpgate mutate?

#

whe you use it, do you see a dismiss button on the actors top bar?

#

or whatever the undo is called for mutates, I think its dismiss

wooden herald
#

No dismiss.

vast bane
# plain bane just follow the macro

Would you be interested in a solution to the oddball font looks of your windows desktop? I happen to notice you have really bad tearing in the edges of your fonts, its a windows setting doing that to you

vast bane
#

trying to find it, windows versions are so annoying when they move things around

plain bane
vast bane
#

click the startmenu, type advanced into the search and then you should see advanced system settings as an option to pick in the search.

plain bane
#

ok

vast bane
#

it will improve how fonts look but also it will change the icons in foundry so they look a lil more...detailed

#

If you are worried about performance that checkbox won't really affect you at all

plain bane
#

thanks for the help there, grateful

short aurora
# wooden herald Out of curiosity for completeness.... Is there any way to get it to "clean up" p...
async function getBaseItem(identifier, fullItem = false) {
  const packName = CONFIG.DND5E.sourcePacks.ITEMS;
  const pack = game.packs.get(packName);

  if (fullItem) return pack.getDocument(identifier);

  return pack
    .getIndex({ fields: ["system.weaponType"] })
    .then((index) => index.get(identifier));
}

async function getWeaponBaseTypes() {
  const ids = CONFIG.DND5E.weaponIds;
  const typeProperty = "weaponType";
  const baseTypes = ["simpleM", "martialM"];

  const items = await Object.entries(ids).reduce(async (acc, [name, id]) => {
    const baseItem = await getBaseItem(id);
    const obj = await acc;
    if (!baseTypes.includes(getProperty(baseItem.system, typeProperty)))
      return obj;
    obj[baseItem.name] = name;
    return obj;
  }, {});

  return Object.fromEntries(
    Object.entries(items).sort((lhs, rhs) => lhs[0].localeCompare(rhs[0]))
  );
}

async function chooseWeapon() {
  const baseWeapons = await getWeaponBaseTypes();

  const choice = await warpgate.dialog(
    [{ type: "select", label: "Weapon", options: Object.keys(baseWeapons) }],
    "Pact Weapon Form"
  );

  if (choice && choice[0]) {
    const label = choice[0];
    const name = baseWeapons[label];
    const identifier = CONFIG.DND5E.weaponIds[name];
    return getBaseItem(identifier, true);
  }
}

const hexbladeItem = await chooseWeapon();
if (hexbladeItem) {
  const itemData = duplicate(hexbladeItem.data);
  // couple changes
  delete itemData._id;
  itemData.name = `Pact ${itemData.name}`;
  itemData.system.proficient = true;
  itemData.system.equipped = true;
  itemData.system.properties.mgc = true;
  // temp change, newer versions of DAE has a fix
  delete itemData.effects;
  // Hex Warrior
  if (token.actor.items.getName("Hex Warrior")) {
    itemData.system.ability = "cha";
  }
  //console.log("itemData", itemData);

  const updates = {
    embedded: {
      Item: {
        [itemData.name]: itemData,
      },
    },
  };
  
  const hasMutation = (tokenDoc) => {
  const stack = warpgate.mutationStack(tokenDoc);
  return !!stack.getName("Hexblade")
}
  if (hasMutation(token.document)) await warpgate.revert(token.document, "Hexblade");
  await warpgate.mutate(token.document, updates,{},{name: "Hexblade"});
}```
#

If you're curious in what we added, it's the last 5 lines I changed, grabbed "does this have a mutation named Hexblade" check, if yes remove that then apply a new one, and named our mutation with Warpgate so it'd pick up on it

wooden herald
short aurora
# dark canopy very neat

All of the Warpgate stuff is yours, so I hope so. 😄 By the way, is there an option to have mutates "overwrite" mutations of a same name? So instead of writing out the code to revert to achieve the above, I could put in a parameter and it'd revert the existing mutation before applying a new one?

dark canopy
#

hmm, not off the top of my head, but...check the return value of revert -- i think i send back undefined if no revert occurs, and something else if it does

wooden herald
#

Getting an error with the new macro:
From the console:

di-qol |  Error evaluating macro  SyntaxError: Identifier 'item' has already been declared
inland vortex
#

We're using the midi qol version of Absorb Elements, the one that says 10.0.10, and when we use it it offers what type of damage we want to be resistant to. Whatever we pick, we get fire resistance. I don't know if it's always been this way, as we had been fighting red dragons. But tonight there was acid and cold damage, and we got fire resistance anyway.

short aurora
wooden herald
short aurora
wooden herald
#
caught (in promise) TypeError: undefined. Cannot set properties of undefined (setting 'ability')
[Detected 1 package: midi-qol]
    at Workflow.eval (eval at callMacro (workflow.js:1662:15), <anonymous>:62:27)
    at async Promise.all (index 0)
    at async Workflow.callMacros (workflow.js:1547:13)
    at async Workflow._next (workflow.js:939:7)
    at async Workflow.next (workflow.js:247:10)
    at async Workflow.next (workflow.js:247:10)
    at async Workflow.next (workflow.js:247:10)
    at async Workflow.next (workflow.js:247:10)
    at async Workflow.next (workflow.js:247:10)
    at async Workflow.next (workflow.js:247:10)
    at async Workflow.next (workflow.js:247:10)
    at async Workflow.next (workflow.js:247:10)
    at async Workflow.next (workflow.js:247:10)
    at async Workflow.next (workflow.js:247:10)
    at async Workflow.next (workflow.js:247:10)
short aurora
#

Ah feck, missed a data

short aurora
wooden herald
#

Ahhh

#

Man... It's like you can't do anything right.

#

Until you do.

#

Like now.

#

Because it's working 100%

#

🥳

short aurora
#

🥳 good stuff

wooden herald
#

Bedtime now. :🛏️:

#

FYI: You should pin this. This was a VERY common request on how-to for a long time.

dark canopy
short aurora
vast bane
#

Working fine on our end, I'd confirm yourself if its failing, the player probably fat fingered the choices

#

the attached damage also is staying the picked choice:

#

Make sure you are on the newest midi and dae

inland vortex
#

i'll update them and see if it fixes

inland vortex
#

i'm on the newest midi and dae. when i look at the effect written in the spell it only has code for resist fire in it, unless I am understanding the spell writing incorrectly

vast bane
opaque current
#

Thats the default, a macro runs to change it when cast

vast bane
#

oh

#

I think I know whats wrong

inland vortex
#

everything is unchecked in Item Macro

vast bane
#

have you confirmed this problem yourself by testing the spell on the actor?

#

cause this could also just be user error, they chose fire

vast bane
#

Otherwise, you are using another roller, or the player has roll automation off in their client in midiqol(only they can check this)

#

These buttons will also cause on use macros not to fire which would be a user error scenario:

inland vortex
#

I have my settings like yours, I'm not using any of the forbidden modules on that list, and i did try using the spell myself extensively on 3 characters. Same results

#

Fire res every time

violet meadow
#

What's the issue?

#

Absorb elements? Do you have the apply DFreds CE first maybe?

inland vortex
#

When we use Absorb Elements it always gives fire resistance no matter what we ask for

#

No, it's CE only if the other thing isn't there

violet meadow
#

Any errors in console when you fire the Reaction?

inland vortex
#

i'll look

vast bane
#

also when you are done with bugbear, can you show us the attacks in chat?

#

when you show us the attacks, mouse over the casters token in the DM damage dialog card so it shows the resistance in a tooltip like I did above

violet meadow
#

Also have you changed the item name from Absorb Elements 10.0.10 to Absorb Elements ?

vast bane
#

I'm handing in my helper card

inland vortex
vast bane
#

its not renamed is it?

#

You have to rename it for it to work:

inland vortex
#

no

vast bane
#

I had renamed mine, I tested from a players sheet

inland vortex
#

lemme try that

violet meadow
#

yes that error is the name issue

inland vortex
#

And that, of course, solved everything

#

So rename all spells that have extra bits like that in the title?

vast bane
#

@violet meadow While I got you:
If the target is within 5 feet of any of the angel’s allies, the target takes an extra 2 (1d4) radiant damage.

target.findNearby(-1, targetUuid, 5, {}).length > 1

vast bane
inland vortex
#

lol. will do, boss!

vast bane
#

I'm plagerizing from the pack tactics and its always rolling the d4 but I think its cause I am confused on how to setup the details of the weapon

violet meadow
inland vortex
#

i'll make sure i do that before asking you why the paladin's aura of protection is helping the saves of nearby monsters clearly marked hostile, even though it doesn't put the effect icon on them

vast bane
#

Is it because I checked the also roll other? I thought that was required but I guess its stepping on things:

violet meadow
#

Mostly is because of the target.findNearby... 😄

#

yeet the target

vast bane
#

oh I thought you had to define the target in activation conditions mb

violet meadow
#

findNearby gets some special handling

#

You indicate the center of the measurement using the targetUuid

#

instead of tokenUuid which would mean the attacking actor in this case

vast bane
#

k, its working now, unchecked also roll other too

#

noticed the item was set to reach for some reason, I think thats a typo in dndbeyond

violet meadow
#

You might need the Crit Other though

violet meadow
vast bane
#

does midi even do anything with the reach property?

violet meadow
#

let me check

vast bane
#

I bet you the importer parses the descriptions and picked up the 5 feet in the description and false flagged it for reach

#

oh shit no, it really is a reach weapon lol

#

wtf lol

#

a redundant reach

#

or does reach 5ft mean 10....now its got me confused

#

oh, apparently this is probably a problem with all dnd beyond importer monsters, but since reach doesn't do anything its ok.

#

it takes the description word for word, and on the statblocks it defines the reach on everything

violet meadow
#

I don't seem to find any mention of rch property in the Midi code, so I don't think there's any special handling

vast bane
#

k, I just looked at the other sources of monsters and its just the importer monsters that do this, its probably a non issue till reach starts getting automated by something.

#

the srd monsters list reach in them too but they don't check the box for reach

#

Either way I'm all set thanks!

rotund mountain
#

Does any one know of an active effect or a midi flag that can cause an effect to trigger when an actor is healed? My goal is to have an actor gain a bonus on attack rolls for one round after being healed

I've tried looking around (mostly at beacon of hope automations as it is vaguely similiar), but to no avail. I looked in to hooks a bit,but macro polo suggested I ask here as there isn't a "on heal" hook

opaque current
#

Does it happen to anyone a specific caster heals, or is it a thing for a certain character who receives healing

vast bane
#

world script territory

#

unless its part of a heal item then its as simple as adding an ae to it

opaque current
#

I would go low tech and just give the receiver a Healing Boon feat. When they receive healing they click it, triggering the 1 round buff.

vast bane
rotund mountain
opaque current
#

It's more automation than having to manually add in the boons to their attacks lol.

rotund mountain
#

It is an effect that an item gives to a character that is attuned to it. So only one character (the one with the item) would get the buff when healed

vast bane
#

a free reaction on isdamaged, can even filter for damage type I think now

opaque current
#

I don't use the reaction automation since I find it bogs down combat, but also sounds like it's expanded since I last looked

vast bane
#

I put a sound hook on the reaction prompt so the whole table yells at the user whose not paying attention and only have a 10 second time out for the prompt

violet meadow
vast bane
#

I'd share the hook but my server just decided to go into its maintenance and I'm bored at work, someone post a problem with midi

violet meadow
#

Hey MidiQOL is no longer bringing me coffee in the morning. How come?

violet meadow
#

with or without ?! 😅

short aurora
#

I mean if you're offering, I could use some automation for my storm sorcerer player so she can swoop around but preferably with all 99 edge cases of flying 10 feet covered and with animation

vast bane
#

My big wishlist item to make currently is a pudge hook ability like from dota2

rotund mountain
rotund mountain
violet meadow
vast bane
rotund mountain
vast bane
#

( 🤓 bless doesn't do ability checks)

rotund mountain
#

Oh lmao

rotund mountain
vast bane
#

Your item is right up the alley of a fun new automation, I suspect bugbears fiddling atm with it

#

situational reactions

rotund mountain
#

That would be excellent ! (And much appreciated 🙂 )

edgy pagoda
#

Please help with two things:

  1. How to correctly specify the number of uses of the Optional Bonus Effects effect?
    Option flags.midi-qol.Optional.1.attack.all - doesn't work.
  2. Can't make a critical hit effect on Assassinate (rogue).
violet meadow
# rotund mountain That would be excellent ! (And much appreciated 🙂 )

Try this.

  1. Drag the Item on the sidebar and delete the one from the actor's inventory.

  2. Create a DAE on the item which should have in:
    a. Details tab: Transfer to actor on item equip checked,
    b. Effects tab: macro.itemMacro | Custom |

  3. Copy paste the macro in the ItemMacro of the item and CHANGE the itemName in the first line of it to match the name of the Item,

  4. Drag the item back onto the character sheet and equip (and attune to, if needed) the item

  5. (optional) let me know if it works correctly 😄

fluid cradle
#

Is there anything in dae + midi, that would check if the ability still has uses and if it does, whenever you roll any skill check, you can add a d6 or not, similar to bardic? (Im looking at Knowledge from a Past Life)

vast bane
#

and it is precisely what bardic inspiration does

fluid cradle
vast bane
#

read the readme section on that feature, its all right there, the answer is yes

frail osprey
# violet meadow

for learning, can I use args onUpdateActor to trigger a macro whenever something in the actor is changed? similar to how a hook would work?

cinder tapir
#

Any way to specify a % of dr?

violet meadow
opaque current
#

DR is usually a set number of damage reduction

#

You could give them healing resistance? I guess?

cinder tapir
#

What key is that?

#

For healing resistance

violet meadow
#

dr instead of DR and then use the autocomplete for the right one

frail osprey
#

that's noice. Is there somewhere I can check all the args passed?

cinder tapir
#

This is all I can see

violet meadow
opaque current
#

beat me

cinder tapir
#

Thank u

violet meadow
#

It mentions the set lastArg that the macro is called with

frail osprey
#

Thank you! 😄

#

I suppose I can't have macro.ItemMacro pass args as well if I use this, right?

#

or it makes no difference?

violet meadow
#

The shared one does this.

The Item has a macro.itemMacro by default on it.
When you attune and equip to it, that becomes a flags.dae.onUpdateTarget.

When you break attunement of unequip, it changes back to macro.itemMacro

#

You can omit this step entirely. It all depends on what you want to do.

#

you can also pass extra arguments to the flags.dae.onUpdateTarget as ```js
key: 'flags.dae.onUpdateTarget',value: ${itemName},ItemMacro.Item.${item.id},system.attributes.hp.value,@attributes.spelldc,"wis",mode: 0}

#

and then get them inside the macro

#

In this case args[1] would be @attributes.spelldc
args[2] would be "wis" etc

frail osprey
#

hmmmmmmmmmmmmmmmmmmmmmmmmmmm that's veeery interesting

#

so I could, for example, pass spell slots and have macro trigger whenever they are updated (a spell is cast)

violet meadow
#

That would be better served as an Actor onUse midiqol macro

#
if (args.item.type === "spell") { /*do stuff */ }

//args.item as of the latest MidiQOL versions
frail osprey
#

true, it's cos I have a lot of homebrew conditions I use on my game. One of them makes all spells cast by the affected player cost 2 spell slots instead of one.

#

wrote a macro for it using hooks and world script, but was looking for a simpler way to do it

violet meadow
#

that hurts 😛

I meant the double the spell slots for the player

vast bane
#

The wiki has the explanation of DR and dr

#

I had a genius idea today while on lunch

#

everyones always asking how to make a creature immune to a specific custom active effect

#

and I think I got it and its ridiculous

frail osprey
vast bane
#

Give them a suspended effect by the same name

frail osprey
#

harsh in a way that my challenges are hard, not that I'm rude or rule enforcer on players

frail osprey
vast bane
#

If it has to be the same status id, then precast/preapply the actual same active effect on them and then suspend it

#

I think you need to change the default from stack by origin to stack by name though

frail osprey
#

but aren't dfreds all configured as "non-stackable by origin"? Would it work?

vast bane
#

which imo the default should be name

frail osprey
#

ah, you were faster than me

vast bane
#

What module gives us the stacking? Dfreds or DAE?

frail osprey
#

I've been using both for so long that I don't even know

vast bane
#

I mean cue, Zhell pointing out none of us ever know whats core or midi lol

frail osprey
#

to be honest, I don't even know what's core anymore. Another day I was asking Zhell's help on macro-polo thinking what I was asking was core, but it was midi

#

and I got hit with the chair

#

yup, just tested it, and it doesn't work with dfreds effects. Created a Blinded suspended effect and tried applying Blinded on the actor.

#

but I'm wondering now why "do not stack by name" isn't the standard

vast bane
#

Fwiw, you can change them

#

and it is indeed working perfectly when set to name

#

I wonder if he could give us a setting to change the default stack setting in dfreds

#

that way we don't have to duplicate everything

violet meadow
#

Stacking is DAE

vast bane
#

Can anyone see a point to origin instead of name by default?

dark canopy
#

conservative defaults, i would imagine

vast bane
#

Its technically all a janky solution so I doubt its worth a request to change a default setting. I'm abusing midi's ignorance of suspended effects to pull off a custom immunity. Its still totally possible manually though just gotta find the players sources of the effects and set them to name instead of origin.

fringe brook
#

How can I make every potion heal for x times hitdice instead of x times d4?

#

Example: Potion of healing heals a barbarian for 2d12 + 2
heals a wizard for 2d6+2

vast bane
#

Macro territory, I don't think there is a value you can reference for the size of the die.

fringe brook
#

would you kindly help me make an item macro that heals for x times hitdice? How to I reference the hitdice of the actor that uses the item?

vast bane
#

I don't know how to make it sadly I know half the things required to do so

fringe brook
#

alright, thanks tho 🙂

vast bane
#

whoever does make it I think wants what I just found though

#

you need to define that value in the actor data as a const, and then reference it in the dice equation for the MidiQOL.applyTokenDamage function. You could search for this here and see other macros using that function

fringe brook
#

will do

vast bane
#

and since its a potion you need to define the actor/target too

violet meadow
fringe brook
#

interesting question, I didnt consider this... probably higher HD?

#

or whatever the base class is? 🤔

violet meadow
#

you tell me what you decide 😅

vast bane
#

highest available, man that macro just got harder

#

(softban multiclassing lawl)

fringe brook
#

i am thinking of removing that homebrew rule

#

seems like too much efford to me now

vast bane
#

he sounds like hes making your macro so just make the decision and he'll put it in

fringe brook
#

my players mostly hord their items anyways

vast bane
#

bugbear thinks in binary, he's probably got your macro waiting for the input

fringe brook
#

😮 ok

#

then I would like the highest hitdice available

vast bane
#

Man Fey Ancestry is messed up with monsters of the multiverse

#

I dunno how to handle it with the wiki, theres two different versions and we actually have two automations of it too

#

midiqol does the old fey ancestry and CPR does the new version

scarlet gale
#

They're different?

vast bane
#

the old one combined trance and fey ancestry I think

#

midiqol's sample does the trance half but is called Fey Ancestry

scarlet gale
#

How does it do trance?

vast bane
#

condition immunity

scarlet gale
#

That's just not sleeping

vast bane
scarlet gale
#

I would not do that like that lol

#

What happens when they hit 0 health?

vast bane
#

they have zero health

scarlet gale
#

They can still go unconscious

vast bane
#

they still go prone, theres no real difference mechanically

#

once you are zero hp combat attacks behave differently anyway

scarlet gale
#

Most sleep automations just look for the fey ancestry or elf race

#

So, doing it this way seems silly

vast bane
#

oh shit yeah, that is a bad one

#

well...

#

only the strength/dex save thing would be missing

#

oh actually no

scarlet gale
#

Huh

vast bane
#

thanks to statusEffect this doesn't matter

#

the zero hp elf gets unconscious through prone

#

cause it all combines

scarlet gale
#

Or you can just not use this jank

vast bane
#

true

#

but I'm not the arbiter of levels of automation, technically it still counts just by adding the language heh

#

I think I will denote old and new fey ancestry

scarlet gale
#

Adding a language hardly an automation

vast bane
#

I'm working on the race checklist for the wiki

#

yeah but not everyone plays at our automation level

scarlet gale
#

Plus what if they're using Tasha's?

vast bane
#

Basically is it setup for effect transfer and/or add something to the sheet automatically.

#

or does it follow midi's target/range setting shennanigans

#

(or does it have midi checkboxes checked on the details)

#

I am pondering using 2 checkmarks one for partial automation and one for thorough automation though.

#

Powerful build is an easy automation that nobody has done.

#

then again its probably best not to use an ae for this

vast bane
# dark canopy here?

Yeah ddbi adds it, but I was pondering just doing the flag for it in an ae for a premade item like powerful build

dark canopy
#

a bit overkill, but doable

vast bane
#

yeah I'm working on the wiki today

#

so I'm working on race feature automations available from the 6 main modules/sources

scarlet gale
#

An ae for every trait seems like a needless waste of performance

vast bane
#

yeah

#

DDBI just adds it during the import instead of using an ae

scarlet gale
#

There is a reason ddbi doesn't do it that way

dark canopy
#

it would be extremely easy to flag actor data changes on an item and apply them on create

vast bane
#

yeah I was pondering an effect macro on create

scarlet gale
#

Why

vast bane
#

oh good point I guess its still an ae lol

dark canopy
#

just item flag data, and a small worldscript to hook on create of an embedded doc

#

add data from item

#

done

vast bane
#

cut me some slack my eyes are seeing the grid overlay of my spreadsheet still reading discord chat

scarlet gale
#

Or just check it once, generally speaking player races don't change

vast bane
#

yeah true, but I still have to include it in the list as not automated by anyone

violet meadow
# fringe brook then I would like the highest hitdice available

Janky way. MidiQOL item on use on the healing potion
ItemMacro | Before damage is rolled

const { hitTargets, workflow:{item:itemD} } = args[0];
const healingDefault = duplicate(itemD.system.damage.parts);
let healingDface;
const hitActor = hitTargets[0].actor;
if (hitActor.type === 'character') healingDface = Math.max(...Object.entries(hitTargets[0].actor.getRollData().classes).map(t=>t[1].hitDice.at(1)));
else healingDface = hitActor.getRollData().attributes.hp.formula.split('d')[1].at(0)
healingDefault[0][0] = healingDefault[0][0].replace(healingDefault[0][0].split('d')[1].at(0), healingDface);
await itemD.update({"system.damage.parts":healingDefault})

Oh nope it will fail for d12... will fix when I am back at a PC

scarlet gale
#

Because it's in core

vast bane
#

I do plan on going back through and X'ing out anything that shouldn't be automated

scarlet gale
#

Make a mark for core feature honestly

vast bane
#

wonder if a module could do what midi does with magic resistance

#

if a feature exists that is called powerful build, add the flag

#

but...only cause I've seen it now, its not always called powerful build

#

Centaur has a feature that is exactly like powerful build but is called Equine Build

dark canopy
#

matching by name is a losing game

vast bane
#

yeah

honest wave
#

Yo, what would be the right Attribute Key for an Effect to give advantage on a saving throw?

fallen token
#

flags.midi-qol.advantage.ability.save.str for Strength

honest wave
#

I need it for any/all saving throws

#

If thats possible, or do I need to do it individually

#

nvm

#

flags.midi-qol.advantage.ability.save.all

#

Thanks mate.

#

Been a while since I played around with effects.

vast bane
honest wave
vast bane
#

ok, was gonna warn you that you don't make magic resistance that way. For Magic Resistance midi has a special flag but 99% of the time all you need is an item called "Magic Resistance" in the inventory of an actor for magic resistance to work.

honest wave
#

Alright yeah thanks, good to know

vast bane
#

the flag for magic resistance is meant for the rare times magic resistance is a temporary effect otherwise you can just rely on the auto detect of the item

#

One of my longest oldest reliable automations has started to fail in midi 41 and am unsure how to fix it.

Divine Sense:

edgy pagoda
#

Please help me make a status that gives a bonus to damage once per turn.
I tried using flags.midi-qol.optional.NAME.damage.all attribute but after using bonus the status disappears regardless of what is specified instead of NAME.
I also tried to modify the Sneak Attack 10.0.33 macro, but I don't understand it and I couldn't set a fixed damage value that is not tied to accuracy and class.

vast bane
edgy pagoda
vast bane
vast bane
# edgy pagoda

yeah you misread the readme, let me show you a sample so you are set right

vast bane
#

I feel like theres a mistake in this premade....that last add is sus

scarlet gale
vast bane
#

also fyi, this is a bad example cause the very key you want isn't shown lol

vast bane
#

We gotta get it to tposney quickly cause I think he's sitting on 42 ready to drop soon

scarlet gale
#

Could also be bad things being sent to the find nearby

vast bane
#

@scarlet gale You were right btw about missing documentation, just add .fail on the end to get them to prompt on fails only.

vast bane
#

I think you just nailed it now I need to find it, I think its midi 37

scarlet gale
#

Yea, might need to be looked at

vast bane
#

its mentioned in the changelog that its a breaking change

scarlet gale
#

Also, v9 script

#

I spy some data.data

edgy pagoda
vast bane
#

Breaking Addition to findNearby to allow inclusion of incapacitated actors, MidiQOL.findNearby(disposition, token, distance, {maxSize, includeIncapacitated}). Only breaking if you were including a maxSize before, you'll need to use {maxSize: size} instead.

scarlet gale
#

Yep that's it

#

Just needs to be slightly adjusted

vast bane
#

it was added in midi 31

scarlet gale
#

If nobody gets to it, I can later when I'm not at work

vast bane
#

k I will attempt to sus it out while I'm doing the datas

vast bane
#

your mistake was you are using the switches in the name of the key instead of in the effect value for the right key

#

My example was bad because bardic inspiration is the exception to the very key you need to add:

#

you need that key, but NAME needs to be changed to the name of your feature

#

and then the effect value for this key should have turn in it

#

I do not know if .count keys can take two values

#

My guess would be turn,ItemUses.ItemName if I had to guess

#

where ItemName is the name of the item with charges in the actors inventory

#

Heres another thing you can use for count:

#

yeah I think this is a bug we can't fix with a change to the macro

#

I think its a failure to null check

edgy pagoda
# vast bane Heres another thing you can use for count:

I still don't understand.
From what I see, the system does not care what is written instead of NAME. Also, the system does not care about Mode. Upon successful execution of the function, the status immediately disappears.

#

I changed the names in the Attribute Key. Changed the Change Mode. In the Effect Value section, I tried to specify options similar to the examples from Lucky (Uses per day) 10.10, but none worked (critical errors). But when I enter the value of the dice, everything works but once.

vast bane
dark canopy
# vast bane

no, just pass it an actual maxsize instead of a null options

#

{maxSize: whatever}

vast bane
#

I was like...what if I just make a size

#

what are the codes for the sizes?

#

specifically gargantuan

dark canopy
#

CONFIG.DND5E.[actor|token]Sizes

#

actor or token

vast bane
#

thank you

#

@edgy pagoda the reason why you should typically use the features name in the key is because generic terms can over time get forgotten and you won't realize you have them on two different automations in your world. Using the features name makes it safest so that you don't reuse it. But whatever you do, Don't use NAME.

#

Even though DAE tries to make you use NAME, rename it this is one of those keys you don't want dae auto completing

#

@honest wave

Change Enemy to Ally to target allies

Change Special to Self if you want to include the caster

edgy pagoda
#

I have renamed it several times. But the problem remains in place: after the bonus is applied, the status disappears.

vast bane
#

Share me what you have again, maybe theres another issue, is it on a feature as transfer on equip?

vast bane
# honest wave Perfect, thanks

Theres more to this though:
The second drop down in this image needs to be setup my way(or don't ignore defeated). This setting has weird results on levels maps and with walls with height.

honest wave
vast bane
vast bane
honest wave
vast bane
#
flags.midi-qol.optional.SomethingLessGeneric.damage.all
flags.midi-qol.optional.SomethingLessGeneric.label
flags.midi-qol.optional.SomethingLessGeneric.count
flags.midi-qol.optional.SomethingLessGeneric.criticalDamage

@edgy pagoda

#

replace SomethingLessGeneric with the name of the feature but change the name of the feature you made cause thats WAY to generic

#

or use mine, its unique enough

#

also FYI, I don't know if count takes 2 values

#

As for why its auto deleting, its because you have your time playing

#

you aren't in combat and your seconds are set to 10 seconds

#

you should clear out the durations entirely

#

@edgy pagoda Is it once per turn endlessly or does it have charges too?

#

Your item has no charges setup, so if its meant to be once per turn endlessly forever, take off the ,Itemuses.SomethingLessGeneric in my above effect image. Otherwise add charges to your feature.

#

Also remove the action type on the item:
(Clear the formula before you clear the action type)

#

I gave you an example of charges too in the image

edgy pagoda
#

I have removed the specified elements

vast bane
#

You aren't going to like my answer bud

lean holly
#

Trying to do a midi overtime regeneration and I keep getting an error about opening or closing of ( ). I cannot figure out what I am missing. Will one of you wizards please instruct an apprentice like me?

turn=start,
damageRoll=max(1, floor(@details.level /2)),
damageType=healing,
condition=@attributes.hp.value > 0 && @attributes.hp.value < @attributes.hp.max
edgy pagoda
# vast bane

I completely forgot about this module. Thanks again!

vast bane
#

ask in macro polo if Math.max is also a thing

dark canopy
#
turn=start,
damageRoll=10,
damageType=healing,
condition=@attributes.hp.value > 0 && @attributes.hp.value < @attributes.hp.max,
rollMode=gmroll,
label=Regeneration(Fire or Acid prevents)

try ini coloring for these blocks, little easier to read

lean holly
#

So the roll isn't a flat 10. its based on total character level. But I do like adding the lable.

#

Ill pop into macro polo thank you 🙂

vast bane
#

yeah I suspect your () error is cause its technically a macro not a damage formula on an item

#

I think it wants Math.floor

umbral basin
#

Is there a way to make an attack/failed saving throw give a creature resources back?
I'm trying to make a boss where if the a player fails/is hit by certain abilities the boss regains charges to powerup an ability.

Is there an easy way to do this?🤔
Basically trying to give it "resources.legres.value"

vast bane
#

If this.hitTargets != 0 { Stuff}

#

if its a save I don't know that one

#

but its probably this.save something so you could ctrl F in here for someone that wrote one already

lean holly
#

well gang. Macropolo sent me back here lol

umbral basin
vast bane
lean holly
#

Too late, honeybadger is in both channels lol

dark canopy
#

nothing from this problem is a macro problem

#

not sure why it was redirected

violet meadow
#

I am confused. What are you using right now @lean holly

umbral basin
# vast bane If this.hitTargets != 0 { Stuff}
async function wait(ms) {return new Promise(resolve => {setTimeout(resolve, ms);});}
if(args[0].hitTargets.length === 0) return {};
let tokenD = canvas.tokens.get(args[0].tokenId);
let actorD = game.actors.get(args[0].actor._id);
let target  = canvas.tokens.get(args[0].hitTargets[0].id);
let itemD = args[0].item;
let gameRound = game.combat ? game.combat.round : 0;

const diceMult = args[0].isCritical ? 2: 1;
const numDice = 3 * diceMult;
args[0].isCritical ? numDice * 2 : numDice;
let damageRoll = await new Roll(`${numDice}d6`).roll();
await new MidiQOL.DamageOnlyWorkflow(actorD, tokenD, damageRoll.total, "necrotic", [target], damageRoll, {flavor: "Necrotic Bite - Damage Roll (Necrotic)", damageList: args[0].damageList, itemCardId: args[0].itemCardId });
await MidiQOL.applyTokenDamage([{damage: damageRoll.total, type: "healing"}], damageRoll.total, new Set([tokenD]), itemD, new Set());
const effectData = {
    label: "Drain",
    icon: "icons/skills/wounds/blood-drip-droplet-red.webp",
    origin: args[0].uuid,
    changes: [{
        "key": "system.attributes.hp.max",
        "value": `-${damageRoll.total}`,
        "mode": 2,
        "priority": 20
    }],
    disabled: false,
    duration: { seconds: 86400, startRound: gameRound, startTime: game.time.worldTime },
    flags: {
        dae: {
            specialDuration: ['longRest']
        }
    }
};
#
await MidiQOL.socket().executeAsGM("createEffects", {actorUuid: target.actor.uuid, effects: [effectData]});
//let hpNow = target.actor.system.attributes.hp.max;
//let updateHP = hpNow - damageRoll.total;
let updateHP = target.actor.system.attributes.hp.max;
let the_message = `<p>${tokenD.name} drains ${target.name} of ${damageRoll.total} pts from their maximum Hit Point value!</p><p>${target.name} now has Maximum Hit Point maximum of ${updateHP}.</p><br><p><b>If it reaches O, they die!!</b></p><br><p> ${tokenD.name} regains ${damageRoll.total} Hit Points back!</p>`;
await wait(600);
ChatMessage.create({
      user: game.user.id,
      speaker: ChatMessage.getSpeaker({actorD: actorD}),
      content: the_message,
      type: CONST.CHAT_MESSAGE_TYPES.EMOTE
    });
lean holly
# violet meadow I am confused. What are you using right now <@285476563066028032>
turn=start,
damageRoll=max(1, floor(@details.level /2)),
damageType=healing,
condition=@attributes.hp.value > 0 && @attributes.hp.value < @attributes.hp.max

This is the OG overtime I am working with. I added the label part after seeing Moto's example.
The error I am getting:

Uncaught (in promise) Error: undefined. Unbalanced group missing opening ( or closing )
violet meadow
umbral basin
lean holly
#

bugbear, same error.

violet meadow
#

@umbral basin quick recap of the issue?

vast bane
#

hot take, who cares if its not a whole number?

#

does @details.level / 2 work?

lean holly
#

Yes, it gives me a roll of 0.5 at level 1

vast bane
#

and does it add 1?

lean holly
#

But it should be a min of 1

vast bane
#

but did their hp go up?

lean holly
#

It seems to.

vast bane
#

its ugly, but they don't call me janky for nothing

honest wave
#

Is it possible to give proficiency in skills upon equipping/attuning to an item?

vast bane
violet meadow
vast bane
#

I think they are copying the regeneration premade

honest wave
vast bane
#

@lean holly can you show us the error?

lean holly
#

Yes I was, and just trying make it based on character level rounded down min of 1

lean holly
violet meadow
#

need to go get dinner, will circle back later

vast bane
#

that error doesn't always mean () it can be {}

inland vortex
#

I'm using the midi Paladin auras. They are unfortunately working for everyone within 10' feet, whether marked friendly or hostile. Aura of Courage actually puts the icon on the the token. Aura of Protection doesn't put the icon on, but it does give the saving throw bonuses. Aura of Protection says it needs BABonus, Devotion and Courage ask for Active Auras. All of those are running. None of them say they need to be renamed to get rid of the 10.0.10, but I tried them both ways and that doesn't change things.

umbral basin
inland vortex
#

Those are the logs when i hit an enemy with Blight while a pally is near

latent spade
vast bane
latent spade
#

i added ( ) around the whole thing that is why it has a ( before max for me.

modern badger
#

how would u code this? As in, letting the PC choose the amount of charges, rolling xd4 and spending that many charges .3.

vast bane
latent spade
#

no

vast bane
#

just don't use max

latent spade
#

i guess

vast bane
#

use round, its homebrew anyway

#

who cares if they get 1 more sometimes

#

Math.round

latent spade
#

does ceil give the right values?

#

1 for lvl 1, 1 for lvl 2, 2 for lvl 3, 2 for lvl 4... etc

vast bane
#

the actual book rule is always round down, but floor will cause 0 at level 1

#

wait a minute...is this a class feature @lean holly

#

I got a really funny idea

#

make it a scale value

latent spade
#

yeah scales are perfect for this

lean holly
#

It’s a race feature. If it says class it’s wrong.

#

Wereravens

#

From Curse of Strahd book.

vast bane
#

a janky solution would be to give their class a custom scale

#

then call the scale in that feature

#

oh wait its a monster?

#

yeah just do round

#

who cares if its 1 more sometimes

#

Math.round

#

and drop the max

#

If you also use my suggestion of putting in a whisper then the players will never know

vast bane
lean holly
#

It’s a character playable race.

#

I’ll try round in a few minutes 🙂

vast bane
static sparrow
modern badger
#

how so?

#

I dont see the way to do so .3.

vast bane
#

that item is all macro territory

#

theres been similar stuff done like that that included "Holy Power"

latent spade
#

not Math.round, just round

#

this is going straight into the roller of Foundry

vast bane
#

@lean holly Woops sorry take off the math in my example, I'll edit it now...

inland vortex
modern badger
latent spade
#

but yeah it sounds like something an issue could be made about that you cant do a little bit more advanced rolls because of , 😄

lean holly
#

That worked!

#

round for the win

vast bane
inland vortex
vast bane
#

you want the Holy Power shennanigans that were made 2-3 months back by some folks

#

Or you could look at Lay on Hands in midiqol samples

inland vortex
static sparrow
# modern badger how so?

Make the damage bonus optional, set resource consumption to the item’s uses, give it a scaling value of 1d4.

vast bane
latent spade
# lean holly round for the win

but since it is a racial feature going the scale route is still advisable. All that take that race get that feature right?

vast bane
lean holly
latent spade
#

ah right.... >.< sleepy brain

vast bane
static sparrow
vast bane
static sparrow
#

It’s worked fine for me.

#

Maybe there are some edge cases I haven’t hit?

latent spade
#

gonna have a short think on what to do.

modern badger
#

this should work but its not asking me :<

#

wait this doesnt work with midi

#

D:

static sparrow
#

You want damage rolls, not attack rolls.

vast bane
#

do you fast forward Saga?

static sparrow
#

Nope.

vast bane
#

@modern badger do you fast forward?

modern badger
#

ye

#

I do :<

static sparrow
#

Yeah, maybe it won’t ask then.

vast bane
#

Try it out, if it doesn't work, try turning off fast forward

static sparrow
#

You didn’t screenshot it but make sure that bonus is set to optional as well.

vast bane
#

I'm 99.9% sure this is pointless if fast forward is non negotiable hehe

static sparrow
#

If you want to use fast-forward or auto-rolling or whatever, macro it may have to be.

vast bane
#

just fast forward is the problem, auto roll is fine

modern badger
#

fast forward is non negotiable ye twt

#

gotdamn

inland vortex
# vast bane

Sorry to ask again, but what module is that setting part of?

modern badger
#

if only chris' premades let me look at the guts

vast bane
#

@tepid dock was the user who made a bunch of Holy Power items, maybe they can share insight on how to help

inland vortex
#

ty

vast bane
#

His auras don't show effects on tokens

static sparrow
modern badger
#

:0

vast bane
#

I actually think lay on hands is a better thing to plagerize

#

the midi sample

modern badger
#

well I'd be v grateful u.u

vast bane
#

it takes a value you enter and then applies a damage

modern badger
#

oooo

vast bane
#

it would be the value you enter *1(d4)

#

lay on hands is technically an item you roll that takes an input and then applies damage to the target(healing damage)

#

and expends that amount of the resource

modern badger
#

I'm gonna take a crack at it using lay on hands but I'd still appreciate the help offer

#

😓

static sparrow
#

Yep, I’ll follow up later.

modern badger
#

it says 'blocked by preitemroll macro'

#

:1

inland vortex
vast bane
#

If you are trying to use lay on hands, it checks for paladin and resource linkage and returns a notification if theres a problem so start with those two

tepid dock
#

Just seeing this, anyone have a TL;DR?

vast bane
inland vortex
#

Is there a module or a way to automate players polymorphing others, or does the DM have to handle that in the case of enemies and the DM or affected player handle it if it's another PC?

#

I see videos online of people doing this, but I'm not finding those modules

vast bane
inland vortex
vast bane
#

its in the same compendium as the generic actions

#

it won't set the permissions right since the summoner summons it, but you can use a hotbar macro to swap permissions

#

OR, you could be really crazy and make it run the macro on the target...

#

advanced macros lets you run macros as other users

inland vortex
tepid dock
# modern badger if only chris' premades let me look at the guts

I can't say I can help too much. Most of the custom holy power items I have created run off resource points. There aren't really weapon charges. You could try using the module Magic Item, but I believe is deprecated, or just not supported and has some bugs. But Magic Item does let you have charges on items and regain them on LR. I still use it and it some times is a pain.

vast bane
#

Its usually wise to set a weapon up like the lay on hands feature so that you aren't consuming charges everytime you swing the weapon anyway

#

aka resource pool setup via dae on the weapon

green wolf
#

Hey all, two questions.

  1. Is there an OverTime tag that lets you add a description (not a name like label)?
  2. Is there a way to make someone immune to an effect after the save? I have saveRemove=true but I was wondering if there was something else that would be better as this will reapply if the character re enters the aura.
vast bane
#

@violet meadow
let targets = await MidiQOL.findNearby(null, paladin, distance, {maxSize: grg});

What am I doing wrong? should it be {maxSize: grg, null, null}?

vast bane
violet meadow
#

instead of grg

#

or define grg first