Arc shooting

Get help using Construct 2

Post » Wed Mar 05, 2014 7:42 pm

Basically I want to know how to make my enemies shoot above me so that arrow would hit me. Its pretty easy to make a straight arrow ( set angle to another object ) but i would like to know how can i make that enemies shoot above me. My game is a side scroller.
Thanks in advance.
B
7
S
2
Posts: 102
Reputation: 975

Post » Wed Mar 05, 2014 7:51 pm

I don't know if I understood you. Use the "Set angle toward position" command. Then do something like this:

x: player.x

y: random(player.y-45,player.y+45)

It should choose a random angle between x° below and x° above the player. I don't know if this is correct.
B
10
S
2
Posts: 135
Reputation: 1,090

Post » Wed Mar 05, 2014 8:05 pm

Yeah it seems about right I meant a bit more advanced (like in terraira if you ever played it ) but it will do for now thanks.
B
7
S
2
Posts: 102
Reputation: 975

Post » Wed Mar 05, 2014 8:07 pm

You mean with physics? You could add physics behaviour to the arrows and mess a bit around with it.
B
10
S
2
Posts: 135
Reputation: 1,090

Post » Wed Mar 05, 2014 8:11 pm

Hmm maybe but i am not sure if physics behavior is necessary because gravity on bullet behavior seems like its enough, but i have no idea i am still learning.
B
7
S
2
Posts: 102
Reputation: 975

Post » Wed Mar 05, 2014 8:48 pm

Oh yeah. You are totally right. I didn't use bullets yet. Gravity should do the trick.
B
10
S
2
Posts: 135
Reputation: 1,090


Return to How do I....?

Who is online

Users browsing this forum: bclikesyou, brunopalermo, kellehk, R0J0hound, ST314 and 25 guests