FileForums

FileForums (https://fileforums.com/index.php)
-   Conversion Tutorials (https://fileforums.com/forumdisplay.php?f=55)
-   -   I need help with inno setup subfolder game.exe!!! (https://fileforums.com/showthread.php?t=106445)

Ivanlakersss2016 23-09-2024 07:39

I need help with inno setup subfolder game.exe!!!
 
Hi guys, I need your help with the inno setup program. My problem is with the shortcut to the desktop of my game. I'm making a repack and my .exe file is in a subfolder and the inno setup program only works well if the .exe file is in the main root folder of the game. I need to edit my script correctly so that the address of my desktop shortcut works correctly. Could you share my script in case you can correct it for me? I hope for your help. Thanks.

ivanlakersss666 23-09-2024 08:05

Quote:

Originally Posted by Ivanlakersss2016 (Post 505658)
Hi guys, I need your help with the inno setup program. My problem is with the shortcut to the desktop of my game. I'm making a repack and my .exe file is in a subfolder and the inno setup program only works well if the .exe file is in the main root folder of the game. I need to edit my script correctly so that the address of my desktop shortcut works correctly. Could you share my script in case you can correct it for me? I hope for your help. Thanks.

https://www.mediafire.com/file/p1iox...copia.iss/file

KaktoR 23-09-2024 08:13

1 Attachment(s)
https://i.imgur.com/TxsnLDV.gif

Ivanlakersss2016 23-09-2024 08:39

Quote:

Originally Posted by KaktoR (Post 505661)

Could you tell me which lines you fixed or deleted exactly so I could solve it, thank you!

KaktoR 23-09-2024 08:49

Code:

[Files]
Source: "C:\GAMES\Advent Rising\*"; DestDir: "{app}"; Flags: ignoreversion recursesubdirs createallsubdirs
; NOTE: Don't use "Flags: ignoreversion" on any shared system files

[Icons]
Name: "{group}\{#MyAppName}"; Filename: "{app}\System\{#MyAppExeName}"
Name: "{group}\{cm:UninstallProgram,{#MyAppName}}"; Filename: "{uninstallexe}"
Name: "{commondesktop}\{#MyAppName}"; Filename: "{app}\System\{#MyAppExeName}"; Tasks: desktopicon


KaktoR 23-09-2024 08:58

You could add something like this if you want to change subfolder name in just one line of script instead of several lines

Code:

#define Subfolder "System\"

[Setup]
.........


[Icons]
Name: "{group}\{#MyAppName}"; Filename: "{app}\{#Subfolder}{#MyAppExeName}"
Name: "{group}\{cm:UninstallProgram,{#MyAppName}}"; Filename: "{uninstallexe}"
Name: "{commondesktop}\{#MyAppName}"; Filename: "{app}\{#Subfolder}{#MyAppExeName}"; Tasks: desktopicon


Ivanlakersss2016 24-09-2024 08:21

I need to fix 3 shortcuts for 3 games, I can't fix it, I'm sharing the file with you in case you can fix it for me, thanks

https://www.mediafire.com/file/iydyw...ction.iss/file

KaktoR 24-09-2024 08:23

What you mean you need to remove shortcuts?

Ivanlakersss2016 24-09-2024 08:29

Quote:

Originally Posted by KaktoR (Post 505689)
What you mean you need to remove shortcuts?

I need to install the 3 shortcuts to my Windows desktop correctly so that the games run properly

Ivanlakersss2016 24-09-2024 10:17

????

KaktoR 24-09-2024 12:15

The problem here is that you use the same {#MyAppName} ISPP code for all 3 games. This just means that the installer actually creates all 3, but overwrites the previous because of the same shortcut name.

Change it like this
Code:

Name: "{commondesktop}\Resident Evil"; Filename: "{app}\Resident Evil\ResidentEvil.exe"; Tasks: desktopicon
Name: "{commondesktop}\Resident Evil 2 Leon"; Filename: "{app}\Resident Evil 2\LeonS.exe"; Tasks: desktopicon
Name: "{commondesktop}\Resident Evil 2 Clair"; Filename: "{app}\Resident Evil 2\ClaireS.exe"; Tasks: desktopicon

Do the same for {group} constant in [Icons] section.

PS: {group} are startmenu icons. If you don't want them you can delete them and just keep desktop shortcuts.

Ivanlakersss2016 24-09-2024 14:41

Thank you very much my friend, in the end it worked with your advice, I suppose that if I want to create more shortcuts to the desktop it is to add more lines respecting the parameters of never placing the same name so that it never gives me another error, I will make a video tutorial for YouTube so that my wisdom reaches more people who need to create repacks :D

Ivanlakersss2016 25-09-2024 03:27

Quote:

Originally Posted by KaktoR (Post 505700)
The problem here is that you use the same {#MyAppName} ISPP code for all 3 games. This just means that the installer actually creates all 3, but overwrites the previous because of the same shortcut name.

Change it like this
Code:

Name: "{commondesktop}\Resident Evil"; Filename: "{app}\Resident Evil\ResidentEvil.exe"; Tasks: desktopicon
Name: "{commondesktop}\Resident Evil 2 Leon"; Filename: "{app}\Resident Evil 2\LeonS.exe"; Tasks: desktopicon
Name: "{commondesktop}\Resident Evil 2 Clair"; Filename: "{app}\Resident Evil 2\ClaireS.exe"; Tasks: desktopicon

Do the same for {group} constant in [Icons] section.

PS: {group} are startmenu icons. If you don't want them you can delete them and just keep desktop shortcuts.

Excuse me, I have 2 questions for you, I would like to know what I should edit in my script so that when I create my desktop shortcut inno setup I check the box directly activated. My second question is, how can I create my accesses from inno setup directs go directly to a folder when I install my game. I hope your help, thank you!

Dario06 25-09-2024 14:48

internal (no isdone)
Code:

#define MyAppName "Games"
#define GameExe1  "RS3.exe"
#define GameExe2  "RS4.exe"
#define GameExe3  "RS7.exe"

[Setup]
AppName={#MyAppName}
AppVersion=3.4.7
DefaultDirName={sd}\{#MyAppName}
DisableProgramGroupPage=yes
OutputBaseFilename=setup
Compression=lzma2/Ultra64
SolidCompression=no
DiskSpanning=yes
Uninstallable=no

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

[Files]
Source: "Resident Evil 3\*"; DestDir: "{app}\Resident Evil 3"; Flags: ignoreversion recursesubdirs createallsubdirs
Source: "Resident Evil 4\*"; DestDir: "{app}\Resident Evil 4"; Flags: ignoreversion recursesubdirs createallsubdirs
Source: "Resident Evil 7\*"; DestDir: "{app}\Resident Evil 7"; Flags: ignoreversion recursesubdirs createallsubdirs
; NOTE: Don't use "Flags: ignoreversion" on any shared system files

[Icons]
Name: "{commondesktop}\{cm:rs3}"; Filename: "{app}\Resident Evil 3\{#GameExe1}"; Tasks: desktopicon
Name: "{commondesktop}\{cm:rs4}"; Filename: "{app}\Resident Evil 4\{#GameExe2}"; Tasks: desktopicon
Name: "{commondesktop}\{cm:rs7}"; Filename: "{app}\Resident Evil 7\{#GameExe3}"; Tasks: desktopicon

[Languages]
Name: "en"; MessagesFile: "compiler:Default.isl"

[CustomMessages]
en.rs3=Run Resident Evil 3
en.rs4=Run Resident Evil 4
en.rs7=Run Resident Evil 7


Ivanlakersss2016 26-09-2024 06:28

If I wanted to edit the .ico files of the desktop shortcuts with others that I like, what should I edit from my script? They would be 4 icons.

Dario06 26-09-2024 07:13

Quote:

Originally Posted by Ivanlakersss2016 (Post 505739)
If I wanted to edit the .ico files of the desktop shortcuts with others that I like, what should I edit from my script? They would be 4 icons.

Code:

[Files]
Source: "CustomIcon.ico "; DestDir: "{app}"; Flags: ignoreversion
[Icons]
Name: "{commondesktop}\{#MyAppName}"; Filename: "{app}\{#MyAppExeName}"; IconFilename:{app}\CustomIcon.ico; Tasks: desktopicon



All times are GMT -7. The time now is 14:56.

Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2026, vBulletin Solutions Inc.
FileForums @ https://fileforums.com