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

[Script] WildShape - easy ShapeShift for your PCs and NPCs

Hello, I am having a problem. I managed to get it to import a NPC from a folder and it adds it to the list. It says "New shape added: SHAPECrocodile" and I see that a new sheet is created for the shape with the player name prepended.  However, when I select the player token, type !ws and select the SHAPEcrocodile, no message is given that it has successfully complete, the player token doesn't change at all (is it supposed to?) and the actual NPC sheet for the player crocodile is incorrect (modifiers are +0 with wis 18 and cha is the crocodile value). What could I have done wrong? Thanks
I am having a similar issue, but with with this error message. (From WildShape): ol' GM (GM) ERROR: cannot use image with marketplace link, the image needs to be re-uploaded into the library and set on the target character as either token or avatar image; character id = -MQcGSXshoqJTanmagsX (From WildShape): ERROR: chatErrorToPlayer: Ye ol' GM (GM), msg: cannot use image with marketplace link, the image needs to be re-uploaded into the library and set on the target character as either token or avatar image; character id = -MQcGSXshoqJTanmagsX Ao I had added the condpendium entry for a baboon to my journal. I have uploaded a token to my library. I have set the token to the journal sheet. But when I try to transform my PC to the baboon. Nothing happens and I get the error messages above. I am certain I am jsut screwing up where things are palced. Any help would be much appreciated! -Jacob
1610324872
Angelo
API Scripter
Matt M. said: Hello, I am having a problem. I managed to get it to import a NPC from a folder and it adds it to the list. It says "New shape added: SHAPECrocodile" and I see that a new sheet is created for the shape with the player name prepended.  However, when I select the player token, type !ws and select the SHAPEcrocodile, no message is given that it has successfully complete, the player token doesn't change at all (is it supposed to?) and the actual NPC sheet for the player crocodile is incorrect (modifiers are +0 with wis 18 and cha is the crocodile value). What could I have done wrong? Thanks Hey Matt, sorry for the late reply, christmas break was busy! It's weird that you are not getting any message at all, what about if you look in the API console, do you see anything there? If you prefer you can just invite me to your game and i can have a quick look
1610324921

Edited 1610327151
Angelo
API Scripter
Jacob B. said: I am having a similar issue, but with with this error message. (From WildShape): ol' GM (GM) ERROR: cannot use image with marketplace link, the image needs to be re-uploaded into the library and set on the target character as either token or avatar image; character id = -MQcGSXshoqJTanmagsX (From WildShape): ERROR: chatErrorToPlayer: Ye ol' GM (GM), msg: cannot use image with marketplace link, the image needs to be re-uploaded into the library and set on the target character as either token or avatar image; character id = -MQcGSXshoqJTanmagsX Ao I had added the condpendium entry for a baboon to my journal. I have uploaded a token to my library. I have set the token to the journal sheet. But when I try to transform my PC to the baboon. Nothing happens and I get the error messages above. I am certain I am jsut screwing up where things are palced. Any help would be much appreciated! -Jacob Hey Jacob, this is a common issue with Roll20, there is a note in the first page/documentation about it, i am gonna just paste it here as well, let me know if you need any more help NOTE 1: There is a limitation on using images directly from the marketplace, whenever you want to use a monster from the Monster Manual (or similar external resource in your compendium) the API might give you an error asking you to reupload the avatar when you try to transform into it, it's really hit or miss so i would suggest you try it first but in case you do get the error to fix it you will need to: open up the character sheet (let's say "Black Dragon") save the avatar image on your PC (e.g. open the avatar image -> right click -> save as) upload that file to the library change the avatar on the "Black Dragon" character sheet to the file you uploaded to the library (if you can prefer you can set the token)  
Hi, I already used macros on rolld20 but it's my first try using a script like this. I never used github too. I have a player that want to play druid and it would be perfect for him. When I see the installation instructions, I just don't understand where to click or what to do. Could someone explain it to me please? Install I put all my utils in a&nbsp; separate file &nbsp;which you&nbsp; need to add &nbsp;to your API&nbsp; before the WildShape script , you can find it here:&nbsp; <a href="https://github.com/ocangelo/roll20/blob/master/WildHelpers.js" rel="nofollow">https://github.com/ocangelo/roll20/blob/master/WildHelpers.js</a> After that you can copy the main WildShape script:&nbsp; <a href="https://github.com/ocangelo/roll20/blob/master/WildShape/WildShape.js" rel="nofollow">https://github.com/ocangelo/roll20/blob/master/WildShape/WildShape.js</a>
1611471719
Angelo
API Scripter
Zhepna said: Hi, I already used macros on rolld20 but it's my first try using a script like this. I never used github too. I have a player that want to play druid and it would be perfect for him. When I see the installation instructions, I just don't understand where to click or what to do. Could someone explain it to me please? Install I put all my utils in a&nbsp; separate file &nbsp;which you&nbsp; need to add &nbsp;to your API&nbsp; before the WildShape script , you can find it here:&nbsp; <a href="https://github.com/ocangelo/roll20/blob/master/WildHelpers.js" rel="nofollow">https://github.com/ocangelo/roll20/blob/master/WildHelpers.js</a> After that you can copy the main WildShape script:&nbsp; <a href="https://github.com/ocangelo/roll20/blob/master/WildShape/WildShape.js" rel="nofollow">https://github.com/ocangelo/roll20/blob/master/WildShape/WildShape.js</a> Hi Zephna you can just use the one click install. Open your game page, go to the API and you should have a drop down there to install scripts, just select "Wild Shape" and you should be good to go&nbsp;
Hi Angelo, I was wondering if you had any success in finding a solution to the problem that Parrot and Josiak had (near bottom of page 3.) It seems I have it to... I installed the wildshape and wild helper via the API library one click button. At first it seemed to work normally, except when i selected a token and try the !ws. I added the shifter (Valumo is his name, so no special character in the name), added the cr1/4 creature as it should be, but when i tried to shapeshift, nothing happen, not even a error msg. No API crashed, everything seemed to work normally (exept !ws). Is there any API incompatibility know?
1612207367
Angelo
API Scripter
Mathieu C. said: Hi Angelo, I was wondering if you had any success in finding a solution to the problem that Parrot and Josiak had (near bottom of page 3.) It seems I have it to... I installed the wildshape and wild helper via the API library one click button. At first it seemed to work normally, except when i selected a token and try the !ws. I added the shifter (Valumo is his name, so no special character in the name), added the cr1/4 creature as it should be, but when i tried to shapeshift, nothing happen, not even a error msg. No API crashed, everything seemed to work normally (exept !ws). Is there any API incompatibility know? never got any more details from them, if you want to send me an invite to your game i can have a look
1612233231
Finds
API Scripter
I'm running into an issue importing where none of the druids stats INT/WIS/CHA are being merged and none of the skills are being added automatically, anyone else seeing this?
1612305479
Angelo
API Scripter
Finds said: I'm running into an issue importing where none of the druids stats INT/WIS/CHA are being merged and none of the skills are being added automatically, anyone else seeing this? are you using NPCs for your shapes? I have some limitations in place right now if your shapes are PCs, I am gonna try to remove those with the next version (hopefully on the one click next monday/tuesday, but i can't make any promises)
1612306203
Finds
API Scripter
they are NPCs yes, I've tried building an entirely new druid fresh in a test campaign with a fresh import of the script and I see the same behavior. I even tried to wipe the state and rebuild it fresh but no go. It's building everything and naming it I just don't see it adding any of the druids skills or INT/WIS/CHA stats into the NPC critters.
1612308125
Angelo
API Scripter
Finds said: they are NPCs yes, I've tried building an entirely new druid fresh in a test campaign with a fresh import of the script and I see the same behavior. I even tried to wipe the state and rebuild it fresh but no go. It's building everything and naming it I just don't see it adding any of the druids skills or INT/WIS/CHA stats into the NPC critters. if you send me a DM with an invite to your game i can have a look
1612313236
Finds
API Scripter
Angelo said: Finds said: they are NPCs yes, I've tried building an entirely new druid fresh in a test campaign with a fresh import of the script and I see the same behavior. I even tried to wipe the state and rebuild it fresh but no go. It's building everything and naming it I just don't see it adding any of the druids skills or INT/WIS/CHA stats into the NPC critters. if you send me a DM with an invite to your game i can have a look sent
1612397956
Angelo
API Scripter
Finds said: Angelo said: Finds said: they are NPCs yes, I've tried building an entirely new druid fresh in a test campaign with a fresh import of the script and I see the same behavior. I even tried to wipe the state and rebuild it fresh but no go. It's building everything and naming it I just don't see it adding any of the druids skills or INT/WIS/CHA stats into the NPC critters. if you send me a DM with an invite to your game i can have a look sent in case other people run into a similar issue, the misunderstanding on this issue here is that the stats are only copied AFTER you shapeshift, if you check the shape's character sheet before you shift into it it won't have the updated skills/attributes
First off, many thanks for this excellent script. I have tried others in the past but this one cannot be beat for ease of use.&nbsp; I did run into a small problem and hope that folks on the thread can help. I grouped my wild shapes into a folder and about half of them would not upload. I saved the avatar images and replaced them as directed and could then import them all. However, while those that imported on the first go are sized correctly, the second group is not, they are all medium tokens. I would appreciate any advice, thanks!
1612562596

Edited 1612562664
Angelo
API Scripter
Michael d. said: First off, many thanks for this excellent script. I have tried others in the past but this one cannot be beat for ease of use.&nbsp; I did run into a small problem and hope that folks on the thread can help. I grouped my wild shapes into a folder and about half of them would not upload. I saved the avatar images and replaced them as directed and could then import them all. However, while those that imported on the first go are sized correctly, the second group is not, they are all medium tokens. I would appreciate any advice, thanks! You are welcome, glad you are enjoying it :) are you using NPC sheets for your shapes? There is a limitation on the auto size settings for PC sheets in the current version
Angelo said: You are welcome, glad you are enjoying it :) are you using NPC sheets for your shapes? There is a limitation on the auto size settings for PC sheets in the current version Thanks for the reply. Everything is working correctly, I was just mistaken about the token size of two of the creatures. Thanks again.
FYI, ran into an error last week where my player's wildshape suddenly stopped working because the script couldn't find the hp_temp attribute on the wildshape tokens (lion, spider, etc.). I had to go into each wildshape character sheet and manually add an hp_temp attribute to make wildshape work properly.&nbsp;
1613584646
Angelo
API Scripter
Jay R. said: FYI, ran into an error last week where my player's wildshape suddenly stopped working because the script couldn't find the hp_temp attribute on the wildshape tokens (lion, spider, etc.). I had to go into each wildshape character sheet and manually add an hp_temp attribute to make wildshape work properly.&nbsp; mmmh i am not using any hp_temp attribute, are you sure it was the wildshape script that was complaining about that?
Angelo said: Jay R. said: FYI, ran into an error last week where my player's wildshape suddenly stopped working because the script couldn't find the hp_temp attribute on the wildshape tokens (lion, spider, etc.). I had to go into each wildshape character sheet and manually add an hp_temp attribute to make wildshape work properly.&nbsp; mmmh i am not using any hp_temp attribute, are you sure it was the wildshape script that was complaining about that? Yes, I am sure. Every time I or my player tried to wildshape his druid it spit back an error saying it couldn't find the hp_temp attribute on the token. It's possible that recent changes to Roll20 have messed something up in the wildshape code.
As a point of reference, neither I nor my players are having this problem and none of the characters - either the main form, or the forms any of them shift into, have the hp_temp attribute. I just tried shapeshifting two characters into shift forms and back and did not see the error. My guess is Jay R has a setting wrong, or there's a conflict with another script. Jay R. said: Angelo said: Jay R. said: FYI, ran into an error last week where my player's wildshape suddenly stopped working because the script couldn't find the hp_temp attribute on the wildshape tokens (lion, spider, etc.). I had to go into each wildshape character sheet and manually add an hp_temp attribute to make wildshape work properly.&nbsp; mmmh i am not using any hp_temp attribute, are you sure it was the wildshape script that was complaining about that? Yes, I am sure. Every time I or my player tried to wildshape his druid it spit back an error saying it couldn't find the hp_temp attribute on the token. It's possible that recent changes to Roll20 have messed something up in the wildshape code.
Saul J. said: As a point of reference, neither I nor my players are having this problem and none of the characters - either the main form, or the forms any of them shift into, have the hp_temp attribute. I just tried shapeshifting two characters into shift forms and back and did not see the error. My guess is Jay R has a setting wrong, or there's a conflict with another script. Jay R. said: Angelo said: Jay R. said: FYI, ran into an error last week where my player's wildshape suddenly stopped working because the script couldn't find the hp_temp attribute on the wildshape tokens (lion, spider, etc.). I had to go into each wildshape character sheet and manually add an hp_temp attribute to make wildshape work properly.&nbsp; mmmh i am not using any hp_temp attribute, are you sure it was the wildshape script that was complaining about that? Yes, I am sure. Every time I or my player tried to wildshape his druid it spit back an error saying it couldn't find the hp_temp attribute on the token. It's possible that recent changes to Roll20 have messed something up in the wildshape code. A script conflict is certainly possible, but I am not sure what "setting" I could have had wrong. I hadn't fiddled with the wild shape settings at all or done anything different. My player just stopped being able to wildshape his token. Anyhow, it's working now. If I encounter the error again, I'll document it and post it in this thread.
1613599232
Angelo
API Scripter
if you check in the main config menu your pc/npc settings, or maybe in the token bars settings you might have changed it in there? If you can let me know if you see any "hp_temp" in there I can look into the code and see if there is a problem when you change an attribute maybe
Angelo said: if you check in the main config menu your pc/npc settings, or maybe in the token bars settings you might have changed it in there? If you can let me know if you see any "hp_temp" in there I can look into the code and see if there is a problem when you change an attribute maybe I haven't changed anything there. That said,&nbsp;I did change my bar3 to hp_temp on the global settings page of my campaign, but since I use bar1 for wildshape, I'm not sure why doing so would stop wildshape from happening. (although I don't have bar3 defined in wildshape ... hmmm...)
1613611968
Angelo
API Scripter
Jay R. said: Angelo said: if you check in the main config menu your pc/npc settings, or maybe in the token bars settings you might have changed it in there? If you can let me know if you see any "hp_temp" in there I can look into the code and see if there is a problem when you change an attribute maybe I haven't changed anything there. That said,&nbsp;I did change my bar3 to hp_temp on the global settings page of my campaign, but since I use bar1 for wildshape, I'm not sure why doing so would stop wildshape from happening. (although I don't have bar3 defined in wildshape ... hmmm...) that is definitely the problem, WildShape is trying to setup attributes on bar1/2/3, if those are attributes are screwed up it won't work. I'll change it so that if the setting in the main WildShape config for bar1/2/3 is empty it will leave it untouched
Angelo said: Jay R. said: Angelo said: if you check in the main config menu your pc/npc settings, or maybe in the token bars settings you might have changed it in there? If you can let me know if you see any "hp_temp" in there I can look into the code and see if there is a problem when you change an attribute maybe I haven't changed anything there. That said,&nbsp;I did change my bar3 to hp_temp on the global settings page of my campaign, but since I use bar1 for wildshape, I'm not sure why doing so would stop wildshape from happening. (although I don't have bar3 defined in wildshape ... hmmm...) that is definitely the problem, WildShape is trying to setup attributes on bar1/2/3, if those are attributes are screwed up it won't work. I'll change it so that if the setting in the main WildShape config for bar1/2/3 is empty it will leave it untouched Thanks! Good to know my issue had a discernible cause beyond user error. :)
1613636032
Angelo
API Scripter
pushed a new version on both WildShape (1.4.1) and WildHelpers (1.3.3) files, they include several fixes for some issues that some people have encountered, plus it makes the "auto" token size setting work if you are shifting into PCs (before it was just working when transforming into an NPC). They should be available on the one click next time they bring new versions over (next monday?)
Angelo said: pushed a new version on both WildShape (1.4.1) and WildHelpers (1.3.3) files, they include several fixes for some issues that some people have encountered, plus it makes the "auto" token size setting work if you are shifting into PCs (before it was just working when transforming into an NPC). They should be available on the one click next time they bring new versions over (next monday?) Great! Looking forward to this update in the one-click.
Before I install wildshape, I'd like to show you my problem with token-mod, so I can have an idea if I might have the same problem with the Wildshape API. If not - I am ready to change. Here goes: I’m trying to build a generic macro for shape-shifting so I don’t have to build one for every character that needs it. For example: I want to turn this !token-mod {{ &nbsp; --set &nbsp;&nbsp;&nbsp; ?{Change to &nbsp;&nbsp;&nbsp;&nbsp; |@{MyDruid|token_name},currentside#1 represents#@{selected|token_name} scale#70&nbsp; &nbsp;&nbsp;&nbsp;&nbsp; |Cat, currentside#6&nbsp; represents#@{Cat|character_id}&nbsp; scale#40&nbsp; &nbsp;&nbsp;&nbsp;&nbsp; |Mastiff, currentside#10 represents#@{Mastiff|character_id} scale#90 &nbsp;&nbsp;&nbsp;&nbsp; } &nbsp;&nbsp;&nbsp;&nbsp; showname#yes&nbsp; bar1_link|hp &nbsp;bar2_link|speed&nbsp; bar3_link|ac }} By adding this attribute to the Druid's sheet: wildshapes|Cat, currentside#6&nbsp; represents#@{Cat|character_id}&nbsp; scale#40|Mastiff, currentside#10 represents#@{Mastiff|character_id} scale#90 Into this !token-mod {{ &nbsp; --set &nbsp;&nbsp;&nbsp; ?{Choose Form &nbsp;&nbsp;&nbsp;&nbsp; |@{selected|token_name},currentside#1 represents#@{selected|token_name} scale#70&nbsp; &nbsp;&nbsp;&nbsp;&nbsp; | @{character_name}|wildshapes } &nbsp;&nbsp; &nbsp;&nbsp;&nbsp;&nbsp; } &nbsp;&nbsp;&nbsp;&nbsp; showname#yes &nbsp;bar1_link|hp&nbsp; bar2_link|speed&nbsp; bar3_link|ac }} It works fine when the shapeshift is first made, but I cannot get back to the main character sheet afterwards. The obvious reason is once the change is made, the new # represents character sheet has no attribute called wildshapes – and&nbsp;that might no work anyway on account of other Druids with overlaping wildshape lists.&nbsp; &nbsp; I tried putting the list in token bar2_max, but it turned into a number. ( bar2|current holds speed) &nbsp; Then I thought that, using !setattr --sel --x|y where x is the current token_id and y is the current wildshapes list, I could, to the alternate shape sheet,&nbsp; create/add a marker each time I called it – and use/read that to get back home. But, I can’t figure out how to set up x|y.&nbsp; &nbsp; &nbsp; Now, if Wildshape API is stable and capable of doing what I'm trying to do with token-mod, I'm on board. Looking to you gurus for help, please &nbsp;
1613685802
Angelo
API Scripter
Hey James, sorry i don't use tokenmod so i am not sure how to help you with that. If i am understanding it right tho you won't need to do anything like that with this API, if you just read the first post or even just the "Usage" section in the first post you should get an idea on what kind of interface both you and your players would get by just running the command "!ws"
Hey Angelo I love the script but running into an issue that you addressed but its not working for me.&nbsp; From WildShape): &nbsp;ERROR: chatErrorToPlayer: DM (GM), msg: cannot use image with marketplace link, the image needs to be re-uploaded into the library and set on the target character as either token or avatar image; character id = -MTwGhChjX7iJKk5SVA5&nbsp; I have added it to my library and redone the charcters avatar and its still telling me this please help
1613777960
Angelo
API Scripter
Jio B. said: Hey Angelo I love the script but running into an issue that you addressed but its not working for me.&nbsp; From WildShape): &nbsp;ERROR: chatErrorToPlayer: DM (GM), msg: cannot use image with marketplace link, the image needs to be re-uploaded into the library and set on the target character as either token or avatar image; character id = -MTwGhChjX7iJKk5SVA5&nbsp; I have added it to my library and redone the charcters avatar and its still telling me this please help Hi Jio, did you follow the instructions to the letter? I have never seen this issue after resetting the avatar with an uploaded image, you might be missing one of the steps
Angelo said: Jio B. said: Hey Angelo I love the script but running into an issue that you addressed but its not working for me.&nbsp; From WildShape): &nbsp;ERROR: chatErrorToPlayer: DM (GM), msg: cannot use image with marketplace link, the image needs to be re-uploaded into the library and set on the target character as either token or avatar image; character id = -MTwGhChjX7iJKk5SVA5&nbsp; I have added it to my library and redone the charcters avatar and its still telling me this please help Hi Jio, did you follow the instructions to the letter? I have never seen this issue after resetting the avatar with an uploaded image, you might be missing one of the steps I do believe so i even put them in their own folder after so i had them all together unless i am mixing something up
Rosco James said: &nbsp; Now, if Wildshape API is stable and capable of doing what I'm trying to do with token-mod, I'm on board. Looking to you gurus for help, please &nbsp; Wildshape will do everything you want and more, and it's stable. There's a bit of up-front setup getting images into the script, but it's really not a big deal. Once you start using it, I doubt you'll want to go back.
I just went thru and did it again please inform me of what im doing wrong
Figured it out i didnt realize it was for the duplicate sheets
1613782549
Angelo
API Scripter
Jay R. said: Rosco James said: &nbsp; Now, if Wildshape API is stable and capable of doing what I'm trying to do with token-mod, I'm on board. Looking to you gurus for help, please &nbsp; Wildshape will do everything you want and more, and it's stable. There's a bit of up-front setup getting images into the script, but it's really not a big deal. Once you start using it, I doubt you'll want to go back. Happy to see people feel that way :) It sucks that the image part cannot be automated with the API and roll20 has that limitation... i feel it's one of those things they will never remove because of copyrights Jio B. said: Figured it out i didnt realize it was for the duplicate sheets great! i'll check and update the documentation to make sure I mention that
I'm not so sure.&nbsp; I've had the problem with some marketplace tokens/characters but not with others. That implies to me some bug somewhere. You might want to bring it up in the appropriate forum.&nbsp; Unless I'm mistaken, the problem comes from this subroutine in the&nbsp;&nbsp; 5th Edition OGL by Roll20 Companion &nbsp;script: var getCleanImgsrc = function (imgsrc) { &nbsp; &nbsp; &nbsp; var&nbsp;parts&nbsp;=&nbsp;imgsrc.match(/(.*\/(?:images|marketplace)\/.*)(thumb|med|original|max)([^\?]*)(\?[^?]+)?$/); &nbsp; &nbsp; &nbsp; if(parts)&nbsp; return&nbsp;parts[1]+'thumb'+parts[3]+(parts[4]?parts[4]:`?${Math.round(Math.random()*9999999)}`); &nbsp; &nbsp; &nbsp;} &nbsp; &nbsp; &nbsp;return; &nbsp; &nbsp; &nbsp;}; It looks to me like it should always return the correct value but maybe not.&nbsp; Maybe someone with more experience can see where the error is and fix it? Angelo said: Jay R. said: Rosco James said: &nbsp; Now, if Wildshape API is stable and capable of doing what I'm trying to do with token-mod, I'm on board. Looking to you gurus for help, please &nbsp; Wildshape will do everything you want and more, and it's stable. There's a bit of up-front setup getting images into the script, but it's really not a big deal. Once you start using it, I doubt you'll want to go back. Happy to see people feel that way :) It sucks that the image part cannot be automated with the API and roll20 has that limitation... i feel it's one of those things they will never remove because of copyrights Jio B. said: Figured it out i didnt realize it was for the duplicate sheets great! i'll check and update the documentation to make sure I mention that
1613845019

Edited 1613845150
Angelo
API Scripter
The limitation is explained here on their documentation,i think it might be ok for SDR content? <a href="https://help.roll20.net/hc/en-us/articles/360037772793#API:Objects-imgsrcandavatarpropertyrestrictions" rel="nofollow">https://help.roll20.net/hc/en-us/articles/360037772793#API:Objects-imgsrcandavatarpropertyrestrictions</a> Saul J. said: I'm not so sure.&nbsp; I've had the problem with some marketplace tokens/characters but not with others. That implies to me some bug somewhere. You might want to bring it up in the appropriate forum.&nbsp; Unless I'm mistaken, the problem comes from this subroutine in the&nbsp;&nbsp; 5th Edition OGL by Roll20 Companion &nbsp;script: var getCleanImgsrc = function (imgsrc) { &nbsp; &nbsp; &nbsp; var&nbsp;parts&nbsp;=&nbsp;imgsrc.match(/(.*\/(?:images|marketplace)\/.*)(thumb|med|original|max)([^\?]*)(\?[^?]+)?$/); &nbsp; &nbsp; &nbsp; if(parts)&nbsp; return&nbsp;parts[1]+'thumb'+parts[3]+(parts[4]?parts[4]:`?${Math.round(Math.random()*9999999)}`); &nbsp; &nbsp; &nbsp;} &nbsp; &nbsp; &nbsp;return; &nbsp; &nbsp; &nbsp;}; It looks to me like it should always return the correct value but maybe not.&nbsp; Maybe someone with more experience can see where the error is and fix it? Angelo said: Jay R. said: Rosco James said: &nbsp; Now, if Wildshape API is stable and capable of doing what I'm trying to do with token-mod, I'm on board. Looking to you gurus for help, please &nbsp; Wildshape will do everything you want and more, and it's stable. There's a bit of up-front setup getting images into the script, but it's really not a big deal. Once you start using it, I doubt you'll want to go back. Happy to see people feel that way :) It sucks that the image part cannot be automated with the API and roll20 has that limitation... i feel it's one of those things they will never remove because of copyrights Jio B. said: Figured it out i didnt realize it was for the duplicate sheets great! i'll check and update the documentation to make sure I mention that
I don't think that's it because I've had the issue crop up with SRD content.&nbsp; That is to say, the "Brown Bear" is in the SRD and I had the problem with shapeshift to Brown Bear.&nbsp; I did not have the problem with Dire Wolf which is also in the SRD.&nbsp; But I did have the problem with Adult Black Dragon which is also in the SRD...&nbsp; so some SRD content has the problem, some doesn't.&nbsp; So I don't think that's it.&nbsp; That's why I think there's a bug. Angelo said: The limitation is explained here on their documentation,i think it might be ok for SDR content? <a href="https://help.roll20.net/hc/en-us/articles/360037772793#API:Objects-imgsrcandavatarpropertyrestrictions" rel="nofollow">https://help.roll20.net/hc/en-us/articles/360037772793#API:Objects-imgsrcandavatarpropertyrestrictions</a>
Saul J. said: I don't think that's it because I've had the issue crop up with SRD content.&nbsp; That is to say, the "Brown Bear" is in the SRD and I had the problem with shapeshift to Brown Bear.&nbsp; I did not have the problem with Dire Wolf which is also in the SRD.&nbsp; But I did have the problem with Adult Black Dragon which is also in the SRD...&nbsp; so some SRD content has the problem, some doesn't.&nbsp; So I don't think that's it.&nbsp; That's why I think there's a bug. Angelo said: The limitation is explained here on their documentation,i think it might be ok for SDR content? <a href="https://help.roll20.net/hc/en-us/articles/360037772793#API:Objects-imgsrcandavatarpropertyrestrictions" rel="nofollow">https://help.roll20.net/hc/en-us/articles/360037772793#API:Objects-imgsrcandavatarpropertyrestrictions</a> Interesting. If it is a bug and Angelo can fix it, that would lower the barrier to using Wildshape even further for new users.
Saul J. said: I don't think that's it because I've had the issue crop up with SRD content.&nbsp; That is to say, the "Brown Bear" is in the SRD and I had the problem with shapeshift to Brown Bear.&nbsp; I did not have the problem with Dire Wolf which is also in the SRD.&nbsp; But I did have the problem with Adult Black Dragon which is also in the SRD...&nbsp; so some SRD content has the problem, some doesn't.&nbsp; So I don't think that's it.&nbsp; That's why I think there's a bug. Nothing to do with the SRD. What matters is where the image is stored. The API cannot manipulate images from the Roll20 Marketplace. The API can only work with images in the game creator's Art Library.
And that's absolutely NOT TRUE. Several of the images that worked WERE FROM THE MARKETPLACE (Monster Manual).&nbsp; Several of those that did not work WERE FROM THE MARKETPLACE (also Monster Manual).&nbsp; Some of the images from the module that I purchased (Tomb of Annihilation) work, some don't. It has nothing to do with the marketplace, or the SRD.&nbsp; There's a bug. Rabulias said: Saul J. said: I don't think that's it because I've had the issue crop up with SRD content.&nbsp; That is to say, the "Brown Bear" is in the SRD and I had the problem with shapeshift to Brown Bear.&nbsp; I did not have the problem with Dire Wolf which is also in the SRD.&nbsp; But I did have the problem with Adult Black Dragon which is also in the SRD...&nbsp; so some SRD content has the problem, some doesn't.&nbsp; So I don't think that's it.&nbsp; That's why I think there's a bug. Nothing to do with the SRD. What matters is where the image is stored. The API cannot manipulate images from the Roll20 Marketplace. The API can only work with images in the game creator's Art Library.
1614018538
Angelo
API Scripter
Saul J. said: And that's absolutely NOT TRUE. Several of the images that worked WERE FROM THE MARKETPLACE (Monster Manual).&nbsp; Several of those that did not work WERE FROM THE MARKETPLACE (also Monster Manual).&nbsp; Some of the images from the module that I purchased (Tomb of Annihilation) work, some don't. It has nothing to do with the marketplace, or the SRD.&nbsp; There's a bug. Rabulias said: Saul J. said: I don't think that's it because I've had the issue crop up with SRD content.&nbsp; That is to say, the "Brown Bear" is in the SRD and I had the problem with shapeshift to Brown Bear.&nbsp; I did not have the problem with Dire Wolf which is also in the SRD.&nbsp; But I did have the problem with Adult Black Dragon which is also in the SRD...&nbsp; so some SRD content has the problem, some doesn't.&nbsp; So I don't think that's it.&nbsp; That's why I think there's a bug. Nothing to do with the SRD. What matters is where the image is stored. The API cannot manipulate images from the Roll20 Marketplace. The API can only work with images in the game creator's Art Library Maybe they have a bug on the roll20 side in the API? According to that doc i linked none of them should work in theory. If you remember which one did/did not work from the monster manual i could have a quick look at it and double check if there is anything i can do with that function that gets the image path but i doubt it to be honest
I think I posted some of the ones that worked and some didn't. If I encounter the issue again, I'll make a note.&nbsp;&nbsp; I agree that I don't know which way the bug crawls - that is to say, the bug may be that some of the things that Roll20 thought were protected are not.&nbsp; I don't have the time to do this but, you already have code to gather up all the images/characters in a folder because you use that to create a menu for which character to shape shift into. It shouldn't be too hard to write a program that basically takes that code, iterates over the results (i.e. all the characters in a folder made up of all the characters from the Monster Manual, for example) to get the image for each one, and print the value that&nbsp;getCleanImgsrc returns&nbsp;for each image to see what, if any, the differences are. That might tell you something, I don't know. Angelo said: Saul J. said: And that's absolutely NOT TRUE. Several of the images that worked WERE FROM THE MARKETPLACE (Monster Manual).&nbsp; Several of those that did not work WERE FROM THE MARKETPLACE (also Monster Manual).&nbsp; Some of the images from the module that I purchased (Tomb of Annihilation) work, some don't. It has nothing to do with the marketplace, or the SRD.&nbsp; There's a bug. Rabulias said: Saul J. said: I don't think that's it because I've had the issue crop up with SRD content.&nbsp; That is to say, the "Brown Bear" is in the SRD and I had the problem with shapeshift to Brown Bear.&nbsp; I did not have the problem with Dire Wolf which is also in the SRD.&nbsp; But I did have the problem with Adult Black Dragon which is also in the SRD...&nbsp; so some SRD content has the problem, some doesn't.&nbsp; So I don't think that's it.&nbsp; That's why I think there's a bug. Nothing to do with the SRD. What matters is where the image is stored. The API cannot manipulate images from the Roll20 Marketplace. The API can only work with images in the game creator's Art Library Maybe they have a bug on the roll20 side in the API? According to that doc i linked none of them should work in theory. If you remember which one did/did not work from the monster manual i could have a quick look at it and double check if there is anything i can do with that function that gets the image path but i doubt it to be honest
Hi Angelo, This is a very helpful script. I'm pretty new to using API and I have a question, which may have a very simple answer: When the druid in my campaign shapeshifts, everything works great--the correct form shows up, stats look good, etc--but when she shapeshifts back the token's bars use the scripts default, which are different than what I have been using. Is there a way I can change the script so that when she shifts back into her druid form I don't have to reset the bars (or just drag the token from my library back into the game)? Thank you, Sean&nbsp;
1614206754
Angelo
API Scripter
Sean D. said: Hi Angelo, This is a very helpful script. I'm pretty new to using API and I have a question, which may have a very simple answer: When the druid in my campaign shapeshifts, everything works great--the correct form shows up, stats look good, etc--but when she shapeshifts back the token's bars use the scripts default, which are different than what I have been using. Is there a way I can change the script so that when she shifts back into her druid form I don't have to reset the bars (or just drag the token from my library back into the game)? Thank you, Sean&nbsp; Hi Sean, in the main config page (just running !ws without anything selected) you should see two entries for "PC Settings" and "NPC Settings", in there you have settings for which attributes you want to link to which bars for whenever you transform into a PC and/or NPC (that includes your "base shape"). If you just set those to the attributes you normally use it will keep it consistent no matter if you it's shapeshifted or not
Ok, I probably shouldn't have said anything in this thread. :-(&nbsp; For a long time, I didn't have any problems. Now I'm having problems. Setup: I have Tomb of Annihilation and Monster Manual.&nbsp; I have a Circle of Moon druid who just got to level 6 and can now shapechange into CR 2 creatures. He wants to add Giant Constrictor Snake, Rhinoceros and Ape to his list.&nbsp; All 3 are in the SRD.&nbsp; The Rhinoceros and Ape are both in the Monster Manual.&nbsp; The Giant Constrictor Snake is in both the Monster Manual and the Tomb of Annihilation monster list. I can't set up shapechanging for any of them with the wildshape script.&nbsp;&nbsp; I started with the Ape. I got the normal error message about marketplace content. I duplicated the sheet, renamed it to "Ape" from "Copy of Ape", replaced BOTH the avatar image and the token image. And the script still fails.&nbsp; When I click "Add NPC" a dropdown menu pops up with all the available entries in it for me to select. After I duplicated "Ape" and renamed it, there were two entries labeled "Ape" in the menu list. Neither worked. Same for the other two - the Giant Constrictor Snake and the Rhinoceros. With Giant Constrictor snake I tried copying both the entry from the Monster Manual, and the entry from the ToA list and both failed, even after changing the images. I don't know what's going on any more. I don't know if I'm making some dumb mistake, or things have changed on Roll20s end, or something else is the issue but... I can't add these shapes. Angelo: I've sent you an invite. Let me know when you accept the invite and I'll promote you to GM so you can poke around.
1614211063
Angelo
API Scripter
Saul J. said: Ok, I probably shouldn't have said anything in this thread. :-(&nbsp; For a long time, I didn't have any problems. Now I'm having problems. Setup: I have Tomb of Annihilation and Monster Manual.&nbsp; I have a Circle of Moon druid who just got to level 6 and can now shapechange into CR 2 creatures. He wants to add Giant Constrictor Snake, Rhinoceros and Ape to his list.&nbsp; All 3 are in the SRD.&nbsp; The Rhinoceros and Ape are both in the Monster Manual.&nbsp; The Giant Constrictor Snake is in both the Monster Manual and the Tomb of Annihilation monster list. I can't set up shapechanging for any of them with the wildshape script.&nbsp;&nbsp; I started with the Ape. I got the normal error message about marketplace content. I duplicated the sheet, renamed it to "Ape" from "Copy of Ape", replaced BOTH the avatar image and the token image. And the script still fails.&nbsp; When I click "Add NPC" a dropdown menu pops up with all the available entries in it for me to select. After I duplicated "Ape" and renamed it, there were two entries labeled "Ape" in the menu list. Neither worked. Same for the other two - the Giant Constrictor Snake and the Rhinoceros. With Giant Constrictor snake I tried copying both the entry from the Monster Manual, and the entry from the ToA list and both failed, even after changing the images. I don't know what's going on any more. I don't know if I'm making some dumb mistake, or things have changed on Roll20s end, or something else is the issue but... I can't add these shapes. Angelo: I've sent you an invite. Let me know when you accept the invite and I'll promote you to GM so you can poke around. you shouldn't need to duplicate anything manually; when you click "Add NPC" it will duplicate the sheet for you and create a new entry in the journal called "XXXX - Ape" (where XXXX is the name of your shapeshifter); you would need to go in there and change the avatar for THAT specific character sheet. I have accepted the invite, If you still have problems just make me a GM and let me know and i can look into it