How do I Change effects value

Get help using Construct 2

Post » Wed Aug 13, 2014 3:33 am

Say i wanna change the Pixellate effect size when pressing a key, in the event sheet how do i do that?

Thanks in advance :)
B
22
S
6
Posts: 244
Reputation: 2,700

Post » Wed Aug 13, 2014 3:48 am

Sprite: Set effect "Pixellate" parameter 0 to <value>
B
24
S
9
G
4
Posts: 1,646
Reputation: 6,596

Post » Wed Aug 13, 2014 4:08 am

Thanks for replying so fast!, it worked but is there a way to make the value changes smoothly (like opacity fading)
B
22
S
6
Posts: 244
Reputation: 2,700

Post » Wed Aug 13, 2014 4:18 am

You can use timers or look into lerp() or the LiteTween add-on. These last two can be used to change any value 'smoothly' or in different ways, including your effect value.
B
24
S
9
G
4
Posts: 1,646
Reputation: 6,596

Post » Wed Aug 13, 2014 4:28 am

@codah I saw your litetween endorsement coming a mile away on this one. haha.

you could also use a variable that you set the parameter to
and have that variable add to itself while the key is down.
B
88
S
43
G
71
Posts: 601
Reputation: 43,669

Post » Wed Aug 13, 2014 4:29 am

spacedoubt wrote:@codah I saw your litetween endorsement coming a mile away on this one. haha.

you could also use a variable that you set the parameter to
and have that variable add to itself while the key is down.


Hey @spacedoubt I mentioned lerp first ;)
B
24
S
9
G
4
Posts: 1,646
Reputation: 6,596

Post » Wed Aug 13, 2014 5:00 am

Thanks for the help, but i don't know how to use lerp or litetween on effects.. a capx would be great :D
B
22
S
6
Posts: 244
Reputation: 2,700

Post » Wed Aug 13, 2014 5:07 am

Can't right now sorry but I'm sure someone will soon! If you search lerp in the forum, manual and tutorials you will find lots of info.

Also what @spacedoubt said :)
B
24
S
9
G
4
Posts: 1,646
Reputation: 6,596

Post » Wed Aug 13, 2014 5:09 am

Alright, thanks guys for replying so fast :D
B
22
S
6
Posts: 244
Reputation: 2,700

Post » Wed Aug 13, 2014 5:38 am

I'll make ya one..
what are you using it for?
or at least, can you tell me the minimum and maximum values for the pixellate size?

Hey, @codah to lerp, I'm still gonna have to use a variable, right? Is there any other way to get the effect parameter into the lerp expression?
B
88
S
43
G
71
Posts: 601
Reputation: 43,669

Next

Return to How do I....?

Who is online

Users browsing this forum: CreativeMind, jezjones24, totoe and 16 guests