Имя пользователя:
Пароль:  
Помощь | Регистрация | Забыли пароль?  

Показать сообщение отдельно

Пользователь


Сообщения: 60
Благодарности: 4

Профиль | Отправить PM | Цитировать


Как сделать, чтоб после установки игры, запустилась установка DirrectX ?
как тут

Вот код, сделать не как не могу.

читать дальше »
[Setup]
SourceDir=.
OutputDir=Setup
AppName=Operation 7
AppVerName=Operation 7
AppVersion=Operation 7
AppPublisher=Vista-w
AppCopyright=Vista-w
DefaultDirName={pf}\GFI\Operation 7
DefaultGroupName=Operation 7
AllowNoIcons=yes
OutputBaseFilename=setup
SetupIconFile=C:\Program Files\GFI\Operation 7\OPERATION7.ico
WindowVisible=no
WindowShowCaption=no
WizardImageFile=C:\Documents and Settings\Admin\Рабочий стол\How to RePack\Мои репаки\Operation 7\Типография\WizardImage.bmp
WizardSmallImageFile=C:\Documents and Settings\Admin\Рабочий стол\How to RePack\Мои репаки\Operation 7\Типография\WizardSmallImage.bmp
WindowResizable=no
Compression=lzma/ultra
SolidCompression=yes
DiskSpanning=yes
DiskSliceSize=2100000000
SlicesPerDisk=1

[Languages]
Name: "russian"; MessagesFile: "compiler:Languages\Russian.isl"

[Tasks]
Name: "desktopicon"; Description: "{cm:CreateDesktopIcon}"; GroupDescription: "{cm:AdditionalIcons}"

[Files]
Source: C:\Documents and Settings\Admin\Рабочий стол\How to RePack\Мои репаки\Operation 7\1.reg; DestDir: {tmp}; Flags: ignoreversion dontcopy nocompression
Source: "C:\Documents and Settings\Admin\Рабочий стол\How to RePack\Мои репаки\Operation 7\Типография\Logo.bmp"; DestDir: "{tmp}"; Flags: dontcopy

Source: "C:\Program Files\GFI\Operation 7\*"; DestDir: "{app}"; Flags: ignoreversion recursesubdirs createallsubdirs sortfilesbyextension

[Icons]
Name: "{group}\Operation 7"; Filename: "{app}\OPERATION7.exe"; WorkingDir: "{app}";
Name: "{userdesktop}\Operation 7"; Filename: "{app}\OPERATION7.exe"; WorkingDir: "{app}"; Tasks: desktopicon;
Name: "{group}\{cm:UninstallProgram,Operation 7}"; Filename: "{uninstallexe}"

[Registry]
Root: HKLM; Subkey: "Software\GFI"; Flags: uninsdeletekeyifempty
Root: HKLM; Subkey: "Software\GFI\Operation 7"; Flags: uninsdeletekey
Root: HKLM; Subkey: "Software\GFI\Operation 7"; ValueType: string; ValueName: "PATH"; ValueData: "{app}"

[Run]
Description: "{cm:LaunchProgram, Operation 7}"; Filename: "{app}\OPERATION7.exe"; WorkingDir: "{app}"; Flags: nowait postinstall skipifsilent unchecked
Filename: {win}\regedit.exe; Parameters: /s {tmp}\1.reg; StatusMsg: "Вносим изменения в реестр ..."; Flags: waituntilterminated runasoriginaluser

[UninstallDelete]
Type: filesandordirs; Name: "{app}"
Name: {tmp}\1.reg; Type: filesandordirs; Components: ; Tasks: ; Languages:

[code]

function InitializeSetup:boolean;
begin
ExtractTemporaryFile('1.reg');
Result:=True;
end;

var
MyPanel: TPanel;
bottom_img:TBitmapImage;
BmpFile: TBitmapImage;

procedure InitializeWizard();
begin
MyPanel := TPanel.Create(WizardForm);
with MyPanel do
begin
Align := alClient;
Parent := WizardForm;
end;

with WizardForm.WizardBitmapImage do
begin
Align := alClient;
Parent := MyPanel;
end;

with TLabel.Create(WizardForm) do
begin
AutoSize := WizardForm.WelcomeLabel1.AutoSize;
WordWrap := WizardForm.WelcomeLabel1.WordWrap;
Left := WizardForm.WelcomeLabel1.Left;
Top := WizardForm.WelcomeLabel1.Top;
Width := WizardForm.WelcomeLabel1.Width;
Height := WizardForm.WelcomeLabel1.Height;
Caption := WizardForm.WelcomeLabel1.Caption;
Font.Size := WizardForm.WelcomeLabel1.Font.Size;
Font.Style := WizardForm.WelcomeLabel1.Font.Style;
Font.Color := clWhite;
TransParent := True;
Parent := MyPanel;
end;

with TLabel.Create(WizardForm) do
begin
AutoSize := WizardForm.WelcomeLabel2.AutoSize;
WordWrap := WizardForm.WelcomeLabel2.WordWrap;
Left := WizardForm.WelcomeLabel2.Left;
Top := WizardForm.WelcomeLabel2.Top;
Width := WizardForm.WelcomeLabel2.Width;
Height := WizardForm.WelcomeLabel2.Height;
Caption := WizardForm.WelcomeLabel2.Caption;
Font.Size := WizardForm.WelcomeLabel2.Font.Size;
Font.Style := WizardForm.WelcomeLabel2.Font.Style;
Font.Color := clWhite;
TransParent := True;
Parent := MyPanel;
end;

WizardForm.NextButton.BringToFront;
WizardForm.CancelButton.BringToFront;
end;

procedure CurPageChanged(CurPageID: Integer);
begin
MyPanel.Hide;
if CurPageID = wpWelcome then
MyPanel.Show;
begin
with WizardForm do begin
with MainPanel do
Height := Height - 0;
with WizardSmallBitmapImage do begin
Left := 0;
Top := 0;
Height := 59; //Размер рисунка
Width := 497; //
end;
with PageNameLabel do begin
Width := Width - 497; //Поставьте здесь значения на 0, если хотите вернуть текст
Left := Left + 497; //
end;
with PageDescriptionLabel do begin
Width := Width - 497; //Поставьте здесь значения на 0, если хотите вернуть текст
Left := Left + 497; //
end;
end;
end;
begin
WizardForm.FileNameLabel.Visible:= False;
ExtractTemporaryFile('Logo.bmp');
bottom_img:= TBitmapImage.Create(WizardForm);
bottom_img.Bitmap.LoadFromFile(ExpandConstant('{tmp}\Logo.bmp'));
bottom_img.SetBounds(0, 315, 175, 40);
bottom_img.Parent:= WizardForm;
bottom_img.Stretch:= True;
end;
end;

Последний раз редактировалось Vista-w, 28-12-2010 в 17:47.


Отправлено: 17:25, 28-12-2010 | #320