using variable colour in action: set filter

For questions about using Classic.

Post » Fri Oct 08, 2010 8:11 pm

I'm making a game where I would like for players to be able to drag a set of rgb sliders to change the colours of various graphics. The Set Filter action seems to do what I would like, except that it doesn't seem to let me choose a variable colour, only a static one. Is there any way around this? Is there some function that would be better suited to this that I haven't found?
I've tried with masks, but I would run into the same problem, and anyways, I'd need to increase my images by ~33% and go through a lot of trouble to ensure their z order is correct, so that masks aren't colouring the wrong items.
B
1
G
2
Posts: 2
Reputation: 629

Post » Fri Oct 08, 2010 8:38 pm

In the action for setting the color filter you can right-click the Filter bar and select Use Expression. Then with the rgb() expression you can use variables for each color channel.



I actually have a tutorial on making color sliders (and other things) here: viewtopic.php?f=8&t=3809
Moderator
B
5
S
2
G
6
Posts: 4,348
Reputation: 10,971


Return to Help & Support using Construct Classic

Who is online

Users browsing this forum: No registered users and 2 guests