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

Problem with Universal saving throws

1496217768

Edited 1496219238
I was searching for ways to make saving throw macro that can be used both for PC and NPC, and I thought i had it until things went wrong.. can anyone tell me what I've done wrong? @{selected|token_name} rolls ?{Save Type| Strength, [[1d20 - (@{selected|npc} - 1)*@{selected|strength_save_bonus} - @{selected|npc}*(@{selected|npc_str_save_flag}-1)*floor((@{selected|npcd_str}-10)/2) + @{selected|npc}*@{selected|npc_str_save_flag}*@{selected|npcd_str_save}]] for STR| Dexterity, [[1d20 - (@{selected|npc} - 1)*@{selected|dexterity_save_bonus} - @{selected|npc}*(@{selected|npc_dex_save_flag}-1)*floor((@{selected|npcd_dex}-10)/2) + @{selected|npc}*@{selected|npc_dex_save_flag}*@{selected|npcd_dex_save}]] for DEX| Constitution, [[1d20 - (@{selected|npc} - 1)*@{selected|constitution_save_bonus} - @{selected|npc}*(@{selected|npc_con_save_flag}-1)*floor((@{selected|npcd_con}-10)/2) + {selected|npc}*@{selected|npc_con_save_flag}*@{selected|npcd_con_save}]] for CON| Intelligence, [[1d20 - (@{selected|npc} - 1)*@{selected|intelligence_save_bonus} - (@{selected|npc})*(@{selected|npc_int_save_flag}-1)*floor((@{selected|npcd_int}-10)/2) + {selected|npc}*@{selected|npc_int_save_flag}*@{selected|npcd_int_save}]] for INT| Wisdom, [[1d20 - (@{selected|npc} - 1)*@{selected|wisdom_save_bonus} - (@{selected|npc})*(@{selected|npc_wis_save_flag}-1)*floor((@{selected|npcd_wis}-10)/2) + {selected|npc}*@{selected|npc_wis_save_flag}*@{selected|npcd_wis_save}]] for WIS| Charisma, [[1d20 - (@{selected|npc} - 1)*@{selected|charisma_save_bonus} - (@{selected|npc})*(@{selected|npc_cha_save_flag}-1)*floor((@{selected|npcd_cha}-10)/2) + {selected|npc}*@{selected|npc_cha_save_flag}*@{selected|npcd_cha_save}]] for CHA} saving throw! This is what happens when I roll for Strength... other saving throws show similar problem.. EDIT: The macro combined two macros i've made, which worked fine seperately PC @{selected|token_name} rolls ?{Save Type| Strength, [[1d20 + @{selected|strength_save_bonus}]] for STR| Dexterity, [[1d20 + @{selected|dexterity_save_bonus}]] for DEX| Constitution, [[1d20 + @{selected|constitution_save_bonus}]] for CON| Intelligence, [[1d20 + @{selected|intelligence_save_bonus}]] for INT| Wisdom, [[1d20 + @{selected|wisdom_save_bonus}]] for WIS| Charisma, [[1d20 + @{selected|charisma_save_bonus}]] for CHA} saving throw! NPC @{selected|token_name} rolls ?{Save Type| Strength, [[1d20 -(@{selected|npc_str_save_flag}-1)*floor((@{selected|npcd_str}-10)/2) + @{selected|npc_str_save_flag}*@{selected|npcd_str_save} ]] for STR| Dexterity, [[1d20 -(@{selected|npc_dex_save_flag}-1)*floor((@{selected|npcd_dex}-10)/2) + @{selected|npc_dex_save_flag}*@{selected|npcd_dex_save}]] for DEX| Constitution, [[1d20 -(@{selected|npc_con_save_flag}-1)*floor((@{selected|npcd_con}-10)/2) + @{selected|npc_con_save_flag}*@{selected|npcd_con_save}]] for CON| Intelligence, [[1d20 -(@{selected|npc_int_save_flag}-1)*floor((@{selected|npcd_int}-10)/2) + @{selected|npc_int_save_flag}*@{selected|npcd_int_save}]] for INT| Wisdom, [[1d20 -(@{selected|npc_wis_save_flag}-1)*floor((@{selected|npcd_wis}-10)/2) + @{selected|npc_wis_save_flag}*@{selected|npcd_wis_save}]] for WIS| Charisma, [[1d20 -(@{selected|npc_cha_save_flag}-1)*floor((@{selected|npcd_cha}-10)/2) + @{selected|npc_cha_save_flag}*@{selected|npcd_cha_save}]] for CHA} saving throw!
1496230791
Ziechael
Forum Champion
Sheet Author
API Scripter
In a meeting so can't delve too deep but I'm noticing a few missing "@" especially from the CON check onwards.
Ah that fixed it! Thank you so much!