different frame for each instance

Get help using Construct 2

Post » Wed Nov 06, 2013 2:41 pm

Hello
please help me with this problem
i trying make different frame for each black blocks but when i change frame for one block, others blocks changes too.
I need every black block to be in different color

https://www.dropbox.com/s/b5a9mhti11je64d/drag_drop.capx
Image
B
14
S
6
G
5
Posts: 99
Reputation: 3,825

Post » Wed Nov 06, 2013 3:09 pm

https://www.scirra.com/manual/124/system-conditions
look at picking instances
Visual Novel 'Engine' in 100 Events
if you ever have to choose between buying Construct 2 on scirra.com or on Steam, read this: Review
B
22
S
9
G
1
Posts: 787
Reputation: 3,786

Post » Wed Nov 06, 2013 3:45 pm

@mindfaQ
Ok
I made

System - Pick move instance4 - move - Set animation frame to1

now every instance is blue color
i don't know how to use it right
any correction please
https://www.dropbox.com/s/j5zltbd521xm3du/frames.capx
Image
B
14
S
6
G
5
Posts: 99
Reputation: 3,825

Post » Wed Nov 06, 2013 4:17 pm

With picking by comparison you can pick only the black pieces.
Once you have picked all the black pieces, just set their frame to a random frame that is not black, so if frame 0 is black and frame 1 till 6 are some colors,

pick block where block.animationframe = 0: set animation frame = floor(random(1,7))
Visual Novel 'Engine' in 100 Events
if you ever have to choose between buying Construct 2 on scirra.com or on Steam, read this: Review
B
22
S
9
G
1
Posts: 787
Reputation: 3,786

Post » Thu Nov 07, 2013 4:19 am

@mindfaQ
Thanks for helping but you get me wrong
look at my capx
https://www.dropbox.com/s/uggxiynvgxwlw73/blocks.capx
i mean Unique frame for each block.
If you can please help me
Image
B
14
S
6
G
5
Posts: 99
Reputation: 3,825

Post » Thu Nov 07, 2013 4:39 am

Set your animation speed to 0.c4sp3r892013-11-07 04:40:13
B
17
S
8
G
4
Posts: 93
Reputation: 3,190

Post » Thu Nov 07, 2013 5:15 am

@c4sp3r89
Yes, thank you that's it. now i fix it.

One more qestion, maybe you now how to randomize instances(not frames)
for example:
i push some button and instances range is 5,9,7,1,2 and so on
Image
B
14
S
6
G
5
Posts: 99
Reputation: 3,825

Post » Thu Nov 07, 2013 5:40 am

I don't quite understand. Maybe you can explain a little more?
B
17
S
8
G
4
Posts: 93
Reputation: 3,190

Post » Thu Nov 07, 2013 5:49 am

@c4sp3r89

randomize instances(not frames)
change position of instances
https://www.dropbox.com/s/u07mu48jox5u6g7/%D0%A1%D0%BA%D1%80%D0%B8%D0%BD%D1%88%D0%BE%D1%82%202013-11-07%2015.47.00.png
Image
B
14
S
6
G
5
Posts: 99
Reputation: 3,825

Post » Thu Nov 07, 2013 6:48 am

The code should be understandable.
The set animation speed can be done in the properties tab in image editor.

https://www.dropbox.com/s/cxthpycjab1scad/Chigabooga_randominst.capx
B
17
S
8
G
4
Posts: 93
Reputation: 3,190

Next

Return to How do I....?

Who is online

Users browsing this forum: fearfulelephants and 26 guests