How do I animate an IID Sprite depending on an other IID Obj

Get help using Construct 2

Post » Wed Jul 22, 2015 2:09 pm

Hello guys,

I recently discovered Construct2 and I get much fun. But I'm stuck with a problem...
I've made a on screen keypad using a file an other user made. And I wanted to animate it a bit.

So I want to change the sprite frame of the Instance Variable Sprite whih correspond to the Letter Instance Variable.

So basicaly I got a Q which IID is 1 and I want to change the frame of the sprite with the IID of 1 for the W which IID is 2 I want to change the frame of the sprite with the IID of 2, ETC.

Hoping someone can help me !

Thanks !
B
4
Posts: 1
Reputation: 202

Post » Wed Jul 22, 2015 2:48 pm

if sprite.IID = 1, set animation frame to sprite(2).framenumber

Put a 2 in brackets just before the . and frame number to pick the sprite in an action.

Alternatively store sprite 2's animation frame in a global variable and set sprite 1's to the value stored there.
B
43
S
22
G
20
Posts: 735
Reputation: 11,977


Return to How do I....?

Who is online

Users browsing this forum: No registered users and 3 guests