
Imports/Exports Roll 20 Characters as JSON objects. You can export all your characters and share them with other Roll 20 Users.
https://github.com/mikrasov/Roll20-Scripts/blob/ma...
https://github.com/mikrasov/Roll20-Scripts/blob/ma...
{"widget": { "debug": "on", "window": { "title": "Sample Konfabulator Widget", "name": "main_window", "width": 500, "height": 500 }, "image": { "src": "Images/Sun.png", "name": "sun1", "hOffset": 250, "vOffset": 250, "alignment": "center" }, "text": { "data": "Click Here", "size": 36, "style": "bold", "name": "text1", "hOffset": 250, "vOffset": 100, "alignment": "center", "onMouseUp": "sun1.opacity = (sun1.opacity / 100) * 90;" } }}It might come out like this:
{"widget": { "debug": "on", "window": { "title": "Sample Konfabulator Widget", "name": "main_window", "width": 500, "height": 500 }, "image": { "src": "Images/Sun.png", "name": "sun1", "hOffset": 250, "vOffset": 250, "alignment": "center" }, "text": { "data": "Click Here", "size": 36, "style": "bold", "name": "text1", "hOffset": 250, "vOffset": 100, "alignment": "center", "onMouseUp": "sun1.opacity = (sun1.opacity / 100) * 90;" } }}There are some ways you can make it look nicer if that's the case.
GenKitty said:
I don't know JSON from Bob or Adam.
I'm looking for something where I could export a character, edit the abilities/attribute data with something like notepad++, and then reimport the character back into the game. Would your script allow for this? (Answers in plain english for the non-programmer would be vastly appreciated)
GenKitty said:
Grf.
How hard would it be to adapt the script such that it is run by a character and only exports/imports THAT character journal?
var characters = findObjs({_type: "character", name: "Sir Bearington"})It would work the same way, it'd just think that "all characters" means "all characters named 'Sir Bearington'".
The Aaron said:
I think I can make you a solution... but I've already failed to go to bed at a reasonable time for the 3rd night in a row. Let's see what tomorrow brings.
{ version: <something>, characters: [ { name: <first character name>, abilities: [...], attributes: [...] }, { name: <second character name>, abilities: [...], attributes: [...] }, ... ] }You can delete out the chars you don't want from the "characters" array (this will be easiest if you either add indentation like above or use a text editor that does brace-matching so you can figure out which closing brace matches up with which opening brace and only delete what you want to).
Your scripts are currently disabled due to an error
that was detected. Please make appropriate changes to your scripts and
click the "Save Script" button and we'll attempt to start running them
again. More info...
For reference, the error message generated was: Unexpected token {