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

[API: Ammo / 5e Shaped] Completely lost... I've tried everything I can think of...

1500852770

Edited 1500856606
Ok first a little disclaimer; I'm a complete macro-idiot, so any help that assumes I know what to do and where to put it is more or less wasted on me, even though I still appreciate it. So I've been trying to set up the Ammo API for one of my players, and I'm having a lot of trouble getting it to work, and it's a no-brainer that it's on my end the problem lies. This is what I'm getting for trying to set it up for the bullets. I'm writing the code into the chat, but I'm not even sure if that is the correct way. So what I've been doing so far is using the chat command to get the token id and the character id. I've tried using both and the normal name but still getting attribute error when typing the !ammo command (with all parameters) into chat. I'm at a loss for where to put everything and what I need to do with the character sheet (if anything) to set it all up.
1500853928

Edited 1500854091
keithcurtis
Forum Champion
Marketplace Creator
API Scripter
What do you get in the chat if you click the bullets area of the macro, and then use the up arrow (while in the chat input field)? That should be the actual command. From what I am seeing, you are referencing a character by token and id, but not referencing a specific ability of the character.
I'm getting this: @{Janne|output_option} &{template:5e-shaped} {{character_name=@{Janne|character_name}}} @{Janne|show_character_name} {{title=Bullets}} {{text_big=40}}
1500854863

Edited 1500855393
I'm using the API Ammo script that The Aaron has made, and I'm typing in !ammo @{selected|character_id} Bullets -1 Bullets inside the chat, while I have the token selected. I've replaced character_id with both the character's id, token's id and the name of the character/token and none of it works. Do I need to set up Uses on the weapon? Do I need to add some commands on the weapon itself? I have no clue here... This is what is says on the script page: According to this, I should be doing it right
Use the companion script instead. Even if you do not need the other functions, the companion script will allow you to track resources by enabling it through the sheet itself. When adding an attack create a new type of ammo with your desired name and copy the identical name into the ammo field located inside the options of the attack.
Yeah I looked at the companion script, but it warned against using it if you were new to setting up scripts, and when I took a look at all the stuff on the script explanation, I skipped it... But does it mess up anything already created, or is it fine and then just follow the install instructions?
1500860305

Edited 1500860367
The ammo portion of the companion script works automatically without needing prior configuration in the API so long as you have ticked the correct box and written the correct stuff inside the sheet itself. You might need to turn off some of the configurations like the automatic monster HP and new token defaults (or rather set them to your liking) as they might be on by default. Either way, I recommend you create a copy of your current game and toy with it there should it cause irreversible problems.
1500860505

Edited 1500860582
I just made a copy of my game and tried it, and it doesn't work with the current sheet version. It's too much I need to change up to get it to work with the companion, so I'm still hoping someone can help me with the Ammo Script from The Aaron, but thanks for the suggestion. Time for bed for now, but I cross my fingers that someone can help :)
1500888030
Kryx
Pro
Sheet Author
API Scripter
Shaped Sheet's ammo is supported by the Shaped Script. I think you'll have a harder time trying to make it work via another script - the behavior is quite different. To use the Sheet and Script you're expected to be on the latest version of both.
Ah ok. But when I use the Shaped Script, I get error messages that says the version is wrong with the 1-click feature, and when I use the installation guide where I copy/paste, i get multiple error messages, which leads me to believe that the companion script isn't updated for the new Shaped Sheet.
1500890167
Kryx
Pro
Sheet Author
API Scripter
1 click is not supported. See  [5e Shaped Script] Version 11+ for installation instructions. The latest Sheet and Script work together, always. If there are errors (and not just log messages) then open an issue on the script issue tracker please.
Ok thanks Kryx I got it to work!