Jump to content
sbobovyc

Combat Mission: Modding tools

Recommended Posts

1 minute ago, sbobovyc said:

I just pushed an update to unmdr which makes it compatible with Python 3 and from now on I will be developing it as a Python 3 codebase. This will ensure a smooth transition into a Blender plugin.

Thanks for your continuing work on this. I'm sure there will be a flood of interest once we have a working export script for blender.

Share this post


Link to post
Share on other sites
On 30.10.2016 at 1:34 AM, sbobovyc said:

I just pushed an update to unmdr which makes it compatible with Python 3 and from now on I will be developing it as a Python 3 codebase. This will ensure a smooth transition into a Blender plugin.

Excellent, seems it's working now as it should, a lot of files were unpackt.

Share this post


Link to post
Share on other sites
15 hours ago, sbobovyc said:

Figured out how transparency on some vehicle windows worked. Instead of alpha channel in the texture file, the object's meta data in the mdr file contains a float constant representing the alpha value for that object's material.

https://drive.google.com/file/d/0B982H8gQa3LZT0lodDh1TXJKeDA/view?usp=sharing

 

Do you have a byte address?

Share this post


Link to post
Share on other sites

python3 unmdr.py -p -v myfile.mdr > out.txt

Now, open out.txt with any text editor and search for "Alpha." Every sub-model will have an alpha constant except for the very first one. Right above this output, will be a bunch of hex addresses followed by a float:

0x35884 1.000000
0x35888 0.000000
0x3588c 0.000000
0x35890 0.000000
0x35894 12.800000
0x35898 1.000000 // This is alpha
Alpha 1.000000

Using your hex editor, you can modify the float at 0x35898 to change the object alpha.

Edited by sbobovyc

Share this post


Link to post
Share on other sites
29 minutes ago, sbobovyc said:

I have a very basic Blender mdr exporter script :)

Superb - I congratulate you! There are lots of ideas for alternative objects; Vehicles, ( lorries, buses), train coaches, storage containers, skips, industrial plant machinery (silos), greenhouses, satellite phone masts, electricity pylons.... 

* Barricades!!

Edited by The Steppenwulf

Share this post


Link to post
Share on other sites
3 hours ago, tankcrew said:

Why unpacking the .brz file may stop at 99% without any error?

And the unpacked folder does not appear.

2017-01-22_002841.png

Can you show me the whole command you are executing? Are you using Python 3?

Share this post


Link to post
Share on other sites
10 hours ago, sbobovyc said:

Can you show me the whole command you are executing? Are you using Python 3?

I used Python 2.7.13

I still don't know why it shows 99%, but I found the unpacked  .brz file in a other location - My C:\Users\folder. And it seems that all is well, thank you for your work! 

Is there a way to set a different place for the unpacked file? My C:\ drive has little space...

Share this post


Link to post
Share on other sites
9 hours ago, tankcrew said:

I used Python 2.7.13

I still don't know why it shows 99%, but I found the unpacked  .brz file in a other location - My C:\Users\folder. And it seems that all is well, thank you for your work! 

Is there a way to set a different place for the unpacked file? My C:\ drive has little space...

You can use the -o flag to specify an output directory.

Share this post


Link to post
Share on other sites

Fantastic tool - It's a massive thumbs up from me. Good idea to provide some instructions with the import/export scripts for beginners, though it's texture mapping that I find challenging with blender for some reason. Regardless I must get to work with this soon enough!

Thanks sooo much for all your work on this!

Edited by The Steppenwulf

Share this post


Link to post
Share on other sites

Thanks! Can't wait to see what he community comes up with.

Keep in mind you can use whatever tool you like to model, texture, map, etc and then import your work into Blender then export into MDR.

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

×