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

ChatSetAttr Muti Target Syntax

Easy question for the community =D I'm trying to change attributes on multiple targeted characters using chatsetattr.  I don't want to use the --sel option as I want the players to be able to pick their targets. I'm using the syntax below which only works on the 1st target chosen.  I'm able to choose 3 targets as hoped, but it only applies to the first one I pick.  I'm sure I'm making a simple rookie syntax error: !setattr --charid @{target|target_1|character_id} --charid1 @{target|target_2|character_id} --charid2 @{target|target_3|character_id} --silent --repeating_savemod_$1_global_save_active_flag|1 --repeating_tohitmod_$1_global_attack_active_flag|1 --repeating_skillmod_$1_global_skill_active_flag|1
You are close - try this: !setattr --charid @{target|target_1|character_id} @{target|target_2|character_id} @{target|target_3|character_id} --silent --repeating_savemod_$1_global_save_active_flag|1 --repeating_tohitmod_$1_global_attack_active_flag|1 --repeating_skillmod_$1_global_skill_active_flag|1 I believe you just need to separate the character ids with spaces.  It doesn't know what --charid1 or --charid2 is.
Hi Will, I actually tried that as well already and got the error below: