How do I change bullet direction? speed not working ?

Get help using Construct 2

Post » Fri Aug 29, 2014 7:53 am

Hi guys,
I have a small problem..I have a tank which turret is rotating ( with arrows that U choose) I set that it spawns with "space" a missile. I set missile ( bullet angle) to Self.angle....but the missiles are flyng in the oposite direction ( but with right angle )...even I set bullet speed positive or negative...there is no change...probably I am making mistakes...can U help me ???

thanks guys :)
B
37
S
16
G
2
Posts: 447
Reputation: 4,865

Post » Fri Aug 29, 2014 8:34 am

You mean like this
You do not have the required permissions to view the files attached to this post.
B
250
S
39
G
15
Posts: 1,953
Reputation: 40,623

Post » Fri Aug 29, 2014 9:01 am

Hi thanks...yes similar like that....my problem is that it is not so obvious in my experiments that the bullet goes in the direction or in angle that it should have. Is ther any command that makes it going exactly with the right angle and with the direction of my choice ???

thanks a lot :)
B
37
S
16
G
2
Posts: 447
Reputation: 4,865

Post » Fri Aug 29, 2014 9:06 am

Yes, there is..

Would you please explain what the direction of your choice is?
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 » Fri Aug 29, 2014 9:14 am

I am sorry I do not understand your question. Will please upload your capx so we can understand what do you wish. Thanks
B
250
S
39
G
15
Posts: 1,953
Reputation: 40,623

Post » Fri Aug 29, 2014 10:57 am

You need to modify the "Angle of motion" of the bullet when its speed is superior to 0.
If the property "Set angle" of the Bullet behavior is set to yes, you will modify the current angle it's moving towards.

Be sure to check the manual to see all the properties and actions of the bullet behavior. When encountering/using a plugin or behavior you're not yet familiar with, do the same. Useful read and it let's you know the tool you can use in C2.
New to Construct ? Where to start

Image Image

Image Image

Please attach a capx to any help request or bug report !
Moderator
B
289
S
112
G
94
Posts: 7,333
Reputation: 69,293

Post » Fri Aug 29, 2014 12:34 pm

Hi again, thanks guys for the help...here I have my simple example...how would U proceed in this case to make the rocket going in the cannon direction ??? ( left mouse to shoot!)


thanks guys
You do not have the required permissions to view the files attached to this post.
B
37
S
16
G
2
Posts: 447
Reputation: 4,865

Post » Fri Aug 29, 2014 2:15 pm

Sprite2 set angle of motion to Sprite.angle degrees

for this youd have to turn the Sprite image about 90 degrees so it's originally pointing right (0 degrees)
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 » Fri Aug 29, 2014 2:54 pm

U need to set direction right when placing sprites. U will see in file
You do not have the required permissions to view the files attached to this post.
B
7
Posts: 16
Reputation: 315

Post » Fri Aug 29, 2014 3:21 pm

thanks U guys...Now I will try :) very kind people here on scirra forum :)
B
37
S
16
G
2
Posts: 447
Reputation: 4,865


Return to How do I....?

Who is online

Users browsing this forum: Lancifer, nahima and 14 guests