Photomanipulation in C2

Get help using Construct 2

Post » Mon Nov 07, 2011 8:28 pm

Well i've been looking around and i can't seem to find any way to make C2 import a different sprite to replace the old one (like when the character turns around). Is this not implanted or am i just doing it wrong?
B
22
S
3
G
6
Posts: 52
Reputation: 4,387

Post » Mon Nov 07, 2011 8:35 pm

Double click the sprite in the editor window or right click it and pick Edit Animation, no?
B
19
S
6
G
6
Posts: 1,101
Reputation: 5,646

Post » Mon Nov 07, 2011 8:58 pm

Not exactly what i was looking for, i want to edit it so it changes it's sprite (2.5d sprite) to one fitting the angle it is in.
B
22
S
3
G
6
Posts: 52
Reputation: 4,387

Post » Mon Nov 07, 2011 9:43 pm

I see. Your topic title and explanation wasn't exactly clear.

In CC this worked by having angles for all the animations, which seems to be missing in C2. So my idea was to just have the animation frame correspond to angle and then you could animate it using events.

So far, so good - we decide to have, say 16 directions, which gives us 360/16 = 22.5 degree increments, thus our animation frame is round(Sprite.Angle/22.5).

And it works, BUT C2 seems to lack a great option from CC, which is the option to not turn the sprite when the angle changes (maybe I'm just missing something).

So what we currently have is the animation is being set correctly, but the object also rotates by itself, so it doesn't look right. Anyhow, the demo is here.

If Ash implements NOT turning the sprite on angle changes we are good to go.

Edit: Lock animation angle is the option from CC that C2 really needs.Somebody2011-11-07 21:50:08
B
19
S
6
G
6
Posts: 1,101
Reputation: 5,646

Post » Tue Nov 08, 2011 12:12 am

You can figure everything without having to actually changing the angle.
Angle(x1,y1,x2,y2) gives you the angle between the points... from within 0 to 180 degrees. You need the full 360 here so you have to do some comparisons.

isoangle

What would be nice here is an expression that takes everything into account... perhaps a behavior.newt2011-11-08 00:13:25
Image Image
B
161
S
48
G
89
Posts: 7,347
Reputation: 66,249

Post » Tue Nov 08, 2011 5:36 am

Thanks guys, i'll try these things when i get home from school.

Also sorry for not expressing the topic better, i didn't really know the words for it.
B
22
S
3
G
6
Posts: 52
Reputation: 4,387


Return to How do I....?

Who is online

Users browsing this forum: Radulepy and 5 guests