Difference between revisions of "Script:It's a Trap"
From Roll20 Wiki
Stephen L. (Talk | contribs) (Created page with "{{script overview |name=It's A Trap |author={{user profile|46544|Stephen L}} |version=2.0 |lastmodified=2015-01-21 |code=Its A Trap |dependencies=none |conflicts=none}} This ...") |
Stephen L. (Talk | contribs) |
||
Line 5: | Line 5: | ||
|lastmodified=2015-01-21 | |lastmodified=2015-01-21 | ||
|code=Its A Trap | |code=Its A Trap | ||
− | |dependencies= | + | |dependencies={{api repository link|Token Collisions}}, {{api repository link|Vector Math}} |
|conflicts=none}} | |conflicts=none}} | ||
Revision as of 03:53, 22 January 2015
Version: 2.0
Last Modified: 2015-01-21
Code: Its A Trap
Dependencies: Token Collisions, Vector Math
Conflicts: none
This is a script that allows GMs to quickly and very easily set up traps on the GM layer, and detect when tokens on the objects layer move over them. This trap detection even works for tokens moving by waypoints.
Contents |
Syntax
none. Traps are set up through token interaction. See below.
Installation and Configuration
Copy the script's code, available from the menu on the right and stored at Roll20's API GitHub Repository. Paste the code into a new script in your campaign's API Script Editor. Save the new script and it will be available inside your campaign.
Script Use
To set up traps:
Place the token for your trap on the GM layer. Give it the cobweb status marker.
By default, traps will only affect characters on the ground (ones that don't have a wing or angel status marker). To have a trap also affect flying characters, give it the wing or angel status marker.
By default, trap tokens won't appear when they are activated. If you would like the trap to become visible to the players when it is activated, give it the bleeding eye status marker.
To set off traps:
If a token moves across a trap at ANY point during its movement, the trap will be activated!
Changelog
See GitHub commit log/wiki page history.