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

5e OGL Sheet Psionic Macros?

I am using the Unearthed Arcana psionic from the take 2 sheet. Does anyone have any macros that let you choose how many psi points to use and display the spellcard based on that then also uses a resource/ammo for psi points?
Here's a macro that uses the API Scripts ChatSetAttr (required) and PowerCards (optional). Add it to the very end of your spell's 'Description' field: ***Psi points spent:*** [[ [[ ?{Points spent|1} * {@{class_resource} + d0}>?{Points spent} ]] + d0cs1cf[[ {@{class_resource} + d0}>?{Points spent} ]] ]] ***Psi points:*** [[ @{class_resource} + d0cs1cf[[ {@{class_resource} + d0}>?{Points spent} ]] ]] → [[ abs([[{@{class_resource} + d0}>?{Points spent}]] * ?{Points spent} - @{class_resource}) + d0cs1cf[[ {@{class_resource} - ?{Points spent}, 0}kh1 ]] ]] }} !setattr --silent --charid @{character_id} --class_resource|[[ abs([[{@{class_resource} + d0}>?{Points spent}]] * ?{Points spent} - @{class_resource}) ]] !power --whisper|none --charid| --?? @{class_resource} < ?{Points spent} ?? emote|ERROR: failed to spend ?{Points spent} / @{class_resource} Psi Points. !
1477916098
Kryx
Pro
Sheet Author
API Scripter
Psi Points is implemented as a native part of the Shaped sheet if you're interested. It also includes my  homebrew version of psionics . I'll probably only add support for UA psionics when that is more finalized.
Kryx said: Psi Points is implemented as a native part of the Shaped sheet if you're interested. It also includes my  homebrew version of psionics . I'll probably only add support for UA psionics when that is more finalized. ....can i switch to shaped sheets with the storm king's thunder?
1477928693
Kryx
Pro
Sheet Author
API Scripter
marty r. said: ....can i switch to shaped sheets with the storm king's thunder? At this current time there are some issues with the conversion script I have setup. A good majority of the process is automated, but items like spells don't port over seamlessly. I'm working toward this being a seamless process, but it is not currently. Perhaps your best bet is to use ammo/resource on the OGL sheet for tracking psi points and reducing that as used. Or perhaps make your own field called "Psi Points" in the "Attributes and Abilities" tab and link that on your token.
current plan is using a resource, like ammo. I just am unsure how to adjust those values within a macro. I was gonna make a macro for each spell, that asks you 'how many psi points will you spend' then display the spell effects based on that and spend points from your resource accordingly.  but, thats above me.
1477937665
Kryx
Pro
Sheet Author
API Scripter
You can't adjust those values with a macro. It has to be done via API.
and a macro cannot initiate an API call?
1477946200

Edited 1477946243
Jakob
Sheet Author
API Scripter
marty r. said: and a macro cannot initiate an API call? It can ( if the right scripts are installed) , look at Silvyre's advice further up. Adjusting attribute values via macros is the reason ChatSetAttr exists.