AtotIK 580 #263066 Posted April 17, 2015 Dark_Knight_MiX, мая есть не уметь читать буква? ---> ВТОРОЙ <--- Quote Share this post Link to post Short link Share on other sites
Kotyarko_O 1,906 #263067 Posted April 17, 2015 там же ещё присвоить всем компонентам идентификаторы Может я что-то не понял, но зачем?Можно записывать в файл имя компонента, а потом по факту его присутствия в текстовике отмечать сам компонент. Quote Share this post Link to post Short link Share on other sites
Ekspoint 2,122 #263068 Posted April 17, 2015 Dark_Knight_MiX, мая есть не уметь читать буква? ---> ВТОРОЙ <--- ааа, этот чтоль function SetupConfigLoad_1(const TagName, CompNo: String): Boolean; var I, CompDigit, TagPos: Integer; SetupConfig: TStringList; SetupConfigDir, Tmp, Tag, Line, FilePath: String; begin Result:=False; FilePath:=ExpandConstant('C:\Setup.ini'); If FileExists(FilePath) then begin Tag:=TagName; SetupConfigDir:=ExpandConstant('C:\'); SetupConfig:=TStringList.Create; try SetupConfig.LoadFromFile(SetupConfigDir + '\Setup.ini'); for I:=0 to SetupConfig.Count - 1 do begin Line:=SetupConfig[I]; TagPos:=Pos(Tag, Line); if TagPos > 0 then begin Result:=True; CompDigit:=StrToInt(CompNo); CustomPage_1ComponentsList.CheckItem(CompDigit, coCheck); end; Log(Line); end; finally SetupConfig.Free; end; end; Quote Share this post Link to post Short link Share on other sites
AtotIK 580 #263069 Posted April 17, 2015 Dark_Knight_MiX, троллишь меня? Второй вариант решения проблемы. Kotyarko_O, мне захотелось ввести именно идентификатор. "St4\Hangar\Statistics\Day" для меня более удобночитаемые данные. Quote Share this post Link to post Short link Share on other sites
Ekspoint 2,122 #263070 Posted April 17, 2015 Dark_Knight_MiX, троллишь меня? Второй вариант решения проблемы. Kotyarko_O, мне захотелось ввести именно идентификатор. "St4\Hangar\Statistics\Day" для меня более удобночитаемые данные. ну уже вариантов нет, наверно это function SearchValues(file,sValue:Ansistring): Boolean; var ss: TArrayOfString; i: Integer; begin LoadStringsFromFile(file, ss); for i:=0 to GetArrayLength(ss)-1 do begin if Pos(sValue, ss[i])>0 then begin Result := true; Exit; end else Result := false; end; end; procedure InitializeWizard(); begin WizardForm.ComponentsList.Checked[0]:= SearchValues(ExpandConstant('{src}\1.txt'),'тополя ля ля ля'); end; Так как мне прикрутить пост Quote Share this post Link to post Short link Share on other sites
Kotyarko_O 1,906 #263071 Posted April 17, 2015 Так как мне прикрутить Отвёрткой. 1 Quote Share this post Link to post Short link Share on other sites
AtotIK 580 #263072 Posted April 17, 2015 Так как мне прикрутить Думай логически. Quote Share this post Link to post Short link Share on other sites
Ekspoint 2,122 #263074 Posted April 17, 2015 (edited) Отвёрткой. Думай логически. не доходит помогите пожалуйста Edited April 17, 2015 by Dark_Knight_MiX Quote Share this post Link to post Short link Share on other sites
Fenixx 1 #263252 Posted April 19, 2015 Всем привет! как правильно прописать в скрипте компоненты? как начинаю ставить инсталлятор тупо не открывает 'Вот как тут не открывает инсталлятор' //====={ Сюда прописываешь те файлы и папки которые закинул в Mods }=====\\[Types]Name: custom; Description: Full installation; Flags: iscustom[Components]Name: KMP; Description: KPAH Mod Pack; Types: custom; Flags: fixedName: KMP\P; Description: 1. Прицел.; Flags: disablenouninstallwarningName: KMP\DP; Description: 2. Дамаг панель.; Flags: disablenouninstallwarningName: KMP\ZK; Description: 2. Звуковой мод звонок при крите модуля.; Flags: disablenouninstallwarningName: KMP\Z; Description: 3. Zoom.; Flags: disablenouninstallwarningName: KMP\Z\NS; Description: а. NoScroll- колёсико не переключает в снайперский режим; Flags: checkablealoneName: KMP\Z\ZX4; Description: б. 4-х позиционный снайперский прицел; Flags: checkablealoneName: KMP\T; Description: 4. Дерево развития.Name: KMP\I; Description: 5. Информационная панель выбранной цели.Name: KMP\CM; Description: 6. Цветные сообщения(ЯсенКрасен).Name: KMP\CLOCK; Description: 7. Часы в ангаре.Name: KMP\A; Description: 8. Ангар.Name: KMP\XVM; Description: 9. Пользомер(Оленемер).[Files]Source: MODS\PRICEL\*; DestDir: {app}; Flags: ignoreversion recursesubdirs createallsubdirs; Components: KMP\PSource: MODS\DAMAGEPANEL\*; DestDir: {app}; Flags: ignoreversion recursesubdirs createallsubdirs; Components: KMP\DP//=== звонок крита ===///=== ставить вначале команду копирование файлов, а уже потом установку мода ===\\:Source: {app}\res\audio\*; DestDir: {app}\res_mods\0.8.6\audio\; Flags: external recursesubdirs skipifsourcedoesntexist; Components: KMP\ZKSource: MODS\ZVONOK\*; DestDir: {app}; Flags: ignoreversion recursesubdirs createallsubdirs; Components: KMP\ZKSource: MODS\ZOOM\COMANDOR\*; DestDir: {app}; Flags: ignoreversion recursesubdirs createallsubdirs; Components: KMP\ZSource: MODS\ZOOM\NOSCROLL\*; DestDir: {app}; Flags: ignoreversion recursesubdirs createallsubdirs; Components: KMP\Z\NSSource: MODS\ZOOM\ZOOM4X\*; DestDir: {app}; Flags: ignoreversion recursesubdirs createallsubdirs; Components: KMP\Z\ZX4Source: MODS\TREE\*; DestDir: {app}; Flags: ignoreversion recursesubdirs createallsubdirs; Components: KMP\TSource: MODS\INFO\*; DestDir: {app}; Flags: ignoreversion recursesubdirs createallsubdirs; Components: KMP\ISource: MODS\COLORMESENGER\*; DestDir: {app}; Flags: ignoreversion recursesubdirs createallsubdirs; Components: KMP\CMSource: MODS\CLOCK\*; DestDir: {app}; Flags: ignoreversion recursesubdirs createallsubdirs; Components: KMP\CLOCKSource: MODS\ANGAR\*; DestDir: {app}; Flags: ignoreversion recursesubdirs createallsubdirs; Components: KMP\ASource: MODS\XVM\*; DestDir: {app}; Flags: ignoreversion recursesubdirs createallsubdirs; Components: KMP\XVM 'Когда так нормально все запускает' [Components]Name: text; Description: Язык субтитров; Types: full; Flags: fixedName: text\rus; Description: Русский; Flags: exclusiveName: text\eng; Description: Английский; Flags: exclusiveName: voice; Description: Язык озвучки; Types: full; Flags: fixedName: voice\rus; Description: Русский; Flags: exclusiveName: voice\eng; Description: Английский; Flags: exclusive Quote Share this post Link to post Short link Share on other sites
AtotIK 580 #263255 Posted April 19, 2015 Fenixx, всё прекрасно работает: Но всё же порекомендовал бы использовать такой формат и привести всё в более удобочитаемый вид: [Types] Name: "full"; Description: "Полная установка"; Flags: iscustom; [Components] Name: "XVM"; Description: "XVM: расширенные маркеры, отлетающий урон, модификация захвата базы, миникарты и лог нанесённого урона"; Flags: disablenouninstallwarning; Types: full; Name: "XVM\Color"; Description: "Цветовая схема конфигурации:"; Flags: exclusive disablenouninstallwarning; Types: full; Name: "XVM\Color\Normal"; Description: "Стандартные цвета"; Flags: exclusive disablenouninstallwarning; Types: full; Name: "XVM\Color\Blindness"; Description: "Режим цветовой слепоты"; Flags: exclusive disablenouninstallwarning; Name: "XVM\Carousel"; Description: "Расширенная карусель танков:"; Flags: disablenouninstallwarning; Types: full; Name: "XVM\Carousel\1"; Description: "В 1 ряд"; Flags: exclusive disablenouninstallwarning; Name: "XVM\Carousel\2"; Description: "В 2 ряда"; Flags: exclusive disablenouninstallwarning; 1 Quote Share this post Link to post Short link Share on other sites
Fenixx 1 #263257 Posted April 19, 2015 (edited) AtotIK, вот то что твое скопировал нормально все заработало! Edited April 19, 2015 by Fenixx Quote Share this post Link to post Short link Share on other sites
Ekspoint 2,122 #263302 Posted April 19, 2015 К примеру есть 2 чекбокса, если выбрал первый чек то 2 должен быть не активен, как это сделать? Quote Share this post Link to post Short link Share on other sites
Kotyarko_O 1,906 #263305 Posted April 19, 2015 К примеру есть 2 чекбокса, если выбрал первый чек то 2 должен быть не активен, как это сделать? http://forum.oszone.net/post-2494486-470.html 1 Quote Share this post Link to post Short link Share on other sites
Ekspoint 2,122 #263306 Posted April 19, 2015 http://forum.oszone.net/post-2494486-470.html спасибо Quote Share this post Link to post Short link Share on other sites
Kotyarko_O 1,906 #263314 Posted April 19, 2015 (edited) спасибо Учись просто нажимать зелёную стрелку вверх под сообщением. Edited April 19, 2015 by Kotyarko_O 1 Quote Share this post Link to post Short link Share on other sites
Ekspoint 2,122 #263315 Posted April 19, 2015 Учись просто нажимать зелёную стрелку вверх под сообщением. ок Quote Share this post Link to post Short link Share on other sites
Fenixx 1 #263381 Posted April 20, 2015 (edited) Добрый день! Как поменять их место положения? в свой скрипт вставил картинки и описание не видно. 'картинка инста стандартого скрипта' 'Обычный тут скрипт с картинками на компонненты и описание к ним' [setup]AppName=Моя программаAppVersion=1.5AppPublisher=YURSHATAppPublisherURL=DefaultDirName={pf}\Моя программа[Languages]Name: RU; MessagesFile: compiler:Languages\Russian.isl[CustomMessages]RU.ComponentsInfo=Наведите курсор мыши на компонент, чтобы прочитать его описание.RU.ComponentsImgInfo=Наведите курсор мыши на компонент, чтобы посмотреть его превью.RU.CompDesc1=Описание первого компонентаRU.CompDesc2=Описание второго компонентаRU.CompDesc3=Описание первого компонентаRU.CompDesc4=Описание второго компонентаRU.CompDesc5=Описание первого компонентаRU.CompDesc6=Описание второго компонентаRU.CompDesc7=Описание первого компонентаRU.CompDesc8=Описание второго компонентаRU.CompDesc9=Описание первого компонентаRU.CompDesc10=Описание второго компонентаRU.CompDesc11=Описание первого компонентаRU.CompDesc12=Описание второго компонента//************************************************ [Описание к модам] ***************************************************////************************************************ [Конец модам] ***************************************************//[Files]Source: img_mod\1.bmp; DestName: CompDescImg1.bmp; Flags: dontcopySource: img_mod\2.bmp; DestName: CompDescImg2.bmp; Flags: dontcopySource: img_mod\3.bmp; DestName: MainPic.bmp; Flags: dontcopy[Components]Name: comp1; Description: 1. Mod Pack ; Types: custom; Flags: fixedName: KMP\P; Description: 1. Прицел.; Flags: disablenouninstallwarningName: KMP\DP; Description: 2. Дамаг панель.; Flags: disablenouninstallwarningName: KMP\ZK; Description: 2. Звуковой мод звонок при крите модуля.; Flags: disablenouninstallwarningName: KMP\Z; Description: 3. Zoom.; Flags: disablenouninstallwarningName: KMP\Z\NS; Description: а. NoScroll- колёсико не переключает в снайперский режим; Flags: checkablealone ;Name: KMP\Z\ZX4; Description: б. 4-х позиционный снайперский прицел ; Flags: checkablealone ;Name: KMP\T; Description: 4. Дерево развития.;Name: KMP\I; Description: 5. Информационная панель выбранной цели.;Name: KMP\CM; Description: 6. Цветные сообщения(ЯсенКрасен).;Name: KMP\CLOCK; Description: 7. Часы в ангаре.;Name: KMP\A; Description: 8. Ангар.;Name: KMP\XVM; Description: 9. Пользомер(Оленемер).; typeTComponentDesc = recordDescription: String;ImageName: String;Index: Integer;end;varCompDescs: array of TComponentDesc;CompDescPanel, CompDescImgPanel: TPanel;CompDescText: array[1..2] of TLabel;CompIndex, LastIndex: Integer;CompDescImg: TBitmapImage;procedure ShowCompDescription(Sender: TObject; X, Y, Index: Integer; Area: TItemArea);vari: Integer;beginif Index = LastIndex then Exit;CompIndex := -1;for i := 0 to GetArrayLength(CompDescs) -1 dobeginif (CompDescs[i].Index = Index) thenbeginCompIndex := i;Break;end;end;if (CompIndex >= 0) and (Area = iaItem) thenbeginif not FileExists(ExpandConstant('{tmp}\') + CompDescs[CompIndex].ImageName) thenExtractTemporaryFile(CompDescs[CompIndex].ImageName);CompDescImg.Bitmap.LoadFromFile(ExpandConstant('{tmp}\') + CompDescs[CompIndex].ImageName);CompDescImg.Show;CompDescText[2].Caption := CompDescs[CompIndex].Description;CompDescText[2].Enabled := True;end elsebeginCompDescImg.Bitmap.LoadFromFile(ExpandConstant('{tmp}\MainPic.bmp'));CompDescText[2].Caption := CustomMessage('ComponentsInfo');CompDescText[2].Enabled := False;end;LastIndex := Index;end;procedure CompListMouseLeave(Sender: TObject);beginCompDescImg.Bitmap.LoadFromFile(ExpandConstant('{tmp}\MainPic.bmp'));CompDescText[2].Caption := CustomMessage('ComponentsInfo');CompDescText[2].Enabled := False;LastIndex := -1;end;procedure AddCompDescription(AIndex: Integer; ADescription: String; AImageName: String);vari: Integer;begini := GetArrayLength(CompDescs);SetArrayLength(CompDescs, i + 1);CompDescs[i].Description := ADescription;CompDescs[i].ImageName := AImageName;CompDescs[i].Index := AIndex - 1end;procedure InitializeWizard();beginExtractTemporaryFile('MainPic.bmp');WizardForm.SelectComponentsLabel.Hide;WizardForm.TypesCombo.Hide;WizardForm.ComponentsList.SetBounds(ScaleX(0), ScaleY(0), ScaleX(184), ScaleY(205));WizardForm.ComponentsList.OnItemMouseMove:= @ShowCompDescription;WizardForm.ComponentsList.OnMouseLeave := @CompListMouseLeave;CompDescImgPanel := TPanel.Create(WizardForm);with CompDescImgPanel dobeginParent := WizardForm.SelectComponentsPage;SetBounds(ScaleX(40), ScaleY(0), ScaleX(225), ScaleY(100));BevelInner := bvLowered;end;CompDescText[1] := TLabel.Create(WizardForm);with CompDescText[1] dobeginParent := CompDescImgPanel;SetBounds(ScaleX(5), ScaleY(5), CompDescImgPanel.Width - ScaleX(10), CompDescImgPanel.Height - ScaleY(10));AutoSize := False;WordWrap := True;Enabled := False;Caption := CustomMessage('ComponentsImgInfo');end;CompDescImg := TBitmapImage.Create(WizardForm);with CompDescImg dobeginParent := CompDescImgPanel;SetBounds(ScaleX(10), ScaleY(10), CompDescImgPanel.Width - ScaleX(10), CompDescImgPanel.Height - ScaleY(10));Stretch := True;Bitmap.LoadFromFile(ExpandConstant('{tmp}\MainPic.bmp'));end;CompDescPanel := TPanel.Create(WizardForm);with CompDescPanel dobeginParent := WizardForm.SelectComponentsPage;SetBounds(ScaleX(192), ScaleY(125), ScaleX(225), ScaleY(80));BevelInner := bvLowered;end;CompDescText[2] := TLabel.Create(WizardForm);with CompDescText[2] dobeginParent := CompDescPanel;SetBounds(ScaleX(5), ScaleY(5), CompDescPanel.Width - ScaleX(10), CompDescPanel.Height - ScaleY(10));AutoSize := False;WordWrap := True;Enabled := False;Caption := CustomMessage('ComponentsInfo');end;AddCompDescription(1, CustomMessage('CompDesc1'), 'CompDescImg1.bmp');AddCompDescription(2, CustomMessage('CompDesc2'), 'CompDescImg2.bmp');AddCompDescription(3, CustomMessage('CompDesc3'), 'CompDescImg1.bmp');AddCompDescription(4, CustomMessage('CompDesc4'), 'CompDescImg2.bmp');AddCompDescription(5, CustomMessage('CompDesc5'), 'CompDescImg1.bmp');AddCompDescription(6, CustomMessage('CompDesc6'), 'CompDescImg2.bmp');AddCompDescription(7, CustomMessage('CompDesc7'), 'CompDescImg1.bmp');AddCompDescription(8, CustomMessage('CompDesc8'), 'CompDescImg2.bmp');AddCompDescription(9, CustomMessage('CompDesc9'), 'CompDescImg1.bmp');AddCompDescription(10, CustomMessage('CompDesc10'), 'CompDescImg2.bmp');AddCompDescription(11, CustomMessage('CompDesc11'), 'CompDescImg1.bmp');AddCompDescription(12, CustomMessage('CompDesc12'), 'CompDescImg2.bmp');end;'Хотелось бы что бы было так ' Edited April 20, 2015 by Fenixx Quote Share this post Link to post Short link Share on other sites
AtotIK 580 #263384 Posted April 20, 2015 Fenixx, играйся с параметрами: WizardForm.ComponentsList.SetBounds(ScaleX(0), ScaleY(0), ScaleX(184), ScaleY(205)); CompDescImgPanel.SetBounds(ScaleX(40), ScaleY(0), ScaleX(225), ScaleY(100)); CompDescPanel.SetBounds(ScaleX(192), ScaleY(125), ScaleX(225), ScaleY(80)); И хватит задавать глупые вопросы. Я вижу, что ты даже не пытаешься что-то понимать. 1 Quote Share this post Link to post Short link Share on other sites
Fenixx 1 #263386 Posted April 20, 2015 (edited) AtotIK, хоть и поменял координаты все равно не видно их. если бы знал все, я бы не спрашивал Edited April 20, 2015 by Fenixx Quote Share this post Link to post Short link Share on other sites
Ekspoint 2,122 #263395 Posted April 20, 2015 (edited) AtotIK, хоть и поменял координаты все равно не видно их. если бы знал все, я бы не спрашивал код скинь(в архиве) как задать артибуту для создаваемого файла только чтение и скрытность? Edited April 20, 2015 by Dark_Knight_MiX 1 Quote Share this post Link to post Short link Share on other sites