HELP!!! w/Custom scripted installer.
Hi guys, I promised the community that I am a part of that I would release a mod I created Thanks Giving day for the game TRIBES.
I successfully created a installer, now the only problem is that I need it to install :\
I originally worked out of gfx.nsi, I got everything to work, and the installer itself looks excellent. I couldn't find any code in the NSI that attaches files to it so I browsed around in zip2exe. I noticed at the top it says the contrib crap, so I went ahead and went to my Programs files/NSIS/Contrib/ bla bla... I then opened up the base, then I attempted to replace the base code with the one gfx gave me.. No luck... Syntax syntax syntax.. Now this is weird knowing the installer works in the scripter but not the zip2exe... I am basically trying to add the zip to my custom gfx.nsi, if anyone could help I would deeply appreciate it..
Josh-
Here is the un-syntaxed GFX.nsi code.
;--------------------------------
!macro BIMAGE IMAGE PARMS
Push $0
GetTempFileName $0
File /oname=$0 "${IMAGE}"
SetBrandingImage ${PARMS} $0
Delete $0
Pop $0
!macroend
;--------------------------------
Name "WTF Mod v0.2"
OutFile "Gfx.exe"
; Adds an XP manifest to the installer
XPStyle on
; Add branding image to the installer (an image placeholder on the side).
; It is not enough to just add the placeholder, we must set the image too...
; We will later set the image in every pre-page function.
; We can also set just one persistent image in .onGUIInit
AddBrandingImage left 100
; Sets the font of the installer
SetFont "Comic Sans MS" 8
; Just to make it three pages...
SubCaption 0 ": !?WTF?! Mod installer - Clanmx.com"
SubCaption 2 ": !?WTF?! Mod installer Page - Clanmx.com"
LicenseText "WTF Mod License page"
LicenseData "License.nsi"
DirText "--!?WTF?! Mod-- (example: C:\Dynamix\Tribes\)"
; Install dir
InstallDir "C:\Dynamix\Tribes\"
;--------------------------------
; Pages
Page license licenseImage
Page custom customPage
Page directory dirImage
Page instfiles instImage
;--------------------------------
Section ""
; You can also use the BI_NEXT macro here...
MessageBox MB_YESNO "You are about ready to install !?WTF?! Mod v0.2. Please NOTE: I am not responsible \
for any problems this installer/mod may cause to your computer. As far as I know, it's safe. Help + \
information at Clanmx.com & clanmx.info." IDNO done
!insertmacro BIMAGE "C:\Documents and Settings\HaCKeR\Desktop\Installer stuff\WTFmod2.bmp" ""
done:
WriteUninstaller uninst.exe
SectionEnd
;--------------------------------
Function licenseImage
!insertmacro BIMAGE "C:\Documents and Settings\HaCKeR\Desktop\Installer stuff\WTFmod2.bmp" /RESIZETOFIT
MessageBox MB_YESNO 'Would you like to skip the license page?' IDNO no
Abort
no:
FunctionEnd
Function customPage
!insertmacro BIMAGE "C:\Documents and Settings\HaCKeR\Desktop\Installer stuff\WTFmod2.bmp" /RESIZETOFIT
MessageBox MB_OK 'After clicking "Ok" Please select a propper TRIBES directory to install !?WTF?! \
Mod to. Make sure you back up your Tribes folder!'
#insert install options/start menu/<insert plugin name here> here
FunctionEnd
Function dirImage
!insertmacro BIMAGE "C:\Documents and Settings\HaCKeR\Desktop\Installer stuff\WTFmod2.bmp" /RESIZETOFIT
FunctionEnd
Function instImage
!insertmacro BIMAGE "C:\Documents and Settings\HaCKeR\Desktop\Installer stuff\WTFmod2.bmp" /RESIZETOFIT
FunctionEnd
;--------------------------------
; Uninstall pages
UninstPage uninstConfirm un.uninstImage
UninstPage custom un.customPage
UninstPage instfiles un.instImage
Function un.uninstImage
!insertmacro BIMAGE "C:\Documents and Settings\HaCKeR\Desktop\Installer stuff\WTFmod2.bmp" /RESIZETOFIT
FunctionEnd
Function un.customPage
!insertmacro BIMAGE "C:\Documents and Settings\HaCKeR\Desktop\Installer stuff\WTFmod2.bmp" /RESIZETOFIT
MessageBox MB_OK 'You have chosen to delete !?WTF?! mod from the directory you selected'
#insert install options/start menu/<insert plugin name here> here
FunctionEnd
Function un.instImage
!insertmacro BIMAGE "C:\Documents and Settings\HaCKeR\Desktop\Installer stuff\WTFmod2.bmp" /RESIZETOFIT
FunctionEnd
;--------------------------------
; Uninstaller
; Another page for uninstaller
UninstallText "--!?WTF?! Mod Uninstaller--"
Section uninstall
MessageBox MB_OK "Are you sure you want to completley delete !?WTF?! mod?"
SectionEnd