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 .
×
Advertisement Create a free account Compendium in Game, Join Today

[5e Shaped Script] Version 11+

1530037379
Lucian
Pro
API Scripter
13.4.0 Features Support "pcOnly" option for "has sight" Bug fixes Fix #1 - set "Expertise as advantage" and custom saves before character import to ensure these features work correctly.
1530039862
keithcurtis
Forum Champion
Marketplace Creator
API Scripter
Bless you for the sight option!
1530040260
Lucian
Pro
API Scripter
keithcurtis said: Bless you for the sight option! Well, I broke my ankle the other day so I've got an unexpected amount of free time... So I thought I might as well fix a few issues :-)
1530042795
keithcurtis
Forum Champion
Marketplace Creator
API Scripter
Ouch. Every silver lining has a dark cloud.
1530048186

Edited 1530048207
I'm late. BUT....Welcome back Lucian! Sorry about your foot :( 
1531826043
Lucian
Pro
API Scripter
13.5.0 Features Support copying uses/recharge from spells on imported monsters (sheet support still needed for this to work) Bug fixes Fix #61 - fix for statblock import being broken on Windows after latest Roll20 update Hopefully this should sort out all the problems people have been having with statblock import. Let me know if you see any more problems.
1531870910
Fox
Pro
Is the 13.5.0 supposed to be a link?  I can't find it otherwise.
1531877921
keithcurtis
Forum Champion
Marketplace Creator
API Scripter
Latest code is always in the Github, and linked from the first post. The best thing is to click on the Raw link and bookmark that. It will always take you to the most up-to-date code. 
1531879614
Fox
Pro
Thanks!
I'm having a brain fart. In the past few months when I created a new character sheet regardless if it was a pc or npc it would create the default token buttons in the upper part of the screen when you click on the token.  Where you have adv, dis, normal, offense, statblock etc.  Some reason in the past month all my new ones do not have these macro abilities.  I been through the script document and config and updated all of my current character sheets and nothing.  I must be missing a setting.  Any help would be appreciated.  Thanks
1531909381
Lucian
Pro
API Scripter
Hi Travis, Something things to check: Is the script installed and working? Any errors showing in the log on startup? In !shaped-config -> New Characters , check that "Apply to all new chars" is switched on. If not, the settings will only apply to characters created by script commands like !shaped-import-monster
I verified all those settings and they are correct and the script is working. This is the INFO and WARN the sandbox produces but its general info as far as I know "5eShapedScript 1531960308277 WARN : Unrecognised entity type equipment" "5eShapedScript 1531960309181 INFO : -=> ShapedScript v13.5.0 <=-" "5eShapedScript 1531960311041 INFO : Detected sheet version as : 18.1.13" "5eShapedScript 1531960311043 INFO : Starting configuration state: {\"version\":5.2,\"config\":{\"genderPronouns\": etc etc etc" I don't believe any of that would cause it.  Should I open an issue ticket for you on this? Thanks
1531977067
Lucian
Pro
API Scripter
Hi Travis, Just to check the obvious - you do actually have some stuff turned on under !shaped-config -> New Characters -> Default Token Actions , right? By default the script isn't configured to create any token actions. If you do have some stuff configured under there and it still isn't working, then yes, create a ticket on BitBucket. The most useful thing would be if you do: !logLevel 5eShapedScript DEBUG and then create a character. This should generate a lot more logging - if you could paste everything in with the ticket that would help me locate the problem.
Issue #62 on bitbucket Lucian.
1532300955
Lucian
Pro
API Scripter
13.5.1 Bug fixes Fix bug which was stripping last trait/action from each section on import Minor relaxation of validation to improve import compatibility
1532668072
I was wondering if I could get a little help with the "Importing Monsters from the Script Database" well more appropriately building of the database? I have used the "Import a Monster from Monster Manual Statblock text" that works really well, but would really like to build a Database from my Mordenkainen's book, so I don't have to have all the monsters in my Journal, and can just pull in a token and apply the stats as and when needed.  Is there a guide somewhere on the format needed to build a Database?
1532670421
keithcurtis
Forum Champion
Marketplace Creator
API Scripter
I think your best bet is to examine the script and back-engineer the format. I don’t think there’s a guide. Of course, you have a pro subscription. You can always set up your “monster manual” ahead of time and transmogrify your monsters in at need. 
1532672008
Lucian
Pro
API Scripter
Yeah, I'm afraid it's something I've never really had the energy to do to document the database format correctly. Unfortunately it's a somewhat technical process involving javascript and JSON. If you have even very basic programming experience it's actually fairly straightforward,  but if not you may find it slightly frustrating. Keith is right on both counts: the fastest way to learn about the format is to grab the data from the top of the script file and look at it. It's the bit inside the function call ShapedScripts.addEntities( .... ) . If you stick that in a JSON pretty printer the format is actually pretty self-explanatory. If none of what I just said makes much sense, this is probably not for you. You're probably better off entering the monsters either manually or using the statblock parser, storing them in a separate campaign and transmogrifying as required. I guess it's slightly less convenient than !shaped-import-monster and one day it might be nice to have a JSON export function but (a) that's a bunch of extra work that I'm not really interested in doing right now and (b) it has the potential for abuse that might make us unpopular with the Powers That Be.
1532676188

Edited 1532676350
keithcurtis said: I think your best bet is to examine the script and back-engineer the format. I don’t think there’s a guide. Of course, you have a pro subscription. You can always set up your “monster manual” ahead of time and transmogrify your monsters in at need.  Thanks as always Keith! Had not thought of having a campaign set up as a “monster manual” and using the transmogrify, I will call this plan B!  Lucian said: Yeah, I'm afraid it's something I've never really had the energy to do to document the database format correctly. Unfortunately it's a somewhat technical process involving javascript and JSON. If you have even very basic programming experience it's actually fairly straightforward,  but if not you may find it slightly frustrating. Keith is right on both counts: the fastest way to learn about the format is to grab the data from the top of the script file and look at it. It's the bit inside the function call ShapedScripts.addEntities( .... ) . If you stick that in a JSON pretty printer the format is actually pretty self-explanatory. If none of what I just said makes much sense, this is probably not for you. You're probably better off entering the monsters either manually or using the statblock parser, storing them in a separate campaign and transmogrifying as required. I guess it's slightly less convenient than !shaped-import-monster and one day it might be nice to have a JSON export function but (a) that's a bunch of extra work that I'm not really interested in doing right now and (b) it has the potential for abuse that might make us unpopular with the Powers That Be. JSON pretty printer!!!! that's what they are called.  Thanks, Really really new to Javascript and only delving into it for the sake of roll 20, but that tip alone has really helped me see the format.....so say I wanted to add a  Nilbog I would put the following in the ShapedScripts.addEntities( .... ) wrapping?   "name":"Nilbog",          "size":"Small",          "type":"Humanoid (goblinoid)",          "alignment":"chaotic evil",          "AC":"13 (leather armor)",          "HP":"7 (2d6)",          "speed":"30 ft.",          "strength":8,          "dexterity":14,          "constitution":10,          "intelligence":10,          "wisdom":8,          "charisma":15,          "skills":"Stealth +6",          "senses":"darkvision 60 ft.",          "languages":"Common, Goblin",          "challenge":1,          "traits":[               {                  "name":"Innate Spellcasting",                "text":"The nilbog’s innate spellcasting ability is Charisma (spell save DC 12). It can innately cast the following spells, requiring no material componentsmage hand, Tasha’s hideous laughter, vicious mockery, confusion"             },             {                  "name":"Nilbogism",                "text":"Any creature that attempts to damage the nilbog must first succeed on a DC 12 Charisma saving throw or be charmed until the end of the creature’s next turn. A creature charmed in this way must use its action praising the nilbog. The nilbog can’t regain hit points, including through magical healing, except through its Reversal of Fortune reaction."             },             {                  "name":"Nimble Escape",                "text":"The nilbog can take the Disengage or Hide action as a bonus action on each of its turns."             }          ],          "actions":[               {                  "name":"Fool’s Scepter",                "text":"Melee Weapon Attack: +4 to hit, reach 5 ft., one target. Hit: 5 (1d6 + 2) bludgeoning damage."             },             {                  "name":"Shortbow",                "text":"Ranged Weapon Attack: +4 to hit, range 80/320 ft., one target. Hit: 5 (1d6 + 2) piercing damage."             }          ],          "reactions":[               {                  "name":"Reversal of Fortune",                "text":"In response to another creature dealing damage to the nilbog, the nilbog reduces the damage to 0 and regains 1d6 hit points."             }          ],          "environments":[               "Forest",             "Hill",             "Underdark"          ]       },       {   Is there a specific order I have to follow for things like Traits, Actions, legendary Actions?  Then I can work out the joy of adding spells! 
1532678729

Edited 1532678872
Lucian
Pro
API Scripter
Ok, it seems like you have the bit between your teeth so I'll try and provide a very quick run-down on what you need. I recommend editing your files outside of Roll20; I've lost a lot of work to hitting the wrong button and refreshing the script editor page! Make sure you're working in a plain text editor of some sort - not something like MS Word. Notepad if you must. If you use a wordprocessor like Word it will stick all manner of invisible formatting crap in that will break things. Your goal is to make a new script file that you save in your campaign alongside the companion script.  This will be your custom data file. The outline content of this file should be: on('ready', function() {     ShapedScripts.addEntities(<YOUR DATA GOES HERE>); }); You need to replace the <YOUR DATA GOES HERE> with a valid JSON object whose outline structure is as follows: {     "name":"PigeonsCustomData",     "dependencies":["SRD"],     "version":"2.0.0",     "monsters":[          <MONSTER1>,        <MONSTER2>     ],    "spells": [         <SPELL1>,         <SPELL2>     ] } You've already identified broadly what you need to put in for each monster in your post above. The one thing you need to be careful of is that each monster needs to be contained inside a pair of {}. So if you were just creating a file for your Nilbog, here's what the whole thing would look like: on('ready', function () {   ShapedScripts.addEntities({     "name": "PigeonsCustomData",     "dependencies": ["SRD"],     "version": "2.0.0",     "monsters": [      {         "name": "Nilbog",         "size": "Small",         "type": "Humanoid (goblinoid)",         "alignment": "chaotic evil",         "AC": "13 (leather armor)",         "HP": "7 (2d6)",         "speed": "30 ft.",         "strength": 8,         "dexterity": 14,         "constitution": 10,         "intelligence": 10,         "wisdom": 8,         "charisma": 15,         "skills": "Stealth +6",         "senses": "darkvision 60 ft.",         "languages": "Common, Goblin",        "challenge": 1,         "traits": [           {             "name": "Innate Spellcasting",             "text": "The nilbog’s innate spellcasting ability is Charisma (spell save DC 12). It can innately cast the following spells, requiring no material components:\nAt will: mage hand, Tasha’s hideous laughter, vicious mockery\n1/day: confusion"           },           {             "name": "Nilbogism",             "text": "Any creature that attempts to damage the nilbog must first succeed on a DC 12 Charisma saving throw or be charmed until the end of the creature’s next turn. A creature charmed in this way must use its action praising the nilbog. The nilbog can’t regain hit points, including through magical healing, except through its Reversal of Fortune reaction."           },           {             "name": "Nimble Escape",             "text": "The nilbog can take the Disengage or Hide action as a bonus action on each of its turns."           }         ],         "actions": [           {             "name": "Fool’s Scepter",             "text": "Melee Weapon Attack: +4 to hit, reach 5 ft., one target. Hit: 5 (1d6 + 2) bludgeoning damage."           },           {             "name": "Shortbow",             "text": "Ranged Weapon Attack: +4 to hit, range 80/320 ft., one target. Hit: 5 (1d6 + 2) piercing damage."           }         ],         "reactions": [           {             "name": "Reversal of Fortune",            "text": "In response to another creature dealing damage to the nilbog, the nilbog reduces the damage to 0 and regains 1d6 hit points."           }         ],         "environments": [           "Forest",           "Hill",           "Underdark"         ]       }     ]   }); }); Before you paste all of your data between the ShapedScripts.addEntities() brackets, you should find an online JSON validator (probably in the same place that you find a pretty printer, but google will give you lots) and check that you haven't made any subtle mistakes with your JSON. This will tell you that basic structure is correct. You may still get errors further down the line if you've put invalid values in for some of the fields, but at least you'll get past the first stage of loading if it parses as valid JSON. You can keep adding more monsters to the same file, putting a comma between each one, and then when you get onto spells you just put those in the spells array ("spells": [ ... ]). Again, see the stuff included in the script for examples. If in doubt about what's valid, try to stick as close as possible to what's used in the existing data, or where there's no appropriate example in the SRD data, keep as close as possible to how things are written in the books. The order of the properties within each monster or spell object is not significant to the script but it makes it easier to edit and debug if you stick to the same order that things appear in the book. Right, I think that's enough to be getting on with. I'm afraid I can't promise to support you through this every step of the way, particularly if you're new to JS/JSON, but I'll try and steer you in the right direction if you get stuck and I have some time to respond. Good luck!
1532679402
Kryx
Pro
Sheet Author
API Scripter
@Lucian we should add this to&nbsp; <a href="https://bitbucket.org/mlenser/5eshapedscript/wiki/Home#tracking-advantage-using-the-script" rel="nofollow">https://bitbucket.org/mlenser/5eshapedscript/wiki/Home#tracking-advantage-using-the-script</a> &nbsp;and update as necessary. :)
1532679784
Lucian
Pro
API Scripter
Kryx said: @Lucian we should add this to&nbsp; <a href="https://bitbucket.org/mlenser/5eshapedscript/wiki/Home#tracking-advantage-using-the-script" rel="nofollow">https://bitbucket.org/mlenser/5eshapedscript/wiki/Home#tracking-advantage-using-the-script</a> &nbsp;and update as necessary. :) As long as we can put a caveat to the effect that 'The script author is a grumpy old curmudgeon; creating custom data files is an advanced task that is supported on a "when he feels like it" basis' :-P
1532681881
Got it! Thanks so much for the help, have harassed a friend who programs javascript for a living to help check my code from now on, so I don't&nbsp;have to harras you guys, who have already done so much!&nbsp; Thank you!&nbsp;&nbsp;
1532682880
Kryx
Pro
Sheet Author
API Scripter
Lucian said: As long as we can put a caveat to the effect that 'The script author is a grumpy old curmudgeon; creating custom data files is an advanced task that is supported on a "when he feels like it" basis' :-P By we I meant you. :D Can you update the wiki with a section that you have above? Then we can link to that section whenever this question is posed.
1532733463
Curious about an error, just put together a bestiary and it had regional effects. The error is regionalEffectsFade: Field is missing. Pretty obvious, I just don't know where to add it. Below is an example monster: "name": "Ryu", "size": "gargantuan", "type": "dragon (kami)", "alignment": "chaotic good", "AC": "20 (natural armor)", "HP": "507 (26d20+234)", "speed": "40 ft., fly 120 ft., swim 120 ft.", "strength": 30, "dexterity": 10, "constitution": 28, "intelligence": 19, "wisdom": 22, "charisma": 30, "savingThrows": "Dex +9, Con +18, Wis +14, Cha +19", "skills": "History +17, Perception +15", "damageResistances": "bludgeoning, piercing, and slashing from nonmagical attacks", "damageImmunities": "cold, lightning, thunder", "conditionImmunities": "blinded, charmed, deafened, exhaustion, frightened, paralyzed, petrified, poisoned", "senses": "darkvision 240 ft., truesight 120 ft., passive Perception 25", "spells": "control weather, divine word, tsunami, whirlwind", "languages": "all, telepathy 120 ft", "challenge": "29", "traits": [{ "name": "Amphibious", "text": "Ryu can breathe air and water." }, { "name": "Aura of Vitality", "text": "Ryu and his allies within 30 feet of him regenerate 10 hit points at the start of each of Ryu’s turns." }, { "name": "Discorporation", "text": "When Ryu drops to 0 hit points or dies, his body is destroyed but his essence travels back to Tengoku, and he is unable to take physical form for a time." }, { "name": "Immutable Form", "text": "Ryu is immune to any spell or effect that would alter his form." }, { "name": "Innate Spellcasting", "recharge": "3/Day", "text": "Ryu can innately cast control weather, divine word, tsunami and whirlwind (spell save DC 27). his spellcasting ability is Charisma." }, { "name": "Legendary Resistance", "recharge": "3/Day", "text": "If Ryu fails a saving throw, he can choose to succeed instead." }, { "name": "Lightning Aura", "text": "At the start of each of Ryu’s turns, each creature of Ryu’s choosing within 10 feet of him takes 14 (4d6) lightning damage. A hostile creature that touches Ryu or hits him with a melee attack while within 10 feet of him takes 14 (4d6) lightning damage." }, { "name": "Limited Magic Immunity", "text": "Unless it wishes to be affected, Ryu is immune to spells of 5th level or lower. It has advantage against all other spells and magical effects." }, { "name": "Magic Weapons", "text": "Ryu’s weapon attacks are magical." }, { "name": "Atmospheric Hypoxia", "text": "Oxygen levels are lower within the Cleansing Cyclone, taxing most creatures that need to breathe. A creature must succeed a DC 10 Constitution saving throw at the start of each of its turns, or spend its action that turn gasping for air." }, { "name": "Heavy Precipitation", "text": "The heavy rains within the Cleansing Cyclone make the entire lair lightly obscured. Creatures within the area also have disadvantage on Wisdom (perception) checks that rely on hearing or sight, and open flames are extinguised." }, { "name": "Powerful Winds", "text": "A creature within the Cleansing Cyclone has disadvantage on ranged weapon attack rolls and Wisdom (perception) checks that rely on hearing. Any open flames are extinguished, fog is dispersed, and flying by nonmagical means is nearly impossible. A flying creature must succeed a DC 15 Strength saving throw at the end of its turn or fall." }], "actions": [{ "name": "Multiattack", "text": "Ryu casts a spell or controls a spell in a way that costs an action. He then makes three attacks: two with his claws and one with his tail." }, { "name": "Booming Tail", "text": "Melee Weapon Attack: +19 to hit, reach 25 ft., one target. Hit: 28 (4d8 + 10) bludgeoning damage plus 11 (2d10) thunder damage. If the target is a creature, it must succeed a DC 27 Strength saving throw or be pushed back 20 feet and knocked prone." }, { "name": "Tempestuous Claw", "text": "Melee Weapon Attack: +19 to hit, reach 15 ft., one target. Hit: 24 (4d6 + 10) slashing damage plus 9 (2d8) lightning damage. If the target is a creature, it must succeed a DC 27 Constitution saving throw or become stunned until the end of its next turn." }, { "name": "Storm Breath", "recharge": "5-6", "text": "Ryu exhales lightning in a 10 feet wide, 120 feet long line. Each creature in that area must make a DC 27 Dexterity saving throw, taking 105 (30d6) lightning damage on a failed save, or half as much on a successful one." }], "legendaryPoints": 5, "legendaryActions": [{ "name": "Attack", "cost": 1, "text": "Ryu attacks with either his Booming Tail or his Tempestuous Claws." }, { "name": "Cast Spell", "cost": 2, "text": "Ryu casts a spell." }, { "name": "Deep Strike", "cost": 5, "text": "In a flash of lightning, Ryu disappears into the stormy skies above him. At the end of the next hostile creature’s turn, Ryu smashes into the ground with the force of a gigantic lightning strike. Each creature within 60 feet of the point of impact, must make a DC 26 Dexterity saving throw. A creature takes 70 (20d6) lightning damage on a failed save, or half as much on a successful one. The lightning ignites flammable objects in the area that aren’t being worn or carried." }, { "name": "Detect", "cost": 1, "text": "Ryu makes a Wisdom (perception) check." }, { "name": "Sonic Boom", "cost": 2, "text": "Ryu supercharges himself with lightning and instantly moves 60 feet in a direction of his choosing as he discharges the energy. Each creature Ryu passes through in that line takes 18 (4d8) thunder damage, and must succeed a DC 26 Strength saving throw or become knocked prone." }, { "name": "Wing Attack", "cost": 2, "text": "Ryu beats his wings. Each creature within 15 feet of Ryu must succeed a DC 27 Dexterity saving throw or take 24 (4d6 + 10) bludgeoning damage and be knocked prone. Ryu can then fly up to half his flying speed." }], "lairActions": ["**Lightning Strikes.** Ryu causes the Cleansing Cyclone to emit powerful lightning strikes. Until initiative count 20 on the next round, a creature is struck by lightning whenever it moves 10 feet unless it is submerged in water. Each lightning strike deals 7 (2d6) lightning damage. A creature hit by the lightning must succeed a DC 15 Constitution saving throw or be unable to take reactions until the start of its next turn.", "**Riptide.** Ryu causes powerful riptides in the water beneath the Cleansing Cyclone. Each creature in contact with the water except Ryu is moved 30 feet in a random direction. Roll a d8 to determine the direction for each affected creature.", "**Tempest.** Each creature not submerged in water other than Ryu is moved 30 feet in a random direction. Roll a d8 to determine the direction for all affected creatures.", "**Undertow.** Ryu targets a 20-foot radius area in the water that he can see. Until initiative count 20 on the next round, a creature that enters the area on its turn or starts its turn in that area must make a DC 27 Strength saving throw. On a failed save, a creature is moved 1d8 x 10 feet directly downwards. On a successful save, a creature is moved half that distance."], "regionalEffects": ["**Tengokuan Influence.** Living creatures in the area must roll on the table below at the end of every hour. Constructs, oni, oozes, and undead are unaffected. 1-4: Outgoing. The creature gains the following ideal: “I love being outside and dancing in the rain.” 5: Bane of Evil. The creature gains the following ideal: “I must eradicate evil wherever I find it.” 6: Fearlessness. The creature gains immunity to the frightened condition until the next time it finishes a short or long rest.", "**Extreme Cold.** The weather in the area is cold and damp. Each creature must succeed a DC 10 Constitution saving throw at the end of each hour or gain one level of exhaustion. Creatures with resistance or immunity to cold damage automatically succeed on the saving throw, as do creatures wearing cold weather gear (thick coats, gloves, and the like) and creatures naturally adapted to cold climates.", "**Frigid Water.** All water in the area becomes frigid. A creature can be immersed in frigid water for a number of minutes equal to its Constitution score before suffering any ill effects. Each additional minute spent in frigid water requires the creature to succeed on a DC 10 Constitution saving throw or gain one level of exhaustion. Creatures with resistance or immunity to cold damage automatically succeed on the saving throw, as do creatures that are naturally adapted to living in ice-cold water.", "**Strong Winds.** A creature within the area has disadvantage on ranged weapon attack rolls and Wisdom (perception) checks that rely on hearing. Any open flames are extinguished, fog is dispersed, and flying by nonmagical means is nearly impossible. A flying creature must succeed a DC 10 Strength saving throw at the end of its turn or fall.", "**Thunderstorms.** Thunderstorms. Thunderstorms rage within the area."]
1532758115
Lucian
Pro
API Scripter
Hey Scythe, You just add it at the end immediately following regionalEffects: "regionalEffects": [....], "regionalEffectsFade" : "If the dragon dies, the fog and precipitation fade within \n 1 day. The ice walls melt over the course of 1d10 days." }
1532764085
Thank you very much. Didn't realize the If/when dies/is destroyed was necessary either at first, so had to do some rewording. That was a pain, but very worth it. On to creating a data set for custom classes.....which i don't suppose there's a template for, is there?
1532766345

Edited 1532766463
Lucian
Pro
API Scripter
<a href="https://bitbucket.org/mlenser/5eshapedscript/wiki/Adding%20Custom%20Data" rel="nofollow">https://bitbucket.org/mlenser/5eshapedscript/wiki/Adding%20Custom%20Data</a> Note that the only thing you can currently define for custom classes is spell lists. This will determine how things are filtered in !shaped-spells but otherwise has no impact. There's no way (afaik) to customise the sheet's classes using custom JSON at the moment.
1532767372
Kryx
Pro
Sheet Author
API Scripter
#343: Allow Custom Class/Race/Archetype inclusion exists for the sheet, but it'd be a lot of work to support json to sheet custom classes. The standard classes are all hardcoded in to the sheet.
1532844614

Edited 1532844650
Sounds fair, on both responses. The spell lists will be fine for now. was hoping for a way to add full custom classes in via data sets, but if need be I suppose I can add them in via editing the sheet. On that note it's basically new entries in the HTML, the CSS, and the Translation right? HTML handles class features, spells, proficiencies, and class progression, CSS handles styling, and then translation is where any features for that class would be written out right?
1532845270
Kryx
Pro
Sheet Author
API Scripter
It would be practically impossible to keep the sheet updated if you made such large changes. I'd definitely not recommend that route. Use the custom class option from the class drop-down and copy&amp;paste the text of features as needed to the class features section. Much easier.
1532861223
Lucian
Pro
API Scripter
13.5.2 Bug fixes Fix typography in SRD data Support importing reaction spells with a condition attached to casting time (e.g. Feather fall) More relaxation of validation to improve import compatibility
1532886209

Edited 1532886377
Lucian
Pro
API Scripter
EDIT: Leaving this here in case the guy still wants an answer, but this was in response to a post that apparently got deleted immediately for some reason.... "5eShapedScript 1532884190904 ERROR : Error: Asked for a single attribute but more than 1 was found matching attributes:&nbsp; Urgh. No idea how that has happened.The easiest way to fix it is to go the attributes and abilities tab for the character, and search through looking for attributes called "spell_level_2_slots_expended". You're going to find two of them. Delete one of them using the little 'x' button and it should start working properly.
1532959790
Having a little problem with Lair Actions using the&nbsp;!shaped-statblock&nbsp;command.&nbsp; I get the error message: Shaped Scripts Error Error: Field lairActionBlurb should have appeared 1 more times Field lairActions should have appeared 1 more times A little confused, do I have to add "lairActionBlurb" and "lairActions" to the GM only text? Right now I just have it formatted like this (redacted the text as copying this for a WOTC book)&nbsp; NAME Large aberration, chaotic evil Armor Class 17 (natural armor) Hit Points 114 (12d10+48) Speed 25ft., climb 25ft. STR 17 (+3) DEX &nbsp;8 (-1) CON 18 (+4) INT 6 (-2) WIS 15 (+2) CHA 8 (-1) Saving Throws Con +8 Skills Perception +6 Condition Immunities TEXT Senses TEXT Languages understands TEXT Challenge 11 (7,200 XP) Legendary Resistance (2/Day). TEXT Actions TEXT Legendary Actions TEXT Lair Actions TEXT Regional Effects TEXT
1532960568
Lucian
Pro
API Scripter
You actually need to populate some actions into those sections for it to be valid, or omit them entirely. Actions/Reactions/Traits look like: Some Title in Titlecase. The remaining text of the action/trait/reaction. Blah blah blah. Legendary Actions look the same but they should be preceded by the standard text&nbsp; detailing how many legendary actions the creature can takes. Regional Actions and Lair Actions start with a * or • (a bullet) . Lair actions should be preceded by the standard text&nbsp; about "On initiative count 20.... " The statblock parser is designed to work on statblocks that look exactly like the WotC books. If you type it in *exactly* as it appears in the MM, it will work. Here's an example: ANCIENT WHITE DRAGON Gargantuan dragon, chaotic evil Armor Class 20 (natural armor) Hit Points 333 (18d20 + 144) Speed 40 ft., burrow 40 ft., fly 80ft ., swim 40 ft. STR 26 (+8) DEX 10 (+0) CON 26 (+8) INT 10 (+0) WIS 13 (+1) CHA 14 (+2) Saving Throws Dex +6, Con + 14, Wis +7, Cha +8 Skills Perception+ 13, Stealth +6 Damage Immunities cold Senses blindsight 60ft., darkvis ion 120 ft., passive Perception 23 Languages Common, Draconic Challenge 20 (24,500 XP) Ice Walk. The dragon can move across and climb icy surfaces without needing to make an ability check. Additionally, difficult terrain composed of ice or snow doesn't cost it extra moment. Legendary Resistance (3/Day). If the dragon fails a saving throw, it can choose to succeed instead. ACTIONS Multiattack. The dragon can use its Frightful Presence. It then makes three attacks: one with its bite and two with its claws. Bite. Melee Weapon Attack:+ 14 to hit, reach 15ft., one target. Hit: 19 (2d10 + 8) piercing damage plus 9 (2d8) cold damage. Claw. Melee Weapon Attack: +14 to hit, reach 10 f.t., one target. Hit: 15 (2d6 + 8) slashing damage. Tail. Melee Weapon Attack: +14 to hit, reach 20ft., one target. Hit: 17 (2d8 + 8) bludgeoning damage. Frightful Presence. Each creature of the dragon's choice that is within 120 feet of the dragon and aware of it must succeed on a DC 16 Wisdom saving throw or become frightened for 1 minute. A creature can repeat the saving throw at the end of each of its turns , ending the effect on itself on a success. If a creature's saving throw is successful or the effect ends for it, the creature is immune to the dragon's Frightful Presence for the next 24 hours . Cold Breath (Recharge 5-6}. The dragon exhales an icy blast in a 90-foot cone. Each creature in that area must make a DC 22 Constitution saving throw, taking 72 (l6d8) cold damage on a failed save, or half as much damage on a successful one. LEGENDARY ACTIONS The dragon can take 3 legendary actions, choosing from the options below. Only one legendary action option can be used at a time and only at the end of another creature's turn . The dragon regains spent legendary actions at the start of its turn. Detect. The dragon makes a Wisdom (Perception) check. Tail Attack. The dragon makes a tail attack. Wing Attack (Costs 2 Actions) . The dragon beats its wings. Each creature within 15 feet of the dragon must succeed on a DC 22 Dexterity saving throw or take 15 (2d6 + 8) bludgeoning damage and be knocked prone. The dragon can then fly up to half its flying speed. LAIR ACTIONS On initiative count 20 (losing initiative ties), the dragon takes a lair action to cause one of the following effects; the dragon can't use the same effect two rounds in a row: • Freezing fog fills a 20-foot-radius sphere centered on a point the dragon can see within 120 feet of it. The fog spreads around corners, and its area is heavily obscured. Each creature in the fog when it appears must make a DC 10 Constitution saving throw, taking 10 (3d6) cold damage on a failed save, or half as much damage on a successful one. A creature that ends its turn in the fog takes 10 (3d6) cold damage. A wind of at least 20 miles per hour disperses the fog. The fog otherwise lasts until the dragon uses this lair action again or until the dragon dies. • Jagged ice shards fall from the ceiling, striking up to three creatures underneath that the dragon can see within 120 feet of it. The dragon makes one ranged attack roll (+7 to hit) against each target. On a hit, the target takes 10 (3d6) piercing damage. • The dragon creates an opaque wall of ice on a solid surface it can see within 120 feet of it. The wall can be up to 30 feet long, 30 feet high, and 1 foot thick. When the wall appears, each creature within its area is pushed 5 feet out of the wall's space; appearing on whichever side of the wall it wants. Each 10-foot section of the wall has AC 5, 30 hit points, vulnerability to fire damage, and immunity to acid, cold, necrotic, poison, and psychic damage. The wall disappears when the dragon uses this lair action again or when the dragon dies. REGIONAL EFFECTS The region containing a legendary white dragon's lair is warped by the dragon's magic, which creates one or more of the following effects: • Chilly fog lightly obscures the land within 6 miles of the dragon's lair. • Freezing precipitation falls within 6 miles of the dragon's lair, sometimes forming blizzard conditions when the dragon is at rest. • Icy walls block off areas in the dragon's lair. Each wall is 6 inches thick, and a 10-foot section has AC 5, 15 hit points, vulnerability to fire damage, and immunity to acid, cold, necrotic, poison, and psychic damage. If the dragon wishes to move through a wall, it can do so without slowing down. The portion of the wall the dragon moves through is destroyed, however. If the dragon dies, the fog and precipitation fade within 1 day. The ice walls melt over the course of 1d10 days.
1532960694
Lucian
Pro
API Scripter
If you want to PM me the statblock you're using then I'll tell you what you're doing wrong.
1533675224

Edited 1533675482
Hey, so I'm back with another question. I'm importing monsters from a data set and It's been working pretty well. Except until I reach something that has innate spellcasting. Below is an example monster and the sheet that it generates. { "name": "Bajang", "size": "small", "type": "fey (shapechanger)", "alignment": "chaotic evil", "AC": "16 (natural armor)", "HP": "42 (12d6)", "speed": "30 ft., climb 30 ft.", "strength": 12, "dexterity": 15, "constitution": 10, "intelligence": 13, "wisdom": 14, "charisma": 16, "savingThrows": "Con +2, Cha +4", "skills": "Acrobatics +4, Perception +4, Stealth +6, Survival +4", "senses": "darkvision 60 ft., passive Perception 12", "spells": "light, bane, gust of wind, divination", "languages": "Common, Oriental, Kami", "challenge": 3, "traits": [{ "name": "Innate Spellcasting", "text": "The bajang’s innate spellcasting ability is Charisma (spell save DC 13). The bajang can innately cast the following spells, requiring no material or verbal components:\nAt will: light\n3/day: bane, gust of wind\n1/day: divination" } I did turn off filtering just to be sure, but honestly I'm probably doing something wrong.
1533677929

Edited 1533677944
Lucian
Pro
API Scripter
Hey Scythe, Congratulations you've found a bug. I've opened a ticket for you . In the meantime the workaround is for you to add the word "each" after 1/day and 3/day and it will import correctly! Thanks!
1533679349
No problem, and that works for now thank you.
1533757544
and yet another thing, sorry for so many questions. I was wondering if lairActions and regionalEffects needed to be formatted a certain way. Currently I have them as follows: "lairActions": ["Dominate. A creature within the lair that the goblin spider can see is affected by the dominate person spell (save DC 15). The goblin spider does not need to maintain concentration on this spell. If a creature succeeds its saving throw, it becomes immune to this lair action for 24 hours. A goblin spider might use this to force a creature to tell its secret if the goblin spider has previously used its Tell Secret action on the creature.", "Mirror Image. The goblin spider is affected by the mirror image spell.", "Recharge Secret. The goblin spider recharges its Tell Secret action."], "regionalEffects": ["Cozy Atmosphere. The atmosphere in the region is magically cozy, joyful, and warm, making humanoids less prone to be alert and suspicious of others.", "Spiders. There's a noticeable increase in the population of spiders in the region. Lifting a tankard in an inn might reveal dozens of small spiders underneath, and basements might become home to one or more giant spiders.", "Webbed Vegetation. Plants within 1 mile of the lair are covered in cobwebs. The cobwebs don't become more prominent the closer they are to the lair, so the lair cannot be found by applying this logic."], "regionalEffectsFade": "If the Goblin Spider dies or creates a new lair, the effects disappear or move to the new lair." but lair actions aren't importing at all, and regionalEffects are showing name inside content (though maybe that's intended?) Picture for reference, showing the last action to show that lair actions aren't there and the regional effects section
1533758296
Kryx
Pro
Sheet Author
API Scripter
Lair actions and regional effects do not have names/titles. Format them as they are in the books. Some examples: "lairActions" : [ "The aboleth casts phantasmal force (no components required) on any number of creatures it can see within 60 feet of it. While maintaining concentration on this effect, the aboleth can’t take other lair actions. If a target succeeds on the saving throw or if the effect ends for it, the target is immune to the aboleth’s phantasmal force lair action for the next 24 hours, although such a creature can choose to be affected." , "Pools of water within 90 feet of the aboleth surge outward in a grasping tide. Any creature on the ground within 20 feet of such a pool must succeed on a DC 14 Strength saving throw or be pulled up to 20 feet into the water and knocked prone. The aboleth can’t use this lair action again until it has used a different one." , "Water in the aboleth’s lair magically becomes a conduit for the creature’s rage. The aboleth can target any number of creatures it can see in such water within 90 feet of it. A target must succeed on a DC 14 Wisdom saving throw or take 7 (2d6) psychic damage. The aboleth can’t use this lair action again until it has used a different one." ] , "regionalEffects" : [ "Underground surfaces within 1 mile of the aboleth’s lair are slimy and wet and are difficult terrain." , "Water sources within 1 mile of the lair are supernaturally fouled. Enemies of the aboleth that drink such water vomit it within minutes." , "As an action, the aboleth can create an illusory image of itself within 1 mile of the lair. The copy can appear at any location the aboleth has seen before or in any location a creature charmed by the aboleth can currently see. Once created, the image lasts for as long as the aboleth maintains concentration, as if concentrating on a spell. Although the image is intangible, it looks, sounds, and can move like the aboleth. The aboleth can sense, speak, and use telepathy from the image’s position as if present at that position. If the image takes any damage, it disappears." ] , "regionalEffectsFade" : "If the aboleth dies, the first two effects fade over the course of 3d10 days." "lairActions" : [ "Pools of water that the dragon can see within 120 feet of it surge outward in a grasping tide. Any creature on the ground within 20 feet of such a pool must succeed on a DC 15 Strength saving throw or be pulled up to 20 feet into the water and knocked prone." , "A cloud of swarming insects fills a 20-foot-radius sphere centered on a point the dragon chooses within 120 feet of it. The cloud spreads around corners and remains until the dragon dismisses it as an action, uses this lair action again, or dies. The cloud is lightly obscured. Any creature in the cloud when it appears must make on a DC 15 Constitution saving throw, taking 10 (3d6) piercing damage on a failed save, or half as much damage on a successful one. A creature that ends its turn in the cloud takes 10 (3d6) piercing damage." , "Magical darkness spreads from a point the dragon chooses within 60 feet of it, filling a 15-foot-radius sphere until the dragon dismisses it as an action, uses this lair action again, or dies. The darkness spreads around corners. A creature with darkvision can’t see through this darkness, and nonmagical light can’t illuminate it. If any of the effect’s area overlaps with an area of light created by a spell of 2nd level or lower, the spell that created the light is dispelled." ] , "regionalEffects" : [ "The land within 6 miles of the lair takes twice as long as normal to traverse, since the plants grow thick and twisted, and the swamps are thick with reeking mud." , "Water sources within 1 mile of the lair are supernaturally fouled. Enemies of the dragon that drink such water regurgitate it within minutes." , "Fog lightly obscures the land within 6 miles of the lair." ] , "regionalEffectsFade" : "If the dragon dies, vegetation remains as it has grown, but other effects fade over 1d10 days."
1533758922
Alright, good to know that formatting is fine. However why aren't lairActions importing? Btw now I'm getting the processing overlay and it hasn't gone away
1533759375
Lucian
Pro
API Scripter
Hey, Could you post or PM the whole monster JSON please and I'll try and debug it for you? Thanks,
1533766972
Here's the entire monster: { "name": "Goblin Spider", "size": "small", "type": "monstrosity (shapechanger)", "alignment": "neutral evil", "AC": "15 (natural armor)", "HP": "66 (12d6+24)", "speed": "30 ft., burrow 5 ft., climb 30 ft., swim 20 ft.", "strength": 10, "dexterity": 17, "constitution": 14, "intelligence": 13, "wisdom": 12, "charisma": 18, "savingThrows": "Wis +4, Cha +6", "skills": "Acrobatics +6, Athletics +8, Deception +9, Perception +4, Stealth +9", "damageResistances": "bludgeoning; bludgeoning, piercing, and slashing from nonmagical attacks, piercing, poison, slashing", "damageImmunities": "bludgeoning, piercing, and slashing from nonmagical attacks that aren't silvered", "conditionImmunities": "charmed, frightened, poisoned", "senses": "blindsight 60 ft., darkvision 120 ft., passive Perception 11", "languages": "Oriental, Telepathy 60ft", "challenge": 5, "traits": [{ "name": "Hold Breath", "text": "The goblin spider can hold its breath for up to 1 hour." }, { "name": "Mimicry", "text": "The goblin spider can mimic animal sounds and humanoid voices. A creature that hears the sounds can tell they are imitations with a successful DC 15 Wisdom (insight) check." }, { "name": "Shapechanger", "recharge": "Short or Long Rest", "text": "The goblin spider can use its action to polymorph into a Small or Medium female humanoid it has seen or back into its true form. Its statistics are the same in each form. Any equipment it is wearing or carrying is transformed with it. It reverts to its true form if it dies." }, { "name": "Spider Climb", "text": "The goblin spider can climb difficult surfaces, including upside down on ceilings, without needing to make an ability check." }, { "name": "Web Sense", "text": "While in contact with a web, the goblin spider knows the exact location of any other creature in contact with the same web." }, { "name": "Web Walker", "text": "The goblin spider ignores movement restrictions caused by webbing." }], "actions": [{ "name": "Multiattack", "text": "In spider form, the goblin spider shoots its web if it can and then makes two bite attacks. In humanoid form, it can either use its Tell Secret and immediately recharge it, or make two attacks with its poisoned tanto." }, { "name": "Bite (Spider Form Only)", "text": "Melee Weapon Attack: +5 to hit, reach 5 ft., one target. Hit: 10 (2d6 + 3) piercing damage. If the target is a creature, it must succeed a DC 15 Constitution saving throw or take 14 (4d6) poison damage." }, { "name": "Tanto (Humanoid Form Only)", "text": "Melee or Ranged Weapon Attack: +5 to hit, reach 5 ft. or range 20/60, one target. Hit: 5 (1d4 + 3) piercing damage. If the target is a creature, it must succeed a DC 15 Constitution saving throw or take 14 (4d6) poison damage." }, { "name": "Draining Kiss", "text": "The goblin spider kisses a creature enslaved by it or a willing creature. The target must make a DC 15 Constitution saving throw against this magic, taking 31 (5d10 + 4) psychic damage on a failed save, or half as much damage on a success ful one. The target’s hit point maximum is reduced by an amount equal to the damage taken. This reduction lasts until the target finishes a long rest. The target dies if this effect reduces its hit point maximum to 0." }, { "name": "Enslave", "recharge": "2/Day", "text": "The goblin spider targets one male creature it can see within 5 feet of it. The target must succeed on a DC 15 Wisdom saving throw or be fall madly in love with and be magically charmed by the goblin spider until the goblin spider dies or until it is on a different plane of existence from the target. The charmed target is under the goblin spider’s control and can’t take reactions, and the goblin spider and the target can communicate telepathically as long as they are within 60 feet of each other. Whenever the charmed target takes damage, the target can repeat the saving throw, except when it takes damage from the goblin spider’s bite attack, as the target will willingly let itself be consumed by the goblin spider. On a successful save, the effect ends. No more than once every 24 hours, the target can also repeat the saving throw when it is at least 1 mile away from the goblin spider. The goblin spider can only have one target enslaved at any given time." }, { "name": "Invisible Passage", "text": "The goblin spider magically turns invisible until it attacks or casts a spell, or until its concentration ends (as if concentrating on a spell). While invisible, it leaves no physical evidence of its passage, so it can be tracked only by magic. Any equipment it wears or carries is invisible with it." }, { "name": "Tell Secret", "recharge": "5-6", "text": "The goblin spider targets a creature within 60 feet of it and telepathically tells it a secret. The secret can be anything the goblin spider knows, but it must be true. The target knows that it should never inform anybody else of this secret. If it ever does, the target takes 45 (10d8) psychic damage, and is afflicted with the following madness: “I will never again share the things I know with anyone”." }, { "name": "Web", "recharge": "4-6", "text": "Ranged Weapon Attack: +6 to hit, range 30/60 ft., one creature. Hit: The target is restrained by webbing. As an action, the restrained target can make a DC 15 Strength check, bursting the webbing on a success. The webbing can also be attacked and destroyed (AC 12; hp 20; vulnerability to fire damage; immunity to bludgeoning, poison, and psychic damage)." }], "lairActions": [ "A creature within the lair that the goblin spider can see is affected by the dominate person spell (save DC 15). The goblin spider does not need to maintain concentration on this spell. If a creature succeeds its saving throw, it becomes immune to this lair action for 24 hours. A goblin spider might use this to force a creature to tell its secret if the goblin spider has previously used its Tell Secret action on the creature.", "The goblin spider is affected by the mirror image spell.", "The goblin spider recharges its Tell Secret action." ], "regionalEffects": [ "The atmosphere in the region is magically cozy, joyful, and warm, making humanoids less prone to be alert and suspicious of others.", "There's a noticeable increase in the population of spiders in the region. Lifting a tankard in an inn might reveal dozens of small spiders underneath, and basements might become home to one or more giant spiders.", "Plants within 1 mile of the lair are covered in cobwebs. The cobwebs don't become more prominent the closer they are to the lair, so the lair cannot be found by applying this logic." ], "regionalEffectsFade": "If the Goblin Spider dies or creates a new lair, the effects disappear or move to the new lair." }
1533801299
Lucian
Pro
API Scripter
Hi Scythe, You've found another bug. You're making a bit of a habit of this! ;-) Sorry, I don't have a workaround for you right now; the fix should be fairly simple but Kryx and I need to work out a strategy to deal with this area slightly more robustly because the interface between the script and the sheet for traits/actions/etc is pretty ugly - largely because it follows the Roll20 Compendium format which has some...err.... "questionable" design choices. Hopefully we'll have something out in the next day or so.
1533805843
Oh, don't you worry. It is a habit of mine regardless. I noticed also that when importing a monster that has a melee weapon attack it will not show the "to hit" section at all, regardless of being formatted correctly or not, until i go back in and edit it to be the exact same thing. It's pretty trivial to be honest so I didn't post about it. But if we're going to talk about my habit of finding bugs then I mean, why not? Also I would have been surprised if I didn't find bugs anyway, the dataset is 260 monsters and 3 spells. I just generally try to figure it out on my own before coming here and making a post on it.
1533806867

Edited 1533806883
Kryx
Pro
Sheet Author
API Scripter
The bug linked by Lucian above is fixed and will be released tonight as part of 19.1.2 For other bugs please open an issue on the sheet or script (default to sheet if you can cause it to occur there, otherwise do it on the script). Without reproduction steps there is very little we can do.
1533807551
Lucian
Pro
API Scripter
Further to what Kryx just said, yes, all bug reports are welcome and encouraged, providing that they are done properly. If you're importing via the script then please include the complete JSON statblock of a monster that demonstrates the issue, otherwise please describe the exact reproduction steps. What you've mentioned sounds like it's probably a sheet bug, but I guess your reproduction path is via script import. If you open a ticket on the sheet bugtracker one of us will try and look into it. Please be sure to state clearly what you feel isn't correct about the behaviour you are seeing.
1533808396
I did open something there on it, but i did mark it as minor. Issue #65. and honestly made a mistake there anyway, what I thought was going on wasn't going on and that's how I found that issue. The problem is that I can post a sample monster (because it did it to all so far) but, I'm not sure how well it can be reproduced. I'll still go back and edit that ticket though with one of the monsters that it's happened to. I posed to script since it seemed to deal with the script. I'm not even sure what reproduction steps there would be other than importing the monster to a token. Here you go.