Posts Tagged ‘Inno Setup’

Setup Utility

January 31, 2011

Before I forget, I wanted to mention Inno Setup. Back in 2009, I wrote this post describing how I was using Wink as a sort of cut rate installer alternative. As I mentioned then, it was ugly, and a clearly inferior alternative to an actual installation utility. Since then, I found Inno Setup. Inno Setup is great. It’s actually easier to use it to create a real installer than it was to use my Wink-based workaround. All that’s necessary is to adapt the following script, which I used to create the installer for Forgotten Times:

; NOTE: The value of AppId uniquely identifies this application.
; Do not use the same AppId value in installers for other applications.
; (To generate a new GUID, click Tools | Generate GUID inside the IDE.)
AppName=Forgotten Times
;AppVerName=Forgotten Times 1.1
AppPublisher=Morriss, William S.
DefaultDirName={pf}\Forgotten Times
DefaultGroupName=Forgotten Times
SetupIconFile=C:\FT2\Forgotten Times\res\GameEngine.ico

Name: “english”; MessagesFile: “compiler:Default.isl”

Name: “desktopicon”; Description: “{cm:CreateDesktopIcon}”; GroupDescription: “{cm:AdditionalIcons}”; Flags: unchecked
Name: “quicklaunchicon”; Description: “{cm:CreateQuickLaunchIcon}”; GroupDescription: “{cm:AdditionalIcons}”; Flags: unchecked; OnlyBelowVersion: 0,6.1

; Set the source to your root directory
Source: “C:\FT\Forgotten Times\GameEngine.exe”; DestDir: “{app}”; Flags: ignoreversion
Source: “C:\FT\Forgotten Times\*”; DestDir: “{app}”; Flags: ignoreversion recursesubdirs createallsubdirs
; NOTE: Don’t use “Flags: ignoreversion” on any shared system files

; For these icons, to get them to work with your GameEngine.exe you must set ‘WorkingDir:’ to ‘{app}’ because it creates
; local files
Name: “{group}\Forgotten Times”; Filename: “{app}\GameEngine.exe”; WorkingDir: {app}
Name: “{group}\{cm:UninstallProgram,Forgotten Times}”; Filename: “{uninstallexe}”; WorkingDir: {app}
Name: “{commondesktop}\Forgotten Times”; Filename: “{app}\GameEngine.exe”; Tasks: desktopicon; WorkingDir: {app}
Name: “{userappdata}\Microsoft\Internet Explorer\Quick Launch\Forgotten Times”; Filename: “{app}\GameEngine.exe”; Tasks: quicklaunchicon; WorkingDir: {app}

Filename: “{app}\GameEngine.exe”; Description: “{cm:LaunchProgram,Forgotten Times}”; Flags: nowait postinstall skipifsilent