Thread: .getColor/.setColor
-
December 23rd, 2021, 21:27 #1
.getColor/.setColor
I'm trying to control the color of labels, dynamically, but I'm not having any luck. Can someone clue me on on the syntax?
-
December 23rd, 2021, 22:26 #2
Did you do a find in files on 5E?
There are many examples of setColor() (but none of getColor)
-
December 24th, 2021, 00:11 #3
1) Look in the API guide for details of available API commands. setColor() for a text based control is detailed here: https://fantasygroundsunity.atlassia...ntrol#setColor As @damned mentions, there's no getColor API function.
2) As @damned mentions, look for examples in existing rulesets. I extract the CoreRPG ruleset and the ruleset I'm working on into directories outside of the FG rulesets directory (so FG doesn't read the extracted data) and then use find in files to get examples of what I'm working on.Private Messages: My inbox is forever filling up with PMs. Please don't send me PMs unless they are actually private/personal messages. General FG questions should be asked in the forums - don't be afraid, the FG community don't bite and you're giving everyone the chance to respond and learn!
-
December 24th, 2021, 01:37 #4
Didn't realize that API was available, thank you. Yup, looks like I was trying to shove the wrong type of data into that method, but even when I corrected it, it's still not working.
Here's the specific error I'm getting.
[ERROR] Script execution error: [string "chkStrength"]:8: attempt to index a nil value
-
December 24th, 2021, 02:09 #5
That specific error is telling you to look at the script code associated with the object chkStrength on line 8 or line 7.
Please post the whole code you have there.
-
December 24th, 2021, 02:55 #6
-
December 24th, 2021, 03:19 #7
-
December 24th, 2021, 03:35 #8
-
December 24th, 2021, 04:01 #9
please share your RWP file and the exact window and object that the code is attached to and how to initiate the error
-
December 24th, 2021, 04:51 #10
Thread Information
Users Browsing this Thread
There are currently 1 users browsing this thread. (0 members and 1 guests)
Bookmarks