
Hi!
In Warhammer we are rolling 1d100.
Some skills refer to the unity value of the rolled result.
I know that there is " $[[0]] " for using last roll in the same macro.
Is there any way to show only the unity value instead?
Hi!
In Warhammer we are rolling 1d100.
Some skills refer to the unity value of the rolled result.
I know that there is " $[[0]] " for using last roll in the same macro.
Is there any way to show only the unity value instead?
GiGs said:
What do you mean by unity value?
When your roll is 51 unity value is 1, when it's 48 unity is 8.
I dont think you'll be able to do that without an API script and pro subscription.
Roll20 dice cant do conditional effects (this value is a 0 sometimes, and a 10 other times). Sometimes its possible with a very convoluted dice roll structure, but to do it in this case would require doing some things with the whole d100 roll, and different things with the units value, which you can't do at all.
Aaron's suggestion will work if you just want to display the units value, and can accept all results of 10, 20, 30, etc will be displayed as 0, and not as 10.
EDIT - crossed posted with Aaron. Ignore my second option. The default template trick would still work, though, to get them in the "right" order.
You can at least get the rolls in order by putting the inline rolls outside of the brackets, like this:
&{template:default} [[ [[1d100]]%10 ]] {{name=Funky Skill Roll}} {{d100 roll=$[[0]]}} {{Unity roll=$[[1]]}}
This doesn't solve the 0's instead of 10's problem, though. If you really want 10's and just want text display (aren't trying to compare the rolls programmatically), I suppose you could create a rollable table with 100 entries, with each entry having text like e.g. "Roll=60 | Unity value=10". Then roll this table with [[1t[TableName]]].
Thanks for the cool idea!
Unfortunately it doesn't work in the wfrp4 template for weapons. Take a look:
/w gm &{template:wfrp4} {{name=@{selected|character_name}}} {{title= Attack}} {{dice=[[(([[1d100]]-1)%10)+1 ]] cs01cs02cs03cs04cs05cs11cs22cs33cs44cs55cs66cs77cs88cf96cf97cf98cf99cf100 ]]}} {{against=[[ @{selected|MeleeTwohanded} ]]}} {{weapon=WarHammer}} {{range= }} {{damage=[[[[@{selected|current_sb}]] + 6]] + Penetrating $[[1]] +}} {{qualities= }} {{description= }} {{hitlocation=1}} ]]
I only get a result of 1-10 from the die roll. Another macro:/w gm &{template:wfrp4} {{name=@{selected|character_name}}} {{title= Attack}} [[(([[1d100]]-1)%10)+1 ]] {{dice=[[$[[0]]cs01cs02cs03cs04cs05cs11cs22cs33cs44cs55cs66cs77cs88cf96cf97cf98cf99cf100 ]]}} {{against=[[ @{selected|MeleeTwohanded} ]]}} {{weapon=WarHammer}} {{range= }} {{damage=[[[[@{selected|current_sb}]] + 6]] + Penetrating $[[1]] +}} {{qualities= }} {{description= }} {{hitlocation=1}} ]]
Yeah, it's definitely not going to work for that. That's context that could have been helpful initially. The only option here would be to have a custom API script that would report the Unity number separately, which would require the API, a Pro Subscriber Feature.
The problem with using this with a rolltemplate, is the template will only print the output its been programmed for.
Also, you'll want to put that long string (cs01cs02 etc) right on the d100.
So you can try something like
/w gm &{template:wfrp4} {{name=@{selected|character_name}}} {{title= Attack}} [[ (([[1d100cs01cs02cs03cs04cs05cs11cs22cs33cs44cs55cs66cs77cs88cf96cf97cf98cf99cf100]]-1)%10)+1]] {{dice=$[[0]]}} {{against=[[ @{selected|MeleeTwohanded} ]]}} {{weapon=WarHammer}} {{range= }} {{damage=[[[[@{selected|current_sb}]] + 6]] + Penetrating $[[1]] +}} {{qualities= }} {{description=Units: $[[1]] }} {{hitlocation=1}} ]]
This shows the units value in the description section. If that rolltemplate allows you to create your own sections, you could try adding {{unity=$[[1]]}} instead.
GiGs said:
The problem with using this with a rolltemplate, is the template will only print the output its been programmed for.
Also, you'll want to put that long string (cs01cs02 etc) right on the d100.
So you can try something like
/w gm &{template:wfrp4} {{name=@{selected|character_name}}} {{title= Attack}} [[ (([[1d100cs01cs02cs03cs04cs05cs11cs22cs33cs44cs55cs66cs77cs88cf96cf97cf98cf99cf100]]-1)%10)+1]] {{dice=$[[0]]}} {{against=[[ @{selected|MeleeTwohanded} ]]}} {{weapon=WarHammer}} {{range= }} {{damage=[[[[@{selected|current_sb}]] + 6]] + Penetrating $[[1]] +}} {{qualities= }} {{description=Units: $[[1]] }} {{hitlocation=1}} ]]
This shows the units value in the description section. If that rolltemplate allows you to create your own sections, you could try adding {{unity=$[[1]]}} instead.
It works perfectly!
Thank you ALL, you are very helpfull :)