PDA

View Full Version : Glass Black Box Inno Setup Script Unicode


y_thelastknight
29-10-2013, 23:29
Support


Precomp 0.38 - 0.42
Srep
7Zip
Rar


Tutorials/Instructions


Download attachment file and extract to a folder.
Open Setup.ini file in output folder and change Appname, Publisher, Version, Size, Exec.
Compress your Games and create archives.
In Setup.ini change archive files names.
[FreearcFile1]
Archive={src}\data.arc
Output={app}\
Disk=1
;Password=123

Archive file Number
Archive name
Which Disk your Archive is
Password of your archvie file
In Setup.ini change Redist Name, Command, Parameter (Only 3 Redist Supports)
Copile the Script.iss in main folder



Changelog

Version v1.4.1_C(Customized Version)

-Fixed Some bug.
-Fixed Shortcut error (thanks to hackjack).
-Added 2nd Shortcut to Desktop and Start menu.
-Added Percentage in Tittle.
-Added Video.
-Added Splash.
-Added Some Button Sounds.
-Added Redist ProgressBar

Version v1.4.1(Original Version)

-Fixed Some bug.
-Fixed Shortcut error (thanks to hackjack).
-Added 2nd Shortcut to Desktop and Start menu.
-Added Percentage in Tittle.

Script by
y_thelastknight
Razor12911 (http://fileforums.com/member.php?u=196265)

Special Thanks to pakrat2k2


Note - Try this Tool (http://fileforums.com/showthread.php?t=95288)for Compressing archives. (Updated to 2.2.0)
If you get error when you compile use Inno Setup Enhanced Version (http://fileforums.com/showpost.php?p=429689&postcount=72)

Preview
http://imageshack.us/a/img46/1913/kkcl.jpg
http://imageshack.us/a/img201/1350/l99y.jpg
http://imageshack.us/a/img5/9599/ha85.jpg
http://imageshack.us/a/img542/8355/cb0n.jpg

sentinelks
29-10-2013, 23:51
Great job, nice code :)

http://prntscr.com/20pbkk

y_thelastknight
30-10-2013, 04:51
@loitha, @varma1993 Chk the 1st post

@sentinelks, im not a pro dude. just a noob trying to improve thing with mistakes so will make a mistakes if your know how to fix it explain me..( it works fine for me )

sentinelks
30-10-2013, 06:41
y_thelastknight

and oh! I believe that already include with / *. * is a wrong method, the rest I should check your script but I'm busy with my codes for now :)

loitha
30-10-2013, 09:33
im sorry im noob here..
how about compressing to 2DVD or more ?

y_thelastknight
30-10-2013, 10:11
im sorry im noob here..
how about compressing to 2DVD or more ?

For 1dvd
[FreearcFile1]
Archive={src}\data1.arc
Output={app}\
Disk=1
;Password=123

For 2dvd
[FreearcFile2]
Archive={src}\data2.arc
Output={app}\
Disk=2
;Password=123

For 3dvd
[FreearcFile3]
Archive={src}\data3.arc
Output={app}\
Disk=3
;Password=123

Red color are the changes you have to do create multiple dvds

loitha
30-10-2013, 16:44
thx sir..
and how to create multiple archive for another DVD?
the compressor just do one archive or is there another setting that i miss?
sorry my eng :)

y_thelastknight
31-10-2013, 05:41
thx sir..
and how to create multiple archive for another DVD?
the compressor just do one archive or is there another setting that i miss?
sorry my eng :)

compressor doesn't do that. you have to manually separate the files.

jksengko
31-10-2013, 06:05
how to set 2 or more icon ?

jksengko
31-10-2013, 06:56
how to add more redist?

loitha
31-10-2013, 07:30
i have this error when i mount dvd2 of the game..
how to fix?

y_thelastknight
31-10-2013, 09:07
how to set 2 or more icon ?
how to add more redist?
Will be added.

i have this error when i mount dvd2 of the game..
how to fix?

What did you do.

Razor12911
31-10-2013, 09:26
Nice one mate. great team work creating this. Compressor Black Edition is coming and will add all the required features this script has.
Cheers

loitha
31-10-2013, 16:00
What did you do.

i make 2 archive(data1.arc on dvd1 and data2.arc on dvd2)
the installer goes well on dvd1 but when it ask for disk 2 i found those error..
edit: my mistake, now works perfect

varma1993
01-11-2013, 02:56
how to hide password from setup.ini

y_thelastknight
04-11-2013, 00:01
Version v1.2.0 Avaliable


Changes

-Fixed some bug
-Updated Custom Component section
__________________

y_thelastknight
04-11-2013, 03:40
how to hide password from setup.ini

There is no option for it.

ashyamsundar
04-11-2013, 23:00
1) Splash screen ?
2) any way to integrate setup.ini to setup.exe ?
3) music ?

sentinelks
04-11-2013, 23:34
1) Splash screen ?
2) any way to integrate setup.ini to setup.exe ?

copy file: Splash.png and isgsg.dll, to include folder

triviet4
05-11-2013, 11:16
I want DirectX, Visual C++ ... All Checked Default, how?

How All ready checked?

y_thelastknight
05-11-2013, 11:57
I want DirectX, Visual C++ ... All Checked Default, how?

All ready checked, don't check

i didn't understand you..do you want checked all or don't check

if you want all checked then find these lines

ShortcutCB := TNewCheckBox.Create(WizardForm);
with ShortcutCB do
begin

DirectXCB := TNewCheckBox.Create(WizardForm);
with DirectXCB do
begin

VisualCCB := TNewCheckBox.Create(WizardForm);
with VisualCCB do
begin

SocialCB := TNewCheckBox.Create(WizardForm);
with SocialCB do
begin

and paste this line under those line..

triviet4
05-11-2013, 15:55
i want all checked

i found those line


ShortcutCB := TNewCheckBox.Create(WizardForm);
with ShortcutCB do
begin
Parent := WizardPanel;
Left :=(116);
Top :=(299);
Width := ScaleX(14);
Height := ScaleY(14);
end;



DirectXCB := TNewCheckBox.Create(WizardForm);
with DirectXCB do
begin
Parent := WizardPanel;
Left :=(116);
Top :=(320);
Width := ScaleX(14);
Height := ScaleY(14);
end;



VisualCCB := TNewCheckBox.Create(WizardForm);
with VisualCCB do
begin
Parent := WizardPanel;
Left :=(250);
Top :=(320);
Width := ScaleX(14);
Height := ScaleY(14);
end;


SocialCB := TNewCheckBox.Create(WizardForm);
with SocialCB do
begin
Parent := WizardPanel;
Left :=(410);
Top :=(320);
Width := ScaleX(14);
Height := ScaleY(14);
end;



but paste what line? under those line..
can you details, please?

SORRY, MY ENGLISH'S BAD

sentinelks
05-11-2013, 23:01
triviet4

all checked yes

copy in:
if CurPageID=wpSelectDir then
begin
DirectXCB.Checked:=True;
VisualCCB.Checked:=True;
SocialCB.Checked:=True;
ShortcutCB.Checked:=True;

CheckAll
DirectXCB.Checked:=True;
VisualCCB.Checked:=True;
SocialCB.Checked:=True;
ShortcutCB.Checked:=True;
-------------------------------------------

Enabled True or False
True..
DirectXCB.Enabled:=True;
VisualCCB.Enabled:=True;
SocialCB.Enabled:=True;
ShortcutCB.Enabled:=True;
False..
DirectXCB.Enabled:=False;
VisualCCB.Enabled:=False;
SocialCB.Enabled:=False;
ShortcutCB.Enabled:=False;

varma1993
06-11-2013, 00:08
please add video to this script

sentinelks
06-11-2013, 04:58
please add video to this script

Test Video and Slides done

sentinelks
06-11-2013, 07:30
Sript Video-Slides-Audio by y_thelastknight and Razor1911
http://fileforums.com/showpost.php?p=425535&postcount=118

triviet4
06-11-2013, 07:59
i'm question
i'm DiskSpanning

DiskSpanning=yes
DiskSliceSize=1566000000
SlicesPerDisk=3

DVD1: Setup-1a, 1b, 1c
DVD2: Setup-2a, 2b, 2c

But when setup DVD1, error... Please insert disk 2... (not found File Setup-2c)
How fix this error?

y_thelastknight
06-11-2013, 08:31
But when setup DVD1, error... Please insert disk 2... (not found File Setup-2c)
How fix this error?

dude add you file code under the slides code..

[files]
Source: Include\*.*; Flags: dontcopy;
///Dont put YourCode here//
#define i 0
#ifexist "Slides\1.jpg"
#sub AddFile
Source: Slides\{#i}.jpg; DestDir: {tmp}; Flags: dontcopy;
#endsub
#for {i = 1; FileExists(StringChange("Slides\FileName.jpg", "FileName", Str(i))) != 0; i++} AddFile
#endif

///Put It Here//


y_thelastknight Accepted for the password of Video & Slides

Please Post The Password

Wait, script will be uploaded.

varma1993
07-11-2013, 04:09
LoL, Permission granted.
Also PM me the password.

Thx For The Video-Slides Script

And If Possible please Add the Video&Slides button like shown in the picture

http://s23.postimg.org/lyi0n8ljv/Capture_Copy.jpg

Thx For This Script

sentinelks
07-11-2013, 04:16
Thx For The Video-Slides Script

And If Possible please Add the Video&Slides button like shown in the picture

http://s23.postimg.org/lyi0n8ljv/Capture_Copy.jpg

Thx For This Script



anything is possible .. soon ;)

varma1993
07-11-2013, 04:51
anything is possible .. soon ;)

Plz Include Setup Icon & Splash in that script thx

jksengko
07-11-2013, 06:12
how to set install on desktop no by disc ?

georg1136
07-11-2013, 06:53
Plz Include Setup Icon & Splash in that script thx

For the icon just write this to the script:

icon=icon destination folder\your icon name.ico

varma1993
08-11-2013, 02:10
Directx& Vcx86 Redists Not Installing

syntax Command Line Error

Plz Help

aj12345
27-11-2013, 07:29
1.Its posibile ad 2 or more language
2.Pleas add buton
http://s5.postimg.org/f32ebkzev/Untitled.png
Sori for bad English

aj12345
28-11-2013, 14:53
How to rename Configure in Подешаваља
http://s5.postimg.org/awm59zp6v/Untitled.jpg

sentinelks
28-11-2013, 15:21
aj12345

your language.isl and [CustomMessages]

aj12345
29-11-2013, 02:00
I do not understand what I have to do with customMesage my language is SerbianCyrillic.isl.
I have to translate:Configure,Begin Install,<<Welcome to Setup Wizard>>,<<Setup Wizard Configuration>>,From here you can change the setup configuration

sentinelks
29-11-2013, 03:09
[Languages]
Name: Serbian; MessagesFile: Include\SerbianCyrillic.isl, Include\SerbianCM.isl; method1


method 2
[CustomMessages]
Serbian.Configure= Configure in your lng
Serbian.BeginInstall=Begin Install in your lng



example:
Default eng is
WizardForm.NextButton.Caption := 'Configure';
Customm is
WizardForm.NextButton.Caption := ExpandConstant('{cm:configure}');





SerbianCM you must create the file with your translation of: Configure,Begin Install,<<Welcome to Setup Wizard>>,<<Setup Wizard Configuration>>,From here you can change the setup configuration

aj12345
29-11-2013, 15:30
How to hide Softwares.
http://s5.postimg.org/n1k8tbcjr/Untitled.png

pakrat2k2
30-11-2013, 10:57
How to hide Softwares.


already been asked & answered.. read entire thread before posting questions for something that may have already been asked. ( answer in post #23 )

Directx& Vcx86 Redists Not Installing

syntax Command Line Error

Plz Help

proper command line entries

http://fileforums.com/showthread.php?t=95092

aj12345
30-11-2013, 11:26
How to ad skin.

pakrat2k2
30-11-2013, 19:06
warnings at bottom of compile screen > which result in settings not being read from setup.ini AppPublisher doesn't get filled in default program folder location.

Warning: The [Setup] section directive "VersionInfoCompany" is not assuming a default value because AppPublisher includes constants.
bold parts don't pick-up value from setup.ini

aj12345
01-12-2013, 13:46
How to ad buton Begin Install.

http://s5.postimg.org/4o6bwwevb/Untitled.png

pakrat2k2
01-12-2013, 15:52
its AFTER configure ( configure is like, begin install process )

hackjack
15-12-2013, 04:40
can we show percentage in progress bar. also i am not getting the shortcut on desktop i tried various times.

y_thelastknight
15-12-2013, 09:32
can we show percentage in progress bar. also i am not getting the shortcut on desktop i tried various times.

will fix it..

pakrat2k2
20-12-2013, 21:31
need to also add the option for splash screen ( sentinelk posted it couple pages back, post #19)
and maybe add default setup.icon to script...

SetupIconFile=Setup.ico

y_thelastknight
20-12-2013, 21:34
need to also add the option for splash screen ( sentinelk posted it couple pages back )
and maybe add default setup.ico

sure :)

pakrat2k2
22-12-2013, 11:28
uploaded new versions into first post for Y_thelastnight, he will update first post with changes made :)

y_thelastknight
22-12-2013, 11:52
Updated to Version v1.4.0
Version v1.4.0(Customized Version)

-Fixed Some bug.
-Fixed Shortcut error (thanks to hackjack).
-Added 2nd Shortcut to Desktop and Start menu.
-Added Percentage in Tittle.
-Added Video.
-Added Splash.
-Added Some Button Sounds.
-Added Redist ProgressBar

Version v1.4.0(Original Version)

-Fixed Some bug.
-Fixed Shortcut error (thanks to hackjack).
-Added 2nd Shortcut to Desktop and Start menu.
-Added Percentage in Tittle.

pakrat2k2
22-12-2013, 18:46
well some strange errors happening here !

Have in setup.ini files for disk 1 / disk 2 / disk 3. Have files set correctly in setup.ini
and jumps from install ( disk 1 ) to ask for disk 3.

[Game]
Name=Aerofly FS
Publisher=IPACS
Version=1.0.0.9
Size=20979
Exec=aerofly-fs.exe
[Settings]
Precomp=0.38
[FreearcFile1]
Archive={src}\Data.cab
Output={userdocs}\aerofly FS\
Disk=1
;Password=
[FreearcFile2]
Archive={src}\Data1.cab
Output={app}
Disk=1
;Password=
[FreearcFile3]
Archive={src}\Data2.cab
Output={app}
Disk=2
;Password=
[FreearcFile4]
Archive={src}\Data3.cab
Output={app}
Disk=3 When switching disks following error popped up.

Razor12911
22-12-2013, 22:02
bug will be fixed right away. spotted something.

hackjack
22-12-2013, 22:19
if we have to delay splash screen by 2 or 3 seconds more then what should i do?

y_thelastknight
22-12-2013, 22:47
bug will be fixed right away. spotted something.

thanks razor :)

if we have to delay splash screen by 2 or 3 seconds more then what should i do?

find this line..
ShowSplashScreen(0,ExpandConstant('{tmp}\splash.pn g'),1000,1000,1000,0,255,False,$FFFFFF,10);
Fade in time
Staying time
Fade out time

Change the values for your choice.

pakrat2k2
23-12-2013, 16:53
Glass Black Box v1.4.1.7z
Glass Black Box v1.4.1_C.7z

added to first post, to correct script errors ;)

sentinelks
23-12-2013, 17:50
why upload all the files together, the better to load only the necessary files :)

pakrat2k2
23-12-2013, 19:02
why upload all the files together, the better to load only the necessary files :)

Just easier to upload complete corrected version, without update 1, 2, 3, 4 etc.

Much like your Darkbox topic > 8 files to choose, which one is latest ? You really need to clean up those files, into #1, #2, #3 etc... AND specify which is latest complete version.

y_thelastknight
23-12-2013, 19:05
why upload all the files together, the better to load only the necessary files :)

We don't want to ruin spirit of the original script :p

sentinelks
23-12-2013, 19:10
this was not the reason im my post lol adm . .. DarkBox about it .. darkbox but there are always update I can not load it all :( .. here there are those who want to crush and who wants crude :D


a very good for me test you script.. working 100% panel+bmp :)
new method tomorrow botva2+png :D

hackjack
25-12-2013, 07:18
why do i keep getting this error whenever i try to extract arc file.it does not happen when using 7z or rar file.
see this image
http://img855.imageshack.us/img855/9670/mmxa.png

i tried using free arc 0.67 and 0.66.
also razor compress tool

Razor12911
25-12-2013, 07:26
unarc.dll problem.

hackjack
25-12-2013, 09:53
what should i do..
i tried inserting other dlls

Razor12911
25-12-2013, 10:01
if you are using my compressing tool. copy and paste the isdone support files to the script. just replace existing file.

I wonder where'z y_thelastknight

GloverK1911
06-02-2014, 06:43
How to compile file Setup.ini to Setup.exe?

pakrat2k2
06-02-2014, 09:47
How to compile file Setup.ini to Setup.exe?

you cant as least not yet, he MAY change that.

y_thelastknight
11-02-2014, 10:24
How to compile file Setup.ini to Setup.exe?

Will add it bro.

Andrey167
12-02-2014, 11:56
how to fix this problem like all prescribed true but when you unpack the archive timer 3 strays http://foto-pic.org/images/92365875639253125710.jpg

ahmetbtmn
07-03-2014, 06:21
I add video.avi but give error. I delete video but again error. Download again and compile (I did not change anything) but error

http://i.imgur.com/muUQfLP.png

altef_4
07-03-2014, 06:39
I add video.avi but give error. I delete video but again error. Download again and compile (I did not change anything) but error

http://i.imgur.com/muUQfLP.png

use inno setup enhanced edition

ahmetbtmn
07-03-2014, 07:08
use inno setup enhanced edition

I use unicode. I serarch but not found enhanced edition

pakrat2k2
07-03-2014, 11:28
I use unicode. I serarch but not found enhanced edition

Here's the Enhanced version, just extract & use.

ashyamsundar
20-06-2014, 09:16
How to increase slide show time ?

pakrat2k2
20-06-2014, 13:09
How to increase slide show time ?

go read post #55

Bilawal
01-07-2014, 00:39
How To Convert PCF Files.

y_thelastknight
22-07-2014, 20:51
How To Convert PCF Files.

that doesn't support by this script mate..

Adonix
19-08-2014, 03:50
when compiling script, it's giving error.
Please help, and this will we used with .bin files ?
http://i.imgur.com/lw9XOlu.jpg

Moreover what's difference between Glass Black Box v1.4.1_C and Glass Black Box v1.4.1

y_thelastknight
19-08-2014, 04:35
when compiling script, it's giving error.
http://i.imgur.com/lw9XOlu.jpg

use inno setup enhanced version for the error...
you get it here (http://fileforums.com/showpost.php?p=429689&postcount=72)

Please help, and this will we used with .bin files ?

yup, you can use razor's quick archive packer.

Moreover what's difference between Glass Black Box v1.4.1_C and Glass Black Box v1.4.1

Glass Black Box v1.4.1_C
- Glass BB Script with splash, video BG, Picture Slideshow.

Glass Black Box v1.4.1
- Original Glass BB Script

Adonix
19-08-2014, 05:35
use inno setup enhanced version for the error...
you get it here (http://fileforums.com/showpost.php?p=429689&postcount=72)

Ok, i downloaded it, but how to use it :p
Like your glass black box is very simple, we just have to compile "Script.iss"
But in enhanced version There is no output folder or script to compile :p

Please help :)

y_thelastknight
19-08-2014, 05:41
Ok, i downloaded it, but how to use it :p
Like your glass black box is very simple, we just have to compile "Script.iss"
But in enhanced version There is no output folder or script to compile :p

Please help :)

dude just open the script.iss file in enhanced version of inno setup and compile..

Adonix
19-08-2014, 05:48
dude just open the script.iss file in enhanced version of inno setup and compile..

If i have "script.iss" in enhanced version then i would not disturbing you !
http://i.imgur.com/0TWHOcm.jpg

y_thelastknight
19-08-2014, 05:54
If i have "script.iss" in enhanced version then i would not disturbing you !
http://i.imgur.com/0TWHOcm.jpg

dude use the script.iss file from Glass Black Box v1.4.1_C or Glass Black Box v1.4.1

Adonix
19-08-2014, 05:59
dude use the script.iss file from Glass Black Box v1.4.1_C or Glass Black Box v1.4.1

Do i have to copy script.iss to enhanced version folder ?
Or i have to copy all files from Glass Black Box v1.4.1_C to Inno Ultra (enhanced edition)

Little confused :(

I also tried to copy script.iss to enhanced version folder and then compiling, but another error.
I also tried to copy all files from Glass Black Box v1.4.1_C to enhanced version folder and then compiling, but same error. http://i.imgur.com/lw9XOlu.jpg

altef_4
19-08-2014, 07:18
Do i have to copy script.iss to enhanced version folder ?
Or i have to copy all files from Glass Black Box v1.4.1_C to Inno Ultra (enhanced edition)

Little confused :(

I also tried to copy script.iss to enhanced version folder and then compiling, but another error.
I also tried to copy all files from Glass Black Box v1.4.1_C to enhanced version folder and then compiling, but same error. http://i.imgur.com/lw9XOlu.jpg

You opened script with inno setup 5.5.5u (this shows on your screenshot). Just open compil32. Exe from folder with inno setup ee and then click open and select your script.iss or just make association of. Iss with cimpil32. Exe

Adonix
19-08-2014, 08:08
You opened script with inno setup 5.5.5u (this shows on your screenshot). Just open compil32. Exe from folder with inno setup ee and then click open and select your script.iss or just make association of. Iss with cimpil32. Exe

YES MAN I DID IT :)
ALL GOOD, JUST ONE LAST QUESTION.

In Script.iss do i have to edit full green text or just some red text ?

AppName={code:GameName}
AppPublisher={code:GamePublisher}
AppVersion={code:GameVersion}
AppComments={code:GameName}
DefaultDirName={pf}\{code:GamePublisher}\{code:Gam eName}
DefaultGroupName={code:GamePublisher}\{code:GameNa me}

And what's matter of setup.ini ?
there are many "[FreearcFile1]" written
i have only 1 .bin file so kindly help to set that setup.ini file, i am marking some text as bold, kindly tell what to fill there :
[Game]
Name=TEST
Publisher=XXXX
Version=1.0.0
Size=5200

Exec=Binaries\Launcher.exe
//Exec2Name=x64
//Exec2=Binaries\Launcher.exe


[Redist]
Redist1Name=Direct X
Redist1Command={src}\Redist\DirectX\DXSetup.exe
Redist1Parameter=/Silent

Redist2Name=Microsoft Visual C++
Redist2Command={src}\Redist\vcredist_x86\vcredist_ x86.exe
Redist2Parameter=/q /norestart

[Settings]
Precomp=0.38

[FreearcFile1]
Archive={src}\Data1.arc
Output={app}
Disk=1
;Password=

[FreearcFile2]
Archive={src}\Data2.arc
Output={app}
Disk=1
;Password=




//[7ZipFile2]
Archive={src}\Data.7z
Output={app}
Disk=2
;Password=

//[RarFile3]
Archive={src}\Data.rar
Output={app}
Disk=2
;Password=

pakrat2k2
19-08-2014, 08:28
[Game]
Name=TEST
Publisher=XXXX
Version=1.0.0
Size=5200

Exec=Binaries\Launcher.exe ( The name & location of Your game's EXE)
//Exec2Name=x64
//Exec2=Binaries\Launcher.exe


[Redist] Comment these out with // IF your game doesn't have them or else enter in the folder name like it exists in game folder
Redist1Name=Direct X
Redist1Command={src}\Redist\DirectX\DXSetup.exe
Redist1Parameter=/Silent

Redist2Name=Microsoft Visual C++
Redist2Command={src}\Redist\vcredist_x86\vcredist_ x86.exe
Redist2Parameter=/q /norestart

[Settings]
Precomp=0.38 not needed unless you used precomp to make your bin file

[FreearcFile1]
Archive={src}\Data1.arc change to match the name of your file
Output={app}
Disk=1
;Password=

The types listed below can be changed to match your files IF you HAD more then 1. Just shows what types of files can be entered in setup.ini.

[FreearcFile2]
Archive={src}\Data2.arc
Output={app}
Disk=1
;Password=

//[7ZipFile2]
Archive={src}\Data.7z
Output={app}
Disk=2
;Password=

//[RarFile3]
Archive={src}\Data.rar
Output={app}
Disk=2
;Password=

Adonix
19-08-2014, 08:34
some guys like pakrat2k2 , razor , y_thelastknight and altef_4 Are fuc***g expert !!
I don't know how someone can be so expert :p

Thanks Thanks...
For below thing, i used precomp also.
[Settings]
Precomp=0.38 not needed unless you used precomp to make your bin file

I used below code for compression :
arc a -lc8 -ep1 -ed -r -w.\ Data\TEST.bin -mprecomp+srep+lzma:a1:mfbt4:d256m:fb128:mc1000:lc8 "C:\*"

So now tell according to this :)

Am i have to write "test.bin" in place of "Data1.arc" ?
[FreearcFile1]
Archive={src}\Data1.arc

pakrat2k2
19-08-2014, 12:37
set the precomp line equal to which version of precomp you used, & secondly change Data1.arc to test.bin for your example. Don't forget to comment out the freearcfile2 line ( use // ) just like the rest.

Adonix
19-08-2014, 19:10
set the precomp line equal to which version of precomp you used, & secondly change Data1.arc to test.bin for your example. Don't forget to comment out the freearcfile2 line ( use // ) just like the rest.

THANKS !!!!!!!!!!!!!!!!!
what to write in Disk=1, Output={app} and password compulsory ??
And i put "//" to all files, except some files which i needed.

In Script.iss do i have to edit full green text or just some red text ?


AppName={code:GameName}
AppPublisher={code:GamePublisher}
AppVersion={code:GameVersion}
AppComments={code:GameName}
DefaultDirName={pf}\{code:GamePublisher}\{code:Gam eName}
DefaultGroupName={code:GamePublisher}\{code:GameNa me}

Can't we have Autorun.inf in place of Setup.ini, can somebody remove setup.ini ?...work would become more easy then :p
And will we have to add setup.ini with test.bin and setup folder ??

Grumpy
19-08-2014, 20:59
@Adonix

Do some reading of the forums instead of spamming the forum with questions which have been asked and 'answered' many many times. All the answers you seek are here on these forums, read read read .... that is the only way you are going to learn.

And do NOT double post all the time, edit your original post instead of double posting.

Adonix
19-08-2014, 21:24
@Adonix

Do some reading of the forums instead of spamming the forum with questions which have been asked and 'answered' many many times. All the answers you seek are here on these forums, read read read .... that is the only way you are going to learn.

And do NOT double post all the time, edit your original post instead of double posting.

Grumpy brother, i am searching + reading the forum since 3 days whole day and night, and when i am not finding some answer, then only asking !!

y_thelastknight
19-08-2014, 21:58
adonix mate..

you don't have anything to edit in Script.iss
1- make your bin files..
2- edit the Setup.ini in output dir for you purpose.
3- open the script.iss and compile..thats all you have to do..

[Game]
Name=(name of the game)
Publisher=(publisher of the game)
Version=(version of the game)
Size=(required disk space for your game)

Exec=Binaries\Launcher.exe (where is your main exe file in the installation dir and main exe file name..)
//Exec2Name=x64 (secondary exe file name)(delete the line if you don't have secondary exe)
//Exec2=Binaries\Launcher.exe (where is your secondary exe file in the installation dir and exe file name..)(delete the line if you don't have secondary exe)

[Redist]
Redist1Name=Direct X
Redist1Command={src}\Redist\DirectX\DXSetup.exe
Redist1Parameter=/Silent

Redist2Name=Microsoft Visual C++
Redist2Command={src}\Redist\vcredist_x86\vcredist_ x86.exe
Redist2Parameter=/q /norestart

[Settings]
Precomp=0.38 (what version of precomp you used to compress your bin files)

[FreearcFile1] (what format you used for compress(Freearc, 7Zip, Rar))(you archive number)
Archive={src}\Setup-1.bin (your bin file directory and bin file)
Output={app} (output directory)
Disk=1 (your disk number where your archive file is)
Password= (your bin password) (if you don't have password for your archive then put it blank)

do you know what to do when you have multiple bin files is it?



Pakrat2k, altef_4, Grumpy thanks for the backup guys..

Adonix
19-08-2014, 22:52
Please help again :(
http://i.imgur.com/jWyApl9.jpg

y_thelastknight
19-08-2014, 22:58
i think that archive is corrupted.

Adonix
19-08-2014, 23:09
i think that archive is corrupted.

not possible,.i used this installer to compress : http://fileforums.com/attachment.php?attachmentid=6493&d=1371369297

Adonix
20-08-2014, 00:20
i think that archive is corrupted.

Ok, you said corrupted,..
i tried by using another bin file created by using : http://fileforums.com/attachment.php...3&d=1371369297
compressor provided here.

But again same error giving : http://i.imgur.com/jWyApl9.jpg

Please help i have done very hard work to complete the installer :'(

Please help. :(

altef_4
20-08-2014, 00:27
some guys like pakrat2k2 , razor , y_thelastknight and altef_4 Are fuc***g expert !!
I don't know how someone can be so expert :p

Thanks Thanks...
For below thing, i used precomp also.

...

if you really think that someone helped you on this forum, then don't forget about thanks button on the bottom right corner of the useful message.

Adonix
20-08-2014, 00:36
if you really think that someone helped you on this forum, then don't forget about thanks button on the bottom right corner of the useful message.

i really don't know thanks for telling :cool:

DCrepacks
27-08-2014, 23:36
i have this error when i mount dvd2 of the game..
how to fix?

I think you add " appid " internally ... i mean in the script . But, need to add it in the Setup.ini or just remove it and compile it again then you`ll get a successful output !

DCrepacks
27-08-2014, 23:39
Friend/Brother,

I'm getting " CallbackAddr " what should i do ... ?!

Should i use the advanced inno setup you asked to do compile if we get any errors is there any solution other than using enchanced edition of inno setup?! ;)

y_thelastknight
28-08-2014, 01:04
I think you add " appid " internally ... i mean in the script . But, need to add it in the Setup.ini or just remove it and compile it again then you`ll get a successful output !

mate that bug has fixed already..

Friend/Brother,

I'm getting " CallbackAddr " what should i do ... ?!

Should i use the advanced inno setup you asked to do compile if we get any errors is there any solution other than using enchanced edition of inno setup?! ;)

you have to change the code to use CallbackCtrl.dll

ahmetbtmn
05-11-2014, 09:00
setup has crashed -m4 compression ? any idea?

Dansoft
11-11-2014, 15:10
How do i add a password to the installer please?

hydefromt70s
13-11-2014, 15:33
Nice installer!

Few questions:
1. Watching screens I'm assuming it works on Win8 x86 & X64 ?
2. Does this script can extract arc-srep-precomp-arc (bin) archives "on the fly" directly in the RAM memory as the Razor IC does? If not, is there any chance to implement this future to reduce extraction time?
3. Could you update ur script to the latest SREP 3.92 and precomp 0.43 ?

y_thelastknight
13-11-2014, 22:06
How do i add a password to the installer please?

what you mean password for the installer?

Nice installer!

Few questions:
1. Watching screens I'm assuming it works on Win8 x86 & X64 ?
2. Does this script can extract arc-srep-precomp-arc (bin) archives "on the fly" directly in the RAM memory as the Razor IC does? If not, is there any chance to implement this future to reduce extraction time?
3. Could you update ur script to the latest SREP 3.92 and precomp 0.43 ?

1. it will wrk on both systems.
2. yeah i will extract on the fly. isdone scripted by razor so it will work like his ic.
3. sorry mate, i dont have time to upgrade my projects. if i have time i will.

hydefromt70s
16-11-2014, 00:09
Thanks for the reply.

Unfortunately, I encountered a problem when extracting packed archives using SREP with PRECOMP. No matter which version of PRECOMP I use, I get an error. I noticed that the problem only occurs when the archives compressed with SREP and PRECOMP - when I use only the SREP, the files are extracted without error. I used to compress files Conversion Quick Archive Packer and this script (no files were swapped - just unpacked and used these programs).
I attach the sample files.

SREP Version: 3.0
PRECOMP Version: 0.38 & 0.42
Compression Method: -msrep + delta + lzma: a1: mfbt4: d158m: fb273: MC1000: LC8 & -mprecomp + SREP + delta + lzma: a1: mfbt4: d158m: fb273: MC1000: LC8
Error when using PRECOMP:
---------------------------
ISDone.dll
---------------------------
An error occurred when unpacking!
Unarc.dll returned an error code: -1
ERROR: archive data corrupted (decompression fails)
---------------------------

BTW. The strange thing is that the error doesn't pops up every time - on 5 installation attempts appears 2 to 3 times. This same files are extracted without any error in the Razor's IC, so ERROR must be on the side of script GBB.

Any solustion?

hydefromt70s
20-11-2014, 06:10
Ok, nevermind with previous problem - somehow I managed it :D

Okay with the previous problem - somehow I worked this.
But I noticed that the progress bar on the top bar does not deduct properly until the end. I made a repack of a certain game (6 files bin, 5xDVD5) and already at the 3-4 disc shows that left 0 minutes to the end.

Any fix?

hydefromt70s
22-11-2014, 01:24
I allowed myself to update this script because @thelastknight do not have time. I am not an expert in INNO, but with each passing day my knowledge grows: D

Here are the changes in my modified version:
- Config file setup.ini moved inside setup.exe when compile
- Updated 7z (alpha 9.34)
- Added new section to the arc.ini to extract 7z files
- Updated CLS-srep.dll to unpack files SREP 3.93
- Updated srep.exe and srep64.exe to 3.93
- Updated unarc.dll
- Modified time to change slides for 60 sec

I hope that @thelastknight and the @Razor will not be mad at me :)

punchao
22-11-2014, 06:07
How to create desktop icon for Borderlands The Pre-sequel?
Binaries\Win32\BorderlandsPreSequel.exe

In the setup.ini or in Script.iss?
i need a Example please

hydefromt70s
22-11-2014, 11:00
How to create desktop icon for Borderlands The Pre-sequel?
Binaries\Win32\BorderlandsPreSequel.exe

In the setup.ini or in Script.iss?
i need a Example please

You don't change anything in Script.iss file, only in setup.ini.

punchao
22-11-2014, 11:36
so?

Exec=\Binaries\Win32\BorderlandsPreSequel.exe
//Exec2Name=x64
//Exec2=Binaries\Launcher.exe

hydefromt70s
22-11-2014, 11:37
so?

Exec=\Binaries\Win32BorderlandsPreSequel.exe
//Exec2Name=x64
//Exec2=Binaries\Launcher.exe

Yes bro :)

punchao
22-11-2014, 11:45
for install redistributables,I created a folder named _CommonRedist
in output folder,its correct?
thanks for your help and sorry for my bad english

hydefromt70s
22-11-2014, 11:56
Yes, just write correct path in setup.ini to yours redist exe files.

hydefromt70s
22-11-2014, 12:05
And here's another small update of GBB Custom Modified Version ;)

- added "ExecParametr" in the setup.ini for desktop shortcut parameters

I missed this option, so I decided to add it :) Usually you rarely use additional parameters when you start the game, but some games require this, e.g. Dead Island Escape.

In "ExecParametr" just type your additional parameters for desktop shortcut :)

punchao
22-11-2014, 12:14
but _CommonRedist folder,put in Output folder or in game folder before compress the game?

hydefromt70s
22-11-2014, 12:21
but _CommonRedist folder,put in Output folder or in game folder before compress the game?

Doesn't really matter. If you put _CommonRedist folder in Output folder (DVD disc) then you type "{src}\_CommonRedist" to your redist folder in setup.ini. If you put it in game folder before compression than type "{app}\_CommonRedist" to your redist folder in setup.ini.

Buddy, try by trial and error method - watch what happens if you change any parameter, and draw conclusions. This is the fastest method for learning;)

punchao
22-11-2014, 12:48
Many thanks for your help bro +10

hydefromt70s
26-11-2014, 03:19
Today I tried to create an installer for the game with using an .avi file, and there is something wrong. I do not know how to explain it well, so I recorded a short video showing the problem.

http://youtu.be/IsM1c44-9ro

Razor, can you fix it?

rakeshbro
06-12-2014, 01:00
Thanks :)

Bilawal
15-01-2015, 01:27
I modified the script and add archives.ini (just like in black box script).
Glass Black Box (https://www.dropbox.com/s/ii3pbsj0hcx1a8d/Script.rar?dl=0)

shuvankardash
10-02-2015, 21:29
Please help, Glass Blackbox splash screen not working

pakrat2k2
11-02-2015, 06:30
which of the versions in this thread are you using ?

shuvankardash
11-02-2015, 21:09
http://i58.tinypic.com/2i74bo1.jpg

Working Perfect Thanks @y_thelastknight

shuvankardash
11-02-2015, 22:10
How i include Setup.ini in installer exe file..
What is the code?
Please reply

shuvankardash
12-02-2015, 01:03
http://s2.postimg.org/i4piytfcp/Problem.jpg

problems :( Please help

Bilawal
12-02-2015, 01:28
http://s2.postimg.org/i4piytfcp/Problem.jpg

problems :( Please help

You can't use special character (/ : * ? < > |) in game's name or game folder's name.

shuvankardash
12-02-2015, 02:00
You can't use special character (/ : * ? < > |) in game's name or game folder's name.

Thanks Frend :-)

DCrepacks
24-03-2015, 14:11
Ok, you said corrupted,..
i tried by using another bin file created by using : http://fileforums.com/attachment.php...3&d=1371369297
compressor provided here.

But again same error giving : http://i.imgur.com/jWyApl9.jpg

Please help i have done very hard work to complete the installer :'(

Please help. :(

Bro! :o please try updating arc.exe or just copy the arc.ini file you used to compress your .bin or .arc files (something similar) into the files folder.. the folder in which inno setup required files might be used for example isdone.dll and so on. I think you are clear! The problem occurred because you have updated the compression code and not the .exe file! :cool: Hope it works for you now... BYE! :D

mht1526
30-03-2015, 05:22
first thanks a ton for the script & the compressor, Everything is working fine for me except the video.. I added 'video.avi' in the image folder & then compiled the script,selected BG video in the installer but it do not play the video when installation begins.
it was a 720p video.. any solutions?

y_thelastknight
30-03-2015, 06:42
Try any other video compression.

mikey26
30-03-2015, 06:56
first thanks a ton for the script & the compressor, Everything is working fine for me except the video.. I added 'video.avi' in the image folder & then compiled the script,selected BG video in the installer but it do not play the video when installation begins.
it was a 720p video.. any solutions?

try installing k-lite mega codec pack you might not have the xvid codec installed which is required to play the video from the installer.:)

Razor12911
30-03-2015, 08:56
best way to do it without codecs.

open script,
Use Keyboard and press Ctrl H
write avi under find what
write wmv under replace with
click on replace all.
convert your video to wmv and it will play, at least wmv on windows environment will not give any problems, tested on my pc, no codecs installed and the video resolution was 720p.

mht1526
30-03-2015, 09:39
Replacing avi format with wmv worked.. Thanks!!
is it possible to add more than one video like the JPEGs?

pakrat2k2
30-03-2015, 11:23
Replacing avi format with wmv worked.. Thanks!!
is it possible to add more than one video like the JPEGs?

nope but you can use free software format factory & combine 1/2/3 files into 1
& it will convert from / to any format. Great little program, has a ton of features & its FREE.

NICE to see ya, back y_thelastknight :D

mht1526
31-03-2015, 04:54
How to fix this? it Shows 0 minutes & 0 Seconds Remaining..

bastien360
02-04-2015, 17:24
how to change progress bar color and fonts?

bastien360
03-04-2015, 05:54
the GBB update extract only 1 archieve plz help

pakrat2k2
03-04-2015, 07:06
the GBB update extract only 1 archieve plz help

re-read step #4 in first post

bastien360
03-04-2015, 12:28
i've done every step,but it extract only my first freearcfile,thnx in advance

pakrat2k2
03-04-2015, 14:10
post your setup.ini

bastien360
03-04-2015, 15:25
just manage to fix it,this was due to my inno setup...how can i change progress bar color and fix my wait time,50% wait 0.0 secs

mht1526
05-04-2015, 04:17
will music be added to the Script in future updates? Or the Script is final?

y_thelastknight
05-04-2015, 08:47
Script is open, i dont have time to finish it.

bastien360
05-04-2015, 12:38
no one,to help me to fix it?

y_thelastknight
05-04-2015, 22:25
Bastien360, what is ur error bro?

pakrat2k2
06-04-2015, 09:28
no one,to help me to fix it?

I asked you to post your setup.ini, never did. Then you skipped that and asked
about progressbar. Then you ask no one help you to fix it.

IF you don't post whats asked for then stop asking for help. Not mind readers here.

Razor12911
07-04-2015, 17:44
just manage to fix it,this was due to my inno setup...how can i change progress bar color and fix my wait time,50% wait 0.0 secs
The reason is hasn't been answered it is because, you don't just change the color just like that, it is not that simple but you can work around that by just changing the progress bar state, which means you can have it as green as it is or yellow or even red.

bastien360
11-04-2015, 11:56
i manage to fix my setup.ini and its working,it extrac all my archieve but the time remaining stop at 50% it shows 0.0

RamiroCruzo
05-09-2015, 10:38
Can anyone help how to remove slides & leave video alone...... i.e. on video to be played????? :)

Please....Thanks in advance....... :D

ffmla
26-09-2015, 05:38
This glass script work fine
Progress bar have some effect(windows glowing),
Is there any way to make this effect to other installer(progress bar) like WPI,old blackbox & etc.
If the way is there ,please post the information. (Script code).
Thanks in advance.

Skheizen
27-09-2015, 05:34
Hi everyone.
I'd like to use this script but only with srep and freearc compression.
How to do it ?
Thanks in advance for your answer.

Melethiel
07-11-2015, 11:53
Hi there. First at all, thank you very much for amazing work and mostly to share this with all of us.

I am using the scrip 1.4.1 customized and the "logo.png" is not being loaded or shown in the dialog box. I have seen some screenshots here, from some members, that are missing the logo.png aswell.

Could anyone give me an insight about this matter, related with the "logo.png" not shown in the dialog box?

Thank you very much, in advance, for any response.

y_thelastknight
07-11-2015, 12:35
Hi there. First at all, thank you very much for amazing work and mostly to share this with all of us.

I am using the scrip 1.4.1 customized and the "logo.png" is not being loaded or shown in the dialog box. I have seen some screenshots here, from some members, that are missing the logo.png aswell.

Could anyone give me an insight about this matter, related with the "logo.png" not shown in the dialog box?

Thank you very much, in advance, for any response.

are you talking about this loge.png mate?

Melethiel
07-11-2015, 12:58
are you talking about this loge.png mate?

Indeed. I compile the script and it works great but the logo.png never is loaded and/or shown. I resized it, to test it, but not luck. I modified the format to bmp as also I changed the format in the script and still it is not being loaded.

I was looking some information throught Google and found nothing about this particular matter. I kept trying but not luck. I read this whole thread and I didn't find any post mentioning an issue similar to mine. Even so I have seen some screenshots, from other, members that are missing the "logo" that you, Y_thelastknight, pointed in your screenshot.

So, this is why I made my post hoping to get a solution from anyone. Thank you, Y_thelastknight, for your quite fast response.

y_thelastknight
07-11-2015, 22:31
hm, interesting.
i think is should ask razor about this.

punchao
08-11-2015, 08:28
logo.png

http://snap.ashampoo.com/uploads/2015-11-08/Pl58W3vX.png
http://snap.ashampoo.com/uploads/2015-11-08/0mb99OaJ.png

Melethiel
08-11-2015, 14:26
Well, Punchao's screenshot does not help. y_thelastknight already posted a screenshot in order to understand further more about what I said. Screenshots with the logo are not necesary because I didn't say that the script is not working. As I posted before, the script is working great for me but I am having this issue with the logo not being loaded or shown.

So, further more screenshots are not necesary because, as I said, y_thelastknight already posted a screenshot showing the logo presented in the dialog box. I needed further more information about what could be my problem as I posted before. So, please, more screenshots of the logo.png are not necesary because are not giving me any information about "my" issue. Thank you.

y_thelastknight
08-11-2015, 23:46
@Melethiel, mate What is your OS?

Melethiel
09-11-2015, 04:36
@Melethiel, mate What is your OS?

My installed OS is Windows Seven x64 bits.

mausschieber
09-11-2015, 05:10
Well, Punchao's screenshot does not help. y_thelastknight already posted a screenshot in order to understand further more about what I said. Screenshots with the logo are not necesary because I didn't say that the script is not working. As I posted before, the script is working great for me but I am having this issue with the logo not being loaded or shown.

So, further more screenshots are not necesary because, as I said, y_thelastknight already posted a screenshot showing the logo presented in the dialog box. I needed further more information about what could be my problem as I posted before. So, please, more screenshots of the logo.png are not necesary because are not giving me any information about "my" issue. Thank you.

but you know you replace the logo of y_thelastknight
to your logo

Melethiel
09-11-2015, 05:54
but you know you replace the logo of y_thelastknight
to your logo

I already know that. No matter is the default logo from y_thelastknight or mine own. As I said in my first post, the logo.png is not being loaded and shown in the dialog box. I didn't say that my custom logo is not appearing. Not even the default y_thelastknight's logo is being loaded and shown by compiling the default script right away after extracting it from the compressed package.

For me, personally for me, my issue with the logo not being shown in the dialog box happens anyway. Not matter if I compile the script with the default logo or if I modify it. I even tried with a bmp format file for the logo and changing the script to call the logo.bmp, still the same result.

Here is a screenshot with the default compiled script, in which the default logo is not loaded.

http://i.imgur.com/lDcxS6j.jpg

Thank you very much.

y_thelastknight
09-11-2015, 07:24
can you check this file..i compiled the script for you.

Melethiel
09-11-2015, 11:17
can you check this file..i compiled the script for you.

Well, the problem still persists. I ran your compiled Setup.exe and the logo.png is not being shown. It is really quite strange. Could it be a problem with or in the OS? or is there something that I might be missing, some plugin or something else?

http://i.imgur.com/U4Qn0pD.jpg

Thanks a lot for your time and effort, y_thelastknight.

mausschieber
09-11-2015, 15:05
Well, the problem still persists. I ran your compiled Setup.exe and the logo.png is not being shown. It is really quite strange. Could it be a problem with or in the OS? or is there something that I might be missing, some plugin or something else?

http://i.imgur.com/U4Qn0pD.jpg

Thanks a lot for your time and effort, y_thelastknight.

which Inno Setup version you are using
the most conversions are using inno setup enhanced
download http://fileforums.com/showpost.php?p=429689&postcount=72

Melethiel
09-11-2015, 15:33
which Inno Setup version you are using
the most conversions are using inno setup enhanced
download http://fileforums.com/showpost.php?p=429689&postcount=72

That is the Inno version that I am using since I downloaded the GBB 1.4.1 C version. The Black Box V2 script loads the logo in the dialog box.

livebaran
26-11-2015, 13:39
How to fix this? it Shows 0 minutes & 0 Seconds Remaining..



function ProgressCallback(OveralPct,CurrentPct: integer;CurrentFile,TimeStr1,TimeStr2,TimeStr3:PAn siChar): longword;
var
Remaining: Integer;
begin
if OveralPct<=Wizardform.ProgressGauge.Max then
Wizardform.Progressgauge.Position := OveralPct;
Result := ISDoneCancel;
with WizardForm.ProgressGauge do begin
if (Position>0)and((GetTickCount-StartInstall)/1000>0) then
Remaining:= ((Max-Position)/(Position/((GetTickCount-StartInstall)/1000)))*1000;
WizardForm.Caption:=(IntToStr(ProgressPercent)+'%' )+(' Wait ' + TicksToTime(Remaining, cm('hour'), cm('min'), cm('sec'), false));
end;
end;

ramazan19833
18-02-2016, 10:52
M&S_Kompressor_1.2 to Glass Black Box v1.4.1_C Scrip arc.ini :confused:

http://i.hizliresim.com/Jn5qzE.jpg (http://hizliresim.com/Jn5qzE)

:confused: HELP

nasir ahmad
28-02-2016, 03:24
My friend please edit this project that do not need to setup.ini

jksengko
04-09-2016, 07:57
how to add & adjust redist installation

pakrat2k2
05-09-2016, 19:46
how to add & adjust redist installation

Edit setup.ini in the output folder. :rolleyes:

Fakhruddinmaruf_
01-10-2016, 17:44
why when i test the setup, suddenly the setup has crashed or not responding.
and suddenly when i compile setup again the setup close by own. how to fix this?http://fileforums.com/attachment.php?attachmentid=15647&stc=1&d=1475368971

Razor12911
01-10-2016, 18:44
You must have done something wrong, installer was last updated a year ago and nobody has had such a problem all this time.

Fakhruddinmaruf_
01-10-2016, 18:52
You must have done something wrong, installer was last updated a year ago and nobody has had such a problem all this time.
so, what should i do now?
have you new installer script now?

Razor12911
01-10-2016, 18:57
Ok, so you downloaded attachment.
Compiled script using unicode enhanced edition then got error?

Fakhruddinmaruf_
01-10-2016, 19:33
http://imgur.com/a/nloMZOk, so you downloaded attachment.
Compiled script using unicode enhanced edition then got error?
can you share the new installer script?
i have not downloaded it yet

Razor12911
01-10-2016, 19:40
new installer script?

Fakhruddinmaruf_
01-10-2016, 19:51
new installer script?

yes, new script of glass blackbox design that have edited

Razor12911
01-10-2016, 20:15
Dude, the script is from the main post.

http://fileforums.com/showpost.php?p=425015&postcount=1

Fakhruddinmaruf_
01-10-2016, 20:30
Dude, the script is from the main post.

http://fileforums.com/showpost.php?p=425015&postcount=1

but the result is same from just now. always not responding and error code always same.
http://imgur.com/0alzgxY

Fakhruddinmaruf_
02-10-2016, 00:52
appear different problem again. like this:
http://fileforums.com/attachment.php?attachmentid=15650&stc=1&d=1475394438
how to fix this

Kral
03-05-2019, 23:33
Error ! I open 0.0% after waiting a few seconds after closing ....!

Gehrman
27-01-2023, 06:48
https://www.upload.ee/image/14875832/Glass_Black_Box_DPI.jpg
https://www.upload.ee/image/14875831/Glass_Black_Box_DPI_FIX_.jpg

/////Script created by y_thelastknight@fileforums and Razor12911@fileforums/////
[Setup]
AppName={code:GameName}
AppPublisher={code:GamePublisher}
AppVersion={code:GameVersion}
AppComments={code:GameName}
DefaultDirName={pf}\{code:GamePublisher}\{code:Gam eName}
DefaultGroupName={code:GamePublisher}\{code:GameNa me}
OutputBaseFilename=Setup
OutputDir=Output
Compression=lzma2/ultra64
UsePreviousLanguage=no
SetupIconFile=Image\Icon.ico
#ifdef Internal
DiskSpanning=yes
DiskSliceSize=906993073
SlicesPerDisk=5
#endif

[files]
Source: Include\*.*; Flags: dontcopy;
Source: Image\*.*; Flags: dontcopy;
#ifexist "Image\Video.avi"
#define Video
Source: Image\video.avi; Flags: dontcopy;
#endif

#define i 0
#ifexist "Slides\1.jpg"
#sub AddFile
Source: Slides\{#i}.jpg; DestDir: {tmp}; Flags: dontcopy;
#endsub
#for {i = 1; FileExists(StringChange("Slides\FileName.jpg", "FileName", Str(i))) != 0; i++} AddFile
#endif

[Icons]
Name: {group}\Uninstall {code:GameName}; Filename: {app}\unins000.exe; WorkingDir: {app};
Name: {group}\{code:GameName}; Filename: {app}\{code:GameIcon1}; WorkingDir: {app};
Name: {group}\{code:GameName} {code:GameIcon2N}; Filename: {app}\{code:GameIcon2}; WorkingDir: {app}; Check: Icon2

Name: {commondesktop}\{code:GameName}; Filename: {app}\{code:GameIcon1}; WorkingDir: {app}; Check: Desktop
Name: {commondesktop}\{code:GameName} {code:GameIcon2N}; Filename: {app}\{code:GameIcon2}; WorkingDir: {app}; Check: Desktop and Icon2

[CustomMessages]
hour= hour
min= min
sec= secs

[UninstallDelete]
Type: filesandordirs; Name: {app};

[code]
var
CanUseXvid,
XvidInstalled : boolean;

Type
TMargins = record
cxLeftWidth: Integer;
cxRightWidth: Integer;
cyTopHeight: Integer;
cyBottomHeight: Integer;
end;

type
TProc=procedure(HandleW, msg, idEvent, TimeSys: LongWord);
TTimerProc = procedure(HandleW, Msg, idEvent, TimeSys: LongWord);
TCallback = function (OveralPct,CurrentPct: integer;CurrentFile,TimeStr1,TimeStr2,TimeStr3:PAn siChar): longword;
TCallback2 = function (OveralPct,CurrentPct: integer;CurrentFile,TimeStr1,TimeStr2,TimeStr3:PAn siChar): longword;

var
BmpFile : TBitmapImage;
LogoImage: TBitmapImage;
WizardPanel:TPanel;
ISDoneCancel: Integer;
ISDoneError: Boolean;

LogoLinkLabel,DiskSpaceLablel,SocialLabel,CreateDL abel,VisualCLabel,DirectXLabel,DirWelcomeLabel,Dir WelcomeLabel1,InstallpathLabel,SoftwaresLabel,Shor tcutLabel: TLabel;
EndFailLabel,EndPassLabel,WLabel:TLabel;
TasksSeparateBevel,TasksSeparateBevel2:TBevel;
ShortcutCB,DirectXCB,VisualCCB,SocialCB:TNewCheckB ox;
TimerID2,TimerID: LongWord;
CurrentPicture:integer;
PicList: TStringlist;
BGRadio1,BGRadio2:TNewRadioButton;
BGRadio1Label,BGRadio2Label:TLabel;

StartInstall: Integer;

#ifdef Unicode
#define A "W"
#else
#define A "A"
#endif

function GetTickCount: DWord; external 'GetTickCount@kernel32';

procedure ISWin7_Apply(File: PAnsiChar; X, Y: Integer; Handle: HWND; Left, Right, Top, Bottom: Integer); external 'iswin7_6594@files:iswin7logo.dll stdcall';
procedure ISWin7_AddCtrl(Handle: HWND); external 'iswin7_9736@files:iswin7logo.dll stdcall';
procedure ISWin7_Shutdown(); external 'iswin7_2054@files:iswin7logo.dll stdcall';
procedure ISWin7_ShowLogo(CmdShow: BOOL); external 'iswin7_2541@files:iswin7logo.dll stdcall';

function SetTimer(hWnd: longword; nIDEvent, uElapse: longword; lpTimerFunc: longword): longword; external '[email protected] stdcall';

procedure InitializeSlideShow(Hwnd:Thandle; l,t,w,h:integer;Animate:boolean; Stretch:integer); external 'InitializeSlideShow@files:isslideshow.dll stdcall';
procedure DeinitializeSlideShow; external 'DeinitializeSlideShow@files:isslideshow.dll stdcall';
procedure ShowImage(ipath:PAnsiChar; Effect:integer); external 'ShowImage@files:isslideshow.dll stdcall';

function sndPlaySound(lpszSoundName: string; uFlags: cardinal):integer;
external 'sndPlaySound{#A}@winmm.dll stdcall';

#ifdef UNICODE
procedure ShowSplashScreen(p1:HWND;p2:AnsiString;p3,p4,p5,p6 ,p7:integer;p8:boolean;p9:Cardinal;p10 :integer); external 'ShowSplashScreen@files:isgsg.dll stdcall delayload';
#else
procedure ShowSplashScreen(p1:HWND;p2:string;p3,p4,p5,p6,p7: integer;p8:boolean;p9:Cardinal;p10:integer); external 'ShowSplashScreen@files:isgsg.dll stdcall delayload';
#endif

function WrapCallback(callback:TCallback2; paramcount:integer):longword;external 'wrapcallback@files:ISDone.dll stdcall delayload';
function ISDoneInit(RecordFileName:AnsiString; TimeType,Comp1,Comp2,Comp3:Cardinal; WinHandle, NeededMem:longint; callback:TCallback2):boolean; external 'ISDoneInit@files:ISDone.dll stdcall';
function ISArcExtract(CurComponent:Cardinal; PctOfTotal:double; InName, OutPath, ExtractedPath: AnsiString; DeleteInFile:boolean; Password, CfgFile, WorkPath: AnsiString; ExtractPCF: boolean ):boolean; external 'ISArcExtract@files:ISDone.dll stdcall delayload';
function IS7ZipExtract(CurComponent:Cardinal; PctOfTotal:double; InName, OutPath: AnsiString; DeleteInFile:boolean; Password: AnsiString):boolean; external 'IS7zipExtract@files:ISDone.dll stdcall delayload';
function ISRarExtract(CurComponent:Cardinal; PctOfTotal:double; InName, OutPath: AnsiString; DeleteInFile:boolean; Password: AnsiString):boolean; external 'ISRarExtract@files:ISDone.dll stdcall delayload';
function ISPrecompExtract(CurComponent:Cardinal; PctOfTotal:double; InName, OutFile: AnsiString; DeleteInFile:boolean):boolean; external 'ISPrecompExtract@files:ISDone.dll stdcall delayload';
function ISSRepExtract(CurComponent:Cardinal; PctOfTotal:double; InName, OutFile: AnsiString; DeleteInFile:boolean):boolean; external 'ISSrepExtract@files:ISDone.dll stdcall delayload';
function ISxDeltaExtract(CurComponent:Cardinal; PctOfTotal:double; minRAM,maxRAM:integer; InName, DiffFile, OutFile: AnsiString; DeleteInFile, DeleteDiffFile:boolean):boolean; external 'ISxDeltaExtract@files:ISDone.dll stdcall delayload';
function ISPackZIP(CurComponent:Cardinal; PctOfTotal:double; InName, OutFile: AnsiString;ComprLvl:integer; DeleteInFile:boolean):boolean; external 'ISPackZIP@files:ISDone.dll stdcall delayload';
function ShowChangeDiskWindow(Text, DefaultPath, SearchFile:AnsiString):boolean; external 'ShowChangeDiskWindow@files:ISDone.dll stdcall delayload';
function Exec2 (FileName, Param: PAnsiChar;Show:boolean):boolean; external 'Exec2@files:ISDone.dll stdcall delayload';
function ISFindFiles(CurComponent:Cardinal; FileMask:AnsiString; var ColFiles:integer):integer; external 'ISFindFiles@files:ISDone.dll stdcall delayload';
function ISPickFilename(FindHandle:integer; OutPath:AnsiString; var CurIndex:integer; DeleteInFile:boolean):boolean; external 'ISPickFilename@files:ISDone.dll stdcall delayload';
function ISGetName(TypeStr:integer):PAnsichar; external 'ISGetName@files:ISDone.dll stdcall delayload';
function ISFindFree(FindHandle:integer):boolean; external 'ISFindFree@files:ISDone.dll stdcall delayload';
function ISExec(CurComponent:Cardinal; PctOfTotal,SpecifiedProcessTime:double; ExeName,Parameters,TargetDir,OutputStr:AnsiString; Show:boolean):boolean; external 'ISExec@files:ISDone.dll stdcall delayload';
function SrepInit(TmpPath:PAnsiChar;VirtMem,MaxSave:Cardina l):boolean; external 'SrepInit@files:ISDone.dll stdcall delayload';
function PrecompInit(TmpPath:PAnsiChar;VirtMem:cardinal;Pre compVers:single):boolean; external 'PrecompInit@files:ISDone.dll stdcall delayload';
function FileSearchInit(RecursiveSubDir:boolean):boolean; external 'FileSearchInit@files:ISDone.dll stdcall delayload';
function ISDoneStop:boolean; external 'ISDoneStop@files:ISDone.dll stdcall';
function ChangeLanguage(Language:AnsiString):boolean; external 'ChangeLanguage@files:ISDone.dll stdcall delayload';
function SuspendProc:boolean; external 'SuspendProc@files:ISDone.dll stdcall';
function ResumeProc:boolean; external 'ResumeProc@files:ISDone.dll stdcall';

function mciSendString(lpstrCommand, lpstrReturnString: PAnsiChar; uReturnLength, hWndCallback: Integer): Integer; external 'mciSendStringA@winmm stdcall delayload';

Function TicksToTime(Ticks: DWord; h,m,s: String; detail: Boolean): String;
Begin
if detail then {hh: mm:ss format}
Result:= PADZ(IntToStr(Ticks/3600000), 2) +':'+ PADZ(IntToStr((Ticks/1000 - Ticks/1000/3600*3600)/60), 2) +':'+ PADZ(IntToStr(Ticks/1000 - Ticks/1000/60*60), 2)
else if Ticks/3600 >= 1000 then {more than hour}
Result:= IntToStr(Ticks/3600000) +h+' '+ PADZ(IntToStr((Ticks/1000 - Ticks/1000/3600*3600)/60), 2) +m
else if Ticks/60 >= 1000 then {1..60 minutes}
Result:= IntToStr(Ticks/60000) +m+' '+ IntToStr(Ticks/1000 - Ticks/1000/60*60) +s
else Result:= Format('%.1n', [Abs(Ticks/1000)]) +s {less than one minute}
End;

procedure GetTime(HandleW, Msg, idEvent, TimeSys: LongWord);
var Remaining: Integer;
begin
with WizardForm.ProgressGauge do begin
if position > 0 then Remaining:= trunc((GetTickCount - StartInstall) * Abs((max - position)/position));
// WizardForm.Caption:= 'Remaining ' + TicksToTime(Remaining, cm('hour'), cm('min'), cm('sec'), false);
end;
end;

procedure XvidDelete;
begin
DeleteFile(ExpandConstant('{sys}\xvidcore.dll'));
DeleteFile(ExpandConstant('{sys}\xvidvfw.dll'));
RegDeleteValue(HKEY_LOCAL_MACHINE,'SOFTWARE\Micros oft\Windows NT\CurrentVersion\Drivers32','VIDC.XVID');
end;

procedure XvidInstall;
var
f:boolean;
begin
CanUseXvid:=False;
XvidInstalled:=False;
if not (FileExists(ExpandConstant('{sys}\xvidcore.dll')) and
FileExists(ExpandConstant('{sys}\xvidvfw.dll')) and
RegValueExists(HKEY_LOCAL_MACHINE,'SOFTWARE\Micros oft\Windows NT\CurrentVersion\Drivers32','VIDC.XVID')) then
try
XvidDelete;
ExtractTemporaryFile('xvidcore.dll');
ExtractTemporaryFile('xvidvfw.dll');

f:=FileCopy(ExpandConstant('{tmp}\xvidcore.dll'),E xpandConstant('{sys}\xvidcore.dll'),False);
f:=f and FileCopy(ExpandConstant('{tmp}\xvidvfw.dll'),Expan dConstant('{sys}\xvidvfw.dll'),False);
f:=f and RegWriteStringValue(HKEY_LOCAL_MACHINE,'SOFTWARE\M icrosoft\Windows NT\CurrentVersion\Drivers32','VIDC.XVID','xvidvfw. dll');
if f then begin
XvidInstalled:=True;
CanUseXvid:=True;
end else XvidDelete;
except
end
else CanUseXvid:=True;
end;

procedure XvidUnInstall;
begin
if XvidInstalled then XvidDelete;
end;

Function cm(Message: String): String;
Begin
Result:= ExpandConstant('{cm:'+ Message +'}')
End;

function ProgressPercent:Integer;
var
pr,i1,i2: Extended;
begin
if (WizardForm.ProgressGauge.Position>WizardForm.ProgressGauge.Min) then begin
i1:=WizardForm.ProgressGauge.Position-WizardForm.ProgressGauge.Min;
i2:=WizardForm.ProgressGauge.Max-WizardForm.ProgressGauge.Min;
pr:=i1*100/i2;
Result:=Round(100*pr/100);;
end;
end;

function ProgressCallback(OveralPct,CurrentPct: integer;CurrentFile,TimeStr1,TimeStr2,TimeStr3:PAn siChar): longword;
var
Remaining: Integer;
begin
if OveralPct<=Wizardform.ProgressGauge.Max then
Wizardform.Progressgauge.Position := OveralPct;
Result := ISDoneCancel;
with WizardForm.ProgressGauge do begin
if position > 0 then Remaining:= trunc((GetTickCount - StartInstall) * Abs((max - position)/position));
WizardForm.Caption:=(IntToStr(ProgressPercent)+'%' )+(' Wait ' + TicksToTime(Remaining, cm('hour'), cm('min'), cm('sec'), false));
end;
end;

function Desktop: Boolean;
begin
Result:= ShortcutCB.Checked;
end;

function Icon2: Boolean;
begin
Result:= ExpandConstant('{code:GameIcon2}') <> '';
end;

function GameName(Default: String):String;
begin
Result:=GetIniString('Game','Name','',ExpandConsta nt('{tmp}\Setup.ini'));
end;

function GamePublisher(Default: String):String;
begin
Result:=GetIniString('Game','Publisher','',ExpandC onstant('{tmp}\Setup.ini'));
end;

function GameVersion(Default: String):String;
begin
Result:=GetIniString('Game','Version','',ExpandCon stant('{tmp}\Setup.ini'));
end;

function GameIcon1(Default: String):String;
begin
Result:=GetIniString('Game','Exec','',ExpandConsta nt('{tmp}\Setup.ini'));
end;

function GameIcon2N(Default: String):String;
begin
Result:=GetIniString('Game','Exec2Name','',ExpandC onstant('{tmp}\Setup.ini'));
end;

function GameIcon2(Default: String):String;
begin
Result:=GetIniString('Game','Exec2','',ExpandConst ant('{tmp}\Setup.ini'));
end;

function GameSize:Integer;
begin
Result:=GetIniInt('Game','Size',0,0,0,ExpandConsta nt('{tmp}\Setup.ini'));
end;

function Redist1Name(Default: String):String;
begin
Result:=GetIniString('Redist','Redist1Name','',Exp andConstant('{tmp}\Setup.ini'));
end;

function Redist2Name(Default: String):String;
begin
Result:=GetIniString('Redist','Redist2Name','',Exp andConstant('{tmp}\Setup.ini'));
end;

function Redist3Name(Default: String):String;
begin
Result:=GetIniString('Redist','Redist3Name','',Exp andConstant('{tmp}\Setup.ini'));
end;

var
FreeMB,TotalMB: cardinal;

procedure LogoLabelOnClick(Sender: TObject);
var
ErrorCode: Integer;
begin
ShellExec('open', 'http://fileforums.com/member.php?u=155239', '', '', SW_SHOWNORMAL, ewNoWait, ErrorCode)
end;

function CreateDS:boolean;
begin
if ShortcutCB.Checked then
Result:=True
else
Result:=False;
end;

Function NumToStr(Float: Extended): String;
Begin
Result:= Format('%.2n', [Float]); StringChange(Result, ',', ',');
while ((Result[Length(Result)] = '0') or (Result[Length(Result)] = ',')) and (Pos(',', Result) > 0) do
SetLength(Result, Length(Result)-1);
End;

function MbOrTb(Float: Extended): String;
begin
if Float < 1024 then Result:= NumToStr(Float)+' MB' else
if Float/1024 < 1024 then Result:= NumToStr(Float/1024)+' GB' else
Result:= NumToStr(Float/(1024*1024))+' TB';
end;

procedure DirEditOnChange(Sender: TObject);
var
HD1, HD2: Cardinal;
begin
GetSpaceOnDisk(ExtractFileDrive(WizardForm.DirEdit .Text), True, HD1, HD2);
DiskSpaceLablel.Caption:='Drive ' + ExtractFileDrive(WizardForm.DirEdit.Text) + ' Needed ' +MbOrTb(GameSize)+'('+MbOrTb(HD1)+'Available)';
end;

procedure CheckBoxOnclick(Sender:TObject);
begin
sndPlaySound(ExpandConstant('{tmp}\Click.wav'), $0001);
end;

procedure CreateDLabelOnclick(Sender:TObject);
begin
if ShortcutCB.Checked=true then ShortcutCB.Checked:=False else ShortcutCB.Checked:=true;
end;

procedure DirectXLabelOnclick(Sender:TObject);
begin
if DirectXCB.Checked=true then DirectXCB.Checked:=False else DirectXCB.Checked:=true;
end;

procedure VisualCLabelOnclick(Sender:TObject);
begin
if VisualCCB.Checked=true then VisualCCB.Checked:=False else VisualCCB.Checked:=true;
end;

procedure SocialLabelOnclick(Sender:TObject);
begin
if SocialCB.Checked=true then SocialCB.Checked:=False else SocialCB.Checked:=true;
end;

function InitializeSetup:boolean;
begin
if FileExists(ExpandConstant('{src}\Setup.ini')) = False then
MsgBox('Cannot locate configuration file.', mbInformation, MB_OK)
else
FileCopy(ExpandConstant('{src}\Setup.ini'),ExpandC onstant('{tmp}\Setup.ini'),False);
Result:=FileExists(ExpandConstant('{src}\Setup.ini '));
XvidInstall;
#ifexist "Image\Video.avi"
if not FileExists(ExpandConstant('{tmp}\video.avi')) then ExtractTemporaryFile('video.avi');
#endif
ExtractTemporaryFile('splash.png');
ShowSplashScreen(0,ExpandConstant('{tmp}\splash.pn g'),1000,1000,1000,0,255,False,$FFFFFF,10);
end;

procedure InitializeWizard();
var
mr: TMargins;
HD1, HD2: Cardinal;
begin
ExtractTemporaryFile('1.bmp');
ExtractTemporaryFile('2.bmp');
ExtractTemporaryFile('click.wav');

with WizardForm do begin
Font.Name:= 'Tahoma';
Font.Color:= $ffffff;
ClientWidth:= ScaleX(654);
ClientHeight:= ScaleY(402);
OuterNotebook.Hide;
InnerNotebook.Hide;
Center;
end;

WizardPanel := TPanel.Create(WizardForm);
with WizardPanel do begin
Name := 'WizardPanel';
Parent := WizardForm;
Left := ScaleX(0);
Top := ScaleY(313);
Width := ScaleX(185);
Height := ScaleY(355);
Align := alTop;
BorderStyle := bsNone;
end;

BmpFile:= TBitmapImage.Create(WizardForm);
with BmpFile do begin
Bitmap.LoadFromFile(ExpandConstant('{tmp}\1.bmp')) ;
SetBounds(ScaleX(0), ScaleY(0), ScaleX(654), ScaleY(355));
Stretch:= true;
Parent:= WizardPanel;
end;

WizardForm.DirEdit.Parent:=WizardPanel;
WizardForm.DirEdit.Top:=ScaleY(211);
WizardForm.DirEdit.Left:=ScaleX(120);
WizardForm.DirEdit.Width:=ScaleX(332);
WizardForm.DirEdit.Font.Color:=clblack;
WizardForm.DirBrowseButton.Parent:=WizardPanel;
WizardForm.DirBrowseButton.Top:=ScaleY(210);
WizardForm.DirBrowseButton.Left:=ScaleX(455);
WizardForm.DirBrowseButton.Width:=ScaleX(75);
WizardForm.DirBrowseButton.Height:=ScaleY(23);

TasksSeparateBevel := TBevel.Create(WizardForm);
with TasksSeparateBevel do
begin
Shape:=bsFrame;
Parent:=WizardPanel;
Width:=ScaleX(500);
Height:=ScaleY(80);
Left:=ScaleX(36);
Top:=ScaleY(189);
end;

TasksSeparateBevel2 := TBevel.Create(WizardForm);
with TasksSeparateBevel2 do
begin
Shape:=bsFrame;
Parent:=WizardPanel;
Width:=ScaleX(500);
Height:=ScaleY(60);
Left:=ScaleX(36);
Top:=ScaleY(289);
end;

DirWelcomeLabel:=TLabel.Create(WizardForm);
With DirWelcomeLabel do begin
Transparent:=true;
Parent:=WizardPanel;
Font.Color:=clWhite;
Font.Height:=ScaleY(-20);
Font.Style:=[fsBold];
SetBounds(ScaleX(16), ScaleY(120), ScaleX(200), ScaleY(30));
Caption:='<<Setup Wizard Configuration>>';
end;

DirWelcomeLabel1:=TLabel.Create(WizardForm);
With DirWelcomeLabel1 do begin
Transparent:=true;
Parent:=WizardPanel;
Font.Color:=clWhite;
Font.Height:=ScaleY(-14);
SetBounds(ScaleX(28), ScaleY(150), ScaleX(200), ScaleY(30));
Caption:='From here you can change the setup configuration.';
end;

InstallpathLabel:=TLabel.Create(WizardForm);
With InstallpathLabel do begin
Transparent:=true;
Parent:=WizardPanel;
Font.Color:=clWhite;
Font.Height:=ScaleY(-13);
SetBounds(ScaleX(46), ScaleY(211), ScaleX(200), ScaleY(30));
Caption:='Install Path:';
end;

GetSpaceOnDisk(ExtractFileDrive(WizardForm.DirEdit .Text), True, HD1, HD2);
DiskSpaceLablel:=TLabel.Create(WizardForm);
With DiskSpaceLablel do begin
Transparent:=true;
Parent:=WizardPanel;
Font.Color:=clWhite;
SetBounds(ScaleX(121), ScaleY(249), ScaleX(200), ScaleY(30));
Caption:='Drive ' + ExtractFileDrive(WizardForm.DirEdit.Text) + ' Needed ' +MbOrTb(GameSize)+'('+MbOrTb(HD1)+'Available)';
end;
WizardForm.DirEdit.OnChange:=@DirEditOnChange;

ShortcutLabel:=TLabel.Create(WizardForm);
With ShortcutLabel do begin
Transparent:=true;
Parent:=WizardPanel;
Font.Color:=clWhite;
Font.Height:=ScaleY(-13);
SetBounds(ScaleX(46), ScaleY(297), ScaleX(200), ScaleY(30));
Caption:='Shortcuts :';
end;

SoftwaresLabel:=TLabel.Create(WizardForm);
With SoftwaresLabel do begin
Transparent:=true;
Parent:=WizardPanel;
Font.Color:=clWhite;
Font.Height:=ScaleY(-13);
SetBounds(ScaleX(46), ScaleY(318), ScaleX(200), ScaleY(30));
Caption:='Softwares :';
end;

ShortcutCB := TNewCheckBox.Create(WizardForm);
with ShortcutCB do
begin
Parent := WizardPanel;
Left :=ScaleX(116);
Top :=ScaleY(299);
Width := ScaleX(14);
Height := ScaleY(14);
Cursor:=crHand;
Checked:=true;
OnClick:=@CheckBoxOnclick;
end;

CreateDLabel:=TLabel.Create(WizardForm);
With CreateDLabel do begin
Transparent:=true;
Parent:=WizardPanel;
Font.Color:=clWhite;
SetBounds(ScaleX(136), ScaleY(299), ScaleX(200), ScaleY(30));
Caption:='Create Desktop icon';
Cursor:=crHand;
OnClick:=@CreateDLabelOnclick;
end;

DirectXCB := TNewCheckBox.Create(WizardForm);
with DirectXCB do
begin
Parent := WizardPanel;
Left :=ScaleX(116);
Top :=ScaleY(320);
Width := ScaleX(14);
Height := ScaleY(14);
Cursor:=crHand;
Checked:=true;
OnClick:=@CheckBoxOnclick;
end;

DirectXLabel:=TLabel.Create(WizardForm);
With DirectXLabel do begin
Transparent:=true;
Parent:=WizardPanel;
Font.Color:=clWhite;
SetBounds(ScaleX(136), ScaleY(320), ScaleX(200), ScaleY(30));
Caption:='Install ' + ExpandConstant('{code:Redist1Name}');
Cursor:=crHand;
OnClick:=@DirectXLabelOnclick;
end;

VisualCCB := TNewCheckBox.Create(WizardForm);
with VisualCCB do
begin
Parent := WizardPanel;
Left :=ScaleX(250);
Top :=ScaleY(320);
Width := ScaleX(14);
Height := ScaleY(14);
Cursor:=crHand;
Checked:=true;
OnClick:=@CheckBoxOnclick;
end;

VisualCLabel:=TLabel.Create(WizardForm);
With VisualCLabel do begin
Transparent:=true;
Parent:=WizardPanel;
Font.Color:=clWhite;
SetBounds(ScaleX(270), ScaleY(320), ScaleX(200), ScaleY(30));
Caption:='Install ' + ExpandConstant('{code:Redist2Name}');
Cursor:=crHand;
OnClick:=@VisualCLabelOnclick;
end;

SocialCB := TNewCheckBox.Create(WizardForm);
with SocialCB do
begin
Parent := WizardPanel;
Left :=ScaleX(410);
Top :=ScaleY(320);
Width := ScaleX(14);
Height := ScaleY(14);
Cursor:=crHand;
Checked:=true;
OnClick:=@CheckBoxOnclick;
end;

SocialLabel:=TLabel.Create(WizardForm);
With SocialLabel do begin
Transparent:=true;
Parent:=WizardPanel;
Font.Color:=clWhite;
SetBounds(ScaleX(430), ScaleY(320), ScaleX(200), ScaleY(30));
Caption:='Install ' + ExpandConstant('{code:Redist3Name}');
Cursor:=crHand;
OnClick:=@SocialLabelOnclick;
end;

WLabel:=TLabel.Create(WizardForm);
With WLabel do begin
Transparent:=true;
Parent:=WizardPanel;
Font.Color:=clWhite;
Font.Size:=15;
Font.Style:=[fsBold];
SetBounds(ScaleX(160), ScaleY(315), ScaleX(200), ScaleY(30));
Caption:='<<Welcome to Setup Wizard>>';
end;

EndFailLabel:=TLabel.Create(WizardForm);
With EndFailLabel do begin
Transparent:=true;
Parent:=WizardPanel;
Font.Color:=clRed;
Font.Size:=15;
Font.Style:=[fsBold];
SetBounds(ScaleX(64), ScaleY(315), ScaleX(200), ScaleY(30));
Caption:='<<Setup encountered an error while Installing>>';
end;

EndPassLabel:=TLabel.Create(WizardForm);
With EndPassLabel do begin
Transparent:=true;
Parent:=WizardPanel;
Font.Color:=clWhite;
Font.Size:=14;
Font.Style:=[fsBold];
SetBounds(ScaleX(120), ScaleY(315), ScaleX(200), ScaleY(30));
Caption:='<<Installation Completed Successfully>>';
end;

WizardForm.NextButton.SetBounds(ScaleX(530), ScaleY(365), ScaleX(90), ScaleY(30));
WizardForm.CancelButton.SetBounds(ScaleX(530), ScaleY(365), ScaleX(90), ScaleY(30));

WizardForm.ProgressGauge.Parent:=WizardForm
WizardForm.ProgressGauge.Top:=ScaleY(365);
WizardForm.ProgressGauge.Left:=ScaleX(10);
WizardForm.ProgressGauge.Height:=ScaleY(31);
WizardForm.ProgressGauge.Width:=ScaleX(510)

LogoLinkLabel:=TLabel.Create(WizardForm);
With LogoLinkLabel do begin
Transparent:=true;
Parent:=WizardForm;
Font.Color:=clWhite;
SetBounds(ScaleX(23), ScaleY(365), ScaleX(200), ScaleY(30));
LogoLinkLabel.Cursor:=crHand;
LogoLinkLabel.OnClick:=@LogoLabelOnClick;
end;

BGRadio1:=TNewRadioButton.Create(WizardForm)
BGRadio1.Parent:=WizardForm;
BGRadio1.Caption:='Video BG';
BGRadio1.SetBounds(WizardForm.NextButton.Left + ScaleX(-90),WizardForm.NextButton.Top + ScaleY(-2),ScaleX(70),ScaleY(13));

BGRadio2:=TNewRadioButton.Create(WizardForm)
BGRadio2.Parent:=WizardForm;
#ifdef video
BGRadio1.Enabled:=True;
BGRadio1.Checked:=True;
BGRadio2.Checked:=False;
#else
BGRadio1.Enabled:=False;
BGRadio1.Checked:=False;
BGRadio2.Checked:=True;
#endif
BGRadio2.Caption:='Picture BG';
BGRadio2.SetBounds(WizardForm.NextButton.Left-ScaleX(90),WizardForm.NextButton.Top+ScaleY(17),Sc aleX(70),ScaleY(13));

ExtractTemporaryFile('Logo.png');
ISWin7_AddCtrl(WizardForm.BackButton.Handle);
ISWin7_AddCtrl(BGRadio1.Handle);
ISWin7_AddCtrl(BGRadio2.Handle);
ISWin7_AddCtrl(WizardForm.NextButton.Handle);
ISWin7_AddCtrl(WizardForm.CancelButton.Handle);
ISWin7_AddCtrl(WizardForm.DirBrowseButton.Handle);
ISWin7_Apply(ExpandConstant('{tmp}\logo.png'), ScaleX(23), ScaleY(358), ScaleX(0), ScaleY(0), 0, WizardForm.ClientHeight - WizardPanel.Height, WizardForm.Handle);
end;

function DirBrowseButtonClick(CurPageID: Integer): Boolean;
begin
sndPlaySound(ExpandConstant('{tmp}\click.wav'), $0001);
Result := True;
end;

function GroupBrowseButtonClick(CurPageID: Integer): Boolean;
begin
sndPlaySound(ExpandConstant('{tmp}\click.wav'), $0001);
Result := True;
end;

function NextButtonClick(CurPageID: Integer): Boolean;
begin
sndPlaySound(ExpandConstant('{tmp}\click.wav'), $0001);
Result := True;
end;

function BackButtonClick(CurPageID: Integer): Boolean;
begin
sndPlaySound(ExpandConstant('{tmp}\click.wav'), $0001);
Result := True;
end;

procedure CancelButtonClick(CurPageID: Integer; var Cancel, Confirm: Boolean);
begin
sndPlaySound(ExpandConstant('{tmp}\click.wav'), $0001);
Confirm:=False;
Cancel:=ExitSetupMsgBox;
if CurPageID=wpInstalling then begin;
if Cancel then begin
ISDoneError:=True;
ISDoneCancel:=1;
DelTree(ExpandConstant('{app}'), True, True, True);
WizardForm.CancelButton.Enabled:=False;
end;
end;
end;

procedure TaskingProgress(h: Longword; msg: Longword; idevent: Longword; dwTime: Longword);
begin
WizardForm.ProgressGauge.Max:=100;
if WizardForm.ProgressGauge.Position = 100 then
WizardForm.ProgressGauge.Position:=0;
WizardForm.ProgressGauge.Position:=WizardForm.Prog ressGauge.Position + 10;
end;

procedure VideoPlay();
begin
begin
mciSendString('open "'+ ExpandConstant('{tmp}\Video.avi') +'" alias AVIFile parent '+ IntToStr(WizardForm.Handle) +' style child','',0,0)
mciSendString('put AVIFile window at 0 0 654 355','',0,0);
mciSendString('play AVIFile repeat','',0,0)
end;
end;

procedure OnTimer(HandleW, msg, idEvent, TimeSys: LongWord);
begin
CurrentPicture:=CurrentPicture+1;
if CurrentPicture=piclist.count+1 then CurrentPicture:=1;
ShowImage(piclist.strings[CurrentPicture - 1], 1);
end;

procedure MakeSlideShow();
var
i :integer;
begin
PicList:=tstringlist.Create;
#ifexist "Slides\1.jpg"
#sub ExtractFile
ExtractTemporaryFile('{#i}.jpg');
#endsub
#for {i = 1; FileExists(StringChange("Slides\FileName.jpg", "FileName", Str(i))) != 0; i++} ExtractFile
#endif
i:=1;
repeat
piclist.add(ExpandConstant('{tmp}\'+IntToStr(i)+'. jpg'));
i:=i+1;
until FileExists(ExpandConstant('{tmp}\'+IntToStr(i)+'.j pg')) = False;
InitializeSlideShow(WizardForm.Handle, 0, 0, scaleX(654), ScaleY(355), true, 2);
CurrentPicture:=2;
ShowImage(piclist.strings[CurrentPicture-2], 1);
end;

Procedure HideComponents();
begin
WizardForm.ProgressGauge.Hide;
WizardForm.DirEdit.Hide;
WizardForm.BackButton.Hide;
WizardForm.NextButton.Hide;
WizardForm.DirBrowseButton.Hide;
TasksSeparateBevel.Hide;
TasksSeparateBevel2.Hide;
DirWelcomeLabel.Hide;
DirWelcomeLabel1.Hide;
InstallpathLabel.Hide;
DiskSpaceLablel.Hide;
ShortcutLabel.Hide;
ShortcutCB.Hide;
CreateDLabel.Hide;
SoftwaresLabel.Hide;
DirectXCB.Hide;
DirectXLabel.Hide;
VisualCCB.Hide;
VisualCLabel.Hide;
SocialCB.Hide;
SocialLabel.Hide;
WLabel.hide;
EndFailLabel.Hide;
EndPassLabel.Hide;
BGRadio1.Hide;
BGRadio2.Hide;

end;

function InstallationError: Boolean;
begin
if ISDoneError = True then Result := False else Result := True;
end;

procedure CurPageChanged(CurPageID: integer);
begin

if CurPageID=wpWelcome then
begin
HideComponents;
WLabel.show;
WizardForm.NextButton.Show;
WizardForm.NextButton.Caption := 'Configure';
end;

if CurPageID=wpSelectDir then
begin
HideComponents;
BmpFile.Bitmap.LoadFromFile(ExpandConstant('{tmp}\ 2.bmp'));
WizardForm.DirEdit.Show;
WizardForm.NextButton.Show;
WizardForm.NextButton.Caption := 'Begin Install';
WizardForm.DirBrowseButton.Show;
TasksSeparateBevel.Show;
TasksSeparateBevel2.Show;
DirWelcomeLabel.Show;
DirWelcomeLabel1.Show;
InstallpathLabel.Show;
DiskSpaceLablel.Show;
ShortcutLabel.Show;
ShortcutCB.Show;
CreateDLabel.Show;
BGRadio1.Show;
BGRadio2.Show;
SoftwaresLabel.Visible:=ExpandConstant('{code:Redi st1Name}') <> '';
DirectXCB.Visible:=ExpandConstant('{code:Redist1Na me}') <> '';
DirectXLabel.Visible:=ExpandConstant('{code:Redist 1Name}') <> '';
VisualCCB.Visible:=ExpandConstant('{code:Redist2Na me}') <> '';
VisualCLabel.Visible:=ExpandConstant('{code:Redist 2Name}') <> '';
SocialCB.Visible:=ExpandConstant('{code:Redist3Nam e}') <> '';
SocialLabel.Visible:=ExpandConstant('{code:Redist3 Name}') <> '';
end;

if CurPageID=wpInstalling then
begin
HideComponents;
If BGRadio1.Checked=true then
begin
VideoPlay;
end;
If BGRadio2.Checked=True then
Begin
MakeSlideShow;
SetTimer(0, 101, 3000, CallbackAddr('OnTimer'));
end;
WizardForm.CancelButton.show;
WizardForm.ProgressGauge.show;
end;

if CurPageID=wpInstalling then
begin
iswin7_showlogo(false);
end else begin
iswin7_showlogo(true);
end;

if CurPageID=wpFinished then
begin
HideComponents;
mciSendString('Close AVIFile','',0,0);
EndPassLabel.Show;
DeinitializeSlideShow;
WizardForm.NextButton.Show;
BmpFile.Bitmap.LoadFromFile(ExpandConstant('{tmp}\ 1.bmp'));
WizardForm.Caption:='Setup - ' + ExpandConstant('{code:GameName}');
end;

if (CurPageID = wpFinished) and ISDoneError then
begin
EndPassLabel.Hide;
EndFailLabel.show;
end;
end;

procedure CurStepChanged(CurStep: TSetupStep);
var
res, i, ResultCode: integer;
Arc1, Arc2, Arc3: Array of String;
PCF: String;
begin

If CurStep = ssInstall then
begin
StartInstall:= GetTickCount
ExtractTemporaryFile('arc.ini');
ExtractTemporaryFile('unarc.dll');
ExtractTemporaryFile('english.ini');
ExtractTemporaryFile('unrar.dll');
ExtractTemporaryFile('facompress.dll');
ExtractTemporaryFile('facompress_mt.dll');
ExtractTemporaryFile('CLS-precomp.dll');
ExtractTemporaryFile('CLS-MSC.dll');
ExtractTemporaryFile('CLS-srep.dll');
ExtractTemporaryFile('packjpg_dll.dll');
ExtractTemporaryFile('zlib1.dll');
ExtractTemporaryFile('lzma64.exe');
ExtractTemporaryFile('srep.exe');
ExtractTemporaryFile('srep64.exe');
ExtractTemporaryFile('precomp038_Inside.exe');
ExtractTemporaryFile('precomp040_Inside.exe');
ExtractTemporaryFile('precomp041_Inside.exe');
ExtractTemporaryFile('precomp042_Inside.exe');
PCF:=GetIniString('Settings', 'Precomp', '', ExpandConstant('{tmp}\Setup.ini'));
if PCF = '0.38' then
begin
ExtractTemporaryFile('precomp038.exe');
FileCopy(ExpandConstant('{tmp}\precomp038_Inside.e xe'),ExpandConstant('{tmp}\precomp.exe'),False);
end;
if PCF = '0.40' then
begin
ExtractTemporaryFile('precomp040.exe');
FileCopy(ExpandConstant('{tmp}\precomp040_Inside.e xe'),ExpandConstant('{tmp}\precomp.exe'),False);
end;
if PCF = '0.41' then
begin
ExtractTemporaryFile('precomp041.exe');
FileCopy(ExpandConstant('{tmp}\precomp041_Inside.e xe'),ExpandConstant('{tmp}\precomp.exe'),False);
end;
if PCF = '0.42' then
begin
ExtractTemporaryFile('precomp042.exe');
FileCopy(ExpandConstant('{tmp}\precomp042_Inside.e xe'),ExpandConstant('{tmp}\precomp.exe'),False);
end;
i:=1;
if (GetIniString('FreearcFile' + IntToStr(i),'Archive','',ExpandConstant('{tmp}\Set up.ini')) <> '') or
(GetIniString('7ZipFile' + IntToStr(i),'Archive','',ExpandConstant('{tmp}\Set up.ini')) <> '') or
(GetIniString('RarFile' + IntToStr(i),'Archive','',ExpandConstant('{tmp}\Set up.ini')) <> '') then
begin
WizardForm.ProgressGauge.Max:=0;
repeat
WizardForm.ProgressGauge.Max:= WizardForm.ProgressGauge.Max + 1000;
i:= i + 1;
until (GetIniString('FreearcFile' + IntToStr(i),'Archive','',ExpandConstant('{tmp}\Set up.ini')) = '') and
(GetIniString('7ZipFile' + IntToStr(i),'Archive','',ExpandConstant('{tmp}\Set up.ini')) = '') and
(GetIniString('RarFile' + IntToStr(i),'Archive','',ExpandConstant('{tmp}\Set up.ini')) = '');
end;
if ISDoneInit(ExpandConstant('{tmp}\records.inf'), $F777, 0,0,0, MainForm.Handle, 512, @ProgressCallback) then begin
repeat
ChangeLanguage('English');
if not SrepInit('',512,0) then ISDoneError := True;
if not PrecompInit('',128,0) then ISDoneError := True;
if not FileSearchInit(true) then ISDoneError := True;

i:=1;
if (GetIniString('FreearcFile' + IntToStr(i),'Archive','',ExpandConstant('{tmp}\Set up.ini')) <> '') or
(GetIniString('7ZipFile' + IntToStr(i),'Archive','',ExpandConstant('{tmp}\Set up.ini')) <> '') or
(GetIniString('RarFile' + IntToStr(i),'Archive','',ExpandConstant('{tmp}\Set up.ini')) <> '') then
begin
SetArrayLength(Arc1,4);
SetArrayLength(Arc2,4);
SetArrayLength(Arc3,4);
repeat
Arc1[0]:=ExpandConstant(GetIniString('FreearcFile' + IntToStr(i),'Archive','',ExpandConstant('{tmp}\Set up.ini')));
Arc1[1]:=ExpandConstant(GetIniString('FreearcFile' + IntToStr(i),'Output','',ExpandConstant('{tmp}\Setu p.ini')));
Arc1[2]:=ExpandConstant(GetIniString('FreearcFile' + IntToStr(i),'Disk','1',ExpandConstant('{tmp}\Setup .ini')));
Arc1[3]:=GetIniString('FreearcFile' + IntToStr(i),'Password','',ExpandConstant('{tmp}\Se tup.ini'));

Arc2[0]:=ExpandConstant(GetIniString('7ZipFile' + IntToStr(i),'Archive','',ExpandConstant('{tmp}\Set up.ini')));
Arc2[1]:=ExpandConstant(GetIniString('7ZipFile' + IntToStr(i),'Output','',ExpandConstant('{tmp}\Setu p.ini')));
Arc2[2]:=ExpandConstant(GetIniString('7ZipFile' + IntToStr(i),'Disk','1',ExpandConstant('{tmp}\Setup .ini')));
Arc2[3]:=GetIniString('7ZipFile' + IntToStr(i),'Password','',ExpandConstant('{tmp}\Se tup.ini'));

Arc3[0]:=ExpandConstant(GetIniString('RarFile' + IntToStr(i),'Archive','',ExpandConstant('{tmp}\Set up.ini')));
Arc3[1]:=ExpandConstant(GetIniString('RarFile' + IntToStr(i),'Output','',ExpandConstant('{tmp}\Setu p.ini')));
Arc3[2]:=ExpandConstant(GetIniString('RarFile' + IntToStr(i),'Disk','1',ExpandConstant('{tmp}\Setup .ini')));
Arc3[3]:=GetIniString('RarFile' + IntToStr(i),'Password','',ExpandConstant('{tmp}\Se tup.ini'));

if Arc1[0] <> '' then
begin
if not FileExists(Arc1[0]) then
begin
if MsgBox('Insert disc: ' + Arc1[2], mbError, MB_OKCANCEL) = IDCANCEL then ISDoneError := True;
end else begin
if not ISArcExtract( 0, 0, Arc1[0], Arc1[1], '', false, Arc1[3], ExpandConstant('{tmp}\arc.ini'), ExpandConstant('{app}'), False) then ISDoneError := True;
i:= i + 1;
end;
end;

if Arc2[0] <> '' then
begin
if not FileExists(Arc2[0]) then
begin
if MsgBox('Insert disc: ' + Arc2[2], mbError, MB_OKCANCEL) = IDCANCEL then ISDoneError := True;
end else begin
if not IS7ZipExtract( 0, 0, Arc2[0], Arc2[1], false, Arc2[3]) then ISDoneError := True;
i:= i + 1;
end;
end;

if Arc3[0] <> '' then
begin
if not FileExists(Arc3[0]) then
begin
if MsgBox('Insert disc: ' + Arc3[2], mbError, MB_OKCANCEL) = IDCANCEL then ISDoneError := True;
end else begin
if not ISRarExtract( 0, 0, Arc3[0], Arc3[1], false, Arc3[3]) then ISDoneError := True;
i:= i + 1;
end;
end;

until ((GetIniString('FreearcFile' + IntToStr(i),'Archive','',ExpandConstant('{tmp}\Set up.ini')) = '') and
(GetIniString('7ZipFile' + IntToStr(i),'Archive','',ExpandConstant('{tmp}\Set up.ini')) = '') and
(GetIniString('RarFile' + IntToStr(i),'Archive','',ExpandConstant('{tmp}\Set up.ini')) = '')) or (ISDoneError = True);
end;
until true;
ISDoneStop;
end;
end;

if (CurStep=ssPostInstall) and ISDoneError then begin
Exec(ExpandConstant('{uninstallexe}'), '/VERYSILENT','', sw_Hide, ewWaitUntilTerminated, ResultCode);
end;

if (CurStep=ssPostInstall) and (ISDoneError = False) then begin
if (DirectXCB.Checked = True) then begin
SetTimer(WizardForm.Handle,1,1000,CallBackAddr('Ta skingProgress'));
WizardForm.Caption := 'Installing ' + ExpandConstant('{code:Redist1Name}') + '...';
Exec(ExpandConstant(GetIniString('Redist','Redist1 Command', '', ExpandConstant('{tmp}\Setup.ini'))), ExpandConstant(GetIniString('Redist','Redist1Param eter', '', ExpandConstant('{tmp}\Setup.ini'))), '', SW_SHOW, ewWaitUntilTerminated, ResultCode)
end;
if (VisualCCB.Checked = True) then begin
SetTimer(WizardForm.Handle,1,1000,CallBackAddr('Ta skingProgress'));
WizardForm.Caption := 'Installing ' +ExpandConstant('{code:Redist2Name}') + '...';
Exec(ExpandConstant(GetIniString('Redist','Redist2 Command', '', ExpandConstant('{tmp}\Setup.ini'))), ExpandConstant(GetIniString('Redist','Redist2Param eter', '', ExpandConstant('{tmp}\Setup.ini'))), '', SW_SHOW, ewWaitUntilTerminated, ResultCode)
end;
if (SocialCB.Checked = True) then begin
SetTimer(WizardForm.Handle,1,1000,CallBackAddr('Ta skingProgress'));
WizardForm.Caption := 'Installing ' + ExpandConstant('{code:Redist3Name}') + '...';
Exec(ExpandConstant(GetIniString('Redist','Redist3 Command', '', ExpandConstant('{tmp}\Setup.ini'))), ExpandConstant(GetIniString('Redist','Redist3Param eter', '', ExpandConstant('{tmp}\Setup.ini'))), '', SW_SHOW, ewWaitUntilTerminated, ResultCode)
end;
end;
end;

function ShouldSkipPage(PageID: Integer): Boolean;
begin
if (PageID=wpSelectProgramGroup) or (PageID=wpReady) or (PageID=wpSelectComponents) then Result:=true;
end;

procedure DeinitializeSetup();
begin
XvidUnInstall;
DeinitializeSlideShow;
ISWin7_Shutdown();
mciSendString('Close AVIFile','',0,0);
end;