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 .
×

Another question about Macros: outcome depends on Attribute number

Hi, I have a game I'm making and playing here on Roll20. Several of the monsters do different damage depending on the player's level (e.g. 1-[1d6] 2-[2d6] etc.) and I'm trying to find a way to make a macro, or macro+attributes mix, for their damage. What I would like to do, but haven't found a way to do it yet: Damage = (if Player Level = 1, then 1d6) (if Player Level = 2, then 2d6) The closest I've been able to come to it is making a {Player Level} Attribute as well as a attribute for each level, containing the matching damage. Then the macro calls the {player Level} which in turn, calls the right level damage:  {Player Level} = @{1}  (currently set to call Attribute {1}) {1} = 1d6 {2} = 2d6 &{template:default} {{name=Otheller White}} {{Attack=[[@{Player Level} ]]}} Does anybody have any ideas on how to do this?
1554191355

Edited 1554191369
vÍnce
Pro
Sheet Author
Not sure of your exact attribute names, but you might try something like this given name=@{character_name} level=@{level} &{template:default} {{name=@{selected|character_name}}} {{Damage=[[@{selected|level} d6 ]]}} The "selected|" bit just tells roll20 to grab the selected token's character name and level from the linked sheet.  This way you can make one macro and use it for multiple token/characters.