Results 1 to 6 of 6

Thread: Installer/Uninstaller default game location (Uninstaller obsolete)

Threaded View

Previous Post Previous Post   Next Post Next Post
  1. #5
    EB annoying hornet Member bovi's Avatar
    Join Date
    Jan 2007
    Location
    Norway
    Posts
    11,796

    Default Re: Installer/Uninstaller default game location (Uninstaller obsolete)

    To clarify, here's the code:

    Code:
    function GetMedFolder(Param: String): String;
    var
      MedVersion: String;
    begin
      if RegKeyExists(HKEY_LOCAL_MACHINE, 'SOFTWARE\SEGA\Medieval II Total War Kingdoms') then
      begin
            RegQueryStringValue(HKEY_LOCAL_MACHINE, 'SOFTWARE\SEGA\Medieval II Total War', 'AppPath', MedVersion);
            Result := MedVersion;
      end
      else
      begin
        if RegKeyExists(HKEY_LOCAL_MACHINE, 'SOFTWARE\Valve\Steam') then
        begin
          RegQueryStringValue(HKEY_LOCAL_MACHINE, 'SOFTWARE\Valve\Steam', 'InstallPath', MedVersion);
          Result := MedVersion + '\SteamApps\common\medieval ii total war\';
        end
        else
          begin
          if RegKeyExists(HKEY_LOCAL_MACHINE, 'SOFTWARE\Wow6432Node\SEGA\Medieval II Total War') then
          begin
            RegQueryStringValue(HKEY_LOCAL_MACHINE, 'SOFTWARE\Wow6432Node\SEGA\Medieval II Total War', 'InstallPath', MedVersion);
            Result := MedVersion;
          end
          else
          begin
            Result := '[No MII:TW Kingdoms Install Found: You will need to select your "Medieval II Total War" Folder manually]';
          end;
        end;
      end;
    end;
    Basically the installer reads several places in the registry in sequence to find the location of your M2TW installation, choosing the first one it finds. If it's not found in any of these, give up.
    * HKEY_LOCAL_MACHINE\SOFTWARE\SEGA\Medieval II Total War
    * HKEY_LOCAL_MACHINE\SOFTWARE\Valve\Steam
    * HKEY_LOCAL_MACHINE\SOFTWARE\Wow6432Node\SEGA\Medieval II Total War

    So in your case, apparently you have registry entries from your disc install, but are currently using a Steam install instead. Confusion accomplished!

    Having problems getting EB2 to run? Try these solutions.
    ================
    I do NOT answer PM requests for help with EB. Ask in a new help thread in the tech help forum.
    ================
    I think computer viruses should count as life. I think it says something about human nature that the only form of life we have created so far is purely destructive. We've created life in our own image. - Stephen Hawking

    Member thankful for this post:



Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Single Sign On provided by vBSSO