View Single Post
  #5  
Old 07-08-2012, 09:21
REV0 REV0 is offline
Banned
 
Join Date: Nov 2010
Location: Hawaii
Posts: 998
Thanks: 63
Thanked 1,851 Times in 292 Posts
REV0 is on a distinguished road
IIID. Internal-External Setups, Registry Keys

a) Internal Installation

This is activated by removing semicolon ( ; ) from following line in script:

Code:
;#define ProgramFiles "F:\Program Files (x86)\Atari\TDU2"
By removing semicolon from this, you will 'authorize' INNO setup to create it's own .bin files according to diskspan(not spam) and compression ratio.

INNO Setup will compress files in given path (in this example; TDU2). It will compress them regardless the content or anything else, so using internal setups in conversions is easy and effective solution.

b) External Installation

By keeping semicolon, you'll create only base files (setup.exe, .ico, trasferring of any changing to exe)

This type of installation will give converter more possibilites about compressions. Since you cant do precomp+srep+lzma at the same time in INNO, using external inst. is more logic. You can compress files better than INNO's compression, however beware; it'll take more time to create conversion and also install the game.

For example, converting MaxPayne 3 with all types of compressions took 12 hours and more than 1 hour to install.

c) Registry Keys:

Another important feature of INNO Setup. No matter how you install the game, you will need registry keys. Adding them may look complicated, however it's easy as other stuff in INNO.

First of all find your game in your Registry Editor. (In our example we'll work on Test Driver Unlimited 2):



Once you found your data, open INNO script and found registry section. Normally you will find default uninstall registry key in there. Copy it, paste it, and edit it along adding regkeys. However DO NOT delete it.

In your registry editor, you will find 3 columns; Name, Type, Data.

Root: HKLM; SubKey: "SOFTWARE\{code:GetAppPublisher}\{code:GetAppName} "; ValueName: UninstallString; ValueData: {uninstallexe}; ValueType: string; Flags: UninsDeleteKey;

Subkey corresponds the path of registry key, so we will not touch it.

ValueName corresponds 'Name' in your registry editor. You will edit this according to your registry key in OS. 'Exepath, InstallDir' are our ValueNames in here.

ValueData corresponds 'Data' in Registry Editor. According to conversion, this can be numbers, game path, or simply a command. If you're working on multiple language supported game, it's better to add all possible languages to it.

If you need to add number or letter, you'll type it directly without these ' {} '

ValueType is generaly remains same, so i'll pass this, same goes for Flags.

So in the end, our Registrykeys about TDU2 will look like this (Attention to multiple language keys and how they're looking):

Code:
Root: HKLM; SubKey: "SOFTWARE\{code:GetAppPublisher}\{code:GetAppName}"; ValueName: UninstallString; ValueData: {uninstallexe}; ValueType: string; Flags: UninsDeleteKey;
Root: HKLM; SubKey: "SOFTWARE\{code:GetAppPublisher}\{code:GetAppName}"; ValueName: ExePath; ValueData: {app}\{code:GetMyAppExePath}\{code:GetMyAppExeName}; ValueType: string; Flags: UninsDeleteKey;
Root: HKLM; SubKey: "SOFTWARE\{code:GetAppPublisher}\{code:GetAppName}"; ValueName: InstallDir; ValueData: {app}\{code:GetMyAppExePath}; ValueType: string; Flags: UninsDeleteKey;
Root: HKLM; SubKey: "SOFTWARE\{code:GetAppPublisher}\{code:GetAppName}"; ValueName: LanguagePack; ValueData: EU; ValueType: string; Flags: UninsDeleteKey;
Root: HKLM; SubKey: "SOFTWARE\{code:GetAppPublisher}\{code:GetAppName}"; ValueName: LauncherPath; ValueData: {app}\{code:GetMyAppExePath}\UpLauncher.exe; ValueType: string; Flags: UninsDeleteKey;
Root: HKLM; SubKey: "SOFTWARE\{code:GetAppPublisher}\{code:GetAppName}"; ValueName: Language; ValueData: en; ValueType: string; Flags: UninsDeleteKey; Languages: eng;
Root: HKLM; SubKey: "SOFTWARE\{code:GetAppPublisher}\{code:GetAppName}"; ValueName: Language; ValueData: fr; ValueType: string; Flags: UninsDeleteKey; Languages: fre;
Root: HKLM; SubKey: "SOFTWARE\{code:GetAppPublisher}\{code:GetAppName}"; ValueName: Language; ValueData: de; ValueType: string; Flags: UninsDeleteKey; Languages: ger;
Root: HKLM; SubKey: "SOFTWARE\{code:GetAppPublisher}\{code:GetAppName}"; ValueName: Language; ValueData: it; ValueType: string; Flags: UninsDeleteKey; Languages: ita;
Root: HKLM; SubKey: "SOFTWARE\{code:GetAppPublisher}\{code:GetAppName}"; ValueName: Language; ValueData: sp; ValueType: string; Flags: UninsDeleteKey; Languages: esp;

Last edited by REV0; 07-08-2012 at 10:21.
Reply With Quote
The Following 9 Users Say Thank You to REV0 For This Useful Post:
mamed3000 (19-09-2015), mausschieber (09-03-2013), mconstantine (17-12-2014), MMR (21-02-2013), pakrat2k2 (13-02-2013), RoxorProject (06-09-2013), samer1 (08-09-2014), Shadow Delta (22-05-2014), zougjaysean (21-06-2013)