Advertisement

quake 2

Started by November 17, 2000 11:41 PM
0 comments, last by Snyper 24 years, 2 months ago
Ok lets see if i can explain my question that makes any sence. Ok im an interested in making a q2 map viewer. This will be my 1st 3d engine type thingy that load this type of maps. ie using brushes and what-not. Well i have looked at a few quake map viewers and i am confused a little. When you load in the stuff that will go in the node structure, like all the polygons, does it automaticly put the polygons in the correct position in the node structure? I know when you compile the map it puts it in a bsp tree. I hope im being clear, im kinda confused on how to explain my questions. So does my node structure, and all the other sturctures for that matter, have to have the members in a certain order? Because from looking at these quake map viewers, i dont see any functions that put the data in the correct spots manually. I mean i dont see a function to look at each polygon in a list and set it in the correct position in the tree. Ok now i feel like i didnt make any sence at all. I hope i did. Oh also, what exatly are the edges? I see edge sturcutres and im not sure what they do. If i made no sence at all, please tell me and ill try again. -Snyper Edited by - Snyper on 11/17/00 11:42:39 PM
=============================Where's the 'any' key?=============================
Hi!

I''ve only looked at the Aftershock Q3 viewer source ... but I think it did the same thing you described.

Basically, it had a bunch of structures, each for a different ''lump'' type. The BSP-file is made up of several lumps (sections), such as leafs, lightmaps, etc...

Then, for each lump, they just read the data into an array of the lumps structures. So, if you had a structure leafs with some members, they just had an array of leafs and fread() the data straight from the file into those arrays.

This means, the structs have to be laid out exactly like the data in the file! That''s also why you don''t see them assign any specific values to fields.

Hope this clarified a few things,

MK42

This topic is closed to new replies.

Advertisement