Shooting Enemy

Get help using Construct 2

Post » Sun Jul 19, 2015 3:48 am

I can't for the life of me figure out why the bullet is going right when I set it to 180 degrees (left)

I have the events set up like this

Event:
>System | Every 2 Seconds
Added Conditions:
>Enemy | X is animation "Reload" playing
>Enemy | Is animation "Shoot" playing > Spawn bullet on Layer 2 (Image Point 1) > Set Bullet angle of motion to 180 degrees

Next Event:
>Bullet | On collision with wall > Destroy

Next Event:
Enemy | On animation "Shoot" finished > Enemy set animation to "Reload"

Enemy | On animation "Reload" finished > Enemy set animation to "Shoot"


I removed the idle animation as it is not needed. It is simply Shoot > Reload > Shoot now. Please help me fix the bullet issue!
Last edited by ChaoticShadow24 on Mon Jul 20, 2015 7:13 am, edited 1 time in total.
B
24
S
10
G
1
Posts: 153
Reputation: 2,660

Post » Mon Jul 20, 2015 12:47 am

Bump bump!
B
24
S
10
G
1
Posts: 153
Reputation: 2,660

Post » Mon Jul 20, 2015 12:57 am

Just add condition to set angle of motion of the bullet = the angle of your enemy
Image Image
B
22
S
13
G
135
Posts: 871
Reputation: 70,320

Post » Mon Jul 20, 2015 6:28 am

Where do I put the condition? I don't think it'll work with one anyway.

The problem I'm having is that even though i've evented the bullet's angle of motion to be 180 degrees, it still travels right. If I change it to 0, it still moves right. I need it to go left.
B
24
S
10
G
1
Posts: 153
Reputation: 2,660

Post » Mon Jul 20, 2015 6:51 am

ChaoticShadow24 wrote:Where do I put the condition? I don't think it'll work with one anyway.

The problem I'm having is that even though i've evented the bullet's angle of motion to be 180 degrees, it still travels right. If I change it to 0, it still moves right. I need it to go left.


The event should work as intended, could you share your eventsheet and/or capx to see what is wrong?
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 » Mon Jul 20, 2015 7:12 am

It's up there ^
B
24
S
10
G
1
Posts: 153
Reputation: 2,660

Post » Mon Jul 20, 2015 7:21 am

ChaoticShadow24 wrote:It's up there ^


If what was up there was enough, I wouldn't have asked..
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 » Mon Jul 20, 2015 7:53 am

But that's literally all there is to it ^-^
B
24
S
10
G
1
Posts: 153
Reputation: 2,660

Post » Mon Jul 20, 2015 8:09 am

ChaoticShadow24 wrote:But that's literally all there is to it ^-^


Cool, so everything is working now?

If not, please share your capx..
You could also choose to make a screenshot of your event sheet and the settings of your bullet object, but a capx would probably be better..
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 » Mon Jul 20, 2015 8:47 am

Got it! It works now ^-^

For some reason, everytime I reply to a thread, it doesn't come up and I have to do it twice -.-

Thanks for the help, I updated Construct and now it works all of a sudden.
B
24
S
10
G
1
Posts: 153
Reputation: 2,660

Previous

Return to How do I....?

Who is online

Users browsing this forum: No registered users and 20 guests