space shooter enemy fleet movement patterns

Get help using Construct 2

Post » Thu Nov 21, 2013 3:47 am

I've been playing around with making an infinite space shooter for a few days. What I'm trying to do is figure out a good way to set patterns for the enemy squads to move in, like back on the old arcade games. I've tried a bunch of different ideas that I came up with but none of them seem to work very well. I'm sure this has been done many times before but I can't find anything in the tutorials or old forum posts on how to do it. Can anyone who has done this before lead me in the right direction on how I can set up some nice patterns?

PS - I've tried using several combinations of sine, bullet, gravity, physics, pinning to invisible rotating sprites, self.x + etc... but I just can't get it to work nicely. I'm not very good at math so that's probably one of my biggest problems. Also, I'm currently using the wrap behavior for the ships, but I can always change that if needed.

Thank you very much for any help you can offer.
B
61
S
20
G
56
Posts: 1,077
Reputation: 35,986

Post » Thu Nov 21, 2013 7:52 pm

If there's anyone out there that has had success making the enemy fleet wave movement patterns I would really like to hear from you and get some ideas. I'm not looking to copy your patterns, I just want to figure out a better way to create mine. Thanks again.
B
61
S
20
G
56
Posts: 1,077
Reputation: 35,986

Post » Fri Nov 22, 2013 2:10 pm

Sorry but I cannot understand what do you mean by Enemy Fleet Wave , if you can tell us more I think maybe some one else can also help you. If the question was clear for me, maybe I can try to help you.
B
96
S
19
G
15
Posts: 198
Reputation: 14,471

Post » Fri Nov 22, 2013 2:22 pm

If you want it randomized you could set up enemy spawn points and enable/disable certain ones so the player never knows what is coming in terms of enemies and it doesn't get tedious.
B
46
S
16
G
79
Posts: 2,170
Reputation: 46,857

Post » Fri Nov 22, 2013 2:47 pm

I am imagining a screen-size invisible sprite with many imagepoints hand-placed by you and enemies moving through them in order via bullet movement? This way you can visualize the movement pattern before they come?

Or you can use many small invisible sprites as waypoints?

You could use arrays to store screen locations and let the enemies loop through various arrays for various flight patterns?

You could also do it in a relativistic way, ie, instead of screen coordinates enemies could have "enters the screen from top, moves 50 pixels south, then 40 pixels west and 90 pixels further south (diagonal), then west until exits the screen... So what you put in 2d array 1: +40,0 2: -40,+90 3: -500,0 and these you add to instance variable called "target" of the bullet behaviour sprite.

Just on the top of my head...
B
18
S
4
G
1
Posts: 332
Reputation: 3,149

Post » Fri Nov 22, 2013 2:53 pm

Create number of patterns and store them in to array. And then call the randomly.
My professional Royalty Free Music at Scirra Assets Store
--------------------------------
Specs: i5 2500, 16gb of ram, gtx 770, win 7, Focusrite Scarlett 8i6, Mackie mr8mk2, Alesis 320, browsing the net on chrome.
B
89
S
30
G
22
Posts: 1,985
Reputation: 20,099

Post » Fri Nov 22, 2013 6:47 pm

Thank you for the ideas. I'll start testing some of these and see what I can come up with. Much appreciated.
B
61
S
20
G
56
Posts: 1,077
Reputation: 35,986


Return to How do I....?

Who is online

Users browsing this forum: Bobbyneal100, Kin, mickclarke, sean080, tinhofiel, TRMG and 40 guests