Jump to content


Photo

[REL] Commandos 2 Nightingale Mod (R5)

commandos 2 mod

  • Please log in to reply
20 replies to this topic

#1 Nightingale1

Nightingale1
  • Members
  • 38 posts

Posted 01 April 2016 - 04:13 PM

Hey guys, I've decided to add some extra functionality to Commandos 2: Destination Paris
I'll try to keep the changes minimal to prevent making the game unstable, while adding new features and maybe fixing some small bugs.

I use Commandos 2 GOG version with Destination Paris 1.42 Installed.

CAUTION:

  • Before using this mod take a backup of your profile and your saved games.
  • Your old save games might not be compatible with this mod.
  • This mod is not tested in multiplayer and most probably will not work.

Feel free to report any bugs or discuss new features.

Options:
You can set the options in "DATA\VAR.DAT" file. If an option is omitted, the default value will be used.

# TYPE | NAME                | VALUE | DEFAULT       | NOTES
#-------------------------------------------------------------------------------------------------------------------------------------------------------------------
INT      SCREEN_WIDTH          1024  # 640             In-game Screen Width
INT      SCREEN_HEIGHT         768   # 480             In-game Screen Height
BOOL     FIX_MENU_RESOLUTION   TRUE  # FALSE           Change menu resolutions too
INT      FRAME_RATE            50    # 25              In-game frame rate (NOTE: Changing frame rate changes game speed too)
INT      FRAME_SKIP            2     # 1               Update the world every Nth frame. Can be used to slow down the game speed without slowing down the interface.

Changes in R1:

  • In-game screen resolution can now be changed by modifying "DATA\VAR.DAT" file.

Changes in R2:

  • You can now remove the last bullet from rifles and pistols.
    last-bullet.gif

Changes in R3:

  • The last sleeping pill can be used now.
    last-sleeping-pill.gif
  • Developer mode is enabled. To open the developer window, enter the cheat code and press CTRL+- (MINUS)

Changes in R4:

  • In-game frame rate can now be changed from "DATA\VAR.DAT" file
  • You can also tune the game speed using frame skip option. This way you can increase the GUI frame rate, while the game speed remains the same.
    For example by setting FRAME_RATE to 50 and FRAME_SKIP to 2, the HUD will be twice as fast, and the game speed stays the same.

Changes in R5:

  • Added the option to enable changing the resolution of game menus.
    Note that there are some minor visual problems with this option set to "TRUE", but fixing them is not a priority right now.

Attached Files


Edited by Nightingale1, 09 April 2016 - 07:25 AM.


#2 SirRH

SirRH

    title available

  • Members
  • 604 posts
  • Location:Uranus

Posted 01 April 2016 - 06:10 PM

Isn't the gog version just the same as normal with 1.2 patch? Only BEL and BCD got modified for the gog release I think

Will 1080p work with this?

Edit:
After playing for a while with that ddraw, the game started freezing and crashing at random times


Edited by robb, 01 April 2016 - 09:37 PM.


#3 Salvadorc17

Salvadorc17

    title available

  • Members
  • 507 posts
  • Location:Colombia
  • Projects:Destination Norway

Posted 01 April 2016 - 08:37 PM

Hey guys, I've decided to add some extra functionality to Commandos 2 GOG Final version.
I'll try to keep the changes minimal to prevent making the game unstable, while adding new features and maybe fixing some small bugs.
 
I use Commandos 2 GOG version with Destination Paris 1.42 Installed.
 
I also include "ddraw.dll" file from DDrawCompat to fix windowed mode problems.


Good idea, why not try to create our custom ddraw hook for the game, so we can use it for later with other things like editor...

#4 Nightingale1

Nightingale1
  • Members
  • 38 posts

Posted 02 April 2016 - 08:16 AM

Isn't the gog version just the same as normal with 1.2 patch? Only BEL and BCD got modified for the gog release I think

Will 1080p work with this?

Edit:
After playing for a while with that ddraw, the game started freezing and crashing at random times

 

I really don't know, the MD5 sum of comm2.exe in my installation is 5bebaeadcb905bb9f838d0fc7d28abc0. Can you confirm this is the same as original 1.2?

 

For 1080p support: The changes I made in the game are same as old resolution fixes, so I guess it is like before. I finished the game in 1440x900 mode without any problem.

 

Does the crash happen in full-screen or windowed mode?



#5 Nightingale1

Nightingale1
  • Members
  • 38 posts

Posted 02 April 2016 - 08:20 AM

 

Hey guys, I've decided to add some extra functionality to Commandos 2 GOG Final version.
I'll try to keep the changes minimal to prevent making the game unstable, while adding new features and maybe fixing some small bugs.
 
I use Commandos 2 GOG version with Destination Paris 1.42 Installed.
 
I also include "ddraw.dll" file from DDrawCompat to fix windowed mode problems.


Good idea, why not try to create our custom ddraw hook for the game, so we can use it for later with other things like editor...

 

 

I have zero experience in creating dll hooks, but I think that would be a much better job. Do you know any resource on how to create one and how much access do we have when we use a dll hook? Can we modify/replace original game functions using the hook?



#6 Salvadorc17

Salvadorc17

    title available

  • Members
  • 507 posts
  • Location:Colombia
  • Projects:Destination Norway

Posted 02 April 2016 - 08:13 PM

I have zero experience in creating dll hooks, but I think that would be a much better job. Do you know any resource on how to create one and how much access do we have when we use a dll hook? Can we modify/replace original game functions using the hook?


Yes, i should be able to create a basic ddraw.dll from dirext sdk source, about the acess, will be limited to just call the functions from exe, not modify those, to create new stuff will need to do from scratch into the custom library attach process code.



#7 Nightingale1

Nightingale1
  • Members
  • 38 posts

Posted 05 April 2016 - 12:28 PM

 

I have zero experience in creating dll hooks, but I think that would be a much better job. Do you know any resource on how to create one and how much access do we have when we use a dll hook? Can we modify/replace original game functions using the hook?


Yes, i should be able to create a basic ddraw.dll from dirext sdk source, about the acess, will be limited to just call the functions from exe, not modify those, to create new stuff will need to do from scratch into the custom library attach process code.

 

 

That would be great! We could make the game more compatible with new OSes and hardware and add other functionality.

But I still continue to add modifications to the game and remove some limitations.



#8 SirRH

SirRH

    title available

  • Members
  • 604 posts
  • Location:Uranus

Posted 05 April 2016 - 02:46 PM

I'm not sure commandos 2 even needs a ddraw mod, it runs fine under pretty much every version of windows (other than the original 1.0 exe with securom), the only minor issue is windowed mode causing some weird graphical problems for other programs, but that can be fixed by just using 16-bit colours. It's only Commandos 3 that has problems on Windows 8 and up.


Edited by robb, 05 April 2016 - 02:53 PM.


#9 Nightingale1

Nightingale1
  • Members
  • 38 posts

Posted 05 April 2016 - 02:58 PM

I'm not sure commandos 2 even needs a ddraw mod, it runs fine under pretty much every version of windows (other than the original 1.0 exe with securom), the only minor issue is windowed mode causing some weird graphical problems for other programs, but that can be fixed by just using 16-bit colours. It's only Commandos 3 that has problems on Windows 8 and up.

 

Thank you for the information.

I have black cursor issues in windowed mode even with 16-bit compatibility. But that's the only problem that ddraw.dll can fix, so I'll remove the ddraw.dll from the mod.



#10 Salvadorc17

Salvadorc17

    title available

  • Members
  • 507 posts
  • Location:Colombia
  • Projects:Destination Norway

Posted 05 April 2016 - 07:54 PM

That would be great! We could make the game more compatible with new OSes and hardware and add other functionality.
But I still continue to add modifications to the game and remove some limitations.

 

Not really, still using ddraw will not allow game to add more Os compatibility, maybe can be fixed for later Windows, but will need some changes in executable so it does not look for old linked libraries like directplay or something else..
 



#11 SirRH

SirRH

    title available

  • Members
  • 604 posts
  • Location:Uranus

Posted 07 April 2016 - 07:31 PM

Nice update is 50fps the max? or could i set to 100 for example with frameskip at 4? might test this on multiplayer to see if it removes some of the input lag

Only thing, i think the rifle ammo change should be put back, as this might make sync issues on MP, i think that feature was added to DP to make it seem like there is 1 ammo always already loaded into the rifle from all the deads as that is a bit more realistic with a bolt action rifle.


Edited by robb, 07 April 2016 - 07:34 PM.


#12 Nightingale1

Nightingale1
  • Members
  • 38 posts

Posted 07 April 2016 - 08:47 PM

Nice update is 50fps the max? or could i set to 100 for example with frameskip at 4? might test this on multiplayer to see if it removes some of the input lag

Only thing, i think the rifle ammo change should be put back, as this might make sync issues on MP, i think that feature was added to DP to make it seem like there is 1 ammo always already loaded into the rifle from all the deads as that is a bit more realistic with a bolt action rifle.

 

The is no max on fps, but by increasing it the HUD animations become too fast. You can change and test it, with my machine 100fps and 4 frame skip works pretty good.

 

Please let me know if you managed to test it in multiplayer, that would mean a lot to me.

 

Are you sure the 1 ammo thing is added in DP? As I recall the original Commandos 2 game had this thing too.

 

Actually unloading a bolt action rifle is pretty easy, so this might have been due to multiplayer syncing issues. I need to test it and see if there is a problem.

Anyway, I guess I have to make this fix optional so modders can decide.

 

Do you think the sleeping pill bug was also related to multiplayer issues? If so, another fix might be decreasing the number shown on the sleeping pill by one. Then when there is one sleeping pill and it can't be used, HUD will shows number 0 instead of 1.  Any ideas about this?



#13 SirRH

SirRH

    title available

  • Members
  • 604 posts
  • Location:Uranus

Posted 07 April 2016 - 09:36 PM

 

Nice update is 50fps the max? or could i set to 100 for example with frameskip at 4? might test this on multiplayer to see if it removes some of the input lag

Only thing, i think the rifle ammo change should be put back, as this might make sync issues on MP, i think that feature was added to DP to make it seem like there is 1 ammo always already loaded into the rifle from all the deads as that is a bit more realistic with a bolt action rifle.

 

The is no max on fps, but by increasing it the HUD animations become too fast. You can change and test it, with my machine 100fps and 4 frame skip works pretty good.

 

Please let me know if you managed to test it in multiplayer, that would mean a lot to me.

 

Are you sure the 1 ammo thing is added in DP? As I recall the original Commandos 2 game had this thing too.

 

Actually unloading a bolt action rifle is pretty easy, so this might have been due to multiplayer syncing issues. I need to test it and see if there is a problem.

Anyway, I guess I have to make this fix optional so modders can decide.

 

Do you think the sleeping pill bug was also related to multiplayer issues? If so, another fix might be decreasing the number shown on the sleeping pill by one. Then when there is one sleeping pill and it can't be used, HUD will shows number 0 instead of 1.  Any ideas about this?

 

Thanks just tried with 100fps, the increased fps definitely makes the game feel much smoother and removes some input lag, much better than the default 25fps, in fact i made a quick test video. You can notice difference in the 720p60 mode looks much smoother 

 



And yes i'm fairly sure that ammo change was in DP only, basically if one player has the mod and uses the extra ammo this would cause the sync to be wrong, one player would have more ammo than other for example, the same would probably be with pills, but I don't think anyone even uses the pills that much anyway 


Edited by robb, 07 April 2016 - 09:38 PM.


#14 Nightingale1

Nightingale1
  • Members
  • 38 posts

Posted 08 April 2016 - 07:57 PM

 

 

Nice update is 50fps the max? or could i set to 100 for example with frameskip at 4? might test this on multiplayer to see if it removes some of the input lag

Only thing, i think the rifle ammo change should be put back, as this might make sync issues on MP, i think that feature was added to DP to make it seem like there is 1 ammo always already loaded into the rifle from all the deads as that is a bit more realistic with a bolt action rifle.

 

The is no max on fps, but by increasing it the HUD animations become too fast. You can change and test it, with my machine 100fps and 4 frame skip works pretty good.

 

Please let me know if you managed to test it in multiplayer, that would mean a lot to me.

 

Are you sure the 1 ammo thing is added in DP? As I recall the original Commandos 2 game had this thing too.

 

Actually unloading a bolt action rifle is pretty easy, so this might have been due to multiplayer syncing issues. I need to test it and see if there is a problem.

Anyway, I guess I have to make this fix optional so modders can decide.

 

Do you think the sleeping pill bug was also related to multiplayer issues? If so, another fix might be decreasing the number shown on the sleeping pill by one. Then when there is one sleeping pill and it can't be used, HUD will shows number 0 instead of 1.  Any ideas about this?

 

Thanks just tried with 100fps, the increased fps definitely makes the game feel much smoother and removes some input lag, much better than the default 25fps, in fact i made a quick test video. You can notice difference in the 720p60 mode looks much smoother 

 



And yes i'm fairly sure that ammo change was in DP only, basically if one player has the mod and uses the extra ammo this would cause the sync to be wrong, one player would have more ammo than other for example, the same would probably be with pills, but I don't think anyone even uses the pills that much anyway 

 

 

Thank you for testing the mod. It's good to know that the fps fix reduced input lag. Seeing more responsive mouse and UI in your video has tempted myself to play and finish the game once again.

 

Well, I'll have to test the game in MP mode to see if the syncing problem can be fixed. If not, I'll have to restore that patch to DP version.

 

UPDATE:

I just tested it: You still can't remove the last bullet from rifles in MP mode, since GUI handling of MP is separate from SP. So my fix only works for SP.


Edited by Nightingale1, 08 April 2016 - 08:27 PM.


#15 Salvadorc17

Salvadorc17

    title available

  • Members
  • 507 posts
  • Location:Colombia
  • Projects:Destination Norway

Posted 09 April 2016 - 04:52 PM

UPDATE:
I just tested it: You still can't remove the last bullet from rifles in MP mode, since GUI handling of MP is separate from SP. So my fix only works for SP.


I was able to test the mod with robb in multiplayer, and we had got really fps decreasing in multiplayer, like some slow motion, you can check for this, maybe fps in multiplayer also need to consider the latency..



#16 Nightingale1

Nightingale1
  • Members
  • 38 posts

Posted 09 April 2016 - 06:36 PM

 

UPDATE:
I just tested it: You still can't remove the last bullet from rifles in MP mode, since GUI handling of MP is separate from SP. So my fix only works for SP.


I was able to test the mod with robb in multiplayer, and we had got really fps decreasing in multiplayer, like some slow motion, you can check for this, maybe fps in multiplayer also need to consider the latency..

 

 

Thank you for reporting this. Did both of you use the mod? If so, I guess the network syncing gets fast just like the UI and it floods the net. I'll look into it.



#17 SirRH

SirRH

    title available

  • Members
  • 604 posts
  • Location:Uranus

Posted 09 April 2016 - 07:43 PM

 

 

UPDATE:
I just tested it: You still can't remove the last bullet from rifles in MP mode, since GUI handling of MP is separate from SP. So my fix only works for SP.


I was able to test the mod with robb in multiplayer, and we had got really fps decreasing in multiplayer, like some slow motion, you can check for this, maybe fps in multiplayer also need to consider the latency..

 

 

Thank you for reporting this. Did both of you use the mod? If so, I guess the network syncing gets fast just like the UI and it floods the net. I'll look into it.

 

yes we both had set to 100fps/frameskip 4, what happened in multiplayer was that the faces/ui went back to normal speed instead of sped up, and gameplay went 4x slower than default


Edited by robb, 09 April 2016 - 09:30 PM.


#18 Nightingale1

Nightingale1
  • Members
  • 38 posts

Posted 15 April 2016 - 03:32 PM

Fix

 

 

 

 

UPDATE:
I just tested it: You still can't remove the last bullet from rifles in MP mode, since GUI handling of MP is separate from SP. So my fix only works for SP.


I was able to test the mod with robb in multiplayer, and we had got really fps decreasing in multiplayer, like some slow motion, you can check for this, maybe fps in multiplayer also need to consider the latency..

 

 

Thank you for reporting this. Did both of you use the mod? If so, I guess the network syncing gets fast just like the UI and it floods the net. I'll look into it.

 

yes we both had set to 100fps/frameskip 4, what happened in multiplayer was that the faces/ui went back to normal speed instead of sped up, and gameplay went 4x slower than default

 

 

Fixing multiplayer was harder than I thought. For now if you set frameskip to 1, the game speed will automatically match slowest client.



#19 Jurigag

Jurigag
  • Members
  • 6 posts

Posted 28 October 2016 - 07:02 PM

Well i have a problem @Nightingale1 that your exe is not working for me on windows 10 and steam version. Only retail steam exe is working for my. Using yours is just causing comm2.exe stopped working error. Any idea ?

Well on legacy version it work !


Edited by Jurigag, 31 October 2016 - 11:35 PM.


#20 sleepinsun

sleepinsun
  • Members
  • 27 posts

Posted 13 December 2016 - 02:32 PM

1.43 support?






1 user(s) are reading this topic

0 members, 1 guests, 0 anonymous users