galaga style pattern movement algorithms

Get help using Construct 2

Post » Mon Oct 15, 2012 6:12 pm

could somebody make a capx that i can study with a view of making galaga style patterns (not the easiest thing to read up on )

there has to be an easier way than "go 90 degrees for 1 second, turn 45 degrees for 0.005" ect...
B
16
S
4
G
4
Posts: 179
Reputation: 4,688

Post » Mon Oct 15, 2012 7:03 pm

Another way to approach it could be to create 2 invisible walls (or use the width of your device) and then simply add a bullet behavior to the enemy. On collision with the side of the play field, reverse its direction and lower is 20 units in Y. Speed increases each time by 1.

Then once you set them all up and hit go they should take care of themselves.
B
50
S
21
G
8
Posts: 844
Reputation: 10,299

Post » Mon Oct 15, 2012 8:43 pm

This is where the PATH movement plugin would come in handy. No word on an official plugin yet (hint, hint Ashley ;) ) You could put your name down in the request thread, but we know the lads are busy so patience is the name of the game. Would be the best feature ever imo though. Would open C2 up to so many more possibilities.

http://www.scirra.com/FORUM/feature-request-path_topic57636_page2.html
B
19
S
5
G
4
Posts: 208
Reputation: 3,960

Post » Mon Oct 15, 2012 9:25 pm

Yeah you really do need something like a path behavior, where you can have multiple nodes, and variable speeds.
Image Image
B
161
S
48
G
90
Posts: 7,356
Reputation: 66,767

Post » Mon Oct 15, 2012 9:43 pm

Thanks, ill try that now. All this has made me REALY fall to my knees before the classic games !!

http://www.youtube.com/watch?v=87vNR8N84bI&feature=youtu.be
B
16
S
4
G
4
Posts: 179
Reputation: 4,688

Post » Mon Oct 15, 2012 9:54 pm

what did you mean by "and lower is 20 units in Y" doesnt quite make sense
B
16
S
4
G
4
Posts: 179
Reputation: 4,688

Post » Mon Oct 15, 2012 10:45 pm

he means increase the Y value of the sprite by 20, so the sprite moves down the screen
B
41
S
11
G
4
Posts: 428
Reputation: 7,356


Return to How do I....?

Who is online

Users browsing this forum: h1k3 and 18 guests