Allow players to choose colors via RGB/HSL color sliders!
Includes a screen named "color_picker"
which when closed, returns the users
selected color as a hex string.
-
Download the latest release
cs-slim
zip. -
Unpack it in your project directory (the one right above
game
). -
Call the color picker screen.
label start: e "Pick a color." window hide $ bg_color = renpy.call_screen("color_picker") window show e "You selected the color {color=[bg_color]}[bg_color]{/color}"
-
Use the returned hex code string for whatever you like, for example changing the colors of the background, dialogue text, or character names.
You may be looking at this thing and thinking "wow, that’s kinda ugly," which is probably true. I don’t have an eye for design, and I don’t pretend to, but luckily the color picker screen and its styles are pretty simple and easily hackable.
This source code and project are released under the MIT license, which to paraphrase in a way that is not legally binding:
-
You can use it for free things
-
You can use it for paid things
-
You can modify it however you see fit
-
You can redistribute it as you see fit
-
Go nuts!
For a better breakdown of what the license actually means see: https://choosealicense.com/licenses/mit/