cj2000 Posted March 17, 2015 Share Posted March 17, 2015 (edited) I was able to encrypt the Bully col format, at least that part needed to read the model. Those who are interested can read more about it here. I have also created a tool, that converts Bully col files to cst. The tool can be downloaded here. After my succes with Bully col format, I started researches with Manhunt col format, that seems to be used by both Manhunt parts. I have also make some progres here. I am planing to make some kind of frameworck that provides reading of most R* col formats and writing of some of this formats. Here some kind of table with features the frameworck should provide: COL format read write GTA (III/VC/SA) yes yes Manhunt (1/2) yes yes Bully yes no GTA LCS yes no GTA VCS yes no LCS and VCS are marked red, because I am very pesimistic about that ones. Also suport for CST2 should be provided, but only write. I would like to make a complete application with this features, but C++ has no own GUI and I hate Qt. During some of my researches I found a tool with similar name, the tool is more than 10 years old and I want to stres out this thread has nothing to do with that tool. Edited March 20, 2015 by cj2000 dkluin, Leeao, Ss4gogeta0 and 10 others 13 Link to comment Share on other sites More sharing options...
cj2000 Posted March 18, 2015 Author Share Posted March 18, 2015 (edited) Here are also some of my first researches about Manhunt (1 & 2) col format.: There are many similarities with GTA COL1 format that can be seing here. Also are most datastructures the same or quite the same. TBounds, TSurface, TSphere and TVertex seams to be identic, and the only change to TBox and TFace datastructures is the absence of TSurface, rhat reduces each of that structures by 4 bytes. The only new datastructure is TString. The structure can be represented by somthing like char[4][]. The last char[4] bloc always contain '\0' character defining the end of string. If '\0' is not the last one in the block, all folowing characters are 'p', that probably should stand for pading. The col file looks like: unsigned int colmodels;TModel models[]; and the TModel datastructure looks like: TString name; TBounds bounds; unsigned int numSpheres;TSphere spheres[]; // TSphere[numSpheres] unsigned int numLines; Lines lines[];//Lines[numLines] sizeof(Lines)=24unsigned int numBoxes; TBox boxes[]; // TBox[numBoxes] int numVertex;TVertex vertices[]; //TVertex[numVertex] unsigned int numFaces;TFace faces[]; //TFace[numFaces] Seems to be some problem with boxes. After some more researches i have made changes to the structure. Looks like a structure called Line, mentioned in the col topic on gtamodding is used. In that topic nothing is said about that structure, in Manhunt col it seems to take 24 byte. Edited April 2, 2015 by cj2000 Link to comment Share on other sites More sharing options...
cj2000 Posted March 19, 2015 Author Share Posted March 19, 2015 (edited) Like I already said, I am very pesimistic about opening LCS and VCS col files. The file format is realy wired, like all other formats used in LCS and VCS. However even here I made some progres and will present my first results here soon. Everibody having knowledge about this formats is welkome to post here. Like promised here are the results: This only referes to col2 files not DTZ. Most datatypes have size that is a multiple of 16 and if the data doesn´t feat padings are used. Only Vertex and Faces does not use padings. Surface{ unsigned char material; unsigned char light; }; Vertex{ unsigned short values[3]; }; Geometry: Sphere{ float pos[3]; float radius; }; Box{ float min[3]; float minZero; //0.f float max[3]; float maxZero; //0.f }; Bounding objects: BSphere{ Sphere sphere; Surface surface; }; BBox{ Box box; Surface surface; }; Face{ unsigned short vertices[3]; Surface surface; }; FaceGroup{ Box box; unsigned short start; unsigned short end; }; File: Header{char forcc[4];//2locunsigned zero;//0x0unsigned listAdr;unsigned listAdrR;//listAdrR=listAdrunsigned listCnt;char pading[8];//0x0}; AdresTableElement{unsigned id;unsigned adr;}; Bounding{ Sphere sphere; Box box; }; This datatypes, I mentioned, are comon for both LCS and VCS. Also have to mention that the filestructure is nonlinear. The begining of a col2 file looks like this: Header header; AdresTableElement adreses[]; The end of adreses array is always marked by endtable element. This element can be defined like: AdresTableElement endtable; endtable.id=0xFFFFFFFF; endtable.adr=0; -adr: contains the adres of the Dataheader of the model with the ID having the value of id. There are some diferences bettween Dataheader representation in LCS and VCS col2 files. LCS version: Dataheader{TBounds bounds;unsigned short numSpheres;unsigned short numBoxes;unsigned short numFaces;unsigned char numUndefs;unsigned char numFaceGroups;unsigned char fileID;char numPading[3];unsigned spheresAdr;unsigned unk;unsigned boxesAdr;unsigned faceGroupsAdr;unsigned vertexAdr;unsigned facesAdr;unsigned undefsAdr;}; VCS version: Dataheader{TBounds bounds;unsigned short numBoxes;unsigned short numFaces;unsigned short numSpheres;unsigned char numFaceGroups;unsigned char fileID;unsigned spheresAdr;unsigned unk;unsigned boxesAdr;unsigned faceGroupsAdr;unsigned vertexAdr;unsigned facesAdr;unsigned unk2;}; Edited April 9, 2015 by cj2000 Link to comment Share on other sites More sharing options...
Ezekiel Posted March 19, 2015 Share Posted March 19, 2015 modding just GTA SA for while has brought me some experience related to collision....breakable collision object's ...Shadows..terrain effects on col mesh,brightness...some basic modding knowledge How you mean wired formats... Link to comment Share on other sites More sharing options...
cj2000 Posted March 19, 2015 Author Share Posted March 19, 2015 (edited) modding just GTA SA for while has brought me some experience related to collision....breakable collision object's ...Shadows..terrain effects on col mesh,brightness...some basic modding knowledge How you mean wired formats... I am really not familiar with this language, so I meaned something like strange or a bit crazy formats. I know this doesn´t also really feat. And if you read my post more precise, you´ll see, I was not tallking about SA formats, they are really OK, but only LCS/VCS ones. Edited March 20, 2015 by cj2000 Link to comment Share on other sites More sharing options...
Leeao Posted March 22, 2015 Share Posted March 22, 2015 (edited) cj2000, good job! Edited March 22, 2015 by Leeao cj2000 and The_GTA 2 Link to comment Share on other sites More sharing options...
cj2000 Posted March 23, 2015 Author Share Posted March 23, 2015 cj2000, good job! Thanks, but the job is still not done completely. Link to comment Share on other sites More sharing options...
cj2000 Posted March 30, 2015 Author Share Posted March 30, 2015 (edited) So here is the current progres:[table] COL format read write GTA (III/VC/SA)to do?done Manhunt (1/2)done?to do? BullydonenoGTA LCSdonenoGTA VCSdonenoCST2nodone[/table]At the moment only stories col2 files are suported, but GTAG (DTZ) suport will be added soon. I have made a pac of comandline tools to open Manhunt (1/2), LCS and VCS col files and extract the colisions as cst. Unforzunatelly there were some bugs, but I hope to have fixed all of them now. Edited April 13, 2015 by cj2000 Frank.s 1 Link to comment Share on other sites More sharing options...
cj2000 Posted April 13, 2015 Author Share Posted April 13, 2015 The import for both stories parts and GTA (III/VC/SA) export (COLL and COL2) also CST are worcking properly. Bully models can be imported, but without faceGroups. Manhunt 1&2 models can be partikulary imported. Also have problem with material convertion from VC to SA. Can somebody tell me how this material convertion worcks? Frank.s 1 Link to comment Share on other sites More sharing options...
Blackbird88 Posted April 27, 2015 Share Posted April 27, 2015 This is some cool stuff. Good job. cj2000 1 Link to comment Share on other sites More sharing options...
cj2000 Posted June 15, 2015 Author Share Posted June 15, 2015 (edited) So have created some comandline tools, that can convert stories col2 files to SA col. The tools can be downloaded here. This is an improoved version. Edited June 25, 2015 by cj2000 Ezekiel, ALMOST610, atfburner and 1 other 4 Link to comment Share on other sites More sharing options...
cj2000 Posted July 14, 2015 Author Share Posted July 14, 2015 Now my stories col2 to SA col converter has a worcking GUI, making worcking with that tool much easier. The tool can handle both LCS and VCS format, it just have to be selected, like can be seeing on the pic. The tool can be downloaded here. Blackbird88, ALMOST610 and dkluin 3 Link to comment Share on other sites More sharing options...
Leeao Posted October 27, 2015 Share Posted October 27, 2015 (edited) Here are also some of my first researches about Manhunt (1 & 2) col format.: There are many similarities with GTA COL1 format that can be seing here. Also are most datastructures the same or quite the same. TBounds, TSurface, TSphere and TVertex seams to be identic, and the only change to TBox and TFace datastructures is the absence of TSurface, rhat reduces each of that structures by 4 bytes. The only new datastructure is TString. The structure can be represented by somthing like char[4][]. The last char[4] bloc always contain '\0' character defining the end of string. If '\0' is not the last one in the block, all folowing characters are 'p', that probably should stand for pading. The col file looks like: unsigned int colmodels; TModel models[]; and the TModel datastructure looks like: TString name; TBounds bounds; unsigned int numSpheres; TSphere spheres[]; // TSphere[numSpheres] unsigned int numLines; Lines lines[];//Lines[numLines] sizeof(Lines)=24 unsigned int numBoxes; TBox boxes[]; // TBox[numBoxes] int numVertex; TVertex vertices[]; //TVertex[numVertex] unsigned int numFaces; TFace faces[]; //TFace[numFaces] Seems to be some problem with boxes. After some more researches i have made changes to the structure. Looks like a structure called Line, mentioned in the col topic on gtamodding is used. In that topic nothing is said about that structure, in Manhunt col it seems to take 24 byte. By testing the TBox and TSurface unused in manhunt 1/2. unsigned int numBoxes;// Unused TSurface;//Unused There are some correction: //from 010 editor template typedef struct{ local byte padLen = 4-(FTell() % 4); if ((padLen < 4) && (padLen > 0)) byte pad[padLen]; }Padding; typedef struct{ TVector center; float radius; TVector min;//seems min.z and max.z swap order. TVector max; }TBounds; typedef struct{ TVector center; float radius; TSurface surface;//Unused , 4 bytes zeros. }TSphere; typedef struct{ TVector point[2]; }Lines; typedef struct{ TVector XYZ; }TVertex; typedef struct{ DWORD VertID[3]; }TFace; typedef struct{ string name; Padding padding; TBounds bounds; DWORD numSpheres; TSphere spheres[numSpheres]; DWORD numLines; Lines lines[numLines]; DWORD numBoxes;//unused in manhunt 1/2 TBox boxes[numBoxes]; int numVertex; TVertex vertices[numVertex]; DWORD numFaces; TFace faces[numFaces]; }TModel; Edited October 27, 2015 by Leeao cj2000 1 Link to comment Share on other sites More sharing options...
reditec Posted October 27, 2015 Share Posted October 27, 2015 This is very interesting! Maybe I can use some of your findings for future version of my tool OpenRW :-) The_GTA 1 Link to comment Share on other sites More sharing options...
cj2000 Posted October 29, 2015 Author Share Posted October 29, 2015 This is very interesting! Maybe I can use some of your findings for future version of my tool OpenRW :-) You welcome. reditec 1 Link to comment Share on other sites More sharing options...
cj2000 Posted December 11, 2015 Author Share Posted December 11, 2015 Have reuploaded my BullyToCst converter here. To convert Bully col files put my tool into the folder where the col file are, than start it in comandline with "bullytocst name1 name2 ..." where name1, name2 etc. are names of col files, but without .col extension. Blackbird88, Frank.s and Hovac 3 Link to comment Share on other sites More sharing options...
cj2000 Posted April 14, 2016 Author Share Posted April 14, 2016 A tool converting Bully colls to GTA one can be downloaded here. This tool has GUI, so no more comandline necesary. The_GTA and Blackbird88 2 Link to comment Share on other sites More sharing options...
cj2000 Posted April 13, 2017 Author Share Posted April 13, 2017 (edited) So the current progres looks like this: [table] COL format read write GTA (III/VC/SA)donedone Manhunt (1/2)doneto do BullydonenoGTA LCSdonenoGTA VCSdonenoCST2nodone[/table] Thanks to Leeao for his corrections to Manhunt format. Also have made the first converter, that is able to convert diferent GTA 3 era collision formats to COL2 format from SA. The tool also has an option for automatc material convertion. Some bugs still need to be fixed, but hope to have a final version worcking next week. Here is a pic of how the tool look like: The tool can be downloaded here. For Bully and LCS you need to put the coresponding ide file in the same folder as the col (col2) file to make collisions have names. This should worck for VCS to, once ide files are avaible for it. If Bully col file has no ide with the same name, than default.ide is used. Material convertion is fully worcking only for GTA, LCS and VCS, for Bully only vehicle material can be converted at the moment, for other materials the bully_dictionary must be edited. Manhunt doesn´t suport any material convertion. Edited April 18, 2017 by cj2000 Link to comment Share on other sites More sharing options...
Davve95 Posted April 14, 2017 Share Posted April 14, 2017 Don't get it to fully. But I guess it's like this: Do you need col files if you example want to port a map or some object? Link to comment Share on other sites More sharing options...
cj2000 Posted April 18, 2017 Author Share Posted April 18, 2017 Don't get it to fully. But I guess it's like this: Do you need col files if you example want to port a map or some object? If you want that objects to have collision, than you need col files. Link to comment Share on other sites More sharing options...
cj2000 Posted April 21, 2017 Author Share Posted April 21, 2017 OK, the collision converter tool is oficially avaible here. guard3 1 Link to comment Share on other sites More sharing options...
guard3 Posted May 7, 2017 Share Posted May 7, 2017 Haven't tested it yet, but seems promising. Great work! Link to comment Share on other sites More sharing options...
cj2000 Posted February 6, 2019 Author Share Posted February 6, 2019 Wrote a new version of R* collision converter, that can convert any number of collision files at once. The tool worcks more or les the same as the previous one, the diference is you have to select the folder with the files that should be converted. The ide files, if necesary for the format also have to be in the selected folder. The new version is now avaible here and looks like this: As seen on the pic, manhunt format is mising in the tool, but there is a separate tool which converts collisions from all levels at once, just need to select the level folder. The tool is now awaible here and looks like this: guard3, Tut98 and Shagg_E 3 Link to comment Share on other sites More sharing options...
cj2000 Posted February 13, 2019 Author Share Posted February 13, 2019 Manhunt col converter is now officially avaible here. Link to comment Share on other sites More sharing options...
GTA_MODS_YT Posted January 31, 2022 Share Posted January 31, 2022 hello brother please fix the downoad links because all the links is dead, i just want sa col to vc :) Link to comment Share on other sites More sharing options...
cj2000 Posted May 17, 2022 Author Share Posted May 17, 2022 On 1/31/2022 at 9:50 PM, GTA_MODS_YT said: hello brother please fix the downoad links because all the links is dead, i just want sa col to vc :) Which links exactly? Link to comment Share on other sites More sharing options...