Difficulties with Set Animation

For questions about using Classic.

Post » Thu Jan 22, 2009 8:22 pm

I have two sprites with animations named the same things. I want to sync up their animations. I have an event,

+Always
-Sprite2: Set animation to Sprite1.AnimName
-Sprite2: Set animation frame to Sprite1.AnimFrame

Yet Sprite2 never changes its animation. Why?
B
2
G
3
Posts: 71
Reputation: 992

Post » Thu Jan 22, 2009 9:44 pm

Could it be because they are the same sprite?
Image Image
B
161
S
48
G
90
Posts: 7,347
Reputation: 66,749

Post » Thu Jan 22, 2009 10:05 pm

No. I actually WANTED it to be the same sprite, as it'd make thing easier, but this is to implement the OnionSkin thingy posted in the suggestion forum. It's definitely two sprites, with the animations from one painstakingly copied from one to the other.
B
2
G
3
Posts: 71
Reputation: 992

Post » Thu Jan 22, 2009 10:40 pm

Why wouldn't it work? Do you have the same animation names and number of frames in both sprites?
Look at this cap, press 1, 2 or 3 to change animations... as you can see it works just fine.
B
21
S
6
G
10
Posts: 1,024
Reputation: 7,445

Post » Fri Jan 23, 2009 12:35 am

Found my problem. I was setting the animation and THEN spawning the object, instead of the other way around. Every time I spawned a new object, it'd default to the 1st animation, and ignore the fact that I was setting a new one 4 ticks later. I had figured that I would be changing the master, and all copies would be the same as the master, but this turned out not to be the case.
B
2
G
3
Posts: 71
Reputation: 992


Return to Help & Support using Construct Classic

Who is online

Users browsing this forum: No registered users and 3 guests