Roll20 uses cookies to improve your experience on our site. Cookies enable you to enjoy certain features, social sharing functionality, and tailor message and display ads to your interests on our site and others. They also help us understand how our site is being used. By continuing to use our site, you consent to our use of cookies. Update your cookie preferences .
×
Create a free account

Simple OGL Passive Perception Macro

1505846305
Zym
Sheet Author
How can I +10 to this to create a passive perception macro? /w gm @{selected|character_name} ***has a Perception bonus of + @{selected|npc_perception_flag}***
1505847430

Edited 1505862929
Use this, it will account for whether the NPC has a perception bonus and if it doesn't it will revert to using the wisdom modifier [[[[@{selected|npcd_wis_mod}*{1@{selected|npc_perception}0,0}=10+0@{selected|npc_perception}]]+10]] EDIT: Sorry I forgot a '|' in the final attribute. Try now.
1505860247
Zym
Sheet Author
I received this error in the chat output. I appreciate the help though :-)  TypeError: Cannot read property 'substring' of undefined
The OGL sheet has a passive_wisdom attribute you can use. It only works if you haven't changed the sheet from the original values.
Sky said: The OGL sheet has a passive_wisdom attribute you can use. It only works if you haven't changed the sheet from the original values. Does that work for NPCs as well? I never tried before. Alex Wilson said: I received this error in the chat output. I appreciate the help though :-)  TypeError: Cannot read property 'substring' of undefined Sorry about that, I fixed the original post. Try now
Yeah, it works with npc's. Didn't try it with pc's.
1505935377

Edited 1505935451
Zym
Sheet Author
Thanks for the edit. It works now What other macros could you recommend set up for an OGL Sheet game? /w gm @{selected|character_name} has a Passive Perception of [[[[@{selected|npcd_wis_mod}*{1@{selected|npc_perception}0,0}=10+0@{selected|npc_perception}]]+10]]
1505937368

Edited 1505937415
I have a saving throw macro that I use. It rolls every save (twice) and I just use the save I need rather than having to select which type. It also takes into account if the NPC has proficiency with the save (same as the perception calculation above). @{selected|wtype} &{template:default}{{name=Saving Throws}}{{ Str Save=[[1d20+[[@{selected|npcd_str_mod}*{1@{selected|npc_str_save}0,0}=10+0@{selected|npcd_str_save}]]]]|[[1d20+[[@{selected|npcd_str_mod}*{1@{selected|npcd_str_save}0,0}=10+0@{selected|npcd_str_save}]]]] }}{{ Dex Save=[[1d20+[[@{selected|npcd_dex_mod}*{1@{selected|npc_dex_save}0,0}=10+0@{selected|npcd_dex_save}]]]]|[[1d20+[[@{selected|npcd_dex_mod}*{1@{selected|npcd_dex_save}0,0}=10+0@{selected|npcd_dex_save}]]]] }}{{Con Save= [[1d20+[[@{selected|npcd_con_mod}*{1@{selected|npc_con_save}0,0}=10+0@{selected|npcd_con_save}]]]]|[[1d20+[[@{selected|npcd_con_mod}*{1@{selected|npcd_con_save}0,0}=10+0@{selected|npcd_con_save}]]]] }}{{Int Save= [[1d20+[[@{selected|npcd_int_mod}*{1@{selected|npc_int_save}0,0}=10+0@{selected|npcd_int_save}]]]]|[[1d20+[[@{selected|npcd_int_mod}*{1@{selected|npcd_int_save}0,0}=10+0@{selected|npcd_int_save}]]]] }}{{Wis Save= [[1d20+[[@{selected|npcd_wis_mod}*{1@{selected|npc_wis_save}0,0}=10+0@{selected|npcd_wis_save}]]]]|[[1d20+[[@{selected|npcd_wis_mod}*{1@{selected|npcd_wis_save}0,0}=10+0@{selected|npcd_wis_save}]]]] }}{{Cha Save= [[1d20+[[@{selected|npcd_cha_mod}*{1@{selected|npc_cha_save}0,0}=10+0@{selected|npcd_cha_save}]]]]|[[1d20+[[@{selected|npcd_cha_mod}*{1@{selected|npcd_cha_save}0,0}=10+0@{selected|npcd_cha_save}]]]] }}
1505937736

Edited 1505937802
Other than Perception/Saves I followed how Taking 20 creates his  monster manual and I have custom macros for enemy spellcasters so that I don't have to open their character sheet to see the spells/dc/slots available to them (without API this last macro takes a lot of time to set up, but I find that it's worth it). This is my spellcasting macro for a Flameskull (you will not be able to copy and paste this because the row ids (repeating_spell-npc_ROWID) will not match your character sheet. You can however replace these values with the row ids (or simply $X where X is how many spells from the top of the list the spell is starting with 0) and it should work that way. @{wtype} &{template:default}{{name=@{selected|character_name} Spellcasting}}{{Spell Save DC @{selected|npc_spelldc}=@{selected|npc_spellattackmod} to hit with spell attacks}}{{• Cantrip (at will) =[@{repeating_spell-npc_-KMzeMTQg8NO-XDsMLaH_spellname}](~Flameskull|repeating_spell-npc_-KMzeMTQg8NO-XDsMLaH_spell) }}{{• 1st level (3 slots) =[@{repeating_spell-npc_-KMzeOayiMC0BD6pVf0r_spellname}](~Flameskull|repeating_spell-npc_-KMzeOayiMC0BD6pVf0r_spell) [@{repeating_spell-npc_-KMzeS5ZWxc6yrmVgQAe_spellname}](~Flameskull|repeating_spell-npc_-KMzeS5ZWxc6yrmVgQAe_spell) }}{{• 2nd level (2 slots) =[@{repeating_spell-npc_-KMzeV1BRTRtgUqtF3oC_spellname}](~Flameskull|repeating_spell-npc_-KMzeV1BRTRtgUqtF3oC_spell) [@{repeating_spell-npc_-KMzeXWw0U8vAH0GNABR_spellname}](~Flameskull|repeating_spell-npc_-KMzeXWw0U8vAH0GNABR_spell) }}{{• 3rd level (1 slot) =[@{repeating_spell-npc_-KMzeaE3poTpD5gPSiSN_spellname}](~Flameskull|repeating_spell-npc_-KMzeaE3poTpD5gPSiSN_spell) }} What's nice about the spellcasting macro is it looks like this in chat
1505944836
Zym
Sheet Author
Okay thanks. I will give that a whirl and see if I can edit some macros and see what I end up with. If I have some productive outcomes I will share in a follow up ;-)