PDA

View Full Version : Swapping between Stock and Team Fusion versions



56RAF_klem
Mar-20-2013, 07:05
A longish post but worth the effort if you want to swap easily between versions. Of course one way is to go into your folders every time and recreate the appropriate maddox.dll but this will do it for you at the click of a button. There are simpler batch files to do simple renaming but this method will always check that you have the necessary files available.

These instructions assume you have the Team Fusion version installed and haven't done anything to change that. They also assume you have installed CoD to your C: drive, if you haven't you must mentally adjust the instructions to suit your installation.

First you must make backup copies of the Stock and Team Fusion (TF) versions of the file maddox.dll in the folder
C:/Programe Files (x86)/Steam/steamapps/common/il-2 sturmovik cliffs of dover/parts/core.
( DO NOT confuse this main game installation location with your personal settings (.ini files) folder at:
C:/Users/[your PC login name]/My Documents/1C Soft Club/il-2 sturmovik cliffs of dover/ )

When you installed the TF patch it will have backed up the stock version of maddox.dll, giving it a name in the form of :

maddox.dll.ModInstallBackup_16-3-2013-9_59_20

You need to rename this file. Note that if you have more than one file like that (usually caused by multiple attempts to install the mod) make sure you rename the oldest version. You should rename the file to maddox_stock.dll and this file should NEVER be deleted.

Next, make a copy of maddox.dll, which is the version placed there by the TF patch, and name it maddox_fusion.dll.

Now go to your Destop and, away from the other Desktop icons, right click on the background, select New.... Text Document. Accept the name it gives you for now.

Double click on the Desktop icon or Right click on it and Open it file with Notepad. Copy all of the following text between, but not including, the ============== lines.

Don't worry, you don't need to understand the code.

==============================


Option Explicit
'mods installation must place a copy of stock maddox.dll as maddox_stock.dll in \parts\core\ folder
'mods installation must place a copy of fusion maddox.dll as maddox_fusion.dll in \parts\core\ folder
'OTHERWISE, make these files yourself by copying and editing the filenames of the stock and fusion maddox.dll's

Dim CodPath

'EDIT YOUR GAME PATH TO SUIT:-
CodPath = "C:\Program Files (x86)\Steam\steamapps\common\il-2 sturmovik cliffs of dover\"


'Main Code:-
Dim objFSO, objShell
Dim strFile0, strFile1, strFile2
Dim stockdll, fusiondll, response, msg

Set objShell = WScript.CreateObject("WScript.Shell")

stockdll= 0
fusiondll = 0


' Create the File System Object
Set objFSO = CreateObject("Scripting.FileSystemObject")

' Check that the required dlls exist

strFile0 = CodPath & "parts\core\maddox.dll"

strFile1 = CodPath & "parts\core\maddox_stock.dll"
If objFSO.FileExists(strFile1) Then stockdll = 1
if stockdll = 0 then call nostockdll

strFile2 = CodPath & "parts\core\maddox_fusion.dll"
If objFSO.FileExists(strFile2) Then fusiondll = 1
if fusiondll = 0 then call nofusiondll

'ask the question
response = MsgBox("Do you want to run Fusion modsversion?" & vbcr & "'Yes' will run Fusion version, 'No' will run Stock version",515, "Stock or MODs version")

if response = 2 then WScript.Quit

if response = 6 then
objFSO.CopyFile strFile2, strFile0, true
msg = "Fusion version"
WScript.Sleep 1000
end if

if response = 7 then
objFSO.CopyFile strFile1, strFile0, true
msg = "Stock version"
WScript.Sleep 1000
end if

'objShell.Run Chr(34) & CodPath & "Launcher.exe" & Chr(34), 1
MsgBox "You can now run CoD in " & msg & " from your usual shortcut or Steam."

WScript.Quit

Sub nostockdll
MsgBox "No stock version of maddox.dll named maddox_stock.dll available. Cannot proceed. You can run your currently installed version by running the Launcher from Desktop or Steam Library."
WScript.Quit
End Sub

Sub nomoddll
MsgBox "No fusion version of maddox.dll named maddox_fusion.dll is available. Cannot proceed. You can run your currently installed version by running the Launcher from Desktop or Steam Library."
WScript.Quit
End Sub


errorswap:
If err.number <> vbEmpty then WScript.echo "VBScript Error: " & err.number

' End of VBScript to select dll file

=============================

Note! This code is written for a main CoD installation on the default path of:
C:\Program Files (x86)\Steam\steamapps\common\Il-2 sturmovik cliffs of dover

If yours isn't at that location find the lines that read:

'EDIT YOUR GAME PATH TO SUIT:-
CodPath = "C:\Program Files (x86)\Steam\steamapps\common\il-2 sturmovik cliffs of dover\"

and edit the CodPath line (inside the quotation marks) to read the location of your CoD main installation folder.
(DO NOT confuse this main game installation location with your personal settings (.ini files) folder at:
C:/Users/[your PC login name]/My Documents/1C Soft Club/il-2 sturmovik cliffs of dover/)

Now save the file and close it. Finally right click on the Desktop icon, select Rename and name it CoD_Swap.vbs. You will probably get warnings about changing the filetype or extension and that it may not work properly, just ignore this and rename it.

That's it, just double click on the Desktop icon and it will ask you which version you want to use. After that you just start the game in the normal way (desktop icon or in Steam, etc).


ERROR MESSAGES:
If you get an error message about maddox.dll, maddox_stock.dll or maddox_fusion.dll not being available you made a mistake renaming files or perhaps renamed maddox.dll instead of renaming a copy of it. Go back to the beginning of these instructions and be sure you named everything correctly. If you find you do not have a maddox.dll you must copy either the _stock or the _fusion version and rename the copy maddox.dll. It doesn't matter which, your Mod Swapper will take you where you want to go.

If all goes to rats just re-validate your game in Steam, test it and then reinstall the patch and follow these instructions again.

FUTURE PATCHES
Install any future patch then immediately make a copy of maddox.dll to replace your maddox_fusion.dll

NOTES

In the very unlikely event that the game is formally updated by 1C through Steam, i.e. creating a new stock version, then that maddox.dll should be used to replaced the maddox_stock.dll you just made. (Updating by 1C is extremely unlikely as they have officially walked away from CoD.)

If you ever re-validate your files through Steam you will be taken back to the stock version but the Mod Swapper will still work because it has the same _stock version of maddox.dll that Steam will have given you.

flightdok
Mar-20-2013, 18:50
I am a little confused on what to do after making the new "text Document"? Which icon do you open and add the script between the ============?

56RAF_klem
Mar-21-2013, 12:05
I am a little confused on what to do after making the new "text Document"? Which icon do you open and add the script between the ============?

The icon for the new Text document you just created. If you created it on your desktop it will have an icon for it.

flightdok
Mar-21-2013, 13:40
The icon for the new Text document you just created. If you created it on your desktop it will have an icon for it.

I sorry, I'm not real computer literate.......when I "right click" and hit "new text", it creates a new "text Doc. icon" not a "clickable" icon. How do you make a new icon that you can "click".....:-)

:FI:Sneaky
Mar-21-2013, 14:47
I simplified the process just doing the following..
1)go to your Steam folder

"C:\Program Files (x86)\Steam\steamapps\common\IL-2 Sturmovik Cliffs of Dover\parts\core"
Making a switcher........
copy the files =
maddox.dll
maddox.dll.ModInstallBackup_20-3-2013-14_39_17
Strategy.dll
Strategy.dll.ModInstallBackup_20-3-2013-14_39_17
- and save to a new folder called "Backup"


2) in "C:\Program Files (x86)\Steam\steamapps\common\IL-2 Sturmovik Cliffs of Dover\parts\core" create "maddox.bak" and "Strategy.bak"


3)Use this .bat file to switch (toggle) versions. copy and paste to notepad and save as clod_switcher.bat
IMPORTANT check the formatting when copying the .bat in notepad so that each xcopy command is on one line with no page breaks or text wrap. run from Cmd console to check all copies performed
__________________________________________________ _________________


xcopy "C:\Program Files (x86)\Steam\steamapps\common\IL-2 Sturmovik Cliffs of Dover\parts\core\maddox.dll" "C:\Program Files (x86)\Steam\steamapps\common\IL-2 Sturmovik Cliffs of Dover\parts\core\maddox.bak"/h/y

xcopy "C:\Program Files (x86)\Steam\steamapps\common\IL-2 Sturmovik Cliffs of Dover\parts\core\maddox.dll.ModInstallBackup_20-3-2013-14_39_17" "C:\Program Files (x86)\Steam\steamapps\common\IL-2 Sturmovik Cliffs of Dover

\parts\core\maddox.dll"/h/y

xcopy "C:\Program Files (x86)\Steam\steamapps\common\IL-2 Sturmovik Cliffs of Dover\parts\core\maddox.bak" "C:\Program Files (x86)\Steam\steamapps\common\IL-2 Sturmovik Cliffs of Dover\parts\core

\maddox.dll.ModInstallBackup_20-3-2013-14_39_17"/h/y

xcopy "C:\Program Files (x86)\Steam\steamapps\common\IL-2 Sturmovik Cliffs of Dover\parts\core\Strategy.dll" "C:\Program Files (x86)\Steam\steamapps\common\IL-2 Sturmovik Cliffs of Dover\parts\core\Strategy.bak"/h/y

xcopy "C:\Program Files (x86)\Steam\steamapps\common\IL-2 Sturmovik Cliffs of Dover\parts\core\Strategy.dll.ModInstallBackup_20-3-2013-14_39_17" "C:\Program Files (x86)\Steam\steamapps\common\IL-2 Sturmovik Cliffs of Dover

\parts\core\Strategy.dll"/h/y


xcopy "C:\Program Files (x86)\Steam\steamapps\common\IL-2 Sturmovik Cliffs of Dover\parts\core\Strategy.bak" "C:\Program Files (x86)\Steam\steamapps\common\IL-2 Sturmovik Cliffs of Dover\parts\core

\Strategy.dll.ModInstallBackup_20-3-2013-14_39_17"/h/y
Note if your Steam folder is not in the default path "C:\Program Files (x86)\Steam" you should use Find/Replace in notepad to redirect the bat file commands


__________________________________________________ _________________

create a handy desktop shortcut.
If it all goes horribly wrong , refer to part 1) and restore ;)

heinkill
Mar-21-2013, 16:39
If you are less computer literate...like me...creating two separate and distinct installations is an alternative to the above.

Howto here:

http://theairtacticalassaultgroup.com/forum/showthread.php?t=3797

H

flightdok
Mar-21-2013, 18:03
Can someone please tell me a simple step by step way of doing the switcher between the games please....all this is now very confusing.....I do not know how to create a "bat" file......etc........

56RAF_klem
Mar-21-2013, 18:26
I sorry, I'm not real computer literate.......when I "right click" and hit "new text", it creates a new "text Doc. icon" not a "clickable" icon. How do you make a new icon that you can "click".....


Can someone please tell me a simple step by step way of doing the switcher between the games please....all this is now very confusing.....I do not know how to create a "bat" file......etc........

If you follow my instructions word for word you will get there but I assumed people would know about Right Click and picking from lists to make a New Text Document. Here's how to do it....

When I say "right click and select New... Text Document" it means move your mouse cursor onto the background of the normal screen you see when you start windows where all the icons are (don;t place it over an icon) then press the right hand mouse button. That brings up a list of things to choose from. Slide your cursor into the list and up (or down) to "New" and another list appears. Slide your cursor onto the second list then slide it up (or down) onto "Text Document" and left click on your mouse. A file will appear on your Desktop named "New Text Document.txt". Accept the file name by simply clicking somewhere else on your Desktop background. Then carry on with "Double click on the Desktop icon ......"

56RAF_klem
Mar-21-2013, 19:08
I simplified the process just doing the following..
1)go to your Steam folder

"C:\Program Files (x86)\Steam\steamapps\common\IL-2 Sturmovik Cliffs of Dover\parts\core"
Making a switcher........
copy the files =
maddox.dll
maddox.dll.ModInstallBackup_20-3-2013-14_39_17
Strategy.dll
Strategy.dll.ModInstallBackup_20-3-2013-14_39_17
- and save to a new folder called "Backup"


2) in "C:\Program Files (x86)\Steam\steamapps\common\IL-2 Sturmovik Cliffs of Dover\parts\core" create "maddox.bak" and "Strategy.bak"


3)Use this .bat file to switch (toggle) versions. copy and paste to notepad and save as clod_switcher.bat
IMPORTANT check the formatting when copying the .bat in notepad so that each xcopy command is on one line with no page breaks or text wrap. run from Cmd console to check all copies performed
__________________________________________________ _________________


xcopy "C:\Program Files (x86)\Steam\steamapps\common\IL-2 Sturmovik Cliffs of Dover\parts\core\maddox.dll" "C:\Program Files (x86)\Steam\steamapps\common\IL-2 Sturmovik Cliffs of Dover\parts\core\maddox.bak"/h/y

xcopy "C:\Program Files (x86)\Steam\steamapps\common\IL-2 Sturmovik Cliffs of Dover\parts\core\maddox.dll.ModInstallBackup_20-3-2013-14_39_17" "C:\Program Files (x86)\Steam\steamapps\common\IL-2 Sturmovik Cliffs of Dover

\parts\core\maddox.dll"/h/y

xcopy "C:\Program Files (x86)\Steam\steamapps\common\IL-2 Sturmovik Cliffs of Dover\parts\core\maddox.bak" "C:\Program Files (x86)\Steam\steamapps\common\IL-2 Sturmovik Cliffs of Dover\parts\core

\maddox.dll.ModInstallBackup_20-3-2013-14_39_17"/h/y

xcopy "C:\Program Files (x86)\Steam\steamapps\common\IL-2 Sturmovik Cliffs of Dover\parts\core\Strategy.dll" "C:\Program Files (x86)\Steam\steamapps\common\IL-2 Sturmovik Cliffs of Dover\parts\core\Strategy.bak"/h/y

xcopy "C:\Program Files (x86)\Steam\steamapps\common\IL-2 Sturmovik Cliffs of Dover\parts\core\Strategy.dll.ModInstallBackup_20-3-2013-14_39_17" "C:\Program Files (x86)\Steam\steamapps\common\IL-2 Sturmovik Cliffs of Dover

\parts\core\Strategy.dll"/h/y


xcopy "C:\Program Files (x86)\Steam\steamapps\common\IL-2 Sturmovik Cliffs of Dover\parts\core\Strategy.bak" "C:\Program Files (x86)\Steam\steamapps\common\IL-2 Sturmovik Cliffs of Dover\parts\core

\Strategy.dll.ModInstallBackup_20-3-2013-14_39_17"/h/y
Note if your Steam folder is not in the default path "C:\Program Files (x86)\Steam" you should use Find/Replace in notepad to redirect the bat file commands


__________________________________________________ _________________

create a handy desktop shortcut.
If it all goes horribly wrong , refer to part 1) and restore ;)

I think this is not as simple as it sounds and is possibly dangerous.

On the first run you are replacing the patch maddox.dll with the original (the one with the backup date in the title) and storing the patch maddox.dll (via the name maddox.bak) under the name used by the original .dll with the backup date in the filename. So you have swapped the contents of the dated patch backup file. That alone rings alarm bells. It will be ok for now, swapping to and fro, but if you install another patch then before patching you will have to ensure that you have toggled to the previous patch version, not stock, so that the backup dated version still stands as the original maddox.dll, or you will end up with a mess to unravel: If you are running as stock when you install the new patch, the old dated backup version will not be the stock version it will be the previous patch version because you swapped the file contents; the stock version will be backed up with a different backup date to that in the .bat file. So now when you start swapping between the filenames in your .bat file you will be swapping between the two patch versions while the original maddox.dll hides away under the new dated backup filename.

With my method all you have to do after installing a new patch is make a new maddox_fusion.dll by copying the maddox.dll from the newly installed patch.

flightdok
Mar-21-2013, 23:28
<When I say "right click and select New... Text Document" it means move your mouse cursor onto the background of the normal screen you see when you start windows where all the icons are (don't place it over an icon) then press the right hand mouse button. That brings up a list of things to choose from. Slide your cursor into the list and up (or down) to "New" and another list appears. Slide your cursor onto the second list then slide it up (or down) onto "Text Document" and left click on your mouse. A file will appear on your Desktop named "New Text Document.txt". Accept the file name by simply clicking somewhere else on your Desktop background.>.......This I know how to do sir, Which icon do you double click on afterward......the steam shortcut icon, the game launcher icon?....when I try to do either, nothing happens?.....

56RAF_klem
Mar-22-2013, 03:31
<When I say "right click and select New... Text Document" it means move your mouse cursor onto the background of the normal screen you see when you start windows where all the icons are (don't place it over an icon) then press the right hand mouse button. That brings up a list of things to choose from. Slide your cursor into the list and up (or down) to "New" and another list appears. Slide your cursor onto the second list then slide it up (or down) onto "Text Document" and left click on your mouse. A file will appear on your Desktop named "New Text Document.txt". Accept the file name by simply clicking somewhere else on your Desktop background.>.......This I know how to do sir, Which icon do you double click on afterward......the steam shortcut icon, the game launcher icon?....when I try to do either, nothing happens?.....

You Double Click on the "New Text Document.txt" file. That is where you are going to paste the code. Later in the instructions you will rename it to "CoD_Swap.vbs".

flightdok
Mar-24-2013, 14:58
Is anyone else having problems trying to make this switcher for the game?.....:(.....if you are able to do it, would you please post a video here to show how, I have tried over and over again with no luck.............:grrr:

56RAF_klem
Mar-24-2013, 16:11
Is anyone else having problems trying to make this switcher for the game?.....:(.....if you are able to do it, would you please post a video here to show how, I have tried over and over again with no luck.............:grrr:

flightdok,

if you have your installation on the C drive and its at
"C:\Program Files (x86)\Steam\steamapps\common\il-2 sturmovik cliffs of dover\"

then save the attached file to your desktop and rename it from a .txt file to a .vbs file.

Then if you have made the maddox_stock.dll and the maddox_fusion.dll exactly as I described the swapper should work ok. Just double click on it to run it.

flightdok
Mar-24-2013, 23:06
Ok, finally was able to make a .vbs file.....clicked on it and this is the error message I got?......

line: 44
Char: 1
Error: Permission denied
Code: 800A0046
Source: Microsoft VBScript runtime error


Any ideas??

56RAF_klem
Mar-25-2013, 06:35
Ok, finally was able to make a .vbs file.....clicked on it and this is the error message I got?......

line: 44
Char: 1
Error: Permission denied
Code: 800A0046
Source: Microsoft VBScript runtime error


Any ideas??

Did you get the question about which version you want to run or did this error message occur as soon as you double clocked the vbs file?
Which version of Windows are you running?

The Windows version shouldn't really matter and the error line is a very simple assignment of a text message. I can only think that there is something wrong in your windows installation that affects .vbs script. However, the line number may be incorrect. Try this: right click on the .vbs file and select Edit, it will open in Notepad. Go down to line 45 where it reads
WScript.Sleep 1000
and put an apostrophe in front of it so it reads
'WScript.Sleep 1000

Do this for both the entries that are in there and save the file. They aren't really needed and are a hangover from something else I was doing. If it solves the problem you can delete those two lines.

flightdok
Mar-25-2013, 14:07
Ok, I am running Windows 7 64 bit home premium and yes it came up and asked for which version do you want to run, yes for mode version and no for standard version. When I click on either yes or no, that is when I get the error message.....and no, it didn't help by placing the symbol in front of the two entries.......:(

56RAF_klem
Mar-25-2013, 16:14
Ok, I am running Windows 7 64 bit home premium and yes it came up and asked for which version do you want to run, yes for mode version and no for standard version. When I click on either yes or no, that is when I get the error message.....and no, it didn't help by placing the symbol in front of the two entries.......:(

OK I am guessing its to do with this line:-
objFSO.CopyFile strFile2, strFile0, true

where the .vbs attempts to copy maddox_fusion.dll to maddox.dll (true means Overwrite).

You may not have admin rights to write inside that folder. Do you know your Windows permissions or User type? Basically, if you are the only login you should have admin rights or do you log in as one of a number of Users?

Try this:
Open Explorer and go to the folder:-
"C:\Program Files (x86)\Steam\steamapps\common\il-2 sturmovik cliffs of dover\"
Right click on the folder icon in the left hand panel and select Properties
Select the Security tab
Click on (highlight) your login name and see what permissions you have in the bottom panel. You need Full Control or Read and Write.
If these aren't ticked click on Edit, select your name in the top panel of the new window and see if you can tick Allow against Full Control in the bottom panel. Or Allow against Write. Then click OK.

If you can't do that you need to get whoever has Admin rights (it is usually listed in the Properties window) to log in and do it for you.

flightdok
Mar-26-2013, 10:41
If you can't do that you need to get whoever has Admin rights (it is usually listed in the Properties window) to log in and do it for you.[/QUOTE]

Ok, I am the administrator and only user of this computer......I'm going to give up on this now.........thanks for trying to help me...........:(

maddysad
Mar-26-2013, 14:06
If you are less computer literate...like me...creating two separate and distinct installations is an alternative to the above.

Howto here:

http://theairtacticalassaultgroup.com/forum/showthread.php?t=3797

H

I don't understand stuff like BAT files etc either but the above method is the same way I have copied favourite games for years :devilish:

On Desktop

iL2 1946 (3 versions), Cliffs of Dover (2 vesions), Red Ochestra (3 versions),Silent Hunter 5 (2 versions) etc.

I can play whichever version I want with each independant from all other versions and suprisingly :dazed: 1946 is the largest portion of my HD

maddysad

56RAF_klem
Mar-26-2013, 18:02
If you can't do that you need to get whoever has Admin rights (it is usually listed in the Properties window) to log in and do it for you.



Ok, I am the administrator and only user of this computer......I'm going to give up on this now.........thanks for trying to help me...........:(

Well, its not the end of the road. You just have to do it by hand. Go to the /parts/core/ folder, delete the maddox.dll and copy whichever .dll you want to use (maddox_stock.dll or maddox_fusion.dll) and rename the copy maddox.dll.

I can't imagine why your system won't let the .vbs run properly. It works for me and others.