Advertisement Create a free account

OGL Companion and Longrest

Is there a way to have !longrest work for all characters instead of having to do it 1 at a time?
1528922312
Yes! Simply make a macro, and type all lines in once. - Then when the time comes, just press the macro.... /emas The group all finish their long rest, heal up and restore their used spell slots ... !longrest PLAYERNAME1 !longrest PLAYERNAME2 !longrest PLAYERNAME3 !longrest PLAYERNAME4 !longrest PLAYERNAME5 ---- I actually went a step further and also set their 'abilities' back to max too. - Such as second wind, wild shape etc.... This is based on them using the two 'resource' boxes. This won't work if they also include things like 'Ammo'. Since this obviously shouldn't increase back to Maximum when they rest.... It also uses the !setattr api (https://app.roll20.net/forum/post/3737514/script-chatsetattr-set-character-attributes-via-chat-messages/?pagenum=1)  !setattr --silent --name PLAYERNAME1 --class_resource|@{PLAYERNAME1|class_resource|max} !setattr --silent --name PLAYERNAME2 --class_resource|@{PLAYERNAME2|class_resource|max} !setattr --silent --name PLAYERNAME3 --class_resource|@{PLAYERNAME3|class_resource|max} !setattr --silent --name PLAYERNAME4 --class_resource|@{PLAYERNAME4|class_resource|max} !setattr --silent --name PLAYERNAME5 --class_resource|@{PLAYERNAME5class_resource|max} !setattr --silent --name PLAYERNAME1 --other_resource|@{PLAYERNAME1|other_resource|max} !setattr --silent --name PLAYERNAME2 --other_resource|@{PLAYERNAME2|other_resource|max} !setattr --silent --name PLAYERNAME3 --other_resource|@{PLAYERNAME3|other_resource|max} !setattr --silent --name PLAYERNAME4 --other_resource|@{PLAYERNAME4|other_resource|max} !setattr --silent --name PLAYERNAME5 --other_resource|@{PLAYERNAME5|other_resource|max} /desc The DM has automatically reset all relevant stats back to max :)