Hidden & Dangerous 2: Courage Under Fire

Hidden & Dangerous 2: Courage Under Fire

Not enough ratings
Solution for missing CD key
By CZBGR Icepick
This is the solution to the missing CD key for those who can't run the game when the error window pops up.
   
Award
Favorite
Favorited
Unfavorite
Introduction
Some folks over the years have encountered a perplexing issue where an error message pops up advising that a CD key is missing. I happen to have found my own solution to this through a bit of investigating while trying to figure how to plug it in on my old Windows XP machine, just like the way it used to be (my first exposure to this franchise was with Hidden & Dangerous Deluxe, which was freeware at the time).

I don't know if it's because most folks don't have this issue because they use Steam directly, but the part of the problem affects those who are just opening the game directly, which is where things appear to go wrong.

It's not very complicated to deal with at all. It doesn't cost you an arm and a leg to fix the problem. There isn't a CD key that you should be looking for, and you don't need to email support for it. It's something you have to produce yourself. This is simply a matter of getting your computer's registry entry for the game properly situated to run the game.

This guide is mainly geared for Windows machines. Other machines might be similar, as long as you basically have the information contained within the registry key, I don't foresee extra issues.
Getting the CD Key Automatically
My simple, most uncomplicated method for getting the CD key is to....just open it through Steam. That easy! This is really the important step you have to do to get it to run, at least in a simple way.

What happens is that when when you use Steam to run it, your CD key is produced in the registry. Theoretically, you could manually create this registry entry yourself, but there are some complicated bits in it that's not just the CD key for it to work. You don't want to be typing all of that, unless you have the time and knowledge of its contents.

Using Steam is the simplest way to get the CD key without needing to bother anyone on the forums or tech support, since it's a digital download, and not through the fashion of a retail install. Since you have your CD key, you're free to open the game directly, or even also use the registry itself for use on other machines.
Further Use of the Registry Key
For the case of using the registry that contains the CD key for other machines (such as Windows XP like I did), the process is straightforward.

However you produced the CD key (either manually through some miraculous knowledge of its contents, or simply through Steam), you'll need to use the export function to save the key as a one-stop shop solution to installing and running the game.

  • First, of course, install the game wherever you want to install it (if you're not using Steam or don't have Steam to your destination machine, simply copy/paste the original game files).

  • Next, you'll need the CD key plugged in to the machine you want to use. To do this, once you have the registry key produced, open your registry editor (regedit) if you have not opened this already, and look to the "HKEY_LOCAL_MACHINE\SOFTWARE\Illusion Softworks\Hidden & Dangerous 2" path for 32bit machines. For 64bit machines, look in "HKEY_LOCAL_MACHINE\SOFTWARE\WOW6432Node\Illusion Softworks\Hidden & Dangerous 2".

  • Simply either right-click the "Hidden & Dangerous 2" item from the tree/list on the left panel or, when selected, use the menu ribbon and select "File > Export...".

  • You can name the file however you want (as long as you know what it is to properly use it).

The next bit is the fun part. When you're ready to use it on the machine you want to play the game, you'll want to do some editing of the file in case you're using a machine with a different architecture.

To do this, you'll want to open the registry file with a text editor (do not left click it yet!). Either use your text editor directly and open the file from there, or, right-click on the file itself and click "Edit" from the menu.

Once you've opened the file for editing, the only thing you need to change is the "[HKEY_LOCAL_MACHINE\SOFTWARE\..." part. For example, if your original install (with the Steam-run machine) is a 32bit machine, and you want to play it on the machine with the 64bit architecture, you'll want to add "WOW6432Node\" in the path between "SOFTWARE" and "Illusion Softworks" (so that it should read as: "["HKEY_LOCAL_MACHINE\SOFTWARE\WOW6432Node\Illusion Softworks\Hidden & Dangerous 2"]")

If your situation is the inverse, simply remove the "WOW6432Node\" bit.

You'll not need to make any changes for any machine with the same architecture. Your job is done from here.

After all that not-so-hard work, put the exported copy of the registry file on the machine you want to use. First making sure you've satisfied the requisites mentioned above (though it really shouldn't be that much of an issue, it can be corrected and you can just delete the offending registry if you've made a mistake), double click it, accept any prompts to approve the registry's registry, and you're done!
Notes
I don't recall if the first game had this CD key issue. However, the method for getting the game installed and running without Steam with the registry keys to act as if you installed it directly on the machine is pretty much the same story as above. Again, simply repeat the steps above, and edit the registry path if you're dealing with a computer with a different architecture. Otherwise, don't change anything if they're the same architecture. Easy!