Page 1 of 1

I'm new to this and deed help with Output

Posted: Sun Oct 18, 2020 1:52 pm
by thunderwolf5445
whenever I Run this regardless of how i might change it the output is always
'' '' Elf has been healed for 65 HP!
or
'' , Elf has been healed for 345 HP! Elf has also been revived! ''
The Quotes are the problem as they are in the chat output itself where I just want it to display the sentences normally.
and the reason for the strings being in [r:"string"] form is something i thought might make a difference but the output is
exactly the same either way i type it also the reason for 4 IFs is i thought that might change it too. Here's the code.


[if(state.Dead == 0), CODE:{[h:isDead = "no"]}]
[if(state.Dead == 1), CODE:{[h:isDead = "yes"]}]
[if(isDead == "yes"), CODE:{[h:state.Dead = 0], [r:token.name][r:" has been healed for "][r:HealAmount][r:" HP! "][r:token.name][r:" has also been revived!"]}] -------Elf has been healed for 345 HP! Elf has also been revived!
[if(isDead == "no"), CODE:{[r:token.name][r:" has been healed for "][r:HealAmount][r:" HP!"]}] --- Name has been healed for 12 HP!

Re: I'm new to this and deed help with Output

Posted: Sun Oct 18, 2020 2:56 pm
by aliasmask
Try something like this:

Code: Select all

[R: strformat("%{token.name} has been healed for %{HealAmount} HP!")]
[R, if(state.Dead): strformat(" %{token.name} has also been revived!"); ""]
[H: state.Dead = 0]

Re: I'm new to this and deed help with Output

Posted: Sun Oct 18, 2020 3:53 pm
by thunderwolf5445
Thanks so much, I was so frustrated, works like a charm now :D