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

Automating creature templates to add to existing monsters

1725291183

Edited 1725291621
Has anyone found a good way to automate adding templates to previously created creatures? My original ideas was to use ChatSetAtt to add useful info and qualities such as feats, description and modded stats but it's limited to only setting the attribute, it cannot add text, only set it.  Has anyone found an easy way to go about this? preferably I'd like to automate additional ability macros being added as well. Currently I'm using google sheets and an old API importer and it works but being able to do this in game and on the fly would be great!
1725416540
timmaugh
Pro
API Scripter
Tristan P. said: My original ideas was to use ChatSetAtt to add useful info and qualities such as feats, description and modded stats but it's limited to only setting the attribute, it cannot add text, only set it.   What do you mean by "it cannot add text, only set it"? And what would be your ideal outcome? For instance, can you... 1) give an example of something you would like to save to the sheet, and 2) tell us where would be the most ideal place to store that item (attribute or ability) ?
1725438427

Edited 1725438954
ok, sorry for being vague. ChatSetAtt cannot add additional text to an attribute. If I wanted an attribute to display 'one two three four five six' and it already has 'one two three' set as the value, I cannot use the API to place the addition txt 'four five six' My ideal outcome would be to do just that, I haven't looked too deep into using the API to create ability macros yet but that would be a huge time saver. I'd like to be able to automate adding creature templates to the dnd 3.5 monster sheet, this would include adding/modding existing ability macros, altering stats, adding additional description details and more. to be even more clear, a creature has ' Special Qualities: low-light vision, sent' the creature template add 'darkvision 60ft. immunity to fire,' I'd like to output ' Special Qualities: low-light vision, sent, darkvision 60ft. immunity to fire' I currently have each creature pre set with ability macros for attacks, skill checks, and Ex/Su abilities. I would ideally be able to alter them or simply create new attack and Ex/Su ability macros
1725452993
timmaugh
Pro
API Scripter
OK, so when you say "adding templates" you're not talking about adding the "html factory" in the sheet that would give you different types of templates (default, attack, npc_action, etc.)... you're talking about abilities that would utilize existing templates in the sheet. You're talking about new "panels" of information about the characters on which these abilities reside. Yes? BTW, ChatSetAttr can add text to an existing attribute, keeping its extant text. It isn't... delicate. Or, aware. For an attribute named "YayaDingDong," which already has "one, two, three", that might look like: !setattr --sel --set YayaDingDong|@{selected|YayaDingDong}, four, five, six Obviously "four, five, six" might come from a different location (another attribute on the sheet), but as I don't know the game or sheet you're using, I can only demonstrate the method. If you want a more delicate or dexterous touch to the composition of the finalized template statement, you could add the Metascript Toolbox or convert to ScriptCards. Alternately, if you're up for a challenge, creating abilities ad hoc is exactly what InsertArg can do. If you share an example command line of a template this process would create (i.e., "&{template:templateName} ..."), and you can annotate it with where the information comes from, I might be able to walk you through the IA command line that would create that and let you distribute it to the NPC sheet.
Ah ya I see where I was tripping people up, my bad! I cant believe I didn't think of using chatsetatt like that... its so simple! Your API InsertArg looks awesome! I see you have a video posted so I'll watch that and read through your documentation 1st before I bother you with more of my questions lol Thank you Tim!