[Bug]: Light functions do not know the "Unique" light Type.
Closed this issue · 6 comments
Describe the Bug
setLight(), getLights(), and hasLightSource() can not access the "Unique" light Type.
To Reproduce
- Add a unique light to a token.
- Attempt to use functions with the type parameter set to "Unique".
Error message:
Unknown light type "Unique" in function [functionName]
Expected Behaviour
Light functions should have access to Unique as a type.
Screenshots
No response
MapTool Info
1.18.3
Desktop
Win11
Additional Context
getLights() and hasLightSource() can find unique lights on a token, but not by Type.
Use $token as the type.
Use
$tokenas the type.
Getting errors with:
[r: setLight($token, "Lamp", 0)]
org.antlr.v4.runtime.misc.ParseCancellationException
[r: setLight("$token", "Lamp", 0)]
java.lang.IllegalArgumentException: Illegal group reference
Shouldn't dollar signs be escaped in MT script?
Shouldn't dollar signs be escaped in MT script?
I thought the same... tried using single and double / and still got errors.
Doh. I was escaping with a forward slash. :/
