As some of you know i am working on a COOP map with the rest of my clan.
I dont actually build anything in it i look after the scritping and everything else.
I have finished my part for a few weeks and started to look at editing the BSP files in game to add stuff to them.
I can open them fine edit the scripts to do whatever i want.
But when i add a model into the BSP file the game crashes loading the map ,i am nearly sure i am doing it correctly.
model number ,inserting the correct grid ref etc:.
Anyone any experience in this ????
I am probably overlooking somfin silly.
Thx
Kdja
Editing BSP files.
Moderator: Moderators
-
Wombat
- Colour Sergeant
- Posts: 93
- Joined: Fri Jun 14, 2002 5:10 pm
- Location: Adelaide, Australia
- Contact:
are you adding the model info to the .bsp file (no no)
Or spawning objects from the .scr file?
run to where you want to add object to the map, pull down console type coords
will output coords, and angles.
spawn object from script, giving those coords, as the origin
etc...spawn all objects, ie triggers, origins, models, set all key/values needed. etc
I assume this is how you would do it, but i have no experience in this matter.
I am working on a program, that reads the mohaa.bsp files, and returns an entity.map file, so you can load the .map into mohradiant and see all the entity's, sorry NO BRUSHS as yet....DAMN
then you can check for targetnames already used
follow the 'Convert .bsp to .map ' post in the scripting forum.
NO Prog uploaded as yet
Or spawning objects from the .scr file?
run to where you want to add object to the map, pull down console type coords
will output coords, and angles.
spawn object from script, giving those coords, as the origin
etc...spawn all objects, ie triggers, origins, models, set all key/values needed. etc
I assume this is how you would do it, but i have no experience in this matter.
I am working on a program, that reads the mohaa.bsp files, and returns an entity.map file, so you can load the .map into mohradiant and see all the entity's, sorry NO BRUSHS as yet....DAMN
then you can check for targetnames already used
follow the 'Convert .bsp to .map ' post in the scripting forum.
NO Prog uploaded as yet
Wombat's
Eats roots shoots then leaves...........
Eats roots shoots then leaves...........
The reason it crashes is because the header portion of the BSP has specific block offsets that reference each section of the BSP. If you modify the length of that section by adding or removing data from the entity section, the offsets for that block and all of the blocks that follow it become corrupt. If you change the length of the entity section by editing it, you must correct the header section of the file.
I've written a program that allows you to extract and edit the entity section of the file all you want, then patch it back into the bsp. I originally wrote it to convert SP maps to MP, but the level editor was released at about the same time (of all the luck), so I kind of let it go. It would also dump all of the shaders and tiki models included in the bsp (useful for seeing what 2015 used for textures).
I have used it to convert the entity section into a .map file (sorry wombat!) I want to continue working on it to make a bsp decompiler, but that is a huge technical challenge.
If you guys want it, I could probably release it.
Grenadiac
I've written a program that allows you to extract and edit the entity section of the file all you want, then patch it back into the bsp. I originally wrote it to convert SP maps to MP, but the level editor was released at about the same time (of all the luck), so I kind of let it go. It would also dump all of the shaders and tiki models included in the bsp (useful for seeing what 2015 used for textures).
I have used it to convert the entity section into a .map file (sorry wombat!) I want to continue working on it to make a bsp decompiler, but that is a huge technical challenge.
If you guys want it, I could probably release it.
Grenadiac
that would be cool.
I think having spoken to Blackonyx about his maps.
he said the only reason he wouldnt do anymore was cos of the time it took to redit the files.
I would give it a shot if i knew
1 i could do it right
2 they would be worth it.
You should release it, as in effect if Half Life and every other game has tons of modding tools available if Mohaa is to last ,its going to need that open endness (damn you EA damn you all to hell)
As Mohaa`s maker isnt adding any kind of support ot modding ,its up to stupid ppl like me to ask stupid questions so that clever ppl like you and Wombat and others make this clever thing........LOL
Kdja
I think having spoken to Blackonyx about his maps.
he said the only reason he wouldnt do anymore was cos of the time it took to redit the files.
I would give it a shot if i knew
1 i could do it right
2 they would be worth it.
You should release it, as in effect if Half Life and every other game has tons of modding tools available if Mohaa is to last ,its going to need that open endness (damn you EA damn you all to hell)
As Mohaa`s maker isnt adding any kind of support ot modding ,its up to stupid ppl like me to ask stupid questions so that clever ppl like you and Wombat and others make this clever thing........LOL
Kdja
-
Wombat
- Colour Sergeant
- Posts: 93
- Joined: Fri Jun 14, 2002 5:10 pm
- Location: Adelaide, Australia
- Contact:
My Prog is here Size 1.98 Mb ( support files are the biggest killer )
It functions, but yes getting the brush info is a gigantic task, to reverse engineer the file.......must get info on how to build bsp files(Grenadiac????)
It installs to the mohaa/main folder, with MohaaBsp2EntMap.exe and a blank.map file ( which is just a hollowed worldspawn brush 16384x16384x8192 ) NO UNINSTALL.....
Some of the .bsp files, 10Mb+ convert into ENTITY.map files of over 12000 lines......
It functions, but yes getting the brush info is a gigantic task, to reverse engineer the file.......must get info on how to build bsp files(Grenadiac????)
It installs to the mohaa/main folder, with MohaaBsp2EntMap.exe and a blank.map file ( which is just a hollowed worldspawn brush 16384x16384x8192 ) NO UNINSTALL.....
Some of the .bsp files, 10Mb+ convert into ENTITY.map files of over 12000 lines......
Wombat's
Eats roots shoots then leaves...........
Eats roots shoots then leaves...........
Ok, I will try to find the code I wrote a while ago. I'll probably need a day or two to retest it to make sure it still works (I have a bunch of different projects where I was trying to hack the code, so I need to find the good one).
Anyway, if you are interested, you should check out the SDK for FAKK2, which I think is very similar to the MOHAA bsp. FAKK2 was created by Ritual, which had some of the same developers at 2015, so it's no surprise that the code is similar. You can use some of the FAKK2 tools to do some MOHAA work (especially editing menus). And there is a lot of documentation, such as a full listing of the cvars and what they do, although some of them probably are disabled in MOHAA.
I was using the FAKK2 bsp format to start decoding the MOHAA bsp, but it is difficult to go back from bsp (which has been VIS'd to remove a bunch of surfaces) to map format, since you have to figure out what brush goes where. It's not impossible, but it is very, very difficult.
I'll try to get my code out in the next day or two for you guys. It's a command line app, so it's not that large (about 140k).
Grenadiac
Anyway, if you are interested, you should check out the SDK for FAKK2, which I think is very similar to the MOHAA bsp. FAKK2 was created by Ritual, which had some of the same developers at 2015, so it's no surprise that the code is similar. You can use some of the FAKK2 tools to do some MOHAA work (especially editing menus). And there is a lot of documentation, such as a full listing of the cvars and what they do, although some of them probably are disabled in MOHAA.
I was using the FAKK2 bsp format to start decoding the MOHAA bsp, but it is difficult to go back from bsp (which has been VIS'd to remove a bunch of surfaces) to map format, since you have to figure out what brush goes where. It's not impossible, but it is very, very difficult.
I'll try to get my code out in the next day or two for you guys. It's a command line app, so it's not that large (about 140k).
Grenadiac
