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

#1 2013-01-16 12:45:11

CAA14
Scratcher
Registered: 2013-01-14
Posts: 1000+

Questions and more Questions.

Hi,

I'm planning on doing a cool remix of pac-man, but before i do, i need to know a few things,

1.

Can i create one pellet, and have it randomly generate pellets for the levels or do i have to place each pellet individually?

2.

I want to have a course that's not all on the screen at a time. How would i do this in such a way that the screen follows pac-man, but "scrolls" to area's off screen if he moves to that area?

3.

Is it possible to do mulitplayer split screen action? Or is that currently impossible in scratch?

(Us the arrow keys for P1 and "a","w","s", and "d" for P2 is how i would do the controls...)

regards,

CAA14

Offline

 

#2 2013-01-16 12:55:02

iaoumeur
Scratcher
Registered: 2012-11-24
Posts: 500+

Re: Questions and more Questions.

CAA14 wrote:

Hi,

I'm planning on doing a cool remix of pac-man, but before i do, i need to know a few things,

1.

Can i create one pellet, and have it randomly generate pellets for the levels or do i have to place each pellet individually?

2.

I want to have a course that's not all on the screen at a time. How would i do this in such a way that the screen follows pac-man, but "scrolls" to area's off screen if he moves to that area?

3.

Is it possible to do mulitplayer split screen action? Or is that currently impossible in scratch?

(Us the arrow keys for P1 and "a","w","s", and "d" for P2 is how i would do the controls...)

regards,

CAA14

Ok number 1: Yes you do have to place every pellet individually.

number 2: I don't actually know what you mean. Could you elaborate on it?

number 3: It is possible you could use the arrow keys for player 2.

Player 2
When (up v) arrow key pressed
Move an amount up
etc.


Here is an example of a very good pacman. If you download it you could use some ideas from it but don't keep everything the same http://scratch.mit.edu/projects/DSLmediapro/2867705


The Dot 3 is out!!! Play it here!

Offline

 

#3 2013-01-16 13:43:48

CAA14
Scratcher
Registered: 2013-01-14
Posts: 1000+

Re: Questions and more Questions.

Hi,

Thanks for responding.

What i meant by #2 was that,

Pac-man is always on screen, but he can move off screen, and when he does, the view follows him to the part of the maze that he's on.

In other words, The maze is bigger than the view port, and the view port follows pac-man where ever he goes on the big maze.

I hope that's a little more clear.(It's kind of hard to put to words)

Thanks again,

regards,

CAA14

P.S. #3 wasn't about a player 2's controls, it was asking about a split screen action's possibility... smile

CAA14 wrote:

3.

Is it possible to do mulitplayer split screen action? Or is that currently impossible in scratch?

P.P.S. Where are you getting a "player 2" block? Can you create blocks in scratch?

Offline

 

#4 2013-01-16 14:24:43

disney22girl
Scratcher
Registered: 2012-09-08
Posts: 100+

Re: Questions and more Questions.

:p


When you wanna see my sexy just ask  smile

Offline

 

#5 2013-01-16 19:50:47

sonicfan12p
Scratcher
Registered: 2011-11-16
Posts: 1000+

Re: Questions and more Questions.

CAA14 wrote:

Hi,

I'm planning on doing a cool remix of pac-man, but before i do, i need to know a few things,

1.

Can i create one pellet, and have it randomly generate pellets for the levels or do i have to place each pellet individually?

Not yet, but in Scratch 2.0 there will be a cloning feature that can have the same effect you're looking for.

2.

I want to have a course that's not all on the screen at a time. How would i do this in such a way that the screen follows pac-man, but "scrolls" to area's off screen if he moves to that area?

There are a few ways to do this.
1. Pac-Man is always in the center of the screen, the only thing moving is the background.
2. Pac-Man moves until he reaches a certain part of the screen, then the background begins scrolling.
3. Make it entirely static, but when Pac-Man moves off screen, the background switches and Pac-Man's coordinated are reset.

Tell me which one you want, and I'll try to explain.


3.

Is it possible to do mulitplayer split screen action? Or is that currently impossible in scratch?

Yes, it is, but it's a bit complicated. I can attempt to dig up information or make an experimental project if you want...

(Us the arrow keys for P1 and "a","w","s", and "d" for P2 is how i would do the controls...)

regards,

CAA14


Why are the secret organizations getting all the attention?  mad

Offline

 

#6 2013-01-16 22:56:13

CAA14
Scratcher
Registered: 2013-01-14
Posts: 1000+

Re: Questions and more Questions.

Hi,

Thanks again sonic fan!

Hi,

I'm planning on doing a cool remix of pac-man, but before i do, i need to know a few things,

1.

Can i create one pellet, and have it randomly generate pellets for the levels or do i have to place each pellet individually?

Not yet, but in Scratch 2.0 there will be a cloning feature that can have the same effect you're looking for.

Awesome!

2.

I want to have a course that's not all on the screen at a time. How would i do this in such a way that the screen follows pac-man, but "scrolls" to area's off screen if he moves to that area?

There are a few ways to do this.
1. Pac-Man is always in the center of the screen, the only thing moving is the background.
2. Pac-Man moves until he reaches a certain part of the screen, then the background begins scrolling.
3. Make it entirely static, but when Pac-Man moves off screen, the background switches and Pac-Man's coordinated are reset.

Tell me which one you want, and I'll try to explain.

The 1st one.

3.

Is it possible to do mulitplayer split screen action? Or is that currently impossible in scratch?

Yes, it is, but it's a bit complicated. I can attempt to dig up information or make an experimental project if you want...

Thanks but there's no need right now, but if you'd tell me where it "dig up" that sort of info, That would be great.  smile

(Us the arrow keys for P1 and "a","w","s", and "d" for P2 is how i would do the controls...)

regards,

CAA14

Offline

 

#7 2013-01-17 00:09:55

amcerbu
Scratcher
Registered: 2009-07-21
Posts: 500+

Re: Questions and more Questions.

Technically, it's possible to create multiple objects onscreen without cloning by using the pen.  However, if you want the background to scroll, you might run into speed problems.  The pen is a feature of Scratch that allows the user to draw lines or "stamp" sprites onto the screen.  These marks will remain until they are overwritten by other pen commands, or the "clear" command is called.  Pen drawings cannot be manipulated (e.g. moved) once they are placed. 

In projects with an indefinite number of objects (for example, this simple physics simulation), it's possible to use the pen to represent many objects, without many sprites.  That's how complex 1-sprite 1-script projects work.  However, since pen marks remain stationary on the screen, this requires clearing and re-drawing all the objects during each frame (30 times a second).  This usually demands the speed of Flash "turbo mode."  There's a shady way to accelerate scripts without Flash turbo, but that's outside the scope of this topic, and I don't like it very much. 

Your "scrolling" Pac-Man game would necessitate either an inordinate number of sprites (which would be rather inefficient, and prone to bugs), or a re-drawing system using the pen.  If you're up to the challenge, I'd encourage you to try the second option.  On the other hand, if you're just getting into programming, it's probably a better idea to start with a version that doesn't scroll.  That would greatly simplify the drawing scripts.  You can draw the "blobs" at the beginning of the game with the pen, and then draw over them when the player reaches an appropriate position.  I can help if you want (I posted some links to a few pen-related projects I've made on my test account, some of which demonstrate constant re-drawing, and some of which draw once and then leave the image onscreen). 

The Tetris program uses a series of stamp commands to re-draw the field all the time.  The platforming project draws the field once, and then leaves it on the stage.  The circle physics and pen test projects both re-draw every frame. 

Tetris: http://scratch.mit.edu/projects/ubrecma/2785703
Platforming: http://scratch.mit.edu/projects/ubrecma/2763376
Circle Physics: http://scratch.mit.edu/projects/ubrecma/2666735
Pen Re-Draw Speed Test: http://scratch.mit.edu/projects/ubrecma/2577639

EDIT: And also check out this one.  It's a simulation of an object subject to the gravitational pulls of an indefinite number of (user-defined) planets. 

http://scratch.mit.edu/projects/ubrecma/3042703

Last edited by amcerbu (2013-01-17 01:58:59)

Offline

 

#8 2013-01-17 09:08:23

CAA14
Scratcher
Registered: 2013-01-14
Posts: 1000+

Re: Questions and more Questions.

Hi,


Thanks for responding,

Ok, I'll look into the pen thing,(to be honest I did not know that it had a practical use)

I Really want it to not all be on one screen, but I guess I can make it all on one screen first, then update it once I figure out the offscreen stuff.  smile


Thanks again!

CAA14

Offline

 

#9 2013-01-17 11:09:08

sonicfan12p
Scratcher
Registered: 2011-11-16
Posts: 1000+

Re: Questions and more Questions.

CAA14 wrote:

2.

I want to have a course that's not all on the screen at a time. How would i do this in such a way that the screen follows pac-man, but "scrolls" to area's off screen if he moves to that area?

There are a few ways to do this.
1. Pac-Man is always in the center of the screen, the only thing moving is the background.
2. Pac-Man moves until he reaches a certain part of the screen, then the background begins scrolling.
3. Make it entirely static, but when Pac-Man moves off screen, the background switches and Pac-Man's coordinated are reset.

Tell me which one you want, and I'll try to explain.

The 1st one.

That's a good choice. Since that's the one you want though, wait until 2.0 to do the pellets. You'll have access to the beta in 11 days, if you want to do that. But making pacman is easy. Sadly I don't have a project that can demonstrate for you, but there's a wiki article here that explains it somewhat, so you can see the basic principles. However, it will tell you in the top down scrolling section to go to the article about it, don't do it. That article displays the most inefficient way to do it, and also the buggiest. Anyway, read that article, and any further questions about it I'll answer.

3.

Is it possible to do mulitplayer split screen action? Or is that currently impossible in scratch?

Yes, it is, but it's a bit complicated. I can attempt to dig up information or make an experimental project if you want...

Thanks but there's no need right now, but if you'd tell me where it "dig up" that sort of info, That would be great.  smile

In the article linked to above, there is a section addressing that. But it's the only info I could find on the wiki. I don't think it's been done too many times if it has been done, so you could be the pioneer of this type of gameplay in Scratch. I'll try to answer any question I can though.

(Us the arrow keys for P1 and "a","w","s", and "d" for P2 is how i would do the controls...)

regards,

CAA14


Why are the secret organizations getting all the attention?  mad

Offline

 

#10 2013-01-17 19:44:27

CAA14
Scratcher
Registered: 2013-01-14
Posts: 1000+

Re: Questions and more Questions.

Hi,

Thanks again sonicfan,

I think i might try that,
As to waiting for 2.0, i was already planing on that.  smile

And to amcerbu, Thanks to you also, But to be honest, using scratch for only a few days as i type this, the pen thing is (Hopefully understandably) confusing, could you recommend, or (If you've got the time, of course:)) make a simple tutorial on that? I may use cloning any way, but at least knowing how to effectively use the pen thing would be valuable.

Thanks again guys, y'all are great.  wink

Regards,

CAA14

Offline

 

Board footer