- Feb 5, 2019
- 14
- 33
Hey, I am having a bit of trouble with this, so what I want to do is allow the user to customize the color of the text and name. That should be done on the Preferences screen, so each (important) character will have 6 bars, 3 for what and 3 for who. being Red, Green, and Blue first I tried to do it with persistent:
then on the screen:
It is probably easy but yeah...
I need some help plz.
NOTE: 2nd time that I edit the question.
Code:
init -4 python:
if persistent.color_ed_whatR is None:
persistent.color_ed_whatR = 255
if persistent.color_ed_whatG is None:
persistent.color_ed_whatG = 0
if persistent.color_ed_whatB is None:
persistent.color_ed_whatB = 255
if persistent.color_ed_whoR is None:
persistent.color_ed_whoR = 0
if persistent.color_ed_whoG is None:
persistent.color_ed_whoG = 0
if persistent.color_ed_whoB is None:
persistent.color_ed_whoB = 0
init -3 python:
#What ?
if persistent.color_ed_what is None:
persistent.color_ed_what = (persistent.color_ed_whatR, persistent.color_ed_whatG, persistent.color_ed_whatB, 255)
#who
if persistent.color_ed_who is None:
persistent.color_ed_who = (persistent.color_ed_whoR, persistent.color_ed_whoG, persistent.color_ed_whoB, 255)
Code:
bar value VariableValue(persistent.color_ed_whatR, 255):
xalign 1.0 yalign 0.0
xmaximum 400
ymaximum 15
left_bar Frame("left_bar", 10, 0)
right_bar Frame("right_bar", 10, 0)
left_gutter 0
right_gutter 0
thumb "thumb_bar"
You don't have permission to view the spoiler content.
Log in or register now.
It is probably easy but yeah...
I need some help plz.
NOTE: 2nd time that I edit the question.
Last edited: