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

Completely new to API scripts, need a walk-thru on how to use one, ammo tracker

I’m completely new in regards to writing macros/API scripts. I can understand them once I see how one is written out, but I have never used API scripts or anything of the sort. Can someone help me with a step by step instruction on how to go about this? I am trying to get my Ammo tracker script working and I simply cannot get it to work.  I am using 5e OGL sheet, and I believe I have everything laid out correctly within the sheet.   I went into my Game Settings, API Scripts, added Ammo from the Script Library, hit Save Script and then loaded the game to check it out.  I have the Ammo Tracker turned on in my character sheet.  I have the character selected.  This is the macro I created: !ammo @{Finellen Emberstone|character_id} Bolts -1  This is the message I get back Here is the setup on the character sheet  What am I doing wrong?  Sorry for the stupid question, but again I've never written macros ever, which means I know nothing about API scripts and the like.  After watching videos I completely understand macros and understand how to inspect elements to gather information, but again I'm totally new to this and cannot figure this out.  Please help!  Thanks!
1473950397

Edited 1473952398
Scott C.
Forum Champion
Sheet Author
API Scripter
Compendium Curator
Hi Krimm, Welcome to the wonderful world of API Scripts. First a warning though: Use of these scripts should be thought about carefully, as prolonged use can cause addiction. Now that I've got my morning whimsy out of the way, on to your actual question. I believe that Aaron's ammo script (which is the ammo script in one-click) doesn't work well with repeating sections. There is however an alternative. The 5e OGL sheet has a companion script (which is also available from the one-click drop-down) that will handle ammo tracking for the sheet very well. Check out the  sheet's wiki , specifically the details on utilizing the ammo tracking functionality of the companion script  at the very bottom of the page . -Scott
1473950803
The Aaron
Pro
API Scripter
(Also, apologies for the confusion. Ammo is a fairly old script and does things in a way that makes sense for 3 years ago, back before character sheets existed. I hope to revamp it soon. )
1473951841
Ziechael
Forum Champion
Sheet Author
API Scripter
The Aaron said: (Also, apologies for the confusion. Ammo is a fairly old script and does things in a way that makes sense for 3 years ago, back before character sheets existed. I hope to revamp it soon. ) The reasons to just keep stacking up don't they ;) Hurry up and relocate to the opposite end of the country so we can have your full attention again already!