Can't figure out simple movement issue

Get help using Construct 2

Post » Fri Jan 31, 2014 7:03 am

Could anybody tell me why my movement and animation is wonky? I've double checked the origins, direction, movement, everything, and I still can't get it to work.

It's a simple "maze" movement system but am I missing something here? I don't know why the sprite is jumping around as well as displaying the wrong animations

I can't post links for now but could I send someone the .capx file to review?
B
3
Posts: 5
Reputation: 260

Post » Fri Jan 31, 2014 7:39 am

Sure, I could take a look. Just PM the link.
B
56
S
15
G
13
Posts: 826
Reputation: 17,705

Post » Fri Jan 31, 2014 7:54 am

Ugh, can't even PM cause of limits

Edit: https://www.dropbox.com/s/yld4i1kw7wsd55w/Pac-ManxPortal.capxsaltyprincess2014-01-31 07:55:21
B
3
Posts: 5
Reputation: 260

Post » Fri Jan 31, 2014 3:29 pm

Hi..

I looked to this and noticed that there is only one animation sequence (down) in it.. I rotated it towards right (so that it turns proplerly) and gave it to all directions.. Not that this would fix all, but for starters.

https://www.dropbox.com/s/5unc25mi8t2at49/Pacmanx2b.capx
Need help? Upload .capx file with your question.
B
16
S
4
G
2
Posts: 233
Reputation: 2,560

Post » Fri Jan 31, 2014 3:43 pm

All you have to do to make it work is to set the bullet set angle property to NO.
I told my dentist I had trouble with my teeth and asked her to fix it without looking in my mouth..
B
54
S
16
G
8
Posts: 6,160
Reputation: 19,775

Post » Sat Feb 01, 2014 2:29 am

[QUOTE=Joannak] Hi..

I looked to this and noticed that there is only one animation sequence (down) in it.. I rotated it towards right (so that it turns properly) and gave it to all directions.. Not that this would fix all, but for starters.

[/QUOTE]

Ah, weird, I had 4 animation sequences (those green film strips right?) for each direction

Did you set the sprite to manually turn and would that be more efficient than making a separate animation sequence for each direction?

[QUOTE=LittleStain] All you have to do to make it work is to set the bullet set angle property to NO.[/QUOTE]

Perfect, may I ask what that option affected exactly?
B
3
Posts: 5
Reputation: 260

Post » Sat Feb 01, 2014 4:51 am

@saltyprincess You are right about multiple animations.. That small animation selection box was under editor window so I missed it totally at the first time. (IMHO C2 Gui needs some overhaul.. there are too many confusing windows appearing and disapperaing)


Bullet-behaviour has a default property that it rotates the sprite into the direction of movement. if you look the example I upped, it uses Bullet automatic rotation with just 1 animation. Of course it's better to use those 4 animations that are on right directions, but then you need to turn the automatic rotation off.

@LittleStain .. I noticed an oddity.. if I take the original and just turn the automatic rotation off, the first movement (if is up or down) seems to be ... Wonky? Like the animation looks ok, but the sprite moves -90degrees what's expected.
Need help? Upload .capx file with your question.
B
16
S
4
G
2
Posts: 233
Reputation: 2,560

Post » Sat Feb 01, 2014 9:11 am

[QUOTE=Joannak]
Bullet-behaviour has a default property that it rotates the sprite into the direction of movement. if you look the example I upped, it uses Bullet automatic rotation with just 1 animation. Of course it's better to use those 4 animations that are on right directions, but then you need to turn the automatic rotation off.
[/QUOTE]

Very helpful info, I didn't even know that was a property of bullet-behavior and probably would have been scratching my head over it for days.

[QUOTE=Joannak]
@LittleStain .. I noticed an oddity.. if I take the original and just turn the automatic rotation off, the first movement (if is up or down) seems to be ... Wonky? Like the animation looks ok, but the sprite moves -90degrees what's expected. [/QUOTE]

I noticed this as well, I fixed it by going into the event sheet and making sure "Set bullet speed" came before "Set bullet angle of motion" in each keyboard event

I don't know how or why this fixes it, though (plus it seems counter-intuitive to start moving *before* changing direction)
B
3
Posts: 5
Reputation: 260

Post » Sat Feb 01, 2014 9:36 am

[QUOTE=saltyprincess]

I noticed this as well, I fixed it by going into the event sheet and making sure "Set bullet speed" came before "Set bullet angle of motion" in each keyboard event

I don't know how or why this fixes it, though (plus it seems counter-intuitive to start moving *before* changing direction)[/QUOTE]

An object already has a value for direction even if it's 0 degrees but you cannot set its angle of motion if it doesn't have any motion.
There are 10 types of people in the World, those that understand binary and those who don't.
B
7
S
2
Posts: 93
Reputation: 797


Return to How do I....?

Who is online

Users browsing this forum: No registered users and 20 guests