mirror of
https://github.com/voicemxil/TS-Starter-Pack.git
synced 2025-01-22 08:11:49 -05:00
v11
This commit is contained in:
parent
1daaef6323
commit
b06fcdd32f
13 changed files with 183 additions and 0 deletions
BIN
assets/InstallerImage.bmp
Normal file
BIN
assets/InstallerImage.bmp
Normal file
Binary file not shown.
After Width: | Height: | Size: 1.2 MiB |
BIN
assets/NewInstaller.ico
Normal file
BIN
assets/NewInstaller.ico
Normal file
Binary file not shown.
After Width: | Height: | Size: 58 KiB |
BIN
assets/header.bmp
Normal file
BIN
assets/header.bmp
Normal file
Binary file not shown.
After Width: | Height: | Size: 100 KiB |
BIN
bin/Web Installer/TS1StarterPack.WebInstaller-v11.exe
Normal file
BIN
bin/Web Installer/TS1StarterPack.WebInstaller-v11.exe
Normal file
Binary file not shown.
BIN
bin/Web Installer/assets/InstallerImage.bmp
Normal file
BIN
bin/Web Installer/assets/InstallerImage.bmp
Normal file
Binary file not shown.
After Width: | Height: | Size: 1.2 MiB |
BIN
bin/Web Installer/assets/NewInstaller.ico
Normal file
BIN
bin/Web Installer/assets/NewInstaller.ico
Normal file
Binary file not shown.
After Width: | Height: | Size: 58 KiB |
BIN
bin/Web Installer/assets/header.bmp
Normal file
BIN
bin/Web Installer/assets/header.bmp
Normal file
Binary file not shown.
After Width: | Height: | Size: 100 KiB |
21
components/PatcherLicense.txt
Normal file
21
components/PatcherLicense.txt
Normal file
|
@ -0,0 +1,21 @@
|
|||
MIT License
|
||||
|
||||
Copyright (c) 2021 FaithBeam
|
||||
|
||||
Permission is hereby granted, free of charge, to any person obtaining a copy
|
||||
of this software and associated documentation files (the "Software"), to deal
|
||||
in the Software without restriction, including without limitation the rights
|
||||
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
||||
copies of the Software, and to permit persons to whom the Software is
|
||||
furnished to do so, subject to the following conditions:
|
||||
|
||||
The above copyright notice and this permission notice shall be included in all
|
||||
copies or substantial portions of the Software.
|
||||
|
||||
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
||||
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
||||
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
||||
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
||||
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
||||
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
||||
SOFTWARE.
|
BIN
components/Sims1WidescreenPatcher.exe
Normal file
BIN
components/Sims1WidescreenPatcher.exe
Normal file
Binary file not shown.
2
components/desktop.ini
Normal file
2
components/desktop.ini
Normal file
|
@ -0,0 +1,2 @@
|
|||
[LocalizedFileNames]
|
||||
Sims1WidescreenPatcher.exe=@Sims1WidescreenPatcher.exe,0
|
23
src/Downloader.nsh
Normal file
23
src/Downloader.nsh
Normal file
|
@ -0,0 +1,23 @@
|
|||
!macro downloadPack packName packLink outputFile packSHA256
|
||||
${Do}
|
||||
DetailPrint "Downloading ${packName} from ${packLink}. Closing the download window will interrupt the download."
|
||||
inetc::get /POPUP "Downloading ${packName}..." "${packLink}" "${outputFile}"
|
||||
Pop $0 # return value = exit code, "OK" means OK
|
||||
DetailPrint "${packName} download status: $0"
|
||||
filecheck::calcFileHash "${outputFile}" sha256
|
||||
Pop $R1
|
||||
${if} $R1 == "${packSHA256}"
|
||||
ExecWait '"${outputFile}" -InstallPath="$INSTDIR" -o"$INSTDIR" -y -gm1'
|
||||
${Break}
|
||||
${else}
|
||||
${If} ${Cmd} `MessageBox MB_RETRYCANCEL|MB_ICONEXCLAMATION "${outputFile} seems to be corrupted. This may be due to a bad connection or interrupted download. If you continue to see this message after retrying, consult the Discord. Would you like to retry?" /SD IDRETRY IDRETRY`
|
||||
Delete "${outputFile}"
|
||||
${Else}
|
||||
${Break}
|
||||
${Endif}
|
||||
${endif}
|
||||
${Loop}
|
||||
Delete "${outputFile}"
|
||||
Pop $0
|
||||
DetailPrint "Cleanup result: $0"
|
||||
!macroend
|
137
src/TS_Web_Installer.nsi
Normal file
137
src/TS_Web_Installer.nsi
Normal file
|
@ -0,0 +1,137 @@
|
|||
Unicode True ;Support Unicode format in the installer
|
||||
|
||||
;Include header files
|
||||
!include "MUI2.nsh"
|
||||
!include "x64.nsh"
|
||||
!include ".\Downloader.nsh"
|
||||
|
||||
!macro simsTouchup
|
||||
SetRegView 32
|
||||
WriteRegStr HKLM32 "SOFTWARE\Maxis\The Sims" "EP2Installed" "1"
|
||||
WriteRegStr HKLM32 "SOFTWARE\Maxis\The Sims" "EP3Installed" "1"
|
||||
WriteRegStr HKLM32 "SOFTWARE\Maxis\The Sims" "EP3Patch" "2"
|
||||
WriteRegStr HKLM32 "SOFTWARE\Maxis\The Sims" "EP4Installed" "1"
|
||||
WriteRegStr HKLM32 "SOFTWARE\Maxis\The Sims" "EP5Installed" "1"
|
||||
WriteRegStr HKLM32 "SOFTWARE\Maxis\The Sims" "EP5Patch" "1"
|
||||
WriteRegStr HKLM32 "SOFTWARE\Maxis\The Sims" "EP6Installed" "1"
|
||||
WriteRegStr HKLM32 "SOFTWARE\Maxis\The Sims" "EP7Installed" "1"
|
||||
WriteRegStr HKLM32 "SOFTWARE\Maxis\The Sims" "EP8Installed" "1"
|
||||
WriteRegStr HKLM32 "SOFTWARE\Maxis\The Sims" "EPDInstalled" "1"
|
||||
WriteRegStr HKLM32 "SOFTWARE\Maxis\The Sims" "EPDPatch" "1"
|
||||
WriteRegStr HKLM32 "SOFTWARE\Maxis\The Sims" "EPInstalled" "1"
|
||||
WriteRegStr HKLM32 "SOFTWARE\Maxis\The Sims" "Installed" "1"
|
||||
WriteRegStr HKLM32 "SOFTWARE\Maxis\The Sims" "InstallPath" "$INSTDIR\The Sims"
|
||||
WriteRegDWORD HKLM32 "SOFTWARE\Maxis\The Sims" "Language" "1033"
|
||||
WriteRegStr HKLM32 "SOFTWARE\Maxis\The Sims" "SIMS_CURRENT_NEIGHBORHOOD_NUM" "1"
|
||||
WriteRegStr HKLM32 "SOFTWARE\Maxis\The Sims" "SIMS_CURRENT_NEIGHBORHOOD_PATH" "UserData"
|
||||
WriteRegStr HKLM32 "SOFTWARE\Maxis\The Sims" "SIMS_DATA" "$INSTDIR\The Sims"
|
||||
WriteRegStr HKLM32 "SOFTWARE\Maxis\The Sims" "SIMS_GAME_EDITION" "255"
|
||||
WriteRegStr HKLM32 "SOFTWARE\Maxis\The Sims" "SIMS_LANGUAGE" "USEnglish"
|
||||
WriteRegStr HKLM32 "SOFTWARE\Maxis\The Sims" "SIMS_MUSIC" "Music"
|
||||
WriteRegStr HKLM32 "SOFTWARE\Maxis\The Sims" "SIMS_SKU" "1"
|
||||
WriteRegStr HKLM32 "SOFTWARE\Maxis\The Sims" "SIMS_SOUND" "$INSTDIR\The Sims\SoundData"
|
||||
WriteRegStr HKLM32 "SOFTWARE\Maxis\The Sims" "TELEPORT" "1"
|
||||
WriteRegStr HKLM32 "SOFTWARE\Maxis\The Sims" "Version" "1.2"
|
||||
WriteRegStr HKLM32 "SOFTWARE\Microsoft\Windows\CurrentVersion\App Paths\Sims.exe" "Path" "$INSTDIR\The Sims"
|
||||
WriteRegStr HKLM32 "SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall\The Sims 1 Starter Pack" "DisplayName" "The Sims 1 Starter Pack"
|
||||
WriteRegStr HKLM32 "SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall\The Sims 1 Starter Pack" "InstallLocation" "$INSTDIR"
|
||||
WriteRegStr HKLM32 "SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall\The Sims 1 Starter Pack" "UninstallString" "$INSTDIR\Uninstall The Sims Starter Pack"
|
||||
!macroEnd
|
||||
|
||||
# Names the built installer
|
||||
Name "The Sims 1 Starter Pack"
|
||||
# Building to:
|
||||
OutFile "..\bin\Web Installer\TS1StarterPack.WebInstaller-v11.exe"
|
||||
# Administrator Privileges
|
||||
RequestExecutionLevel admin
|
||||
# Default Installation Directory
|
||||
InstallDir "$PROGRAMFILES32\The Sims 1 Starter Pack"
|
||||
|
||||
Function .OnInit
|
||||
Dialer::AttemptConnect
|
||||
FunctionEnd
|
||||
|
||||
########################### MUI SETUP
|
||||
brandingText "osab Web Installer v11"
|
||||
!define MUI_ABORTWARNING
|
||||
!define MUI_HEADERIMAGE_BITMAP_STRETCH AspectFitHeight
|
||||
!define MUI_HEADERIMAGE_BITMAP "..\assets\header.bmp"
|
||||
!define MUI_ICON "..\assets\NewInstaller.ico"
|
||||
!define MUI_PAGE_HEADER_TEXT "TS1: Starter Pack - Web Installer"
|
||||
!define MUI_PAGE_HEADER_SUBTEXT "TS1 Ultimate Collection repacked by osab!"
|
||||
|
||||
!define MUI_WELCOMEPAGE_TITLE "osab's Sims 1 Starter Pack"
|
||||
!define MUI_WELCOMEPAGE_TEXT "Welcome to the Sims 1 Starter Pack Web Installer (v11). Please ensure you have downloaded the latest version from the GitHub! Helpful log messages will be shown in the 'More Details' box."
|
||||
|
||||
!define MUI_LICENSEPAGE_TEXT_TOP "License Information:"
|
||||
|
||||
!define MUI_WELCOMEFINISHPAGE_BITMAP "..\assets\InstallerImage.bmp"
|
||||
!define MUI_FINISHPAGE_NOREBOOTSUPPORT
|
||||
!define MUI_FINISHPAGE_LINK "TS2 Community Discord Server!"
|
||||
!define MUI_FINISHPAGE_LINK_LOCATION "https://discord.gg/invite/ts2-community-912700195249197086"
|
||||
|
||||
!insertmacro MUI_PAGE_WELCOME
|
||||
!insertmacro MUI_PAGE_LICENSE "..\LICENSE.txt"
|
||||
!insertmacro MUI_PAGE_COMPONENTS
|
||||
!insertmacro MUI_PAGE_DIRECTORY
|
||||
!insertmacro MUI_PAGE_INSTFILES
|
||||
!insertmacro MUI_PAGE_FINISH
|
||||
|
||||
!insertmacro MUI_LANGUAGE "English"
|
||||
|
||||
##################################### Begin Installation
|
||||
|
||||
Section "TS1 Starter Pack" Section1
|
||||
SectionIn RO
|
||||
SetOutPath $INSTDIR
|
||||
SetOverwrite on
|
||||
InitPluginsDir
|
||||
AddSize 240000
|
||||
|
||||
!insertmacro downloadPack "The Sims" https://github.com/mintalien/The-Puppets-2-Definitive-Edition/releases/download/v11/SFX_TheSims.v11.exe SFX_TheSims.exe "5f3fc0dceec692f0b528f5e0b0060f2faf717bb88f622ad5d5c7f6eb3435d607"
|
||||
|
||||
# Touchup
|
||||
DetailPrint "Touching Up..."
|
||||
!insertmacro simsTouchup
|
||||
|
||||
RMDir /r "$INSTDIR\temp"
|
||||
|
||||
WriteUninstaller "$INSTDIR\Uninstall The Sims 1 Starter Pack.exe"
|
||||
ExecShell "open" "$INSTDIR"
|
||||
|
||||
SectionEnd
|
||||
|
||||
Section "TS1 Widescreen Patcher" Section2
|
||||
inetc::get /POPUP "Downloading TS1 Widescreen Patcher. Choose DDrawCompat as your wrapper!" https://github.com/voicemxil/TS-Starter-Pack/raw/v11/components/Sims1WidescreenPatcher.exe "$INSTDIR\Sims1WidescreenPatcher.exe"
|
||||
inetc::get /BANNER "One moment..." https://github.com/voicemxil/TS-Starter-Pack/raw/v11/components/PatcherLicense.txt "$INSTDIR\PatcherLicense.txt"
|
||||
Pop $0 # return value = exit code, "OK" means OK
|
||||
DetailPrint "Patcher download status: $0. Executing Patcher..."
|
||||
Execwait "$INSTDIR\Sims1WidescreenPatcher.exe"
|
||||
SectionEnd
|
||||
|
||||
Section "Start Menu/Desktop Shortcut" Section7
|
||||
SetShellVarContext current
|
||||
SetOutPath "$INSTDIR"
|
||||
CreateDirectory '$SMPROGRAMS\The Sims 1 Starter Pack\'
|
||||
CreateShortCut '$SMPROGRAMS\The Sims 1 Starter Pack\The Sims.lnk' '$INSTDIR\Sims.exe' "" '$INSTDIR\Sims.exe' 0
|
||||
CreateShortCut '$Desktop\The Sims.lnk' '$INSTDIR\Sims.exe' "" '$INSTDIR\Sims.exe' 0
|
||||
SectionEnd
|
||||
|
||||
Section "Uninstall" Section8
|
||||
SetRegView 32
|
||||
Delete "$INSTDIR\Uninstall The Sims 1 Starter Pack.exe"
|
||||
ReadRegStr $R4 HKLM32 "SOFTWARE\Maxis\The Sims" "InstallPath"
|
||||
RMDir /r $R4
|
||||
DeleteRegKey HKLM32 "SOFTWARE\Maxis\The Sims"
|
||||
DeleteRegKey HKLM32 "SOFTWARE\Microsoft\Windows\CurrentVersion\App Paths\Sims.exe"
|
||||
DeleteRegKey HKLM32 "SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall\The Sims 1 Starter Pack"
|
||||
RMDir /r "$SMPROGRAMS\The Sims 1 Starter Pack"
|
||||
Delete "$Desktop\The Sims.lnk"
|
||||
SectionEnd
|
||||
|
||||
!insertmacro MUI_FUNCTION_DESCRIPTION_BEGIN
|
||||
!insertmacro MUI_DESCRIPTION_TEXT ${Section1} "Installs The Sims Complete Collection (minimal install)."
|
||||
!insertmacro MUI_DESCRIPTION_TEXT ${Section2} "Installs The Sims 1 Widescreen Patcher by FaithBeam."
|
||||
!insertmacro MUI_DESCRIPTION_TEXT ${Section7} "Create a shortuct to launch the game in your Start Menu/Desktop."
|
||||
|
||||
!insertmacro MUI_FUNCTION_DESCRIPTION_END
|
Loading…
Reference in a new issue