Is object moving?

Get help using Construct 2

Post » Thu Jul 11, 2013 5:27 pm

Hi

Im having problems playing the moving animation, because I cant detect accurately when the enemy object is moving.

I do this:


http://s24.postimg.org/438kwllxx/Screenshot_32.png

but what I get is that sometimes the object plays the walk animation, without moving. im guessing its when the object is moving along the path, but moving very, very slowly.

But when the object is moving along path, the 8way behavior don't register movement.

Is there a way to know absolutely if an object is moving regardless of which behavior is making the movement?

or the speed?
B
7
S
3
G
3
Posts: 53
Reputation: 2,459

Post » Thu Jul 11, 2013 5:57 pm

Yes! There is a way !

Actually there isn't a global speed variable that I know of, but every "moving" behavior has one.
You can then have your condition on event 3 look something like this :
screenshot
B
17
S
8
G
4
Posts: 473
Reputation: 6,221

Post » Thu Jul 11, 2013 11:30 pm

thanks. gonna try it.

BTW, what does "[CODE]? 1 : 0 = 1[/CODE]" do?
B
7
S
3
G
3
Posts: 53
Reputation: 2,459


Return to How do I....?

Who is online

Users browsing this forum: No registered users and 5 guests