Archived

This topic is now archived and is closed to further replies.

NetherDaemon

.md2 files

Recommended Posts

NetherDaemon    122
I''m having some trouble with my game engine and I can''t figure out whats wrong. I have a MD2 class used for loading Quake 2 files. This source is based off the tutorial from Nehe, except im converting it into DirectX. I havn''t implemented the textures yet, but the objects will not show up and my app will just close. For drawing the objects I just create a VB, lock it, edit it, unlock it, and then use DrawPrimitive to stick it on the screen, except that part doesn''t seem to work. Any help would be appreciated. Thanx

Share this post


Link to post
Share on other sites
setzor21    122
um. well, i recently wrote some md2 code for dx8, it seems to be pretty fast. in 640x480x16bpp i am able to have 36 textured MD2 models on screen at only a 20 fps loss.

I have a p3-550, 256 megs pc100 ram, matrox mg400 32 meg

if you would like this code i have decided to give it away due to my recent realization that i will never amount to anything in this game development industry. If anybody would like any other code from me that I might have, please email me @ setzor@hotmail.com

to download the code

http://www.geocities.com/khaotix/md2code.zip

it''s a simple class. you just have to pass the 3d device and texture format you are using, plus the name of the md2 file and the name of the bmp texture you want to use with it. if you want an example of it being used, email me too...

it uses a custom vertex which is basically just the default vertex for dx8, but with an extra set of texture coordinates... which aren''t being used, but it''s there if anyone wants to try multitexturing

if you think this code is crap, then go screw yourself. I''m not saying this is the code of gods, or any other bs like that. but it works, and it seems to work efficiently to me. If i were to use it in a game, It would''ve served me well. If it breaks your computer, I''m sorry, but I don''t care, and it''s definitely not my fault. I mean, YOU are the one downloading foreign crap off the net and running it.

Share this post


Link to post
Share on other sites