problem with umui
i tried to create a setup with umui but it looks like this :D
http://bildupload.sro.at/a/images/umui.jpg
here is the script:
SetCompressor lzma
;MUI SETTINGS
!include "UMUI.nsh"
!define UMUI_SKIN blue
!define MUI_ICON "GRM_48.ico"
;Installer Pages
!insertmacro MUI_PAGE_WELCOME
!insertmacro MUI_PAGE_LICENSE "licence.rtf"
!insertmacro MUI_PAGE_COMPONENTS
!insertmacro MUI_PAGE_DIRECTORY
!insertmacro MUI_PAGE_INSTFILES
!insertmacro MUI_PAGE_FINISH
;Uninstaller Pages
!insertmacro MUI_UNPAGE_WELCOME
!insertmacro MUI_UNPAGE_COMPONENTS
!insertmacro MUI_UNPAGE_DIRECTORY
!insertmacro MUI_UNPAGE_INSTFILES
!insertmacro MUI_UNPAGE_FINISH
;Languages
!insertmacro MUI_LANGUAGE "German"
!insertmacro MUI_LANGUAGE "English"
;--------------------------------
Name "Gothic Reloaded Mod"
OutFile "GRM.exe"
InstallDir "$PROGRAMFILES\PiranhaBytes\Gothic"
;--------------------------------
Function .onGUIInit
;/////////////////////////////////////////
InitPluginsDir
SetOutPath $PLUGINSDIR
File "background.bmp"
BgImage::setBg /NOUNLOAD /FILLSCREEN "$PLUGINSDIR\background.bmp"
BgImage::Redraw /NOUNLOAD
;/////////////////////////////////////////
FunctionEnd
Function .onInit
!insertmacro MUI_LANGDLL_DISPLAY
InitPluginsDir
;--------------------------------
; SetOutPath $PLUGINSDIR
; File "Installer_loop.mp3"
; System::Call 'msvfw32.dll::MCIWndCreate(i 0, i 0,i 0x0070, t "$PLUGINSDIR\Installer_loop.mp3") i .r0'
; StrCpy $hmci $0
; SendMessage $hmci 0x0490 0 0 $0
; IntCmp $0 0 nosup
; ShowWindow $hmci SW_HIDE
; SendMessage $hmci 0x0465 0 "STR:play repeat"
; nosup:
;--------------------------------
FunctionEnd
;Sections
;/////////////////////////////////////////////////////
;/////////////////////////////////////////////////////
Section "Gothic1-mod" G1
SectionIn RO
;Icon und INI in System kopieren
SetOutPath "$INSTDIR\System"
File ".\install\System\GRM.ini"
File ".\install\System\GRM_48.ico"
;.mod in modvdf kopieren
SetOutPath "$INSTDIR\Data\modvdf"
File ".\install\Data\modvdf\GRM.mod"
;Uninstaller
WriteUninstaller "$INSTDIR\GRM-Uninstall.exe"
;Save Ordner
CreateDirectory "$INSTDIR\saves_GRM\current"
SectionEnd
Section "Gothic Reloaded Mod" GRM
;Icon und INI in System kopieren
SetOutPath "$INSTDIR\System"
File ".\install\System\GRM.ini"
File ".\install\System\GRM_48.ico"
SectionEnd
;/////////////////////////////////////////////////////
;/////////////////////////////////////////////////////
LangString DESC_G1 ${LANG_ENGLISH} "Gothic 1 Modification for the game Gothic 2"
LangString DESC_GRM ${LANG_ENGLISH} "More detailed meshes and better textures to improve the graphics of the game"
LangString DESC_G1 ${LANG_GERMAN} "Gothic 1 Mod für Gothic 2"
LangString DESC_GRM ${LANG_GERMAN} "Detailreichere Meshes und bessere Texturen für Gothic 1"
!insertmacro MUI_FUNCTION_DESCRIPTION_BEGIN
!insertmacro MUI_DESCRIPTION_TEXT ${G1} $(DESC_G1)
!insertmacro MUI_DESCRIPTION_TEXT ${GRM} $(DESC_GRM)
!insertmacro MUI_FUNCTION_DESCRIPTION_END
Function un.onUninstSuccess
HideWindow
MessageBox MB_ICONINFORMATION|MB_OK "Gothic Reloaded wurde erfolgreich deinstalliert."
FunctionEnd
Section "Uninstall"
Delete "$INSTDIR\System\GRM.ini"
Delete "$INSTDIR\Data\modvdf\GRM.mod"
Delete "$INSTDIR\DS-Uninstall.exe"
RMDir "$INSTDIR\Data\modvdf"
SectionEnd
also the window to select the language doesnt show up
and the part to play background music isnt working -> error while compiling in line: "StrCpy $hmci $0"
thx for all help i may will get :D
and sorry for the bad english