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

Script:Marking Conditions

From Roll20 Wiki

Jump to: navigation, search

Main Page: API:Script Index


API ScriptAuthor: Brian
Version: 3.3
Last Modified: 2015-03-26
Code: Marking Conditions
Dependencies: splitArgs
Conflicts: None

Marking Conditions creates the API commands !mark, !unmark, and !clearmark

Syntax

!mark <tokenid> [status [type]]
!unmark <tokenid> [status [type]]
!clearmark <tokenid>
Formally:

S

→ !mark tokenid
status


S

→ !unmark tokenid
status


S

→ !clearmark tokenid


tokenid

string

status

→ ε

status

stringdamage


damage

→ ε

damage

→ acid

damage

→ cold

damage

→ fire

damage

→ force

damage

→ lightning

damage

→ necrotic

damage

→ poison

damage

→ psychic

damage

→ radiant

damage

→ thunder
Parameter Values
tokenid ID of a token object. This can be obtained with @{target|token_id} or @{selected|token_id}.
status Optional. Either the name of a statusmarker icon, or else one of many aliases to D&D 4e conditions.


If status is not specified, the purple statusmarker will be used.

type Optional. A D&D 4e damage type. Only used if status is "ongoing", "damage", or "dam". If supplied, should be one of:
  • acid
  • cold
  • fire
  • force
  • lightning
  • necrotic
  • poison
  • psychic
  • radiant
  • thunder

If type is not specified, a statusmarker to represent untyped damage will be used.

The !mark command will set a marker, while the !unmark command will clear it. !clearmark will clear all markers from the token.

Conditions and Aliases

The available status aliases and the D&D 4e conditions they map to are listed below.

Condition Aliases Condition Aliases
Blinded blinded
blind
Prone prone
Dazed dazed
daze
Restrained restrained
Deafened deafened
deaf
Slowed slowed
slow
Dominated dominated
dominate
Stunned stunned
stun
Immobilized immobilized
immobile
immob
Weakened weakened
weak
Marked marked
mark
Ongoing Damage ongoing
damage
dam
Petrified petrified
petrify
stone
Dying
Helpless
Unconscious
Insubstantial
Surprised
Marking Conditions explicitly does not handle these statuses, and will generate an error message if you try to use one.

Changelog

v3.3 (2015-03-26)

  • [bugfix] fixed bugs reported by Ron


v3.2 (2015-01-24)

  • [bugfix] no-arg crash


v3.1 (2015-01-22)

  • Fixed transcription error


v3.0 (2015-01-09)

  • Release