Character Vault
Any Concept / Any System
Compendium
Your System Come To Life
Roll20 for Android
Streamlined for your Tablet
Roll20 for iPad
Streamlined for your Tablet

Personal tools

Difference between revisions of "Script:Modify Token Image"

From Roll20 Wiki

Jump to: navigation, search
(Created page with "{{script overview |name=Modify Token Image |author={{user profile|3482602|Zachare S}} |version=1.0.3 |lastmodified=2019-04-03}} [[Script:Modify Token Image|Modify Token Image]...")
 
 
(2 intermediate revisions by one user not shown)
Line 1: Line 1:
 
{{script overview
 
{{script overview
|name=Modify Token Image
+
|name=ModifyTokenImage
 
|author={{user profile|3482602|Zachare S}}
 
|author={{user profile|3482602|Zachare S}}
|version=1.0.3
+
|version=1.0.4
|lastmodified=2019-04-03}}
+
|lastmodified=2019-04-11}}
 
[[Script:Modify Token Image|Modify Token Image]] is a script to allow you to change your token images via the API. It allows you to change the look of your tokens (for example, polymorph or if someone switches from NPC to enemy).
 
[[Script:Modify Token Image|Modify Token Image]] is a script to allow you to change your token images via the API. It allows you to change the look of your tokens (for example, polymorph or if someone switches from NPC to enemy).
  
Line 32: Line 32:
 
''!ModifyTokenImage --gm''<br />
 
''!ModifyTokenImage --gm''<br />
 
'''GM ONLY COMMAND''' Allows or disallows Player use of the above commands.<br />
 
'''GM ONLY COMMAND''' Allows or disallows Player use of the above commands.<br />
'''NOTE:''' Even though players can use these commands, they can *only* execute these commands on tokens controlled by themselves. GMs can modify *all* tokens *always*.
+
'''NOTE:''' Even though players can use these commands, they can *only* execute these commands on tokens controlled by themselves. GMs can modify *all* tokens *always*. Also, this defaults to Players off. If you want to change the default, you need to change it in the script.
 +
 
 +
''!ModifyTokenImage --debug''<br />
 +
'''GM ONLY COMMAND''' Enables or disables Debug outputting to the log.
 +
 
 +
== Changelog ==
 +
1.0.4: Fixing issues with locating the correct image to place on the token. Initial commit.

Latest revision as of 14:37, 11 April 2019

API ScriptAuthor: Zachare S
Version: 1.0.4
Last Modified: 2019-04-11
Code: ModifyTokenImage
Dependencies: None
Conflicts: None
Modify Token Image is a script to allow you to change your token images via the API. It allows you to change the look of your tokens (for example, polymorph or if someone switches from NPC to enemy).

This is also how you can switch out Character Tokens if you come up with something different.

WARNING: Changing the token image will *NOT* change the Default Token Image for *any* of the Journal Character Entries. You must delete the default token, and then re-add it.

Contents

[edit] Setup

Before you can run any Modify Token Images, you must have a Folder in your Journal named "Token Images" (without the quotes, obviously). The system will expect this folder exists, and, if you install this script without this folder, it will notify you that the Folder does not exist.

[edit] Adding in Token Images

Each Token Image needs to be added as a Handout with a Folder name of the name of the Token. For example:

See Example: Imgur Url Link

The Token "Oriana" needs to have a Folder named "Oriana" in "Token Images." Each token needs to have an avatar image of what token you plan on switching out for the current token.

[edit] Commands

!ModifyTokenImage --next
Changes the currently selected token's image to the next token valid token image in the folder for that token.

!ModifyTokenImage --previous
Changes the currently selected token's image to the previous token valid token image in the folder for that token.

!ModifyTokenImage --set <NameOfHandout>
Changes the currently selected token's image to the <NameOfHandout> image in that folder.

!ModifyTokenImage --gm
GM ONLY COMMAND Allows or disallows Player use of the above commands.
NOTE: Even though players can use these commands, they can *only* execute these commands on tokens controlled by themselves. GMs can modify *all* tokens *always*. Also, this defaults to Players off. If you want to change the default, you need to change it in the script.

!ModifyTokenImage --debug
GM ONLY COMMAND Enables or disables Debug outputting to the log.

[edit] Changelog

1.0.4: Fixing issues with locating the correct image to place on the token. Initial commit.