Th3 bsp documentation

Discussion about Pre-THUG1 things can go here, such as modding, etc
Vadru
VIP
Posts: 40
Joined: Wed Jul 07, 2010 2:39 pm

Th3 bsp documentation

Postby Vadru » Wed Jul 07, 2010 2:43 pm

this is my first documentation ever so it isn't that great hope you understand if not or if you think I leaved something just make a comment. :D

*Update*
I'll rewrite the whole thing when I get more time.
offsets:
each offset is 4 byte befor each 0x1003 and it point to another offset some offsets doesn't matter if they are right and some must be right or it crash.
to calculate the offset you take those 4 bytes example: 23010000100300004200000032 and then skip 8 bytes in this ecample offset start at 32 now we go 23010000 (123) and we find next offset and if we skip 4 byte we should find 1003.
so offsets that does not show offset to end of object show offset to offset that show end of object (hope you understand what I mean lol).



begining of bsp
4 byte always 0x0B000000
4 byte file size -12 bytes
2 byte thing 0x1003
10 byte always 0x00000100000034000000
2 byte thing 0x1003
30 byte always 0x0000000000000000008000000080000000800000803F000000000000803F
?? byte unknow can't remeber some here was like number oF object or something when you added object and didn't increas this texture got Fucked upp like in lost levels




Reading an object in Bsp
4 byte unknow
2 byte thing 0x1003
10 byte always 0x00000100000018000000
2 byte thing again 0x1003
30 byte unknown
4 byte offset to end of object
2 byte thing again 0x1003
6 byte always 0x000001000000
4 byte offset to 4 byte befor image loading 1003
2 byte thing again 0x1003
6 byte always 0x000000000000
4 byte number of triangles each triangle is 24byte but after first triangle there is 8byte of 0x00
4 byte number of faces? don't know how many bytes those are neighter am I sure if it really is number of faces
2 byte 0x0000
?? byte triangles
?? byte faces?
?? byte if not loaded in qb file here goes script to load etc if loaded in qb here goes script like kill_skater_Water if not added in qb too it will crash when go water
?? byte unknow
4 byte offset until end of object
2 byte 1003 thing again
4 byte 0x0E050000 now come load img
4 byte offset to 4 byte befor unknow col data 1003
2 byte thing again 0x1003
skip 16 byte to get the first texture
4 byte first texture linking to the array of pictures at the begining of bsp
?? byte unknown
4 byte offset to 4 byte befor col info 1003 first
2 byte thing again 0x1003
?? byte unknow
4 byte offset to 4 byte befor col info 1003 2nd
2 byte thing again 0x1003
4 byte 0x01Af94 indicate colition info same number of those as number of trinagles each info is 2 byte
4 byte offset to end of object
2 byte thing again 0x1003
6 byte always 0x0000060000
?? byte colition info ex. wallrideable 8400 skateable 8000
4 byte 0x00000000
4 byte object name can almost always be refound in the script (.qb) of the level

4 byte end of object 0x0A000000
4 byte offset to end of all object (I think) this you can change to any don't need to be right. this is also begining of nect object
Last edited by Vadru on Sun Aug 01, 2010 11:01 am, edited 2 times in total.

Vadru
VIP
Posts: 40
Joined: Wed Jul 07, 2010 2:39 pm

Re: Th3 bsp documentation

Postby Vadru » Sat Jul 10, 2010 6:29 pm

Today I remebered a thing that I had forgot about color editing:
I still don't remeber enaugh to add it to the documentation yet but I'll show a pic of what I mean with color editing this pic is without texture only color editing
Image

Morten1337
Site Admin
Posts: 321
Joined: Mon Mar 01, 2010 2:23 pm
Location: Norway

Re: Th3 bsp documentation

Postby Morten1337 » Mon Jul 12, 2010 12:41 pm

Woah, this is really good! :D

Vadru
VIP
Posts: 40
Joined: Wed Jul 07, 2010 2:39 pm

Re: Th3 bsp documentation

Postby Vadru » Mon Jul 12, 2010 12:54 pm

glad you think so I know most of you don't play th3 but I thought it might be worth post anyway but i forgot alot havn't used those knowledge for like half a year but when inox come online on msn I'll ask him if he still has the source for the thif project (the project that could load th4/th3 maps) I'm not so good in programming my selfe but maybe I can find something from it since the source is built on my knowledge of bsp 1 year ago :D also for those who didn't know the "collor editing" here is what will look like lightning when you have texture here is what the effect look like with texture:
Image

bAstimc
VIP
Posts: 135
Joined: Thu Jun 10, 2010 2:33 pm

Re: Th3 bsp documentation

Postby bAstimc » Fri Aug 06, 2010 12:34 am

nice :)


Return to “Legacy THPS”

Who is online

Users browsing this forum: No registered users and 1 guest