2d in 3d mode?

Blitz3D Forums/Blitz3D Programming/2d in 3d mode?

Slider(Posted 2003) [#1]
I'm planning on writing a 2d game in Blitz, but am unsure if I should use the 2d or 3d mode.

I need:
* Fast spite rotation (B3D advantage)
* Parallax scrolling (B3D advantage)
* Pixel perfect collisions (is this supported for 'sprites' in B3D?)

I assume the approach when using B3D for 2d games is to create sprites using textured rectangles (2 triangles)? Or is it internally supported by B3D?


FlameDuck(Posted 2003) [#2]
* Parallax scrolling (B3D advantage)
How is this a "Blitz3D advantage"?
* Pixel perfect collisions (is this supported for 'sprites' in B3D?)
Nope. But you seldomly need *pixel perfect* collision. Vector perfect will usually be more than enough. (Even if you're working in 2D).
I assume the approach when using B3D for 2d games is to create sprites using textured rectangles (2 triangles)?
Yup, that's pretty much it.


Slider(Posted 2003) [#3]
I thought parallax would be easier in B3D as you could create several textures (with transparent sections) and layer them on top of each other (varying z position). Wouldn't this create parallax?


Slider(Posted 2003) [#4]
Also what kind of performance difference would there be with between Blitz 2d and 2d in 3d mode using a poor 3d card?

Busy topic so far guys... ;-)


goodeep(Posted 2003) [#5]
this is also what's i'm trying to do, a 2d game in 3d. some major problems are: looking a 3d "pixelled" world from a camera.. wouldn't it be queer?
how can i menage to get a scrolling map (say like the ones in most old final fantasy rpgs)? tiling a terrain surface by surface?
any help or suggestion would be greatly appriciated


Warren(Posted 2003) [#6]
Busy topic so far guys... ;-)

Well, you have to understand that this topic has been discussed many, many times in the past. People are probably tired of typing out the answers.


Slider(Posted 2003) [#7]
>> People are probably tired of typing out the answers.
So where's the tutorial then ;-)


podperson(Posted 2003) [#8]
"Also what kind of performance difference would there be with between Blitz 2d and 2d in 3d mode using a poor 3d card?"

It would have to be a very old/poor 3d card indeed not to have a performance edge over Blitz2D. Certainly any reasonably decent desktop machine that's less than 4 years old, and any decent laptop less than 2 years old has hardware 3D acceleration sufficient to justify this approach.

And someone with a 5y old PC with a lousy graphics card -- what's the odds they (a) download shareware games and (b) pay for them?


smilertoo(Posted 2003) [#9]
The biggest benefit i can see is the 3d throws in fast scaling and rotation, as well as the obvious access to blending/alpha effects.


skn3(Posted 2003) [#10]
You could always use the extended 2D dll, which allows fast 2d alpha/scaling/rotating without the blurred edges(in 3d), and without the speed hit of rolling your own (in 2d).

Although there are certain restrictions, like no windowed mode, and you have to use the dll's functions instead of blitzes, BUT! these are 95% identical, and easy to convert.

Here is a screensaver I created using it:

http://skn3.acsv.net/files/fruitburst.zip

And the dll information can be found here:

http://www.blitzbasic.com/bbs/posts.php?topic=21685