ThePlatoon.com
December 02, 2008, 11:49:43 PM *
Welcome, Guest. Please login or register.
Did you miss your activation email?

Login with username, password and session length
News: Look around and get acquainted to the new settings and features.
 
  Home   Forum   Help Search Calendar Login Register  
  Shop Gallery  
Pages: 1 [2] 3   Go Down
  Print  
Author Topic: Ghost Recon maps  (Read 7862 times)
0 Members and 1 Guest are viewing this topic.
Zazoo
Administrator
Hero Member
*****

Rep: 13
Offline Offline

Posts: 1332
1829.50 credits

View Inventory
Send Money to Zazoo

View Profile WWW
« Reply #20 on: January 07, 2007, 09:34:33 AM »

Quote from: Ronin;28349
I think this kind of stuff is actually harder using VB 6 than VC 6.  But hey, whatever works for you. Cheesy  


I don't doubt that. It's just easier for me because I have greater proficiency with VB at this point.

Quote
I can fix you up with DS and IT if you want.  I think I have 3 or 4 copies of the game (can't recall).  At least one (GR Gold) I've never even opened.  Let me know and I'll hook you up. Cheesy


Thanks for the offer, but I have them. I just don't know where they are at the moment. I'll try to dig them out today.

Quote
What version of the Geometry List and room entries are your training.map, Mike?
Mine are 1 and 8 respectively. (map version 4.0)


Same here (1 for geometrylist, 8 for room entries)

Quote
I believe the heirarchy of the geometry is list->room->polygon->triangles. There don't appear to be any primitives represented other than triangles. (no quads, fans, strips, etc.)


Yes, that's what I get too.
Everything in the formats I've looked at (QOB/CHR/MAP) is triangles.

Quote
I'm also going to explore the other chunk types, too. Lights, fog, portals and much of the rest I'm pretty sure we can figure out. Some of the other stuff like Occluders and PlanningLevels might prove more difficult.


Working from memory:
LightList is empty on every map. It looks like an unused chunk. This would make sense since all lighting data is stored in the DMP file (which is a pretty simple format, just contains positions and color/intensity data of all lights).
Portal entries are (IIRC) just 2 room indices and 4 coordinates (the two rooms being connected, and the physical dimensions of the portal)
There is also a list in the file (ObjectList or something like that) that gives the position and animation data for all the doors/glass/trees etc (the geometry for these objects is stored in the geometry list though).

~Mike
Logged

Ignacio
Newcomer


Rep: 0
Offline Offline

Posts: 2
0.00 credits

View Inventory
Send Money to Ignacio

View Profile
« Reply #21 on: January 07, 2007, 05:19:12 PM »

Hi Mike, can you do the same as you did on Ghost Recon Red Square & Training, for the maps in Rainbow Six Rogue Spear?
Logged
Ronin
Full Member
***

Rep: 0
Offline Offline

Posts: 445
584.00 credits

View Inventory
Send Money to Ronin

View Profile WWW
« Reply #22 on: January 07, 2007, 08:53:53 PM »

Quote from: Zazoo;28355

Working from memory:
LightList is empty on every map. It looks like an unused chunk. This would make sense since all lighting data is stored in the DMP file (which is a pretty simple format, just contains positions and color/intensity data of all lights).
Portal entries are (IIRC) just 2 room indices and 4 coordinates (the two rooms being connected, and the physical dimensions of the portal)
There is also a list in the file (ObjectList or something like that) that gives the position and animation data for all the doors/glass/trees etc (the geometry for these objects is stored in the geometry list though).

~Mike


In the training.map there are 102 lights.  So it's not always empty.  I don't know how they work in conjunction with the DMP file.  It might not be used.  But they are there.  This might be what the DMP file is generated from.

The TransitionLineList appears to be the lines that demarc crossing the threshhold of doors.  There are fewer transition lines than there are portals.  Portals also include windows.  And the training map has a lot of windows as well as doors.

The PlanningLevelList appears to be some sort of room listing.  I don't know the significance of that, yet.

The VFogList is, I think, a setup for fog areas in the map so you can have denser/lighter fog in some areas.  It might also be what does the rain effects in some areas.  ("fog" by room?)
Logged

Just an average schmo.
    * Intel Core 2 Duo 2.4Ghz, 3GB DDR2-667 RAM
    * GeForce 8800GTX PCI-Express 16, 768MB
No XBox 360 :sad:
Zazoo
Administrator
Hero Member
*****

Rep: 13
Offline Offline

Posts: 1332
1829.50 credits

View Inventory
Send Money to Zazoo

View Profile WWW
« Reply #23 on: January 07, 2007, 09:02:10 PM »

Quote from: Ignacio;28361
Hi Mike, can you do the same as you did on Ghost Recon Red Square & Training, for the maps in Rainbow Six Rogue Spear?


The maps for RS are a similar but slighty different format. Perhaps in the future I (or Ronin) can work on that format.

~Mike
Logged

Zazoo
Administrator
Hero Member
*****

Rep: 13
Offline Offline

Posts: 1332
1829.50 credits

View Inventory
Send Money to Zazoo

View Profile WWW
« Reply #24 on: January 07, 2007, 11:07:49 PM »

Quote from: Ronin;28365
In the training.map there are 102 lights.  So it's not always empty.  I don't know how they work in conjunction with the DMP file.  It might not be used.  But they are there.  This might be what the DMP file is generated from.


The values are probably indices into the DMP file then. The DMP file is definitely where the lighting data is stored though.

Quote
The PlanningLevelList appears to be some sort of room listing.  I don't know the significance of that, yet.


It is probably tied to the shermanlevelheight stuff, which indicates which "floor" (what height level) a particular room is on.

Also, I cleaned up the code I had best I could. Commenting is a bit light, and it's still a bit of a mess in some areas... sort of the way things are with me when I'm trying to write and test at the same time. :tongue:
I was going to roll everything up into a class, but VB 6's classes leave much to be desired. I left everything as UDT's (structs)

I found and installed DS (still looking for IT). The parser/converter has no problem with those maps, save for one map (Depot - Mission 3). The problem seems to be in the file though, not my parser. The parser chokes on room/object 33, but only because the file gives the wrong length for the room name string. If I jump the file pointer ahead to where it should be,everything is good.
So yeah, this exports geometry and texture data. I chose the OBJ/MTL format, mainly because it is an easy to use plain text 3D format.

The parser will load a map and display the contents of the file in a tree-view, where you can expand the nodes to look at data. Nodes in bold will load their contents into a list at right when you click on the node (e.g. vertex arrays, normal arrays, etc).


Exported OBJ/MTL files show up in the same folder as the program code.
In order to get textures to show up they'll need to be converted from RSB to BMP format and put into the same folder as the OBJ/MTL file.

I start college again soon, so this will probably be all I can do for now.
~Mike
Logged

Ronin
Full Member
***

Rep: 0
Offline Offline

Posts: 445
584.00 credits

View Inventory
Send Money to Ronin

View Profile WWW
« Reply #25 on: January 07, 2007, 11:42:08 PM »

I'll look at that source in a bit.

I'm looking through the lights.  They actually appear to be lighting data.  There appears to be a "projector" section following each light that might have been for projected textures.  I don't think they used that, either.

They might have for SOAF, though.  But I don't recall any projectors in those maps.

Thanks for your help, Mike.  :cookie: :cookie: :cookie: It has been quite valuable and has probably knocked a great deal of time off of what it will take to complete this project.

Your college work is far more important than any of this stuff.  So no worries about that.  I just hope you do well. Thumbs up 2

Now, I'm going back to work... :tongue:  Cheesy
Logged

Just an average schmo.
    * Intel Core 2 Duo 2.4Ghz, 3GB DDR2-667 RAM
    * GeForce 8800GTX PCI-Express 16, 768MB
No XBox 360 :sad:
Zazoo
Administrator
Hero Member
*****

Rep: 13
Offline Offline

Posts: 1332
1829.50 credits

View Inventory
Send Money to Zazoo

View Profile WWW
« Reply #26 on: January 08, 2007, 08:57:59 AM »

A couple of other things:

Regarding the NONE data.
I have no idea what this is for. At the end of each room entry is a bunch of data, mostly floats, and then the list of NONE entries. One thing I do know, within that data (after the polygroups but before the NONE list) is an array of vertices/poly data. It's basically one giant polygon group without texturing that, when exported and loaded, looks like a somewhat simplified model of the entire room. My best guess was bounding box data.
The exporter I coded simply jumps to the next room entry when its done loading the polygon groups, skipping over this extra data.

Also, the material setup in OBJ/MTL files is limited. As far as I can tell it can't do multiple textures on a single object and each material is tied to exactly one texture. The MAP format has seperate lists for materials and textures, allowing them to be paired in a variety of ways. Since this can't be done in the OBJ format, I simply "defaulted" all the material properties in the MTL file texture entries.

~Mike
Logged

Zazoo
Administrator
Hero Member
*****

Rep: 13
Offline Offline

Posts: 1332
1829.50 credits

View Inventory
Send Money to Zazoo

View Profile WWW
« Reply #27 on: January 09, 2007, 12:34:30 PM »

Format of the PortalList entries:

Long: Chunk Size
Long: Chunk ID (0)
Long: String Size
String: "Version" & CHR$(0)
Long: Version #
Long: String Size
String: Portal Name & CHR$(0)
Long: Number of Vertices
----{
Float: X
Float: Y
Float: Z
}---- (repeat # vertices)
Long: Room #1
Long: Room #2
Byte: Unknown (0 in the maps I've looked at)

~Mike
Logged

Zazoo
Administrator
Hero Member
*****

Rep: 13
Offline Offline

Posts: 1332
1829.50 credits

View Inventory
Send Money to Zazoo

View Profile WWW
« Reply #28 on: January 09, 2007, 02:10:28 PM »

Format of OccluderList entries

Long: Chunk Size
Long: Chunk ID
Long: String Size
String: "Version" & CHR$(0)
Long: Version #
Long: String Size
String: Occluder Name & CHR$(0)
Byte: Unknown
Byte: Unknown
Long: Room #
Byte: Unknown
Byte: Unknown
Byte: Unknown
Long: Number of Vertices
----{
Float: X
Float: Y
Float: Z
}---- (repeat # vertices)

This list wasn't really used by the developers. Of the original GR's maps, only one contains anything in this list (M05_Embassy), and even this map has only one occluder.

The occluders look to be exactly what they sound like, regions that prevent hidden parts of the map from being rendered to save processing/fps

The occluder in the Embassy map is indexed to Room 12 (in red). The occluder, when rendered as a rectangular face (in green), masks the embassy behind the building (which can't be seen from room 12 in the map, so needs not be rendered).



Whether these regions are even used by the engine is questionable. It certainly wasn't utilized much by the dev's (not even on maps where it would be more useful) -- and I don't remember reading anything about occluders in the official 3D Studio map making tools documentation. The expansion packs may have maps with this list filled.
~Mike
Logged

Ronin
Full Member
***

Rep: 0
Offline Offline

Posts: 445
584.00 credits

View Inventory
Send Money to Ronin

View Profile WWW
« Reply #29 on: January 09, 2007, 09:29:57 PM »

Thanks for the updates, Mike. Thumbs up 2

I figured out the formats for the TransitionLines, PlanningLevels, RoomList and the DoorList last night and have them parsed.

As you said, the Planning Levels are probably just a room listing by "floors".  I guess that's used when interpreting the mission scripts to determine which "level" to place tangos with "room over room" situations.

Transition lines are, I think, transition from one "thing" to another.  They are just two points.  I don't know what the "thing" is, yet.  Loading them into Max would at least show where they are.  Their proximity to a door or a stair case would probably show what they are for.  Perhaps transitions between rooms and/or levels.

Their storage is simple.  For each entry you have:

integer - length of transition line name
string - transition line name (i.e. shermantransition101_1.39)
float x 3 - point 1
float x 3 - point 2

I got the storage for the Lights parsed but I don't know what all the values are for, yet.  I've been looking at the light settings in GMax (same as Max 4) to see what settings there are.  I think they will be about the same information.  They each seem to start with a 6.  I think this might a light type.  Probably an "omni" light (as opposed to a spot or ambient).  The rest is probably color, intensity, falloff, etc.

Some of the objects in the object list have some XML data followed by binary data.  I think the ones with XML data can be interacted with by the player.  The others don't appear to have any of the XML info and are probably "static" objects. How that's organized I'm still not sure, yet.  But I'm working on that, now.  Since you said they use the geometry data in the geometrylist.  The binary data may be placement, rotation, scaling, etc.

I'm wondering how the "helicopter" in the last mission of Island Thunder (the one with the watch towers on the periphery and the old mansion in the middle) fits in with that.  That object is in the object data outside the maps.  I think it has two models, too.  One whole and one blown up.

The RoomList is an odd thing.  Each room listed appears to contain one or more sections, each with a different name.  In each "section", it appears to have a 3x3 matrix embedded in it as well as three vertex/locations, some long integers and a couple of character values.  I don't know the significance of those, yet.

What makes me think the 9 float values are a matrix is that when you look at the values on most of them, they appear to be a 3x3 identity matrix.
(i.e.
1,0,0
0,1,0
0,0,1 )

Two values might be a line or bounding box.  I don't know what three would be for.  Three vertices together usually mean a triangle.  But I can't fathom what a triangle would be useful for in this.  I'm not even sure what these entries are for, really.

The storage format for that after the count is:

integer - unknown use at this time
integer - version string length
string - "Version"
integer - version

room loop using room count

integer - room name length
string - room name (length of integer above)
char  - unknown use at this time
integer - section count for this room

section loop using section count

integer - section name length
string - section name (length of integer above - i.e. shermanlevel101_1.0a)
char - unknown use at this time
integer - usually 1
float 3x3 matrix:
usually 1.00,0.00,0.00;0.00,1.00,0.00;0.00,0.00,1.00
sometimes 0.00,-1.00,0.00;1.00,0.00,0.00;0.00,0.00,1.00
float x 3: a point or vertex
float x 3: a point or vertex
float x 3: a point or vertex
integer - unknown use, usually 1
float - unknown use, usually 1.000
char - unknown use, usually 0

end section loop

integer - unknown use usually 1
float - usually 1.00
float - usually 0.00
float - usually 0.00
float - usually 0.00

end room loop

Here's a sample section of a room with the trailer:
Section Name: shermanlevel101_1.0h
Int value.: 1
3x3 matrix?
0.000000,-1.000000,0.000000
1.000000,0.000000,0.000000
0.000000,0.000000,1.000000
Vertex 1: -22.081812,-41.610008,1.540660
Vertex 2: -1.379159,-3.526352,0.000000
Vertex 3: 1.379159,3.526352,0.400000
Int value.: 1
Float value: 1.000000
Char value: 0
Room Trailer?
Int value.: 1
Float value: 1.000000
Float value: 0.000000
Float value: 0.000000
Float value: 0.000000


I was going to work on the PortalList next.  You've made that easier.  Thanks.

I had suspected that the OccluderList did something like you pointed out by the name.  But it's nice to see that you've already figured it out.  At least it's fairly simple. The newer versions of the game engine probably use those whereas the original version did not.  They probably did that to try to improve performance for the patches.  I can see why they didn't go back and add them to all the maps.  That probably would have been lot of work.  They probably only did it in places where it made a big difference.

When do you start back to school?  I would have thought it would be this week.

Cheers,
Bruce
Logged

Just an average schmo.
    * Intel Core 2 Duo 2.4Ghz, 3GB DDR2-667 RAM
    * GeForce 8800GTX PCI-Express 16, 768MB
No XBox 360 :sad:
Ronin
Full Member
***

Rep: 0
Offline Offline

Posts: 445
584.00 credits

View Inventory
Send Money to Ronin

View Profile WWW
« Reply #30 on: January 09, 2007, 09:47:50 PM »

Quote from: Zazoo;28379
A couple of other things:

Regarding the NONE data.
I have no idea what this is for. At the end of each room entry is a bunch of data, mostly floats, and then the list of NONE entries. One thing I do know, within that data (after the polygroups but before the NONE list) is an array of vertices/poly data. It's basically one giant polygon group without texturing that, when exported and loaded, looks like a somewhat simplified model of the entire room. My best guess was bounding box data.
The exporter I coded simply jumps to the next room entry when its done loading the polygon groups, skipping over this extra data.

Also, the material setup in OBJ/MTL files is limited. As far as I can tell it can't do multiple textures on a single object and each material is tied to exactly one texture. The MAP format has seperate lists for materials and textures, allowing them to be paired in a variety of ways. Since this can't be done in the OBJ format, I simply "defaulted" all the material properties in the MTL file texture entries.

~Mike


It's a lot more complicated but I think the 3DS file format can handle multiple textures per polygon.  I haven't fiddled with Max/GMax much.  But I think it can also do multi-texturing.  An importer for another 3D editing program would be able to handle that, too.  I don't know if MilkShape can do multiple textures.

I'm also wondering if the dark maps are used at all in Max.  I'm thinking that they are generated when the map is exported using the lighting data put into Max.  There may be lights in the original Max maps that we just don't know about.  My goal here isn't to be able to change these maps although an importer would help in that regard.  My goal is to make it cheaper for new maps to be made.

After I figure out the storage for all the chunks and get the parser done, I'm going to work on a viewer that could display the various parts of the maps so we can see what each of these things looks like. Experimentation with displaying those will probably yield a lot of information about what those things are. It should also show whether the data storage is being interpreted correctly.

I surmise that your guess about the data before the "none" sections being bounding boxes is probably correct.  I'm still trying to guess what the "none" sections are for.  It looks like all the geometry sections have them.  Maybe it's places where you can't go?  There are a lot of those places in GR maps.  There has to be _some_ place in the map data that prevents you from walking over a rock that's 8 inches high. :tongue: Cheesy  Maybe "none" means "nogo"?
Logged

Just an average schmo.
    * Intel Core 2 Duo 2.4Ghz, 3GB DDR2-667 RAM
    * GeForce 8800GTX PCI-Express 16, 768MB
No XBox 360 :sad:
Zazoo
Administrator
Hero Member
*****

Rep: 13
Offline Offline

Posts: 1332
1829.50 credits

View Inventory
Send Money to Zazoo

View Profile WWW
« Reply #31 on: January 09, 2007, 11:05:00 PM »

Quote from: Ronin;28420
Transition lines are, I think, transition from one "thing" to another. They are just two points. I don't know what the "thing" is, yet. Loading them into Max would at least show where they are. Their proximity to a door or a stair case would probably show what they are for. Perhaps transitions between rooms and/or levels.

Their storage is simple. For each entry you have:

integer - length of transition line name
string - transition line name (i.e. shermantransition101_1.39)
float x 3 - point 1
float x 3 - point 2


Transitions are used by the game to indicate floor surfaces where a character transitions from one level to another (e.g. a ramp). They aren't placed with portals (portals are their own transitions).
When working with the tools and MAX they were made by creating a rectangular coplanar face along the "joint" between the two faces that served as the transition from one level to another. The two points in the file must define either the line between the two faces (i.e. the two vertices shared by each face) or the upper left/lower right of the rectangular polygon created in MAX.

If you look at the map tools documentation in the Desert Siege disk's "Extra" folder covers the purpose of shermanlevels and shermantransitions in greater detail.

Quote
The RoomList is an odd thing. Each room listed appears to contain one or more sections, each with a different name. In each "section", it appears to have a 3x3 matrix embedded in it as well as three vertex/locations, some long integers and a couple of character values. I don't know the significance of those, yet.


No idea. If it helps though: When making maps with the official tools it was necessary to include a roomlist.txt file for the MAX exporter to use. The room list file had to contain the names of all the rooms along with the list of each shermanlevelheight represented in the room (otherwise the map wouldn't run properly). The physical dimensions of the shermanlevelheight designators may be stored in there (per room).

Quote
I'm also wondering if the dark maps are used at all in Max.  I'm thinking that they are generated when the map is exported using the lighting data put into Max.  There may be lights in the original Max maps that we just don't know about.  My goal here isn't to be able to change these maps although an importer would help in that regard.  My goal is to make it cheaper for new maps to be made.


No lighting is done within MAX. The darkmaps are created automatically with a stand-alone lighting tool. They included it free with the modding tools (in the GR:Desert Seige Disk's "Extras" folder).
When you exported a map from MAX using the exporter, the .map file always had an empty light list (hence my confusion earlier). You'd then have to run the lighting tool and place your lights there. When you saved, the tool automatically generated the darkmaps and filled the MAP's light list.

Quote
I got the storage for the Lights parsed but I don't know what all the values are for, yet. I've been looking at the light settings in GMax (same as Max 4) to see what settings there are. I think they will be about the same information. They each seem to start with a 6. I think this might a light type. Probably an "omni" light (as opposed to a spot or ambient). The rest is probably color, intensity, falloff, etc.


After the 6 is another long value (unknown), then a float (angle of light), four more values (long's or float's) and then a float (attenuation). After that I don't know. The string contained in the light entry is the texture projection file (usually "none"). If you fire up the lighting tool you can see the properties available for each light (also covered in MAP documentation). You could easily use the tool to tweak properties and then see the effect on the file's lightlist to pin-point the locations. Or just ignore the lightlist completely since the tool is free for download and already handles the generation of this list Cheesy Cheesy Cheesy

Quote
When do you start back to school? I would have thought it would be this week.


Next week.

~Mike
Logged

Ronin
Full Member
***

Rep: 0
Offline Offline

Posts: 445
584.00 credits

View Inventory
Send Money to Ronin

View Profile WWW
« Reply #32 on: January 11, 2007, 06:51:12 PM »

I got a lot done on this yesterday.  I've got 7 of the 10 lists parsing all the data (not skipping any).  I'm working on the ObjectList right now and will be adding the OccluderList today.

I haven't found any maps that have a VFogList with anything in it.  There may not be any.  The maps I thought would be likely candidates (like swamp) don't have any of these.

I found something bizarre in the M05_Embassy map in the GeometryList after the room data and before the bounding meshes.  It was a character string with a 3x3 matrix and a vertex/location.  I have no idea what this is for.

The "counter" value immediately after each room is zero for every other room I've looked at in every map.  But the one in M05_Embassy has a value of 1 which is apparently the counter for the number of entries like the one below:

Room Trailer
Counter: 1
String: foliagesetup(2)(m05_groundcover.qob)(1)02
Matrix value:
1.000000,0.000000,0.000000
0.000000,1.000000,0.000000
0.000000,0.000000,1.000000
Vertex value: 138.242615,-162.056061,13.608776

I don't know what this data is for.  I don't even really understand the character string.  It appears to be an object (the qob) but I don't know what the number are for.  I assume it's something embedded into that room.

I've been looking at the RSE Lighting Tool this morning.  It crashes a lot.  I'm still figuring out how to use it.

I also took a little detour into RSB files yesterday.  I've mapped out the RSB V9 format completely.  The RSB Editor in the Extras folder has a lot of options in the properties editor.  I've mapped all those out in the RSB format.  I've also figured out how it stores; subsampled images, mipmaps, animation frames, alpha operations, scrolling/rotation and storage formats.  The version 1 RSBs don't support anything (apparently) except a single copy of the image.  The version 5 RSBs also have much of the same stuff that the version 9 RSBs.  But the format is a bit different. Unfortunately, the RSBEditor only writes version 9 RSBs so you can't change a version 5 RSB and figure out what got changed in the file that way (that's how I mapped the version 9 RSBs).

I need to be able to read all the RSB formats correctly to be able to display them on maps and to convert them so that 3D editors can use them for texturing.

@Mike, I figured out why that 39 byte section in the room geometry changes (I think -- my solution appears to work).  The first entry in that data after the byte value and the 16 bit integer is the material index for that "sub-room".  If that entry is -1 (0xFFFFFFFF) then there is no material for that sub-room and it cannot be displayed.  Since there is no display, there is no dark map entry, either.  Hence the entry is one 32 bit integer short (35 bytes instead of 39 bytes).  I haven't found any that are longer than 39 bytes but quite a few that are 35 bytes and this test works on all of them.

When there is no material index, there is also no texture or darkmap coordinates before the triangle colors.

I parsed out the "NONE" data entries, too.  It's a counter for a number of 3 float vertices.  Followed by the list of vertices. After that is another integer counter for a list of quad float values (unknown utility).  Then there is a counter for a list of entries consisting of a string length, the string, and two integer values.  After that is a counter that has the number of bounding meshes.

Each bounding mesh has a string length integer followed by the string.  Then there are two more unknown integers.  After that is a counter value.  This counter indicates how many sets of four short integers follow.  These four short integer sets are somewhat odd.  The first three are the vertex indices for a triangle.  The fourth member is an index into the list of "NONE" entries with the two trailing integers.  I have no idea what that list is for or why there is an index into that list.  I suppose answering one question might answer the other.

I have called the "NONE" data/bounding mesh area the "Room Trailer" because it follows all the data for the sub-rooms for each room.

I think once I can start displaying all these things along with the map in context it will suggest some uses for this data as well as how it may have been derived.

This has been fun so far.  It's beginning to get complicated, now.  Writing a viewer for the map data isn't going to be trivial.  But I should have something that will display maps, soon.  Then it's a matter of adding functionality to it to help determing the utility and origin of some of the data.  This will also allow me to refine the various data type classes which will, in turn, aid in writing a map importer/exporter for a 3D editor.

I should be done with the initial data parser within a few days.  After that, I'll begin working on the viewer to aid in map data analysis.

Stay tuned, the adventure continues... :tongue: Cheesy
Logged

Just an average schmo.
    * Intel Core 2 Duo 2.4Ghz, 3GB DDR2-667 RAM
    * GeForce 8800GTX PCI-Express 16, 768MB
No XBox 360 :sad:
Ronin
Full Member
***

Rep: 0
Offline Offline

Posts: 445
584.00 credits

View Inventory
Send Money to Ronin

View Profile WWW
« Reply #33 on: January 11, 2007, 08:21:08 PM »

I'm having real problems getting the RSE lighting tool to work.  I got it work for a few minutes this morning on the swamp level.  Since then it crashes EVERY time I select "start".  No matter what map I select.

I've even rebooted my PC a couple of times and tried the swamp level again.  It still won't startup.

Even when I did get it running the first time, the image was extremely dark.  I could just barely make out the level.  I'm sure there's a way to lighten the image but I don't know how.  It might be in those popup messages at the start but they don't show up, now.

I'm going to try powering off my PC to see if that will get it to work again.  If that's what it takes, I'm amazed they ever got their maps lit using this thing.  It seems to be pretty wobbly.
Logged

Just an average schmo.
    * Intel Core 2 Duo 2.4Ghz, 3GB DDR2-667 RAM
    * GeForce 8800GTX PCI-Express 16, 768MB
No XBox 360 :sad:
Zazoo
Administrator
Hero Member
*****

Rep: 13
Offline Offline

Posts: 1332
1829.50 credits

View Inventory
Send Money to Zazoo

View Profile WWW
« Reply #34 on: January 11, 2007, 09:40:09 PM »

Quote from: Ronin;28508
I found something bizarre in the M05_Embassy map in the GeometryList after the room data and before the bounding meshes.  It was a character string with a 3x3 matrix and a vertex/location.  I have no idea what this is for.

The "counter" value immediately after each room is zero for every other room I've looked at in every map.  But the one in M05_Embassy has a value of 1 which is apparently the counter for the number of entries like the one below:

Room Trailer
Counter: 1
String: foliagesetup(2)(m05_groundcover.qob)(1)02
Matrix value:
1.000000,0.000000,0.000000
0.000000,1.000000,0.000000
0.000000,0.000000,1.000000
Vertex value: 138.242615,-162.056061,13.608776

I don't know what this data is for.  I don't even really understand the character string.  It appears to be an object (the qob) but I don't know what the number are for.  I assume it's something embedded into that room.


These entries are in most of the maps, often in outdoor rooms (e.g. M01_caves has one at 0x1BBB58). They indicate that the room contains dymanic ground cover. When building a map in MAX you can place a helper point in a room and set a flag so that, when in game, the engine will cover the floor of that room with grass (or whatever 3D object is in the QOB file used -- usually a simple polygon with a grass texture on it). The dynamic grass is automatically and randomly spread throughout the room, and the engine fades it in and out when the player gets a set distance from it. The matrix is most likely a scaling matrix. The vertex is just the location where the helper point was placed in MAX.

The MAX map building documentation gives the meaning of the numbers in the string (some of them):
Quote from: PDF
“^foliagesetup(x)(y)(z)” where x is the density of the objects in the environment, y is the filename of the referenced grass object and z is something I can’t seem to remember. Example:
^foliagesetup(2)(m01_groundcover.qob)(1)
By setting the density to 0, 1, or 2, the amount of grass can be controlled.


Quote
I've been looking at the RSE Lighting Tool this morning.  It crashes a lot.


Sounds about right.It was buggy as hell.

Quote
I also took a little detour into RSB files yesterday.  I've mapped out the RSB V9 format completely.  The RSB Editor in the Extras folder has a lot of options in the properties editor.  I've mapped all those out in the RSB format.  I've also figured out how it stores; subsampled images, mipmaps, animation frames, alpha operations, scrolling/rotation and storage formats.  The version 1 RSBs don't support anything (apparently) except a single copy of the image.  The version 5 RSBs also have much of the same stuff that the version 9 RSBs.  But the format is a bit different. Unfortunately, the RSBEditor only writes version 9 RSBs so you can't change a version 5 RSB and figure out what got changed in the file that way (that's how I mapped the version 9 RSBs).


The photoshop RSB plugins may give you the option to save in a particular version.

Quote
@Mike, I figured out why that 39 byte section in the room geometry changes (I think -- my solution appears to work).  The first entry in that data after the byte value and the 16 bit integer is the material index for that "sub-room".  If that entry is -1 (0xFFFFFFFF) then there is no material for that sub-room and it cannot be displayed.  Since there is no display, there is no dark map entry, either.  Hence the entry is one 32 bit integer short (35 bytes instead of 39 bytes).  I haven't found any that are longer than 39 bytes but quite a few that are 35 bytes and this test works on all of them.
When there is no material index, there is also no texture or darkmap coordinates before the triangle colors.


The size of the section is actually determined by the long integer directly following the material index. This value indicates how many textures indices follow. If it is zero, no texture indices follow (hence the section is 4 bytes shorter -- 35 bytes). In most entries it is 1 (making the entry 39 bytes), however it is occasionally 2, on outdoor rooms where the floor textures are actually a combination of two RSB textures, the large ground texture, and the small tiled "faux" bump map texture. Whenever 2 texture indices are used the darkmap is blank (-1). Whether this is by design or coincidence I don't know. Perhaps the engine can only support a maximum of 2 textures per face -- hence if the faux bump map texture is used, a dark map cannot be. However, the format allows for more than 2 texture indices to be specified (through the texture count value preceeding the indices), but I've never seen more than 2 used.

I posted this a little earlier in the thread, but it's getting so big it was easy to miss:
Byte - Unknown (always 1)
Byte - Unknown (always 0)
Byte - Unknown (always 0)
Long - Material Index
Long - Number of Textures Indices
Long - Texture Indices (repeated according to the number above)
Long - Unknown (always -1)
Long - DarkMap Index
Long - Unknown (always -1)
Long - Unknown (always -1)
Long - Unknown (always -1)
Long - Unknown (always -1)

Lots of unknowns, the -1's seem to be nothing more than padding.

Quote
I parsed out the "NONE" data entries, too.  It's a counter for a number of 3 float vertices.  Followed by the list of vertices. After that is another integer counter for a list of quad float values (unknown utility).  Then there is a counter for a list of entries consisting of a string length, the string, and two integer values.  After that is a counter that has the number of bounding meshes.

Each bounding mesh has a string length integer followed by the string.  Then there are two more unknown integers.  After that is a counter value.  This counter indicates how many sets of four short integers follow.  These four short integer sets are somewhat odd.  The first three are the vertex indices for a triangle.  The fourth member is an index into the list of "NONE" entries with the two trailing integers.  I have no idea what that list is for or why there is an index into that list.  I suppose answering one question might answer the other.
I have called the "NONE" data/bounding mesh area the "Room Trailer" because it follows all the data for the sub-rooms for each room.


I wonder if any of this is a reference into the SHT file which contains the 2D collision data.

Quote
This has been fun so far.  It's beginning to get complicated, now.  Writing a viewer for the map data isn't going to be trivial.  But I should have something that will display maps, soon.  Then it's a matter of adding functionality to it to help determing the utility and origin of some of the data.  This will also allow me to refine the various data type classes which will, in turn, aid in writing a map importer/exporter for a 3D editor.

I should be done with the initial data parser within a few days.  After that, I'll begin working on the viewer to aid in map data analysis.

Stay tuned, the adventure continues... :tongue: Cheesy


Weeeeee!

~Mike
Logged

Ronin
Full Member
***

Rep: 0
Offline Offline

Posts: 445
584.00 credits

View Inventory
Send Money to Ronin

View Profile WWW
« Reply #35 on: January 12, 2007, 04:33:21 AM »

Yeah, I knew we'd talked about that 39 byte section before.  This thread has some pretty big posts in it. Cheesy  I'll go back and look at that when I need to focus on the GeometryList again (possibly tomorrow).

I got the Occluders working today. So that's done.  The only thing I don't have any info on is the VFogList.  So far, I haven't found one that has anything in it.  I guess it's unused.

Something really weird about the lighting tool.  It won't work at all on my "new" machine after that first time.  It doesn't seem to matter what I do, restart, reboot, power off/restart.  It just won't load maps at all, now.  It looks like if you try to load a map and it crashes, it won't run after that unless you fix something.  I knows it read out those messages after it starts. So maybe it corrupts an INI file or registry entry(ies).

But on another machine it seems to work just fine and hasn't crashed there.

I'm looking at the ObjectList right now.  Some of these things have two versions and some have three.  Some are object type 0x32 and some are type 0x2E (and there are probably others, I've just been looking at these two, so far).  The layout of those types is different.  I don't yet understand why some objects have two version/name headers and why some have three.  I did find the size values for the complete object data and for the string data.  So I can process the "chunk size/chunk type/version, name/version,name" and skip over the rest right now.  But that data is important.  It's not needed to begin drawing the maps for placing things in context, though.

The first thing to do, now, is get a wireframe view working.  Then solid shaded polygons.  Then I'll need textures.  So I guess I'll start working on an RSB class at the same time that can read all the various formats and versions.  I don't have to display the objects at first.  And the viewer will help me determine if my interpretation of the data is correct.

Cheers
Logged

Just an average schmo.
    * Intel Core 2 Duo 2.4Ghz, 3GB DDR2-667 RAM
    * GeForce 8800GTX PCI-Express 16, 768MB
No XBox 360 :sad:
Ronin
Full Member
***

Rep: 0
Offline Offline

Posts: 445
584.00 credits

View Inventory
Send Money to Ronin

View Profile WWW
« Reply #36 on: January 15, 2007, 11:06:47 PM »

One thing I've noticed when I display the maps right now.  Is that there is always a cluster of "stuff" at the origin of the map (0.0f, 0.0f, 0.0f).  I've looked through the room list and it's not just rooms in there.  There are things like "twisted_birch".  I think these things are just being displayed at the origin because their vertices are relative and there should be some vertex value that translates the geometry for that object to the correct location.  Either that, or a matrix.  I haven't found the name "twisted_birch" in the ObjectList but it is in the MaterialList.

I need to figure out how those things get placed.  There may be a link between these and the ObjectList but not by name.  Possibly by an index into the geometry list from the ObjectList with multiple references that same "object" in the geometry with different locations, rotations, etc.  (Mike, you might have said this before but I didn't understand it.)

I'll be looking at the ObjectList some more to see if I can find the correlation.

For the most part, I think the ObjectList is objects that are placed on the map.  This probably includes things like window glass, doors, parts of destructable buildings, etc.

/me goes back to it.
Logged

Just an average schmo.
    * Intel Core 2 Duo 2.4Ghz, 3GB DDR2-667 RAM
    * GeForce 8800GTX PCI-Express 16, 768MB
No XBox 360 :sad:
Zazoo
Administrator
Hero Member
*****

Rep: 13
Offline Offline

Posts: 1332
1829.50 credits

View Inventory
Send Money to Zazoo

View Profile WWW
« Reply #37 on: January 15, 2007, 11:33:08 PM »

Yes, the stuff at the origin in the Geometry List is the geometry for the objects in the map (cars, trees, doors, glass, etc.)
These entries have the same layout as the room entries but they have a chunk ID of 3 instead of 4.
For example, here's the collection of the objects in the Embassy map (spread out):


As you said, the ObjectList contains no geometry, but specifies instances of these objects and the properties for them (location, animation, etc). Somewhere in each ObjectList entry is an index/reference into the object in the geometry list. I'm not exactly sure where or how it is referenced, but it shouldn't be hard to find.

~Mike
Logged

Javaman
Administrator
Full Member
*****

Rep: 3
Offline Offline

Posts: 400
1021.00 credits

View Inventory
Send Money to Javaman
christopher.mcclellan@gmail.com JavamanRocks1234 justanothermilitaryman
View Profile
« Reply #38 on: January 16, 2007, 05:27:39 AM »

mike your having to much fun lol Smiley nice work the both of you...........
Logged

Zep
Newcomer


Rep: 0
Offline Offline

Posts: 4
130.00 credits

View Inventory
Send Money to Zep

View Profile
« Reply #39 on: March 13, 2008, 11:07:08 AM »

Hello guys

Sorry to reply on this old thread but I've got some questions about Ghost Recon models (MAP, CHR, QOB etc...). I sent a PM to Zazoo but he did not answer me yet :/
In fact, I am in internship in a small serious video game company and I have to update Zazoo's 3ds max plugin to make it works on latest versions of 3ds max (as Ronin said, it only works on 3ds max 3, 4 and 5). The problem is : these formats are closed, and I have to use a hex editor to figure out the structure of the files. I use also Ronin's Ghost View which give some parsing informations.
But this work was already made by Ronin and Zazoo, and I am loosing my time to redo it (even worse than Ronin and Zazoo - I am not used to hex - and I only have 3 months to do this job).
So my request is simple : is there anybody who can help me to figure out these formats, or who have MAP, QOB etc.. specifications or better the sources of Zazoo's plugin or parser or Ronin's GhostView ?

Thank you for whoever helps me
« Last Edit: March 18, 2008, 03:59:41 PM by Zep » Logged
Pages: 1 [2] 3   Go Up
  Print