Not logged in, Join Here! or Log In Below:  
 
News Articles Search    
 


Submitted by Joe Banach, posted on April 06, 2001




Image Description, by Joe Banach



This is a little polygon pusher I’ve been playing around with written in Visual Basic 6 and DirectX 8. Much of the code I have ported from mrgamemaker.com’s BSP Tutorial II. I got tired of manually typing coordinates to make my own map file, so I used the .mwm file from the above tutorial. I know that mrgamemaker.com took the BSP tutorials down but I hope they don’t mind I used their map file. DX8Maze does not use binary space partitioning (BSP) or potentially visible sets (PVS). It is just a polygon pusher I wrote to learn DirectX 8. It uses discreet lighting with mostly ambient light. I threw one point light in there and sucked the green and red components out to leave a blue color. I think it looks pretty cool. I had lightmaps at one point, but editing the .mwm file with a hex editor I found to be just as tedious as writing my own map. So I left the .mwm file in its original form.

Special thanks to mrgamemaker.com for the two excellent BSP tutorials, Romka Graphics for some textures, flipcode.com and gamedev.net for the awesome web sites, the DirectX newsgroups for answers to some questions and Microsoft for DirectX 8, Visual Basic and the DirectX 8 SDK.

This code may be used freely by anyone for any purpose. I hold no responsibility for anyone’s use of this code. I have successfully run this on a Matrox G400 and an nVidia TNT2.

The code can be found at www.gdcopen.com/DX8Maze

Thanks,
Joe Banach


[prev]
Image of the Day Gallery
www.flipcode.com

[next]

 
Message Center / Reader Comments: ( To Participate in the Discussion, Join the Community )
 
Archive Notice: This thread is old and no longer active. It is here for reference purposes. This thread was created on an older version of the flipcode forums, before the site closed in 2005. Please keep that in mind as you view this thread, as many of the topics and opinions may be outdated.
 
Ready4Dis

April 06, 2001, 03:07 PM

Pretty neat... in VB non the less. Now that takes guts ;). Nothing like using a slow language with a fast API right. Anyways, what's next? Are you going to make your own editor soon. Keep up the coding.

Billy

 
Vorteks

April 06, 2001, 03:11 PM

Nice job, especially for Visual Basic. I don't know what kind of polygons counts for program can handle, but the map reminds me of old games like WolfenStein and Corridor 7. It's too bad the tutorials aren't on MrGameMaker.com anymore, I would like to have read them.

 
Buster

April 06, 2001, 03:17 PM

too bad the whores at MrGameMaker.com took down their BSB tutorials.
:(

 
Mitch

April 06, 2001, 03:28 PM

Visual Basic is not that slow. It approaches the speed of C++ in alot of areas (it uses the same compiler). But for games it can be slower. You basically have to code it like a C style program, because objects in VB are all COM, which has an overheaded attached. The slowdown can occur because the DX8 library for VB is a wrapper around DX.

 
LeP

April 06, 2001, 05:18 PM

The tutorials were taken down because the guys who wrote them are teaching an online course using the information in them. I think they said they will be touched up though and have some stuff added. Its like 65 bucks or something, head to gameinstitute.com to check it out.

 
JoeB

April 06, 2001, 05:26 PM

To those that have emailed me asking for the mrgamemaker.com BSP tutorials, I have chosen to repsect mrgamemaker.com's request and not pass them along. I only have the second one anyway.

I would like to port what I've done in VB to C but it's so much quicker to develop in VB. Every time I sit down and say I am going to port to C I end up adding some new feature in VB.

Joe

 
STZ

April 06, 2001, 06:03 PM

I remember I have both tutorials, and I hope that they still exist in zip. If so, it can cost you ... well 50 bucks :)

 
STZ

April 06, 2001, 06:07 PM

Well ... I decided not to sell it, cuz they paid me $500 to keep it for myself

 
Lucid

April 06, 2001, 06:25 PM

good job...
only one thing... The camera/movement will probably cause seizure in little kids... I'm a little dazed right now... heh... oh well... cool...

 
Wolfier

April 06, 2001, 06:43 PM

STZ: Are you serious they paid you $500 to keep it? Very interesting of them.

But anyway, I'm sure there aren't anything in that tutorial you cannot learn from elsewhere if it is just a BSP tutorial. Not worth the $50 if you ask me.

A very good BSP site is

http://www.bsphq.com

Everything about BSP that you can know until today, in my opinion.

 
Wolfier

April 06, 2001, 07:03 PM

Sorry, that link is only for Quake enging BSP map editing. Maybe I was too fast. BUT, nothing beats Michael Abrash's Blackbook (which teaches about BSP too), and it was recently given away free at ddj.

http://www.ddj.com/articles/2001/0165/0165f/0165f.htm

Also, some very relevant BSP information can be obtained from
http://www.exaflop.org/

Finally, there is the BSP FAQ by SGI.

http://reality.sgi.com/bspfaq/index.shtml

I purposely omitted the easy-to-find but still good ones you can find here, CFXweb.net, gamasutra.com, and gamedev.net.

 
Jesse Yurkovich

April 06, 2001, 08:02 PM

He didnt take them down on purpose. There was some kind of legal mumbo jumbo that caused him to be more or less forced to take them down. So just lay off a bit!

 
Scrambled Monkey

April 06, 2001, 08:43 PM

Wolfier: The M. Abrash articles are about over-simplified 2D node based BSPs, and the same goes for the stuff on exaflop. The bsp faq is pretty lame too. None of those cover leafy BSPs which are in general the only type of BSP that are used in games ( at least those that use a PVS ). Those mr gamemaker tutorials covered making a PVS, which I have only found 2 other papers that talk about building a PVS from a 3D BSP. So the fact that BSP/PVS imformation is quite sparce makes this worth it's price of admission for some. The sad thing is, it's really not that terribly complicated stuff, it's just that sources of imformation are lacking.

Ok, now that I've gone way off topic... Cool work Joe. I can't imagine trying to do a game engine in VB, I'd kill myself! :)
Dan

 
Nikkoz

April 07, 2001, 05:01 AM

Is there any "qualifyed" FAQ or tutorial on BSP avalible anywhere, then?

 
STZ

April 07, 2001, 06:32 AM

I would like that they pay...
:)

 
Sebastian Sylvan

April 07, 2001, 07:12 AM

Abrash talks about leafy BSPs and how to do PVS with them. 2D principles apply to 3D as well btw. There's more than one chapter about BSP-trees in the black book.

 
Scrambled Monkey

April 07, 2001, 12:23 PM

Now that I think of it, you're right. I haven't picked up the book in a while. It's just that he covered node based BSPs very thoroughly, while he glazed over leafy BSPs, and he didn't cover HOW to build a PVS. He explained what a PVS is, and how quake uses one, but he doesn't explain how to calculate them, ie. building portals and using anti-penumbra calculations ( or (ug!) sampling ). So it's a good source for node BSP information, but for leafy BSPs with a PVS it skimps on details. You're right that 2d translates to 3d easily, but like I said he mainly covered 2d 'node' BSPs, which takes a bit of thought before you can translate that to 3d 'leafy' BSPs. When people are just starting out with BSPs, it's hard to make that big of a jump with only a vague description to go by. Ok, I'm talking in circles. :) Don't mind me...
Dan

 
Scrambled Monkey

April 07, 2001, 12:31 PM

Nikkoz: I've never seen a faq/tutorial that covers all things you may want to know about BSPs. Right now you just have to read every paper you can get your hands on to get the whole picture. I was thinking of doing a monolithic BSP tutorial myself... but then I'd be constantly pestering everybody for info since I certainly don't know it all! :) If you search hard enough though, you should find all you need to know.
Dan

 
STZ

April 07, 2001, 09:02 PM

Well, scrambled one is scrambled one.
Im not interested in your oppinion, cuz you showed your extremely naive understanding of surrounding world. Trying to follow fashionable things again ... heh ? Remember good old(or old good) movie ? u think it's good cuz it's fashionable ... it is good if its used ?
Well I feel that I should say:
poor scrambled minds ... at age of 14 , it's .. maybe normal. But my personal experience of life was quite different from yours all so I see things differently.
---------------------------
I will NOT look what you write next. I simply don't care.
I think I should write a book about my philosophy of life, cuz I often feel like your soul-teacher
I will need 2 write it in english, cuz I want to lighten your minds, and describe common human faults.
//currently I do not have enought time, but I'll try to enlighten you... maybe
That's sad, I see how many ppl can't understand, can't see the truth ...
just piece of my thoughts
---------------------------
your answers will be ignored

Thanks (thats just because I love2say thanks)

 
Dean Harding

April 07, 2001, 11:43 PM

Hey yeah, now that you mention it... uh... I have one of those too... can I have $500?

 
SigmundSEGV

April 14, 2001, 01:34 AM


STZ wrote:
I will NOT look what you write next. I simply don't care.
I think I should write a book about my philosophy of life, cuz I often feel like your soul-teacher

"Everybody now, tryin't make it real; compared to what?"
-- Eugene McDaniel

I agree with Scrambled entirely: I haven't picked up the book in a while. It's just that he covered node based BSPs very thoroughly, while he glazed over leafy BSPs, and he didn't cover HOW to build a PVS. He explained what a PVS is, and how quake uses one, but he doesn't explain how to calculate them, ie. building portals and using anti-penumbra calculations ( or (ug!) sampling ). ... EXACTLY how I felt about the black book in '97, '98 or whenever it was.

Bill


 
This thread contains 21 messages.
 
 
Hosting by Solid Eight Studios, maker of PhotoTangler Collage Maker.