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

#1 2008-03-26 20:05:53

Rook
Scratcher
Registered: 2008-01-12
Posts: 2

3-D games

Can you make 3-D games?

Offline

 

#2 2008-03-26 20:36:08

S65
Scratcher
Registered: 2007-05-18
Posts: 100+

Re: 3-D games

No, you can't make true 3D games. However, there are ways to "simulate" 3D with the pen functions or other things.

I've actually done several experiments in 3D:

http://scratch.mit.edu/projects/S65/42662
http://scratch.mit.edu/projects/S65/43418
http://scratch.mit.edu/projects/S65/125617

Also check out Canthiar's 3D Model project and Mayhem's 3D Dungeon Adventure.

Offline

 

#3 2008-03-27 23:30:24

AddZero
Scratcher
Registered: 2007-08-11
Posts: 100+

Re: 3-D games

Short answer:
Yes, but not like modern "3d" games.

Scratch can do the math necessary to draw points in 3d space, ([urlhttp://en.wikipedia.org/wiki/3D_projection]3d projection[/url])

Here's tech demo for a 3d tank game I'm working on.
You can move the camera around a object.
http://scratch.mit.edu/projects/AddZero/129124
Scratch can't draw solid colored shapes (polygons), just lines.

Scratch is good at drawing sprites. by making the sprite bigger it seems closer and smaller- farther away.  But, as far as I know there's not an easy way change the order (z-sort) of the sprites, so closer objects are in front.  I'm working on that.

You can make a sprite that has pictures for every direction it turns then change the pictures depending on what angle it is viewed. 
http://scratch.mit.edu/projects/AddZero/127846
http://scratch.mit.edu/projects/dingdong/107889


Longer answer:
Well, we need to define "3d"

All "3d" games and cg animations are 2d on your screen.  They're flat illusions.  They use tricks to emulate how our eyes see objects, with perspective, lighting, textures... When objects are big on the screen we think they're closer, and when they're smaller, we think they're farther away...

In the early days of 3d games, before fast computers- programmers had to use simpler, clever tricks to draw "3d"... 
Wolfenstein 3d  drew sprites like Scratch can. when objects are closer they are bigger.  But to draw the walls it use "raycasting".  I bet it's possible for Scratch to do a form of this, just not textured walls, fast.

Ahh, I'll keep the long answer short for now.


Here's my 3d gallery.
http://scratch.mit.edu/galleries/view/14803

Last edited by AddZero (2008-03-28 00:09:41)


http://scratch.mit.edu/static/icons/buddy/524717_med.png?t=2010-06-15+09%3A48%3A36

Offline

 

#4 2008-03-27 23:34:43

dingdong
Scratcher
Registered: 2007-08-09
Posts: 1000+

Re: 3-D games

it is possible but it's very hard, you can only make 3D games that make it so you are heading down a tunnel


http://img851.imageshack.us/img851/2829/superanbanner.png
click the image for my music

Offline

 

#5 2008-03-28 00:14:47

AddZero
Scratcher
Registered: 2007-08-11
Posts: 100+

Re: 3-D games

Yes Scratch is limited, but that just makes us have to be more clever in finding solutions.  Not everything has been explored yet.  smile


http://scratch.mit.edu/static/icons/buddy/524717_med.png?t=2010-06-15+09%3A48%3A36

Offline

 

#6 2008-03-29 23:52:59

Sakani
Scratcher
Registered: 2007-07-09
Posts: 100+

Re: 3-D games

Thats my goal to make a 3d game. Just I need Someone to make the sprites that look 3d and Ill script it


http://img4.imageshack.us/img4/1686/demonscratchcomingsoon.png

Offline

 

#7 2008-03-30 00:00:17

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

Re: 3-D games

You can find 3D sprites for your projects @ http://reinerstileset.4players.de/englisch.html


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

 

#8 2008-04-05 15:52:26

the_guardian
Scratcher
Registered: 2008-03-16
Posts: 98

Re: 3-D games

I am working on a 3D game.  i uploaded the first piece (just a rotating space ship and scrolling starfield).  http://scratch.mit.edu/projects/the_guardian/135440
I used three levels of scrolling starfields to try and give the game "depth".  Check it out, I plan to upload another version when i get an enemy and the firing control figured out.  I used POV Ray to model the space ship.  It is a free ray tracing program.


Guardian 3D!  http://scratch.mit.edu/projects/the_guardian/169865

Offline

 

#9 2008-04-13 18:48:38

VF1
Scratcher
Registered: 2007-07-25
Posts: 26

Re: 3-D games

Why, yes!

There is software called Blender that allows you to make 3D objects and take screenshots of them, turning them into sprites. The URL for the website is:
http://www.blender.org

It also involves scripting, for the more advanced ones. I know how to hack into the Smalltalk code that Scratch is written in, and add scripts to my 3D project. This gives me full control over my sprites and backgrounds, music, and allows me to do things that you just can't do with the regular Scratch features. This is essential for some 3D games.

Whew. I have a lot of things to catch up on on the Scratch website, so I'd better get going. Bye all!


Skilled in Java, Javascript, HTML, XML, Smalltalk, XHTML, BBC, and Scratch, of course!
Aliases: SmartyPants34, SP34, YummyPancakes, MastR, C-man
If it has to do with computers, I know it!
Shooting for forum moderator

Offline

 

#10 2008-04-14 00:52:35

thecooltodd
Scratcher
Registered: 2008-03-08
Posts: 75

Re: 3-D games

This'll probably be the closest someone will ever get to a 3d game:
https://scratch.mit.edu/projects/blob8108/125971

Offline

 

#11 2008-06-06 13:55:16

dbal
Scratcher
Registered: 2007-07-19
Posts: 100+

Re: 3-D games

Sakani wrote:

Thats my goal to make a 3d game. Just I need Someone to make the sprites that look 3d and Ill script it

A practical way to create sprite costumes from a variety of angles is to take screen shots of an Alice object while rotating the Alice object.  Just do the following:

1. Open an Alice world.
2. Select an object from the gallery and add it to the world.
3. Take a picture of the world.
4. Make an interactive method call to turn the object around its vertical axis by, say 15 degrees.
5. Go back to 3, take another picture, and continue looping until you have pictures of the object from all of the desired angles.

Do the same thing again by rotating the object around the horizontal axis if you also want views from those angles.

Import the pictures into Scratch as costumes for a sprite.

Edit the costumes to erase the background and you have a set of costumes for a sprite viewed from a variety of different angles.


Dick Baldwin - Don't get stuck scratching. When you master Scratch, move on up to more serious programming languages. Free online programming tutorials:
Scratch - Alice - Java - C# - C++ - JavaScript - XML - Python - DSP

Offline

 

#12 2008-06-06 14:45:27

bigB
Scratcher
Registered: 2007-06-09
Posts: 100+

Re: 3-D games

AddZero wrote:

Yes Scratch is limited, but that just makes us have to be more clever in finding solutions.  Not everything has been explored yet.  smile

I couldn't agree more.

Ive just released a 3D game. (the link is in my signature)
Now that scratch has trig functions it is alot simpler.


http://scratch.mit.edu/projects/bigB/260981 Draw to Text
http://scratch.mit.edu/projects/bigB/181829 3D Stunt Flyer

Offline

 

#13 2008-07-06 13:12:09

the_guardian
Scratcher
Registered: 2008-03-16
Posts: 98

Re: 3-D games

I have a new 3D game out now http://scratch.mit.edu/projects/the_guardian/169865
It's really just 3D images moving on a 2D plane, but i think it looks good.


Guardian 3D!  http://scratch.mit.edu/projects/the_guardian/169865

Offline

 

#14 2008-07-07 13:28:46

bigB
Scratcher
Registered: 2007-06-09
Posts: 100+

Re: 3-D games

ive released another 3D game.  It was  http://scratch.mit.edu/projects/bigB/181829more complicated than my previous one as everything moves and rotates in relation to you so you effectively appear to stay still.
   The angles and viewing of sprites depending on which way you are facing was harder than the actual distances and projection which surprised me.
  Cleverly I chose to set the game in space and most of the sprites are just stars which kept things simpler.  Maybe i'll improve it with better graphics eventually.


http://scratch.mit.edu/projects/bigB/260981 Draw to Text
http://scratch.mit.edu/projects/bigB/181829 3D Stunt Flyer

Offline

 

Board footer