Go Back   Steam Users' Forums > Steam Game Discussions > # - C > Battlefield series

Reply
 
Thread Tools Display Modes
Old 12-26-2010, 08:02 AM   #1
GermanDarknes
 
 
 
Join Date: Aug 2009
Reputation: 49
Posts: 29
Exclamation Battlefield 2 - Invalid CDKey Fix

Hi there,
you have 3 ways to fix it, 2 simple(with third party applications) and 1 with a little work but without third party applications.

IMPORTANT!
Quote:
Originally Posted by LemonMeringueTy View Post
EDIT: Don't forget to update PunkBuster and disable the Steam Overlay since PB sees it as a cheat (wtf)
Useful Links:
- How to Update Punkbuster
- How to Disable Steam Overlay - fix 3rd party program kick!
- Fix crashes to Desktop

Steam Guide:
- http://steamcommunity.com/sharedfile.../?id=122953468

How to fix this problem:
1. Step:
Start Battlefield 2 without changing anything.

2. Step:
Download the Battlefield 2 CD-Key changer.
http://www.germandarknes.net/index.php?downloadsview-6

3. Step:
Start the CD-Key Changer, type in your CD-Key and press Apply.

You have to run the tool as administrator!

4. Step:
Delete or rename this file:
C:\Program Files\Steam\steamapps\common\battlefield 2\installscript.vdf

5. Step:
Run Battlefield 2 as Administrator.

6. Step:
Try out if it works. If you still get the error, go back to Step 2 and tick the "Don't include hyphens" checkbox before pressing Apply.

If it works:
Enjoy Battlefield

Please report if it works or if you have any problems.

OUTDATED WAY:
Quote:
1. Way: Simple
Quote:
Quote:
Download:
http://germandarknes.net/index.php?downloads-show-14

Sourcecode:
http://germandarknes.net/content/BF2KeyFixSource.zip (Written in Delphi7)

How to:
1. Step: Start BF2 Key Changer.exe - type in your CD-Key and press apply
IMPORTANT: Every 4 characters write -
e.g. ABCD-1234-EFGH-5678-IJKL

2. Step: Move BF2CdKeyCheck.exe to your battlefield 2/support dir
default: default: C:\Program Files\Steam\steamapps\common\battlefield 2\support
Overwrite the exiting one

3. Step: Enjoy Battlefield
Please report if it works

Tested with:
- Windows 7 32Bit
- Windows 7 64Bit
- Windows XP 32Bit (Thanks to BigMoser)

How it works:


Normal Start:
When you start Battlefield 2, Steam will write your CDKey in
SOFTWARE\Wow6432Node\Electronic Arts\EA Games\Battlefield 2\ergc
and
SOFTWARE\Wow6432Node\Electronic Arts\EA Games\Battlefield 2 Special Forces\ergc

and then it starts BF2CdKeyCheck.exe and this will crypt it and now BF2 is unable to read it

With this Tool:
When you start Battlefield 2, Steam will write your CDKey in
SOFTWARE\Wow6432Node\Electronic Arts\EA Games\Battlefield 2\ergc
and
SOFTWARE\Wow6432Node\Electronic Arts\EA Games\Battlefield 2 Special Forces\ergc

and then it starts BF2CdKeyCheck.exe, but now this is my tool that will not crypt this Key it will copy it from
SOFTWARE\Wow6432Node\Electronic Arts\EA Games\Battlefield 2\ergc\CDKey
(That what you write with BF2 Key Changer.exe).
So it looks like x9392YOUR-CD-KEY

And now Battlefield can read it.

So the problem is that Steam write your Key every start and with this Tool every start it will get overwritten with your original.
2. Way: Fix by dotDev

Quote:
Originally Posted by dotDev View Post
Thanks again! Here goes the solution not requiring any third party applications:

Step 1: Go to .\Steam\steamapps\common\battlefield 2\ and open installscript.vdf in a text editor of your choice. Make a backup before editing it, in case anything goes wrong! I'm not responsible for any damage the following changes might cause.

Step 2: Look for this:
Code:
"HKEY_LOCAL_MACHINE\\Software\\Electronic Arts\\EA Games\\Battlefield 2\\ergc"
{
	"string"
	{
		"(Default)"		"%CDKEY%"
	}
}
"HKEY_LOCAL_MACHINE\\SOFTWARE\\Electronic Arts\\EA Games\\Battlefield 2 Special Forces\\ergc"
{
	"string"
	{
		"(Default)"		"%CDKEY%"
	}
}
Remove all of it.

Step 3: Right below the portion you just deleted, you should find this snippet:
Code:
"HKEY_LOCAL_MACHINE\\SOFTWARE\\Valve\\Steam\\Apps\\24860"
{
	"dword"
	{
		"BF2 Key"		"0"
		"BF2 XP Key"		"0"
	}
}
Change it to this one:
Code:
"HKEY_LOCAL_MACHINE\\SOFTWARE\\Valve\\Steam\\Apps\\24860"
{
	"dword"
	{
		"BF2 Key"		"1"
		"BF2 XP Key"		"1"
	}
}
Step 4: Lastly, find this and remove it as well:
Code:
"BF2 Key"
{
	"process 1"		"%INSTALLDIR%\\support\\BF2CdKeyCheck.exe"
	"NoCleanUp"		"0"
}
"BF2 XP Key"
{
	"process 1"		"%INSTALLDIR%\\support\\BF2CdKeyCheck.exe"
	"command 1"		"Software\\Electronic Arts\\EA GAMES\\Battlefield 2 Special Forces"
	"NoCleanUp"		"0"
}
Save the file.

Step 5: Now that we got rid of this, it's time to fix your keys in the registry. First, get a hold of your key by right-clicking on Battlefield 2 in the Steam library and then clicking "View game CD key". Copy it to the clipboard, open up notepad and paste it. Now add a dash (-) every four characters and add "x9392" at the very beginning of it. Your key should then look like this:
x9392ABCD-EFGH-IJKL-MNOP-QRST

Copy your key.

Step 6: Open up regedit (Win + R, type "regedit" and hit the enter). Browse to the registry keys of Battlefield 2. On 32-bit systems, this is HKEY_LOCAL_MACHINE\SOFTWARE\Electronic Arts\EA Games\Battlefield 2\. On 64-bit systems, it's HKEY_LOCAL_MACHINE\SOFTWARE\Wow6432Node\Electronic Arts\EA Games\Battlefield 2\.

Now, inside the "Battlefield 2" key there's another one called "ergc". Inside, there's one value. Double-click it and paste your modified key (x9392AND-SO-ON) and hit okay. Do the same with the ergc value in the "Battlefield 2 Special Forces" key.

Step 7: You are done. This should do the trick. Did it for at least. Enjoy! Thanks to GermanDarknes for revealing the issue behind this problem.


On a second note, I'm not sure if all the steps I described for the installscript.vdf are necessary. I went through it and modified everything I thought was important, and it worked. Might work with less changes, not sure.
3. Way: Fix by dotDev, without editing files

Quote:
Download: http://germandarknes.net/content/BF2FixdotDev.zip

1. Step: Move install.vdf to your battlefield 2 dir
default: C:\Program Files\Steam\steamapps\common\battlefield 2\
Overwrite the exiting one

2. Step: Start KeyChangerXXBit.exe (xx = your version!) and type in your CD-Key and press apply
IMPORTANT: Every 4 characters write -
e.g. ABCD-1234-EFGH-5678-IJKL

3. Step: Enjoy Battlefield!

Last edited by GermanDarknes: 04-12-2014 at 01:51 PM.
GermanDarknes is offline  
Reply With Quote
Old 12-26-2010, 08:12 AM   #2
RivaGe
 
 
 
Join Date: Feb 2009
Reputation: 33
Posts: 717
looks totally legit
(not saying you're trying to steal our keys, but I'm not trying this right now)
RivaGe is offline   Reply With Quote
Old 12-26-2010, 08:15 AM   #3
Olav
 
Guest
Posts: n/a
THANK YOU! I seriously love you.

Tested on Windows 7 64 bit and worked LIKE A CHARM.

Someone give this man some rep!

(I have two CD-keys because of all the hassle, so if this one is stolen, meh ;D)
  Reply With Quote
Old 12-26-2010, 08:17 AM   #4
GermanDarknes
 
 
 
Join Date: Aug 2009
Reputation: 49
Posts: 29
OK I released the source, it's written in Delphi7
GermanDarknes is offline   Reply With Quote
Old 12-26-2010, 08:24 AM   #5
MarcBaldy
 
Guest
Posts: n/a
OK I was unsure at first to do this. But its working! Just alt tabbed as its loading up right now.

Thanks alot dude, was waiting for someone smart like you to come along
  Reply With Quote
Old 12-26-2010, 08:28 AM   #6
BigMoser
 
Join Date: Dec 2008
Reputation: 0
Posts: 9
OMGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGG!!! !!!!!

I am so putting this on my other thread!

I was very skeptical at first. Scanned all the files, this is no scam.

I used the 32 bit version on my Windows XP machine and I GOT INTO A RANKED SERVER!!!!

THANK YOU THANK YOU!!!!!!!!!!!!!!!!

(this isn't sarcasm, this guy is a f'n life saver)
BigMoser is offline   Reply With Quote
Old 12-26-2010, 08:32 AM   #7
surfer6boy
 
Guest
Posts: n/a
Windows 7 Ultimate 32bit
works like a charm
thanks alot ^___^
  Reply With Quote
Old 12-26-2010, 08:34 AM   #8
Blazer71
 
Join Date: Apr 2009
Reputation: 37
Posts: 696
Quote:
Originally Posted by RivaGe View Post
looks totally legit
(not saying you're trying to steal our keys, but I'm not trying this right now)
I would say use at your own risk but as I see people are trying it and it works.

Edit: For all of you that are getting it to work, you should rep this guy.

Last edited by Blazer71: 12-26-2010 at 08:49 AM.
Blazer71 is offline   Reply With Quote
Old 12-26-2010, 08:52 AM   #9
dotDev
 
Join Date: Dec 2010
Reputation: 11
Posts: 112
Thank you! Can you explain the magic behind this?
dotDev is offline   Reply With Quote
Old 12-26-2010, 09:00 AM   #10
GermanDarknes
 
 
 
Join Date: Aug 2009
Reputation: 49
Posts: 29
see first post if you really want to know it

Last edited by GermanDarknes: 12-26-2010 at 09:09 AM.
GermanDarknes is offline   Reply With Quote
Old 12-26-2010, 09:06 AM   #11
Xiaminou
 
Join Date: Mar 2009
Reputation: 0
Posts: 18
It really ing works!
Xiaminou is offline   Reply With Quote
Old 12-26-2010, 09:07 AM   #12
Xiaminou
 
Join Date: Mar 2009
Reputation: 0
Posts: 18
Quote:
Originally Posted by LemonMeringueTy View Post
Windows 7 64bit, working here. It's amazing what one community member could do that Steam couldn't. Thanks a billion, +rep.

EDIT: Don't forget to update PunkBuster and disable the Steam Overlay since PB sees it as a cheat (wtf)
Exactly, steam do not care about us!

STICKY THIS THREAD RIGHT NOW!!!!!!
Xiaminou is offline   Reply With Quote
Old 12-26-2010, 09:11 AM   #13
dotDev
 
Join Date: Dec 2010
Reputation: 11
Posts: 112
But why, for s sake, does BF2CdKeyCheck.exe encrypt it anyway? What is that for? Does this file also exist on retail BF2 installations?
dotDev is offline   Reply With Quote
Old 12-26-2010, 09:16 AM   #14
xterminatortr
 
 
 
Join Date: Dec 2010
Reputation: 0
Posts: 6
Or maybe you could also put your serial key manually into your registry and then put that registry key on read-only?
xterminatortr is offline   Reply With Quote
Old 12-26-2010, 09:17 AM   #15
emobabo
 
Guest
Posts: n/a
Can't believe! This really works on my Windows 7 32 Bit!

Wie hast du das geschafft?

Let's spam EA so this guy gets the money instead of those stupid programmers working for EA!!!!!!!!!!!!!

Last edited by emobabo: 12-26-2010 at 09:24 AM.
  Reply With Quote
Reply

Go Back   Steam Users' Forums > Steam Game Discussions > # - C > Battlefield series


Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



All times are GMT -7. The time now is 02:52 AM.


Powered by vBulletin® Version 3.8.7
Copyright ©2000 - 2014, vBulletin Solutions, Inc.
Site Content Copyright Valve Corporation 1998-2012, All Rights Reserved.