Page 1 of 2

3D Platforms -UPDATED now with X and Y scrolling

PostPosted: Wed Aug 06, 2008 5:46 am
by feral
I am not sure yet what I want to do with this idea ?

any one have an idea ?

basically a 3D/parallax crossover effect - parallaxing but with real 3d - basically as you move around the platforms change perspectives on the fly to give a moving 3d ? ...not sure how to say it...but a real 3d effect.


use cursor keys to move screen around ( the cavemen actors do nothing - they are only there to give a sense of perspective)
if there are no blocks showing on your screen -you have scrolled to far ( this is only a demo type thing)
3dplat.jpg

click pic to enlarge
3dplat2.zip
windows executable
(754.08 KiB) Downloaded 179 times


PS: NOT counting the caveman actors - see if you can guess how many animations are in this.....

Re: 3D Platforms

PostPosted: Wed Aug 06, 2008 5:59 am
by feral
Same effect only this time it is TOP DOWN

eg: gauntlet style

Think of looking "DOWN" into a warehouse full of crates stacked on each other

( again the skeleton actors are only to give the sense of perspective ( and they are not my artwork either)

only the crates are my artwork.
3dtopdown.jpg
click to enlarge pic


use cursor keys to scroll around ( if no more crates show you went to far )
topdown3d.zip
windows executable
(1009.02 KiB) Downloaded 154 times

Re: 3D Platforms

PostPosted: Thu Aug 07, 2008 10:57 pm
by asmodeus
great job! that's very nice. It would be better if the effect is also avaible in the horizontal scrolling, then it would be perfect! :D

Re: 3D Platforms

PostPosted: Thu Aug 07, 2008 11:12 pm
by feral
asmodeus wrote:great job! that's very nice. It would be better if the effect is also avaible in the horizontal scrolling, then it would be perfect! :D


thanks :) vertical and horizontal scrolling version coming soon - tho, you can't imagine how much more complex it is to do both....

the key to the current method is the question I posed before

"PS: NOT counting the caveman actors - see if you can guess how many animations are in this....."


to do both, the "answer" to that question, becomes a whole new nightmare... but I am working on it.... LOL

Re: 3D Platforms - UPDATED -now X and Y

PostPosted: Sat Aug 23, 2008 6:42 am
by feral
Here is another version which scrolls in both x and y - I am not sure how effective the illusion is tho ? any feedback, does the "illusion" of 3D hold up OK ? ?

I am trying to think of game ideas for it ? but not sure if it is worth using ?
3dplat3.jpg
click to enlarge pic

3dplat3c.zip
win exe
(752.01 KiB) Downloaded 148 times


BTW
"PS: NOT counting the caveman actors - see if you can guess how many animations are in this....."

just in case anyone was wondering ... in the first example there is only 1 Actor (a cloned "square" and it is not even animated

In the second example there is only 2 actors, the box top, and the box side - again no animations at all.

in this example only 2 actors cloned :roll: and no animations 8)

Re: 3D Platforms - UPDATED -now X and Y

PostPosted: Sat Aug 23, 2008 10:40 am
by asmodeus
feral wrote:Here is another version which scrolls in both x and y [...]

That's great! I have got an idea what kind of game can be made with that effect: Maybe try a maze or puzzle game or something like that seen from the top. There could be blocks in different colours which are for different things.

Re: 3D Platforms -UPDATED now with X and Y scrolling

PostPosted: Fri Oct 10, 2008 10:13 am
by Bee-Ant
What if you implement those 3D effect to a game like this
viewtopic.php?f=4&t=6235

I wonder how to make the z axis...

Re: 3D Platforms -UPDATED now with X and Y scrolling

PostPosted: Thu Oct 23, 2008 6:30 am
by smallville
first of all what is Z axis? i know what Z depth is, but i am really confused :? :shock: :?: :shock:
second of all HOW DO YOU DO YHE 3D EFFECT?! it's great!

Re: 3D Platforms -UPDATED now with X and Y scrolling

PostPosted: Thu Oct 23, 2008 9:10 pm
by feral
first of all what is Z axis? i know what Z depth is, but i am really confused :? :shock: :?: :shock:
second of all HOW DO YOU DO YHE 3D EFFECT?! it's great!


zdepth (also called zbuffering) refers to the screen depth order the actors are drawn in.

The Z axis is basically a similar thing, but refers to how "deep" into the 3d screen an item is placed.

in a 2d game you have two axis,... an x axis and a y axis

ie: x axis how far left or right, y axis how far up or down...

In 3D the "z axis" is how far "in or out" of the screen

it gets more complicated then that when rotation is occurring, for example if you think of a 2d game where the actor and other objects are ALL rotating around a single point...

you then have to recalculate ALL the new x and y axis...

in 3D (if you have rotation) you now also have to calculate the new Z axis as well..

note: if you look into 3D programming you will almost immediately come across something called matrices (more then one matrix), eg: rotation matrices, translation matrices, etc etc

if you were taught these in high school/college etc you should be OK... unfortunately I was never taught them.. I don't know why.. but anyhow.. they are NOT needed, and are simply a "shortcut way" to use regular geometry, so if they confuse you, don't worry, just ignore them until you get a grip on 3D using regular geometry maths, and then you will understand them.

hope that helps.

PS: I will shortly be releasing all the source code for the 3d platforms above, and will attempt to finish of the tutorials I was doing on "2D to 360 to 3D", they should all help for anyone thinking of 3D

feral

Re: 3D Platforms -UPDATED now with X and Y scrolling

PostPosted: Fri Oct 24, 2008 9:13 pm
by BlarghNRawr
z axis example...
its sort-of like this... didnt you learn this in math class
its like a 3D x axis

Re: 3D Platforms -UPDATED now with X and Y scrolling

PostPosted: Fri Oct 24, 2008 9:18 pm
by smallville
oh thankyou! that helps a lot, and now i understand because 3D game design is the new 2D! :lol:
... ... ... ... ... lame joke.... just another Quiestion would it work if i typed in this:
Code: Select all
z = z + 5;

or
Code: Select all
zvelocity = + 5;


i tried it once and it didn't work but is there a new way to do it?

Re: 3D Platforms -UPDATED now with X and Y scrolling

PostPosted: Fri Oct 24, 2008 9:20 pm
by smallville
i know all about those axis but just asking if there is a simple way to make " z " a real axis
in a 2D game maker because the grid on GE has NO depth

Re: 3D Platforms -UPDATED now with X and Y scrolling

PostPosted: Fri Oct 24, 2008 9:29 pm
by BlarghNRawr
u must use z depth ot place on top of each oter

Re: 3D Platforms -UPDATED now with X and Y scrolling

PostPosted: Sat Oct 25, 2008 1:16 am
by j2graves
the zdepth control is on the actor control at the top and toward the left

Re: 3D Platforms -UPDATED now with X and Y scrolling

PostPosted: Sat Oct 25, 2008 9:33 pm
by feral
would it work if i typed in this:

Code: Select all
z = z + 5;
or
code: Select all
zvelocity = + 5;

i tried it once and it didn't work but is there a new way to do it?


A 2D Engine ( and indeed a 3D engine) has no real concept of Z... because the screen is 2 dimensional, the z axis is Faked.

in otherwords in a 2D world ( ie: a computer screen, there is no Z axis. what happens is , we use "tricks" to allow the human eye to think it is looking at 3D.

have you ever looked at a picture or photograph of a railway line dissapearring into the distance ? The paper it is on is only 2D.

example
basic3D.JPG
basic 3d with Crayolas (crayons) LOL


But because it has "perspective" and "disappears" our eyes believe it to be 3D (sort of)

so how to translate that to a game ?

well if you look closely at the example of the cube that BlarghNRawr posted, you will see that the "back" of the cube is simply on a higher "Y" point then the front. In otherwords we use the Y axis to "fake" the Z axis. which is why there is no command such as Z=Z-1;

BTW; this is where ZDepthing ( or Z buffering comes in..

if something is plotted on the Y axis to be further away then something else ( ie: deeper on the fake Z axis) then it should be drawn first, to ensure everything else "in front of it" , on the fake Z axis is drawn over the top, ie: things closer to you should obscure things further away.

note: if your "horizon" (or zero origin points) are within in the screen, things above the horizon should be on a lower Y axis ( think of that railway line picture,if the horizon is on the picture then clouds that are further away will be lower on the screen, not higher)

have a closer look at some of the 3d demos that have already been posted, and you should now get the idea of how it all works. The only thing left is to work out how "perspective" fits in to it all..

ie: the further away things are, the closer to each other they should appear and the smaller they should be ( think again of the railwayline image), there are many formulaes for this, and, for most games they are very simple.

Now, once you add the perspective the human eye really starts to see 3D,

so for a simple 3D game this is enough to work quite well... see one of my first examples... this is the "old school" way to do it and works quite well without complex math - viewtopic.php?f=6&t=5431&p=37982&hilit=balls+of+fire#p37183

The real difficulty is when you wish to "rotate" the scene around you .eg: wolfenstein (and I got that wrong so many times... LOL .) So, that will be another subject all together... you are best to try the basic 3D stuff first, until you get the hang of it.

In the mean time read up on basic "perspective" in drawings and art. ie: how artist paint pictures with depth.

hope that helps

oh... also there are a few other tricks you can add, because technically, things further way are also harder to see, so you can add blurryness to items the further away they get ( not easy in GE), they also tend to look slightly darker, which is a bit easier to do in GE using RGB or transparencies