How do i change/blink player color [Super Mario Bros]

Get help using Construct 2

Post » Sat Aug 13, 2016 6:54 pm

what i want to do: when the player picks up a power-up to begin to [1] blink and also [2] change the players color...without using different sprite sheets. in another words, use the existing sprite sheet, set the FLASH to blink and somehow change the color.

Just like in super mario bro when you get a power up. Can anyone give a CAPX example of how to do this dynamic color change for a spritesheet?
B
131
S
40
G
10
Posts: 131
Reputation: 13,445

Post » Sat Aug 13, 2016 7:59 pm

There is a behavior called Flash which you can use to make the blinking effect, and there are some WebGL effects you can add to the object that change color, you'd just have to enable/disable them through events as needed.
B
51
S
24
G
17
Posts: 292
Reputation: 12,559

Post » Sat Aug 13, 2016 8:05 pm

i already know about the flash behavior, but dont know anything about WebGL effects. do you know which to use, and how to use it? that was my main question. thanks a million for your help.
B
131
S
40
G
10
Posts: 131
Reputation: 13,445

Post » Sat Aug 13, 2016 8:38 pm

This is quite easy to do, but you'll need to familiarize yourself with how to control effects from within event sheets - please take a look at this thread which points to using the Set Color effect, and there are some good words in the manual to cover what you need to think about when using them.

As for varying the color, you'll need to change the Set Color parameters in events via the System. So... add the effect to your sprite and then you will be able to edit the effect parameters as required.
A big fan of JavaScript.
B
74
S
20
G
69
Posts: 2,211
Reputation: 43,844

Post » Sat Aug 13, 2016 8:49 pm

awesome thanks a million...you're the best Colludium :-)
B
131
S
40
G
10
Posts: 131
Reputation: 13,445


Return to How do I....?

Who is online

Users browsing this forum: MadSpy and 53 guests