This is a read-only archive of the old Scratch 1.x Forums.
Try searching the current Scratch discussion forums.

#1 2010-05-10 20:35:20

JNet
Scratcher
Registered: 2010-05-02
Posts: 21

Creating a Galaga project...

I'm trying to create a remake of the Galaga game from the arcades into a Scratch version. I'm running into some trouble.

Entrance
When the level started, the enemies entered in in groups in different arrays. How would I replicate this?

Last edited by JNet (2010-05-10 21:18:40)

Offline

 

#2 2010-05-10 20:42:32

technoguyx
Scratcher
Registered: 2008-10-18
Posts: 1000+

Re: Creating a Galaga project...

1. Maybe you should use the same scripts in both missiles. If they're not meant to have the same scripts check the second missile's script, or upload your project for someone to fix it.

2. For this I'd use broadcasts - when a certain broadcast is sent, some ships will move in a certain way.


http://getgnulinux.org/links/en/linuxliberated_4_78x116.png

Offline

 

#3 2010-05-10 23:09:54

JNet
Scratcher
Registered: 2010-05-02
Posts: 21

Re: Creating a Galaga project...

I got the missiles working. I just don't know how I'd do the formations. Here's the game.
http://www.smiliegames.com/galaga/

Offline

 

#4 2010-05-10 23:29:06

archmage
Scratcher
Registered: 2007-05-18
Posts: 1000+

Re: Creating a Galaga project...

Yeah, all the basics like shooting and player movement are not that difficult. What confuses me is how to get the enemies to get those nice looking routes and end up at their destination.

For the movement paths the simplest way I can think of is using 2 arrays to record the x and y positions of the paths the enemies should take which would work similarly to the mouse recorded project included with scratch. Each specific enemy should be numbered and go to its specific place on the map after it has run its path.


Hi, I am Archmage coder extraordinaire. I do Scratch,pascal,java,php,html, AS2 and AS3. Leave me a message if you want coding advice. Also check out my personal website, lots of good stuff about web development, Flash, and Scratch (v1 and v2) !

Offline

 

#5 2010-05-10 23:46:23

JNet
Scratcher
Registered: 2010-05-02
Posts: 21

Re: Creating a Galaga project...

archmage wrote:

Yeah, all the basics like shooting and player movement are not that difficult. What confuses me is how to get the enemies to get those nice looking routes and end up at their destination.

For the movement paths the simplest way I can think of is using 2 arrays to record the x and y positions of the paths the enemies should take which would work similarly to the mouse recorded project included with scratch. Each specific enemy should be numbered and go to its specific place on the map after it has run its path.

I wasn't aware that scratch was able to use arrays. Here's what I have so far: http://scratch.mit.edu/projects/JNet/1041347

Offline

 

#6 2010-05-10 23:52:47

archmage
Scratcher
Registered: 2007-05-18
Posts: 1000+

Re: Creating a Galaga project...

Well scratch has a beginner friendly name for its one-dimensional arrays called lists. Your project seems to have some of the easy parts done but now you are faced with the difficult task of making the enemies.


Hi, I am Archmage coder extraordinaire. I do Scratch,pascal,java,php,html, AS2 and AS3. Leave me a message if you want coding advice. Also check out my personal website, lots of good stuff about web development, Flash, and Scratch (v1 and v2) !

Offline

 

#7 2010-05-12 18:51:08

JNet
Scratcher
Registered: 2010-05-02
Posts: 21

Re: Creating a Galaga project...

archmage wrote:

Well scratch has a beginner friendly name for its one-dimensional arrays called lists. Your project seems to have some of the easy parts done but now you are faced with the difficult task of making the enemies.

Exactly why I made this thread  tongue . I need help in making the enemies "spin" as they attack/enter, then I can do the rest.

Offline

 

#8 2010-05-12 19:34:22

archmage
Scratcher
Registered: 2007-05-18
Posts: 1000+

Re: Creating a Galaga project...

Ok, you need 3 lists, 1 for the x positions, 1 for y positions, and 1 for directions.

The arcade game probably used sine waves or something to get those curvy enemy paths but I am not a math wiz so I can't figure out how to do that.


Hi, I am Archmage coder extraordinaire. I do Scratch,pascal,java,php,html, AS2 and AS3. Leave me a message if you want coding advice. Also check out my personal website, lots of good stuff about web development, Flash, and Scratch (v1 and v2) !

Offline

 

Board footer