World of Tanks Map format.

Post questions about game models here, or help out others!
SkaceKachna
advanced
Posts: 66
Joined: Thu Jan 14, 2016 11:32 am
Has thanked: 9 times
Been thanked: 19 times

Re: World of Tanks Map format.

Post by SkaceKachna »

Coffee wrote:Ok my friend....
I found the missing entries for WGSD.

Code: Select all

P	Type	Desc
0	uint32	 ? - always 0 so far
4	16 * float32	decal matrix
20	uint32	key referencing BWST - diffuse map
24	uint32	key referencing BWST - normal map
28	uint32	key referencing BWST - ?
 ?	 ?	rest is unknwon, altrought it seems to be static
BTW.. I think your P offsets are incorrect in that table?
You're right, I must have had brainfart ... corrected them now:
http://wiki.vbaddict.net/pages/WGSD#1._TABLE
SkaceKachna
advanced
Posts: 66
Joined: Thu Jan 14, 2016 11:32 am
Has thanked: 9 times
Been thanked: 19 times

Re: World of Tanks Map format.

Post by SkaceKachna »

Here is some info about BSMO
http://wiki.vbaddict.net/pages/BSMO

Note: Each model structure is:

Model HAS nodes
Node HAS primitive groups
Primitive group HAS material and vertices and indicies
User avatar
Coffee
ultra-veteran
ultra-veteran
Posts: 518
Joined: Thu Aug 06, 2015 5:57 pm
Has thanked: 74 times
Been thanked: 205 times

Re: World of Tanks Map format.

Post by Coffee »

SkaceKachna wrote:Here is some info about BSMO
http://wiki.vbaddict.net/pages/BSMO

Note: Each model structure is:

Model HAS nodes
Node HAS primitive groups
Primitive group HAS material and vertices and indicies
I'll have a look later.. I'm trying to decode BWT2. I have all the tables worked out.. Im trying to figure how how to use the data :?
I'd love to change the world but I can't get my hands on the code.
User avatar
Coffee
ultra-veteran
ultra-veteran
Posts: 518
Joined: Thu Aug 06, 2015 5:57 pm
Has thanked: 74 times
Been thanked: 205 times

Re: World of Tanks Map format.

Post by Coffee »

If you want to create a page for the SpTr:

Code: Select all

Start of section:
Entry Length Uint32
Entry Count Uint32

Entry Structure:

16 floats = matrix
Key Uint32   = speedtree key in BWST
E1 Uint32     = unknown : always = 1
E2 Uint32     = unknown : always = 1
There is some data at the end I don't know about and won't need.
I think this is associated with a shader but not sure.
I'd love to change the world but I can't get my hands on the code.
User avatar
Coffee
ultra-veteran
ultra-veteran
Posts: 518
Joined: Thu Aug 06, 2015 5:57 pm
Has thanked: 74 times
Been thanked: 205 times

Re: World of Tanks Map format.

Post by Coffee »

Ok...
BWT2 has a bunch of tables and I only need the 2nd one to get what I need.
I actually don't even needs this. I could get the prefix locations from the .cdata file names.
At the start of the section there are 6 numbers (int32s and floats) I don't need.
All the grids MUST BE 100meters x 100meters.
Using the location numbers and offsetting by 50 in x and y I get the centers of each grid.

Code: Select all

:fffcfffc:fffdfffc:fffefffc:fffffffc:0000fffc:0001fffc:0002fffc:0003fffc:
:fffcfffd:fffdfffd:fffefffd:fffffffd:0000fffd:0001fffd:0002fffd:0003fffd:
:fffcfffe:fffdfffe:fffefffe:fffffffe:0000fffe:0001fffe:0002fffe:0003fffe:
:fffcffff:fffdffff:fffeffff:ffffffff:0000ffff:0001ffff:0002ffff:0003ffff:
:fffc0000:fffd0000:fffe0000:ffff0000:00000000:00010000:00020000:00030000:
:fffc0001:fffd0001:fffe0001:ffff0001:00000001:00010001:00020001:00030001:
:fffc0002:fffd0002:fffe0002:ffff0002:00000002:00010002:00020002:00030002:
:fffc0003:fffd0003:fffe0003:ffff0003:00000003:00010003:00020003:00030003:

Code: Select all

( 350.0:-350.0) ( 250.0:-350.0) ( 150.0:-350.0) ( 050.0:-350.0) (-050.0:-350.0) (-150.0:-350.0) (-250.0:-350.0) (-350.0:-350.0) 
( 350.0:-250.0) ( 250.0:-250.0) ( 150.0:-250.0) ( 050.0:-250.0) (-050.0:-250.0) (-150.0:-250.0) (-250.0:-250.0) (-350.0:-250.0) 
( 350.0:-150.0) ( 250.0:-150.0) ( 150.0:-150.0) ( 050.0:-150.0) (-050.0:-150.0) (-150.0:-150.0) (-250.0:-150.0) (-350.0:-150.0) 
( 350.0:-050.0) ( 250.0:-050.0) ( 150.0:-050.0) ( 050.0:-050.0) (-050.0:-050.0) (-150.0:-050.0) (-250.0:-050.0) (-350.0:-050.0) 
( 350.0: 050.0) ( 250.0: 050.0) ( 150.0: 050.0) ( 050.0: 050.0) (-050.0: 050.0) (-150.0: 050.0) (-250.0: 050.0) (-350.0: 050.0) 
( 350.0: 150.0) ( 250.0: 150.0) ( 150.0: 150.0) ( 050.0: 150.0) (-050.0: 150.0) (-150.0: 150.0) (-250.0: 150.0) (-350.0: 150.0) 
( 350.0: 250.0) ( 250.0: 250.0) ( 150.0: 250.0) ( 050.0: 250.0) (-050.0: 250.0) (-150.0: 250.0) (-250.0: 250.0) (-350.0: 250.0) 
( 350.0: 350.0) ( 250.0: 350.0) ( 150.0: 350.0) ( 050.0: 350.0) (-050.0: 350.0) (-150.0: 350.0) (-250.0: 350.0) (-350.0: 350.0) 
This image's coordinates are inverted because its drawn with OpenGL from DirectX model data.
Image
All maps are square.
Not all playable areas are centered on the map. A good example is Himmelsdorf.
Last edited by Coffee on Sun Jan 24, 2016 10:13 pm, edited 1 time in total.
I'd love to change the world but I can't get my hands on the code.
User avatar
Coffee
ultra-veteran
ultra-veteran
Posts: 518
Joined: Thu Aug 06, 2015 5:57 pm
Has thanked: 74 times
Been thanked: 205 times

Re: World of Tanks Map format.

Post by Coffee »

"Overlord" has a uneven map size. It's 15x15 in size.
Don't assume anything.
I'd love to change the world but I can't get my hands on the code.
User avatar
Coffee
ultra-veteran
ultra-veteran
Posts: 518
Joined: Thu Aug 06, 2015 5:57 pm
Has thanked: 74 times
Been thanked: 205 times

Re: World of Tanks Map format.

Post by Coffee »

SkaceKachna wrote:
Coffee wrote:Ok my friend....
I found the missing entries for WGSD.

Code: Select all

P	Type	Desc
0	uint32	 ? - always 0 so far
4	16 * float32	decal matrix
20	uint32	key referencing BWST - diffuse map
24	uint32	key referencing BWST - normal map
28	uint32	key referencing BWST - ?
 ?	 ?	rest is unknwon, altrought it seems to be static
BTW.. I think your P offsets are incorrect in that table?
You're right, I must have had brainfart ... corrected them now:
http://wiki.vbaddict.net/pages/WGSD#1._TABLE
I posted the format for the missing info earlier :)
I'd love to change the world but I can't get my hands on the code.
User avatar
Coffee
ultra-veteran
ultra-veteran
Posts: 518
Joined: Thu Aug 06, 2015 5:57 pm
Has thanked: 74 times
Been thanked: 205 times

Re: World of Tanks Map format.

Post by Coffee »

I can't wait to get the models back in Terra!
It took a month to figure out how to blend the textures (up to 4 per grid) and deal with the low res texture mixing with distance.
I worked for another 5 weeks getting the shader to do the texture translation correctly.
It's still not exactly like the game but it is very close.

Image
I'd love to change the world but I can't get my hands on the code.
User avatar
ShadowHunterRUS
n00b
Posts: 17
Joined: Wed Jan 13, 2016 11:04 am
Location: Russia
Has thanked: 9 times
Been thanked: 5 times

Re: World of Tanks Map format.

Post by ShadowHunterRUS »

Coffee wrote:I can't wait to get the models back in Terra!
It took a month to figure out how to blend the textures (up to 4 per grid) and deal with the low res texture mixing with distance.
I worked for another 5 weeks getting the shader to do the texture translation correctly.
It's still not exactly like the game but it is very close.
But why? For whom?
SkaceKachna
advanced
Posts: 66
Joined: Thu Jan 14, 2016 11:32 am
Has thanked: 9 times
Been thanked: 19 times

Re: World of Tanks Map format.

Post by SkaceKachna »

That looks pretty neat! I spent about month of time decrypting and decoding replays and I finally have working replay player, but without objects on maps ... it just looks weird:
You do not have the required permissions to view the files attached to this post.
User avatar
Coffee
ultra-veteran
ultra-veteran
Posts: 518
Joined: Thu Aug 06, 2015 5:57 pm
Has thanked: 74 times
Been thanked: 205 times

Re: World of Tanks Map format.

Post by Coffee »

ShadowHunterRUS wrote:
Coffee wrote:I can't wait to get the models back in Terra!
It took a month to figure out how to blend the textures (up to 4 per grid) and deal with the low res texture mixing with distance.
I worked for another 5 weeks getting the shader to do the texture translation correctly.
It's still not exactly like the game but it is very close.
But why? For whom?
Terra! is a 3D tactical battle designer I started on about 3 years ago.
I used to be very active in Clan wars and didn't like any of the planners.
I have worked on it when I had time and many times, spent more than an entire night sorting things out.

Up until this last update, I have been able to fix slight changes but this last one has removed all the info on whats on the map.
Its there but, as you know in the space.bin.

We have sorted out a lot of the data but there is a lot more to be done.
I need to know how to get the water info. Also.. For what ever reason. Terra can't find the skydome now. This is probably because of a path change. WarGaming tends to do this a lot.
Last edited by Coffee on Mon Jan 25, 2016 12:54 am, edited 1 time in total.
I'd love to change the world but I can't get my hands on the code.
User avatar
Coffee
ultra-veteran
ultra-veteran
Posts: 518
Joined: Thu Aug 06, 2015 5:57 pm
Has thanked: 74 times
Been thanked: 205 times

Re: World of Tanks Map format.

Post by Coffee »

SkaceKachna wrote:That looks pretty neat! I spent about month of time decrypting and decoding replays and I finally have working replay player, but without objects on maps ... it just looks weird:
Thats cool...

Well.. we are going to sort this out and than you will have the other models.

Do the tanks move like a regular replay?

Where do the tank models come from? Game.. Something you created to export them?
I'd love to change the world but I can't get my hands on the code.
User avatar
Coffee
ultra-veteran
ultra-veteran
Posts: 518
Joined: Thu Aug 06, 2015 5:57 pm
Has thanked: 74 times
Been thanked: 205 times

Re: World of Tanks Map format.

Post by Coffee »

I found this...
It is an offline world of tanks map viewer mod.
All items and effects are the same as in a match. Only YOU are on the map.
This makes it nice to look around.

Place the files that are under 9.12 in the 9.13 res_mods folder.

After you start the game and get to the login screen, there will be a new icon at the bottom right of the window.
Click it and select the mod.
After, select the map... Don't bother selecting a tank.. it wont show up.
To driver around us the A-D-W-S keys and the mouse to point where you are going.
The mouse wheel moves you up and down.
To exit. use ALT+F4
You do not have the required permissions to view the files attached to this post.
I'd love to change the world but I can't get my hands on the code.
User avatar
Coffee
ultra-veteran
ultra-veteran
Posts: 518
Joined: Thu Aug 06, 2015 5:57 pm
Has thanked: 74 times
Been thanked: 205 times

Re: World of Tanks Map format.

Post by Coffee »

OK... getting back to decoding here.

I'm working on helping sort out BSMO

It looks like and entry in table 2 that has 'From - To' indexes that = 0xFFFFFFFF have no matching String Key in BWST.
If it is 0xFFFFFFFF than the string key is ZERO.
Last edited by Coffee on Mon Jan 25, 2016 7:08 pm, edited 1 time in total.
I'd love to change the world but I can't get my hands on the code.
SkaceKachna
advanced
Posts: 66
Joined: Thu Jan 14, 2016 11:32 am
Has thanked: 9 times
Been thanked: 19 times

Re: World of Tanks Map format.

Post by SkaceKachna »

Coffee wrote:OK... getting back to decoding here.

I'm working on helping sort out BSMO

It looks like and entry in table 2 that has 'From - To' indexes that = 0xFFFFFFFF have no matching String Key in BWST.
Yeah, I noticed that there are some objects without BWST name there (having 0xFFFFFF or 0x000000 as key), I have no clue what is their purpose or why're they nameless
Coffee wrote:
Thats cool...

Well.. we are going to sort this out and than you will have the other models.

Do the tanks move like a regular replay?

Where do the tank models come from? Game.. Something you created to export them?
Yes, it works like regular replay, tanks move, shoot, aim ....
It's all in browser, so I had to export all models into obj and same with heightmaps. I use https://github.com/SkaceKamen/wot-model-converter for exporting objects ... (I started writing it, but now It's community project with multiple contributors)
Post Reply