Widescreen and resolution fix for Commandos 2 and CSF

Discussion of the original groundbreaking Commandos games (Commandos BEL, BCD, C2 and C3)

Moderator: TAFN staff

Post Reply
User avatar
ss666
Lieutenant
Posts: 77
Joined: Thu Oct 14, 2004 3:32 pm

Widescreen and resolution fix for Commandos 2 and CSF

Post by ss666 »

Widescreen resolution Fix for Commandos 2 and CSF
It's posted at this site:
http://www.widescreengamingforum.com/wi ... s_List_-_C


1024x768 (4:3)
http://img405.imageshack.us/img405/5815 ... 24x768.jpg

1440x900 (16:10)
http://img132.imageshack.us/img132/7457 ... 40x900.jpg
Signature Commandos ruls
herbert3000
Soldier
Posts: 15
Joined: Tue May 20, 2008 9:42 pm
Location: Vienna, Austria
Contact:

Post by herbert3000 »

Thank you ss666 and BooTx.

I tried to set the Commandos 3 resolution to 1280*800 - and failed.
At least I managed to set it to 1024*768. Here are the instructions:

Open commandos3.exe with a HexEditor. Search for these strings:

20 03 00 00 B9 58 02 00 00
C2 04 00 B8 20 03
C2 04 00 B8 58 02
00 00 C3 B8 20 03
00 00 C3 B8 58 02
90 90 90 B8 20 03
90 90 90 B8 58 02
00 EB 13 BA 20 03
44 24 04 B9 58 02

And replace all 20 03's with 00 04 and replace 58 02's with 00 03

Save it and play Commandos!

Image
note the graphical glitches (buttons, knapsack)
qazx12
Soldier
Posts: 2
Joined: Wed Feb 24, 2010 4:27 pm

Post by qazx12 »

Thanks, works for me :D

Finally can play Commandos 3 in 1024 hehe

Do you have any ideas about those graphical glitches (buttons, knapsack)?
qazx12
Soldier
Posts: 2
Joined: Wed Feb 24, 2010 4:27 pm

Post by qazx12 »

Don't change it:
90 90 90 B8 20 03
90 90 90 B8 58 02
because it fuckes the menu resolution:P

Try to replace 20 03 with 00 05 and 58 02 with 00 03 - you will have 1280x768 resolution that works fine, and also glitches like on your screenshot.
E'ven
Soldier
Posts: 2
Joined: Tue Mar 03, 2009 6:16 pm

Post by E'ven »

Very nice to be able to play C2 at higher resolutions, thanks ss666.
herbert3000
Soldier
Posts: 15
Joined: Tue May 20, 2008 9:42 pm
Location: Vienna, Austria
Contact:

Post by herbert3000 »

@qazx12: I fixed some graphical glitches with this file:

http://sites.google.com/site/belcommand ... TERFAZ.MSB
(resolution = 1024*768)
BooTx
Soldier
Posts: 3
Joined: Fri Mar 12, 2010 6:48 pm

Post by BooTx »

First off I'd like to thank herbert for pointing me in the right direction with the INTERFAZ.MSB file (and the guys at Commandos HQ for providing one). I now nearly have a fully functional high res / widescreen hack for Commandos 3.

Image

As you can see I've got the basic interface working correctly, but unfortunately I've run into a few small issues and I've pretty much run out of ideas. So I thought I'd call on you guys to help since you're a lot more knowledgeable than I when it comes to Commandos 3 (I actually don't even own the game--I'm working completely off the demo).

Image

The first issue is the title screen at the beginning of the missions. The words themselves stretch to the center horizontally which is nice, but not vertically (it's still centered for 600 pixels vertically). And more bothersome is the red background which only stretches to the default 800 pixels.

Ideally I'd like for the title to center itself both horizontally and vertically, and I'd like for the red background to either do the same, or be removed completely, since it's a bit of an eyesore as-is.

Image

And next we have these two issues. The objectives box should be aligned all the way to the right side of the screen, but it remains in its default location.

And then there's the tips box, which you can tell is a bit of a mess. On the one hand, the box itself seems to have centered itself perfectly with the new resolution. I can't say the same for "HELP" and "CLOSE" (and its button). Needless to say, those need to be moved to the correct location inside the tips box.

I have spent hours in the INTERFAZ file and I just can't find anything that corresponds to these issues. Perhaps another file needs to be edited. Perhaps the executable needs to be edited further.

Also, I have no means of playing the game in multiplayer since the demo is single player only, so eventually somebody else will have to test it out and report back what, if anything, needs to be fixed.

Now, on with the fix.

I should note that this will not work with the Steam version because it's encrypted with copy protection. You'll need the retail version. You may be able to use the retail executable with Steam, however.

You will need a hex editor such as Be.HexEditor. Open your Commandos 3 executable with it (feel free to back it up first) and search for the following strings (you don't have to search for the entire thing, just the first few bytes to make sure you're at the right location).

Address (line) 00164bc0
20 03 00 00 c3 b8 00 04 00 00 c3 b8 00 05 00 00 c3 c4 4b 56 00 ca 4b 56 00 d0 4b 56 00 d6 4b 56 00 90 90 90 90 8b 49 48 b8 e0 01 00 00 83 f9 03 77 1e ff 24 8d lc 4c 56 00 b8 e0 01 00 00 c3 b8 58 02

Address (line) 00164c60
20 03 00 00 eb 0c ba 00 04 00 00 eb 05 ba 00 05 00 00 83 f8 03 b9 e0 01 00 00 77 3f ff 24 85 e4 4c 56 00 8b 44 24 04 b9 e0 01 00 00 89 10 89 48 04 c2 04 00 8b 44 24 04 b9 58 02

20 03 and 58 02 represent the resolution 800x600. Change those numbers to the following:

1024x600 - Replace 20 03 with 00 04 and replace 58 02 with 58 02
1280x720 - Replace 20 03 with 00 05 and replace 58 02 with D0 02
1280x800 - Replace 20 03 with 00 05 and replace 58 02 with 20 03
1366x768 - Replace 20 03 with 56 05 and replace 58 02 with 00 03
1440x900 - Replace 20 03 with A0 05 and replace 58 02 with 84 03
1680x1050 - Replace 20 03 with 90 06 and replace 58 02 with 1A 04
1920x1080 - Replace 20 03 with 80 07 and replace 58 02 with 38 04
1920x1200 - Replace 20 03 with 80 07 and replace 58 02 with B0 04

At the moment I've only tested 1280x720 and 1440x900 and apart from a somewhat minor graphical glitch on the exterior of the moving train level (though it may not be so minor at really high resolutions--you'll see what I'm talking about), they seem to work fine. As you've noted, other 5:4 and 4:3 resolutions work as well. I have no idea how well this fix works on other levels in the full game.

After you're done, save the file. Now we have to fix the interface, which will require an extracted and decrypted INTERFAZ.MSB file.

I've created and zipped up files for 1280x720, 1280x800, 1366x768, 1440x900, 1680x1050, 1920x1080, and 1920x1200. Download, extract the one you want, and rename it INTERFAZ.MSB. Then place it in the Data\INTERFAZ\ directory.

Alternatively, you can make your own for whatever resolution you want by following these instructions:

Code: Select all

	.MOCH0
        [
            .COORDS
            (
                257.0 -56.0
            )
        ]
        .MOCH1
        [
            .COORDS
            (
                506.0 -56.0
            )
        ]
The default for both of the y coordinates are 544. Change it to -56.0 and it should align properly with every resolution.

Code: Select all

	.BAJO0
        [
            .COORDS
            (
                334.0 -44.0
            )
        ]
        .BAJO1
        [
            .COORDS
            (
                372.0 -58.0
            )
        ]
        .BAJO2
        [
            .COORDS
            (
                410.0 -44.0
            )
        ]
Change both the x and y coordinates to the above.

Code: Select all

		    .ELEM ARMAS
                    .GRUPO GRUPO_MOCHILA
                    .LAYOUT MOCH0MULTI
                    .COORDSINICIALES
                    [
                        .X 191.0
                        .Y 647.0
                    ]
The .Y resolution should be the vertical resolution you chose minus 73. So for instance, I chose 1280x720, so 720 minus 73 is 647.

Code: Select all

		    .ELEM OBJETOS
                    .GRUPO GRUPO_MOCHILA
                    .LAYOUT MOCH1MULTI
                    .COORDSINICIALES
                    [
                        .X 440.0
                        .Y 647.0
                    ]
Do the same for this one.

Code: Select all

[
                    .ELEM INTERFAZ2
                    .GRUPO GRUPO_PRINCIPAL
                    .PESO  2.0
                    .COORDS
                    (
#                        736 -SIZEY # bottom terminal with back bag (512.0 -SIZEY)
			512.0 -SIZEY
                    )
			.SIZE
			(
			48 103
			)
                    .BMP INTERFAZ2
                    .EMPIEZADISPONIBLE  1.0
                    .LIBRERIA TERMINAL.GRL
                ]
Then change this section to read like this.

Code: Select all

		GestorCaras
                [
                    .ELEM GESTORCARAS
                    .PESO 11.0
                    .COORDS
                    (
                        0, 570.0
                    )
                ]
And finally, change the y resolution to whatever your vertical resolution is minus 150. 720 minus 150 = 570.
Last edited by BooTx on Tue Mar 16, 2010 4:04 pm, edited 2 times in total.
User avatar
TAFNsick
TAFN Staff
Posts: 704
Joined: Sun Sep 19, 2004 11:16 am
Location: the Netherlands
Contact:

Post by TAFNsick »

Have you tried to edit the .grl files? The files you need to edit are in the INTERFAZ folder if I'm not mistaken. You can edit them with the Commandos developing toolkit:

http://files.cnblogs.com/Rex/CommDevToolkit.rar
http://files.cnblogs.com/Rex/CommDevToolkitSrc.rar

Hope this helps!
BooTx
Soldier
Posts: 3
Joined: Fri Mar 12, 2010 6:48 pm

Post by BooTx »

It did help, thank you. So far I've been able to find the red title background (it was in the "INTENDENCIA" folder). Unfortunately though, every effort I've made to stretch / remake the images in higher resolutions has led to the game crashing before the level loads.

I'm not entirely certain what's causing it, but I feel that it may be because the GRL size is almost twice as large for the 1280x720 files, and the game for whatever reason can't handle it (maybe the programmers set aside a specific amount of memory for it...maybe it just doesn't like the higher resolution). Regardless of how simple I make the images, I just can not get the final GRL file size down.

I was however able to just black out all of the images so the background doesn't appear at all. It's not what I'd prefer, but it's better than nothing.

Image

I still haven't figured out how to align the title vertically, and I also still need to figure out how to move the objectives box and the tips box. I'll keep looking.

Here's the blacked out title background file, if anyone is interested (it goes in Data\INTENDENCIA\).
BooTx
Soldier
Posts: 3
Joined: Fri Mar 12, 2010 6:48 pm

Post by BooTx »

Whoops I forgot to fix a section in the zipped up interface files. I fixed them and re-uploaded so it should work now.
herbert3000
Soldier
Posts: 15
Joined: Tue May 20, 2008 9:42 pm
Location: Vienna, Austria
Contact:

Post by herbert3000 »

Thanks a lot. Works perfectly.
Finally I can play C3 @ 1280x800 :D
Bee
Soldier
Posts: 9
Joined: Wed Sep 08, 2010 5:00 am

Post by Bee »

I registered just to say thanks for all this information. I gave up playing C3 not long after I got it because the resolution was just too low and that combined with no weapon hot keys just turned me off the game.

I dug it out of the dust today and googled resolution fixes and came across this thread. I'm now enjoying C3 for the first time, and in 1280x800 it looks good. Works great!

Thanks,
Bee
squallzinn
Soldier
Posts: 6
Joined: Sat Sep 11, 2010 12:50 am

Post by squallzinn »

Hi all,

I'm new here and I found this site through the google serching for a solution of the resolution issue. I notice everyone here had success by following the steps. I tried to do it and in my Commandos 3 folder don't have any INTERFAZ folder or any .MSB file in entire directory.

The first step worked well, but it only resized the game. the interface had duplicated in some parts and in others the buttons isn't in the right position.

Thanks in advanced.
Bee
Soldier
Posts: 9
Joined: Wed Sep 08, 2010 5:00 am

Post by Bee »

You have to create the Interfaz folder in your Data folder, then copy the file into it.

I was surprised to also find on the net a hotkey fix so that C3 now has hotkeys just like C2. If you can't find it, I can post it here.
squallzinn
Soldier
Posts: 6
Joined: Sat Sep 11, 2010 12:50 am

Post by squallzinn »

Bee wrote:You have to create the Interfaz folder in your Data folder, then copy the file into it.

I was surprised to also find on the net a hotkey fix so that C3 now has hotkeys just like C2. If you can't find it, I can post it here.
Wow it works!!! So just to confirm, Only the main menu and submenus and the introduction video of each map are in the default resolution, is that it?
Bee
Soldier
Posts: 9
Joined: Wed Sep 08, 2010 5:00 am

Post by Bee »

squallzinn wrote: Wow it works!!! So just to confirm, Only the main menu and submenus and the introduction video of each map are in the default resolution, is that it?
Yes, but you can change that by searching for and changing the following:

90 90 90 B8 20 03
90 90 90 B8 58 02

Just change the hex values 20 03 and 58 02 to whatever resolution you are using.

I had to change these values as well because it would crash on some maps when trying switch resolutions to go back to the main menu (on Vista). But it doesn't look pretty because the menus and cut scenes are positioned in the upper left of your screen.

You can always change them back if you don't like it. Just remember to always back up your commandos.exe before editing.


PS Don't forget to get the HotKey mod. That was one of the biggest issues for me with C3 was it didn't have weapons hotkeys.
squallzinn
Soldier
Posts: 6
Joined: Sat Sep 11, 2010 12:50 am

Post by squallzinn »

Is it normal the game crashes randomly and return to the desktop?

It generally crashes when will change the screen.
Bee
Soldier
Posts: 9
Joined: Wed Sep 08, 2010 5:00 am

Post by Bee »

squallzinn wrote:Is it normal the game crashes randomly and return to the desktop?

It generally crashes when will change the screen.
It depends on the resolution. If the vertical resolution is too high (i.e. 1024) then it will crash regardless. Try using 1280x800.
squallzinn
Soldier
Posts: 6
Joined: Sat Sep 11, 2010 12:50 am

Post by squallzinn »

Bee wrote:
squallzinn wrote:Is it normal the game crashes randomly and return to the desktop?

It generally crashes when will change the screen.
It depends on the resolution. If the vertical resolution is too high (i.e. 1024) then it will crash regardless. Try using 1280x800.
I was trying to use 1440x900. So the max I can set is 1280x800? I mean in terms of the game doesn't crash.

Thanks for response.
Bee
Soldier
Posts: 9
Joined: Wed Sep 08, 2010 5:00 am

Post by Bee »

I never tried 1440x900 so I can't say. I just stuck with 1280x800 because I know it worked without crashing. When I had it set to 1280x1024 it crashed on a number of maps.
squallzinn
Soldier
Posts: 6
Joined: Sat Sep 11, 2010 12:50 am

Post by squallzinn »

Bee wrote:I never tried 1440x900 so I can't say. I just stuck with 1280x800 because I know it worked without crashing. When I had it set to 1280x1024 it crashed on a number of maps.
The game doesn't work here with these resolution I don't know why. It always crashes in the initial screen.

My native resolution is 1440x900 I don't know if it interfere in something.
Bee
Soldier
Posts: 9
Joined: Wed Sep 08, 2010 5:00 am

Post by Bee »

Just keep trying other resolutions until you find one that doesn't crash. You had it working before, didn't you? Maybe you're editing the wrong values, I don't know.

You don't have to run the game in your monitor's native resolution. If you don't want it to look stretched, then turn off "scaling" in both your video card driver settings and in your monitor's internal settings.
Majin
Soldier
Posts: 3
Joined: Tue Oct 04, 2011 11:31 pm

Post by Majin »

Hi there mates,

I'd like to know if you could help me please...i'd love to play commandos 2 men of courage on may laptop with the right resolution, in widescreen, i read all the things i found on internet, but unfourtainly i can't change the resolution...i've downloaded be.hexeditor but when i try to change the file, an error is returned...could you please help me?
Thank you!
Bee
Soldier
Posts: 9
Joined: Wed Sep 08, 2010 5:00 am

Post by Bee »

Hi Majin,
For Commandos 2, I think you only need to edit the COMM2.CFG file in your OUTPUT folder to increase the resolution. If I remember correctly, you just open it and change the .MODOVIDEO line then save it. Mine is set to 3 (which is 1280x1024 I think).
Majin
Soldier
Posts: 3
Joined: Tue Oct 04, 2011 11:31 pm

Post by Majin »

Thanks for your reply!
I edited the file with the notepad and put in .MODO the number 3, but nothing happened...
Bee
Soldier
Posts: 9
Joined: Wed Sep 08, 2010 5:00 am

Post by Bee »

Make sure you actually start a game. The menus and intros to the missions will still be in 800x600, but when you actually start the map it will be in a different resolution.

A quick google shows this info for C2 but I know I didn't go through all that.
http://widescreengamingforum.com/dr/com ... en-courage

I just changed some entries in my existing files.
Majin
Soldier
Posts: 3
Joined: Tue Oct 04, 2011 11:31 pm

Post by Majin »

I allready tried to modify the comm2.exe filme as they say, but when i try to edit the file with be.hexeditor, returns me an error...could anyone please upload the file allready changed so i can have this situation solved please? Many thanks
Bee
Soldier
Posts: 9
Joined: Wed Sep 08, 2010 5:00 am

Post by Bee »

I can't help you there because I didn't change my comm2.exe file. All I did was edit the CFG file to get the resolution I need. Sorry.

However, you might try using UltraEdit (which is what I used to edit the commandos 3 exe). Since you don't say the error you are encountering, it's hard to give any specific advice. However, make sure you have full administrator access. Try right-clicking on the hex editor and select "Run As Administrator...". This should resolve some access errors.
herbert3000
Soldier
Posts: 15
Joined: Tue May 20, 2008 9:42 pm
Location: Vienna, Austria
Contact:

Post by herbert3000 »

Also make sure that comm2.exe isn't write-protected.
What's your desired resolution?
Post Reply