
So i'm trying to make a Chat Menu for one of my NPC sheets that gives me quick access to all it's ability macros that are tied to it's sheet. The ability macro works without a problem on it's own, but when used through the Chat Menu, it gives me the TypeError: Cannot read property 'substring' of undefined, and I can't figure out why.
This is the ability macro.
/w gm &{template:default} {{name=Close the Gap}} {{Claw1=* Hit: * [[ 1d20+@{Kotokaze|melee-total}[Attack Bonus]+1[Weapon Focus]-2[Two-Weapon Fighting] ]] * Crit Confirm: * [[ 1d20+@{Kotokaze|melee-total}[Attack Bonus]+1[Weapon Focus]-2[Two-Weapon Fighting] ]] * Damage: * [[ 1d6+@{Kotokaze|str-mod}[STR] ]] Slashing}} {{Claw2=* Hit: * [[ 1d20+@{Kotokaze|melee-total}[Attack Bonus]+1[Weapon Focus]-2[Two-Weapon Fighting] ]] * Crit Confirm: * [[ 1d20+@{Kotokaze|melee-total}[Attack Bonus]+1[Weapon Focus]-2[Two-Weapon Fighting] ]] * Damage: * [[ 1d6+@{Kotokaze|str-mod}[STR] ]] Slashing}} {{Slam=* Hit: * [[ 1d20+@{Kotokaze|melee-total}[Attack Bonus]-2[Two-Weapon Fighting] ]] * Crit Confirm: * [[ 1d20+@{Kotokaze|melee-total}[Attack Bonus]-2[Two-Weapon Fighting] ]] * Damage: * [[ 2d6+@{Kotokaze|str-mod}[STR] ]] Bludgeoning + [[ 1d8+@{Kotokaze|str-mod}[STR] ]] Bludgeoning from Off-hand}}
Here is the Chat Menu, which only has the above ability in it for now as I am testing.
/w gm &{template:default} {{name=Test}} {{Test=[Close the Cap](~Close the Gap)}}
What am I doing wrong?