最新消息:

实例MOD播放例子

nsis 永恒心锁 1790浏览 0评论
SetCompressor /SOLID lzma
XPStyle on
Name "Test"
OutFile "Test.exe"
Caption "Test安装向导"
BrandingText 'Test'
Var count
SetFont /LANG=2052 "tahoma" 8
!include "UseFulLib.nsh"
!include "MUI.nsh"
InstallDir "$EXEDIR"
!define MUI_ABORTWARNING
!define MUI_CUSTOMFUNCTION_GUIINIT MyGUIInit ;创建关于相关链接
!insertmacro MUI_PAGE_WELCOME
!insertmacro MUI_PAGE_COMPONENTS
!insertmacro MUI_PAGE_DIRECTORY
!insertmacro MUI_PAGE_INSTFILES
!insertmacro MUI_PAGE_FINISH
!insertmacro MUI_LANGUAGE "SimpChinese"
Section "BOO"
SectionEnd
Function MyGUIInit
Push `;`
System::Call 'User32::CreateWindowEx(i,t,t,i,i,i,i,i,i,i,i,v) i (0,"button",s,0x54000000,i 10,i 327,i 24,i 24,$HWNDPARENT,1199,s,0) .s'
Exch $R0
Push $R1
CreateFont $R1 "webdings" 11 1500
SetCtlColors $R1 0xFF0080 transparent
SendMessage $R0 ${WM_SETFONT} $R1 0
GetFunctionAddress $R2 Link1
ButtonLinker::AddEventHandler /NOUNLOAD 1199 $R2
FunctionEnd
Function Link1
GetDlgItem $R2 $HWNDPARENT 1199
IntOp $count $count !
StrCmp $count 1 +1 +4
System::Call '$PLUGINSDIRBASSMOD::BASSMOD_MusicPause()'
SendMessage $R2 ${WM_SETTEXT} 0 "STR:4"
Goto +3
System::Call '$PLUGINSDIRBASSMOD::BASSMOD_MusicPlay()'
SendMessage $R2 ${WM_SETTEXT} 0 "STR:;"
FunctionEnd
Function .onInit
InitPluginsDir
StrCpy $count 0
File /oname=$PLUGINSDIRBASSMOD.dll BASSMOD.dll
File /oname=$PLUGINSDIRmymusic.mod mymusic.mod
StrCpy $R1 "$PLUGINSDIRmymusic.mod"
System::Call '$PLUGINSDIRBASSMOD::BASSMOD_Init(i -1,i 44100,i 0)'
System::Call '$PLUGINSDIRBASSMOD::BASSMOD_MusicFree()'
System::Call '$PLUGINSDIRBASSMOD::BASSMOD_MusicLoad(i 0,t R1,i 0,i 0,i 4)'
System::Call '$PLUGINSDIRBASSMOD::BASSMOD_MusicPlay()'
FunctionEnd
Function .onGUIEnd
System::Call '$PLUGINSDIRBASSMOD::BASSMOD_MusicStop()'
System::Call '$PLUGINSDIRBASSMOD::BASSMOD_MusicFree()'
FunctionEnd
永恒心锁,版权所有丨如未注明,均为转载丨本网站采用BY-NC-SA协议进行授权

转载请注明:永恒心锁-分享互联网 » 实例MOD播放例子

您必须 登录 才能发表评论!