a sprite change to another

Get help using Construct 2

Post » Mon Jun 25, 2012 6:33 pm

a sprite change to another sprite
hello,
I could help make an event to change a sprite and another sprite so the sprite continue playing again.
B
12
S
4
G
4
Posts: 138
Reputation: 3,710

Post » Mon Jun 25, 2012 6:46 pm

please someone help me
B
12
S
4
G
4
Posts: 138
Reputation: 3,710

Post » Mon Jun 25, 2012 7:03 pm

Animations?
B
10
S
3
G
3
Posts: 45
Reputation: 2,984

Post » Mon Jun 25, 2012 7:26 pm

is not an animation, I just want to change a sprite on the other of which I have in my library. for example it happens to touch an object.
B
12
S
4
G
4
Posts: 138
Reputation: 3,710

Post » Mon Jun 25, 2012 7:26 pm

[QUOTE=TehChikenHater] Animations?[/QUOTE]

is not an animation, I just want to change a sprite on the other of which I have in my library. for example it happens to touch an object.
B
12
S
4
G
4
Posts: 138
Reputation: 3,710

Post » Mon Jun 25, 2012 7:28 pm

Have you followed the beginner's tutorial and the Platform game tutorial? Simple concepts like this can be easily learned through following these tutorials.

Also, not sure what you mean by 'library'. This isn't GameMaker, every sprite has its own image library, if you will, in its animations.sqiddster2012-06-25 19:29:39
B
90
S
30
G
24
Posts: 3,189
Reputation: 32,400

Post » Mon Jun 25, 2012 7:31 pm

[QUOTE=sqiddster] Have you followed the beginner's tutorial and the Platform game tutorial? Simple concepts like this can be easily learned through following these tutorials.

Also, not sure what you mean by 'library'. This isn't GameMaker, every sprite has its own image library, if you will, in its animations.[/QUOTE]

when I say "library" are the sprites that I created
B
12
S
4
G
4
Posts: 138
Reputation: 3,710

Post » Wed Jun 27, 2012 12:37 pm

If you are talking about changing one Object:Sprite (Sprite 1) to another Object:Sprite( Sprite 2); you can code it a multiple of ways.

After the event where you 'touch' or 'collide' with it. Destroy Create Sprite 2 to the position and layer of Sprite 1, then destroy Sprite 1.

Alternatively If Sprite 2 is always positioned to Sprite 1. At the start of the layout turn Sprite 2 invisible. Then once Sprite 1 is touch, turn Sprite 1 invisible and Sprite 2 visible.

However, as has been suggested. An easy wasy is to have Sprite 1 form the first frame of an animation and Sprite 2 to form the second frame. At the start of the layout you stop the animation and set the frame to the fisrt. Then afte the 'touch' even occurs, you change the animation frame to the second one. Creating the illustion of the Sprites switching.
B
85
S
31
G
14
Posts: 106
Reputation: 16,440


Return to How do I....?

Who is online

Users browsing this forum: Google [Bot], Yahoo [Bot] and 20 guests