Help with a movement behavior plz

Get help using Construct 2

Post » Mon Apr 02, 2012 12:59 am

Hello

I'm currently trying to make a sprite follow some paths and for that I used the bullet behavior and set it angle to these paths but by doing that the image rotate and I need to make it doesn't rotate.. is there a way?
The ideal would be keep the bullet behavior because of the events already made..

it's also controlled by computer, not player.Guif0DA2012-04-02 01:27:10
B
30
S
6
G
5
Posts: 433
Reputation: 6,061

Post » Mon Apr 02, 2012 2:18 am

You can make the bullet object invisible, then pin another object to it.

You could then every tick, set the angle of the pinned object to 0, to ensure it's always the correct angle.

Image
B
27
S
9
G
5
Posts: 487
Reputation: 11,939

Post » Mon Apr 02, 2012 3:40 am

[QUOTE=JohnnySix] You can make the bullet object invisible, then pin another object to it.

You could then every tick, set the angle of the pinned object to 0, to ensure it's always the correct angle.

[/QUOTE]
yA I Have thinked about that but in my game, there will be alot of sprites at the same time, so doubling it's quantity isn't a good idea because of the FPS..
B
30
S
6
G
5
Posts: 433
Reputation: 6,061

Post » Wed Apr 04, 2012 1:20 am

Any1?
B
30
S
6
G
5
Posts: 433
Reputation: 6,061

Post » Wed Apr 04, 2012 1:28 am

Could you use a variable on that object, and set the movement angle to that variable?
On Construct Classic you could set the object not to rotate it's sprite... I wonder if they'll add that feature for C27Soul2012-04-04 01:28:17
B
83
S
21
G
15
Posts: 1,039
Reputation: 15,134

Post » Wed Apr 04, 2012 1:49 am

[QUOTE=7Soul] Could you use a variable on that object, and set the movement angle to that variable?
On Construct Classic you could set the object not to rotate it's sprite... I wonder if they'll add that feature for C2[/QUOTE] ya this would be a feature that I need.

about your suggestion, doing that the object ill always follow his angle and so it can't go to where I want..

because I use the action to rotate to a position and he won't rotate correctly if it can't change his angle..

I had saw an action that is set angle of motion but it's a behavior's action and families can't access it yet.. this would help already
B
30
S
6
G
5
Posts: 433
Reputation: 6,061

Post » Wed Apr 04, 2012 2:56 am

You can use what 7Soul suggested, and check when the object reaches the waypoint - stop the movement.
ImageImage
B
25
S
6
G
8
Posts: 773
Reputation: 6,643

Post » Wed Apr 04, 2012 3:19 am

[QUOTE=Noga] You can use what 7Soul suggested, and check when the object reaches the waypoint - stop the movement.[/QUOTE] the sprite rotate toward a position to reach the waypoints, but doing that the angle changes.

If I add a variable to a fixed value and set his angle to that variable, the sprite won't rotate and so it can't reach his destiny..

need to figure out a way that only the 'object' itself changes his angle, not the 'image' of the object.
B
30
S
6
G
5
Posts: 433
Reputation: 6,061

Post » Wed Apr 04, 2012 4:24 am

I think it could work, but maybe I just don't know how you exactly want it. Here's an example how I see it, can you explain it on this one?
ImageImage
B
25
S
6
G
8
Posts: 773
Reputation: 6,643

Post » Wed Apr 04, 2012 1:30 pm

Im at work now but when I get home ill check it.. thanks!
B
30
S
6
G
5
Posts: 433
Reputation: 6,061

Next

Return to How do I....?

Who is online

Users browsing this forum: flemmig, Jarnopa, nimos100, semaso, Skebab and 10 guests