-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathsb-setup.iss
322 lines (276 loc) · 13.8 KB
/
sb-setup.iss
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
; Script generated by the Inno Setup Script Wizard.
; SEE THE DOCUMENTATION FOR DETAILS ON CREATING INNO SETUP SCRIPT FILES!
[Setup]
AppName=Sanny Builder 4
AppVerName=Sanny Builder {#VERSION}
AppPublisherURL=https://sannybuilder.com
AppSupportURL=https://sannybuilder.com
AppUpdatesURL=https://sannybuilder.com
DefaultDirName={userpf}\Sanny Builder 4
DefaultGroupName=Sanny Builder 4
AllowNoIcons=yes
OutputBaseFilename=SannyBuilder-v{#VERSION}
SetupIconFile=sanny_v4.ico
Compression=lzma
SolidCompression=yes
VersionInfoVersion=1.00
ShowUndisplayableLanguages=yes
PrivilegesRequired=none
LicenseFile=..\..\Release\eula.txt
UsePreviousAppDir=no
[Languages]
Name: "english"; MessagesFile: "compiler:Default.isl"
Name: "dutch"; MessagesFile: "compiler:Languages\Dutch.isl"
Name: "french"; MessagesFile: "compiler:Languages\French.isl"
Name: "german"; MessagesFile: "compiler:Languages\German.isl"
Name: "polish"; MessagesFile: "compiler:Languages\Polish.isl"
Name: "russian"; MessagesFile: "compiler:Languages\Russian.isl"
Name: "italian"; MessagesFile: "compiler:Languages\italian.isl"
Name: "portuguese"; MessagesFile: "compiler:Languages\BrazilianPortuguese.isl"
Name: "spanish"; MessagesFile: "compiler:Languages\Spanish.isl"
Name: "ukrainian"; MessagesFile: "compiler:Languages\Ukrainian.isl"
Name: "finnish"; MessagesFile: "compiler:Languages\Finnish.isl"
Name: "czech"; MessagesFile: "compiler:Languages\Czech.isl"
Name: "turkish"; MessagesFile: "compiler:Languages\Turkish.isl"
[CustomMessages]
; --------------------------------
_ass1 = SCM files association
_ass2 = Want to associate .scm files with Sanny Builder?
_ass3 = Check this box if you want to associate .scm file extension with Sanny Builder
_ass4 = Associate .SCM files with Sanny Builder?
russian._ass1 = Сделать редактором по умолчанию
russian._ass2 = Хотите ассоциировать расширение .scm с Sanny Builder?
russian._ass3 = Поставьте галочку, если вы хотите по умолчанию открывать .scm-файлы %n в Sanny Builder
russian._ass4 = Ассоциировать .scm-файлы с Sanny Builder?
french._ass1 = Associer le fichiers SCM
french._ass2 = Vouler vous associer les fichier .SCM avec Sanny Builder?
french._ass3 = Cochez cette case si vous vouler associer les fichiers .SCM avec Sanny Builder.
french._ass4 = Associer les fichiers .SCM avec Sanny Builder?
polish._ass1 = Współpraca z plikami SCM
polish._ass2 = Chcesz powiązać pliki .scm z Sanny Builder?
polish._ass3 = Zaznacz jeśli chcesz powiązać pliki .scm z Sanny Builder
polish._ass4 = Powiązać pliki .SCM z Sanny Builder?
italian._ass1 = Associazione file SCM
italian._ass2 = Vuoi associare i file .scm al Sanny Builder?
italian._ass3 = Spunta la casella se vuoi associare i file .scm al Sanny Builder
italian._ass4 = Associare i file .SCM al Sanny Builder?
portuguese._ass1 = Associacao com os arquivos SCM
portuguese._ass2 = Voce gostaria de asscoiar os arquivo .scm com Sanny Builder?
portuguese._ass3 = Marque esta caixa se voce quer associar a extensao .scm com o Sanny Builder
portuguese._ass4 = Associaar os arquivo .SCM com Sanny Builder?
; --------------------------------
_dir1 = Game directory location
_dir2 = Where is the game installed?
_dir3 = Locate your game directory (either GTA 3, Vice City or San Andreas).%n Leave it blank if the game is not installed.%n If you locate the game directory, you will be able to install the CLEO library
russian._dir1 = Путь к игре
russian._dir2 = Куда была установлена игра?
russian._dir3 = Укажите путь к папке игры (GTA3, Vice City или San Andreas).%n Оставьте поле пустым, если игра не установлена.%n Если вы укажете путь к игре, вы сможете также установить библиотеку CLEO
french._dir1 = Location du dossier du jeu
french._dir2 = OU le jeu est-il installй ?
french._dir3 = Dйfinisser le chemin d'accиs du jeu (GTA 3, Vice City or San Andreas).%n Laisser le champ blanc si le jeu n'est pas instйllй.%n Si vous dйfinisser la dossier du jeu, vous pourrez installer la bibliothиque CLEO
polish._dir1 = Ścieżka do katalogu gry
polish._dir2 = Gdzie gra jest zainstalowana?
polish._dir3 = Wskaż ścieżkę do katalogu gry (GTA III, Vice City lub San Andreas).%nPozostaw to pole puste jeśli nie masz zainstalowanej gry.%nJeśli wskażesz katalog gry, będziesz mógł zainstalować bibliotekę CLEO
italian._dir1 = Locazione cartella del gioco
italian._dir2 = Dove и installato il gioco?
italian._dir3 = Determina la locazione della cartella del gioco (GTA 3, Vice City o San Andreas).%n Lascia vuoto se il gioco non и installato.%n Se determini la locazione della cartella del gioco, potrai installare la CLEO library
portuguese._dir1 = Diretorio da localizacao do jogo
portuguese._dir2 = Onde o jogo esta instalado?
portuguese._dir3 = Localize o diretorio do seu jogo (tambem GTA 3, Vice City or San Andreas).%n Deixe em brnco se o jogo nao esta instalado.%n Se voce colocou o diretorio do jogo, voce ira instalar tambem a livraria CLEO
; --------------------------------
_cleo1 = CLEO Library Installation
_cleo2 = Should the CLEO library be installed?
_cleo3 = Check this box if you want to install CLEO library
_cleo4 = Install CLEO library?
russian._cleo1 = Установка CLEO
russian._cleo2 = Должна библиотека CLEO быть установленной?
russian._cleo3 = Поставьте галочку, если вы желаете установить библиотеку CLEO
russian._cleo4 = Установить библиотеку CLEO?
french._cleo1 = Installation de CLEO
french._cleo2 = Voulez vous installer la bibliothиque CLEO?
french._cleo3 = Cochez cette case si vous vouler installer la bibliothиque CLEO.
french._cleo4 = Installer la bibliothиque CLEO?
polish._cleo1 = Instalacja CLEO
polish._cleo2 = Czy biblioteka CLEO ma być zainstalowana?
polish._cleo3 = Zaznacz jeśli chcesz zainstalować bibliotekę CLEO
polish._cleo4 = Zainstalować bibliotekę CLEO?
italian._cleo1 = Installazione CLEO
italian._cleo2 = Dovrebbe essere installata la CLEO library?
italian._cleo3 = Spunta la casella se vuoi installare la CLEO library
italian._cleo4 = Installare la CLEO library?
portuguese._cleo1 = Instalacao do CLEO
portuguese._cleo2 = Voce deseja que a livraria CLEO seja instalada?
portuguese._cleo3 = Marque esta caixa se voce deseja instalar a livraria CLEO
portuguese._cleo4 = Instalar a livraria CLEO?
[Tasks]
Name: "desktopicon"; Description: "{cm:CreateDesktopIcon}"; GroupDescription: "{cm:AdditionalIcons}"; Flags: unchecked
Name: "quicklaunchicon"; Description: "{cm:CreateQuickLaunchIcon}"; GroupDescription: "{cm:AdditionalIcons}"; Flags: unchecked
[Messages]
;BeveledLabel=Sanny Builder Installer
;[Types]
;Name: "full"; Description: "Full installation"
;Name: "compact"; Description: "Compact installation"
;Name: "custom"; Description: "Custom installation"; Flags: iscustom
[Components]
;Name: "program"; Description: "Program Files"; Types: full compact custom; Flags: fixed;
; help
;Name: "help"; Description: "{cm:PrefHelp}"; Types: full compact custom;
;Name: "help\en"; Description: "{cm:PrefHelpEn}"; Types: full;
;Name: "help\ru"; Description: "{cm:PrefHelpRu}"; Types: full; Languages: russian;
; lang
;Name: "lang"; Description: "{cm:PrefLang}"; Types: full compact custom;
;Name: "lang\en"; Description: "English"; Types: full compact custom; Flags: fixed;
;Name: "lang\ru"; Description: "Russian"; Types: full compact; Languages: russian;
;Name: "lang\pl"; Description: "Polish"; Types: full
;Name: "lang\de"; Description: "Deutch"; Types: full
;Name: "lang\fr"; Description: "French"; Types: full
;Name: "lang\nl"; Description: "Dutch"; Types: full
[Files]
Source: "..\..\Release\sanny.exe"; DestDir: "{app}"; Flags: ignoreversion;
Source: "..\..\Release\EULA.txt"; DestDir: "{app}"; Flags: ignoreversion;
Source: "install.exe"; DestDir: "{app}"; Flags: deleteafterinstall;
;Flags: dontcopy;
; NOTE: Don't use "Flags: ignoreversion" on any shared system files
Source: "..\..\Release\*"; Excludes: ".git\*,.gitignore,data\settings.ini,*.md,setup.bat,*.log,*.zip"; DestDir: "{app}\"; Flags: ignoreversion recursesubdirs;
[Dirs]
;Name: "{app}"; Components: program
Name: "{app}\data";
Name: "{app}\lang";
Name: "{app}\tools";
Name: "{app}\help";
Name: "{app}\updates";
[Icons]
Name: "{group}\Sanny Builder 4"; Filename: "{app}\sanny.exe"
Name: "{group}\{cm:ProgramOnTheWeb,Sanny Builder 4}"; Filename: "https://sannybuilder.com"
Name: "{group}\{cm:UninstallProgram,Sanny Builder 4}"; Filename: "{uninstallexe}"
Name: "{commondesktop}\Sanny Builder 4"; Filename: "{app}\sanny.exe"; Tasks: desktopicon
Name: "{userappdata}\Microsoft\Internet Explorer\Quick Launch\Sanny Builder 4"; Filename: "{app}\sanny.exe"; Tasks: quicklaunchicon
[Run]
Filename: "{app}\sanny.exe"; Description: "{cm:LaunchProgram,Sanny Builder 4}"; Flags: nowait postinstall skipifsilent
[Code]
var
AssociatePage, GameFolderView, CLEO3Install: TWizardPage;
AssociateCheckBox, CLEO3CheckBox: TCheckBox;
AssociateLabel, GameFolderLabel, CLEO3Label: TLabel;
GameFolderTreeView: TFolderTreeView;
GameFolderEdit: TEdit;
ParamLine: String;
const
GameDirDefault = '\Rockstar Games\San Andreas';
procedure MakeAddInstall;
var
ResultCode: Integer;
begin
ParamLine := '"' + ExpandConstant('{app}') + '" ';
if AssociateCheckBox.Checked then
ParamLine := ParamLine + '-a ';
if GameFolderEdit.Text <> '' then
ParamLine := ParamLine + '-g "' + GameFolderEdit.Text + '" ';
if CLEO3CheckBox.Checked then
ParamLine := ParamLine + '-c ';
if ActiveLanguage = 'english' then
ParamLine := ParamLine + '-l 1033'
else
if ActiveLanguage = 'dutch' then
ParamLine := ParamLine + '-l 1043'
else
if ActiveLanguage = 'russian' then
ParamLine := ParamLine + '-l 1049'
else
if ActiveLanguage = 'german' then
ParamLine := ParamLine + '-l 1031'
else
if ActiveLanguage = 'polish' then
ParamLine := ParamLine + '-l 1045'
else
if ActiveLanguage = 'french' then
ParamLine := ParamLine + '-l 1036'
else
if ActiveLanguage = 'italian' then
ParamLine := ParamLine + '-l 1040'
else
if ActiveLanguage = 'portuguese' then
ParamLine := ParamLine + '-l 1046'
else
if ActiveLanguage = 'spanish' then
ParamLine := ParamLine + '-l 3082'
else
if ActiveLanguage = 'hungarian' then
ParamLine := ParamLine + '-l 1038'
else
if ActiveLanguage = 'finnish' then
ParamLine := ParamLine + '-l 1035'
else
if ActiveLanguage = 'ukrainian' then
ParamLine := ParamLine + '-l 1058'
else
if ActiveLanguage = 'czech' then
ParamLine := ParamLine + '-l 1029';
if ActiveLanguage = 'turkish' then
ParamLine := ParamLine + '-l 1055';
Exec(ExpandConstant('{app}\install.exe'), ParamLine, ExpandConstant('{app}'), SW_HIDE, ewWaitUntilTerminated, ResultCode);
end;
procedure ViewChange(Sender: TObject);
begin
GameFolderEdit.Text := GameFolderTreeView.Directory;
end;
procedure InitializeWizard();
begin
// SCM FILE ASSOCIATION PAGE
AssociatePage := CreateCustomPage(wpSelectTasks, ExpandConstant('{cm:_ass1}'), ExpandConstant('{cm:_ass2}'));
AssociateLabel := Tlabel.Create(AssociatePage);
AssociateLabel.Top := ScaleY(0);
AssociateLabel.Caption := ExpandConstant('{cm:_ass3}')
AssociateLabel.AutoSize := True;
AssociateLabel.Parent := AssociatePage.Surface;
AssociateCheckBox := TCheckBox.Create(AssociatePage);
AssociateCheckBox.Top := AssociateLabel.Top + AssociateLabel.Height + ScaleX(10);
AssociateCheckBox.Width := AssociatePage.SurfaceWidth;
AssociateCheckBox.Height := ScaleY(17);
AssociateCheckBox.Caption := ExpandConstant('{cm:_ass4}');
AssociateCheckBox.Checked := False;
AssociateCheckBox.Parent := AssociatePage.Surface;
// GAME FOLDER LOCATION PAGE
GameFolderView := CreateCustomPage(AssociatePage.ID, ExpandConstant('{cm:_dir1}'), ExpandConstant('{cm:_dir2}'));
GameFolderLabel := Tlabel.Create(GameFolderView);
GameFolderLabel.Caption := ExpandConstant('{cm:_dir3}')
GameFolderLabel.AutoSize := True;
GameFolderLabel.Parent := GameFolderView.Surface;
GameFolderEdit := TEdit.Create(GameFolderView);
GameFolderEdit.Top := GameFolderLabel.Top + GameFolderLabel.Height + ScaleX(10);
GameFolderEdit.Width := GameFolderView.SurfaceWidth;
GameFolderEdit.Parent := GameFolderView.Surface;
// GameFolderEdit.Text := ExpandConstant('{pf}') + GameDirDefault;
GameFolderTreeView := TFolderTreeView.Create(GameFolderView);
GameFolderTreeView.Width := GameFolderView.SurfaceWidth;
GameFolderTreeView.Top := GameFolderEdit.Height + GameFolderEdit.Top + ScaleY(10);
GameFolderTreeView.Height := GameFolderView.SurfaceHeight - GameFolderTreeView.Top;
GameFolderTreeView.Parent := GameFolderView.Surface;
GameFolderTreeView.Directory := ExpandConstant('{pf}') + GameDirDefault;
GameFolderTreeView.OnChange := @ViewChange;
// CLEO 3 INSTALL PAGE
CLEO3Install := CreateCustomPage(GameFolderView.ID, ExpandConstant('{cm:_cleo1}'), ExpandConstant('{cm:_cleo2}'));
CLEO3Label := Tlabel.Create(CLEO3Install);
CLEO3Label.Top := ScaleY(0);
CLEO3Label.Caption := ExpandConstant('{cm:_cleo3}')
CLEO3Label.AutoSize := True;
CLEO3Label.Parent := CLEO3Install.Surface;
CLEO3CheckBox := TCheckBox.Create(CLEO3Install);
CLEO3CheckBox.Top := CLEO3Label.Top + CLEO3Label.Height + ScaleX(10);
CLEO3CheckBox.Width := CLEO3Install.SurfaceWidth;
CLEO3CheckBox.Height := ScaleY(17);
CLEO3CheckBox.Caption := ExpandConstant('{cm:_cleo4}');
CLEO3CheckBox.Checked := True;
CLEO3CheckBox.Parent := CLEO3Install.Surface;
end;
function ShouldSkipPage(PageID: Integer): Boolean;
begin
if (PageID = CLEO3Install.ID) and (GameFolderEdit.Text = '') then
Result := True
else
Result := False;
end;
procedure CurStepChanged(CurStep: TSetupStep);
begin
if CurStep = ssPostInstall then MakeAddInstall;
end;