; ; CustomSongWidget::onPlayback from 0x1400caec0 to 0x1400cb2a0 (992 bytes) ; ; 2 xrefs: ; > CustomSongWidget::init @ 0x1400c89df ; > @ 0x1406c831c ; ; This function is hookable on this platform! ; ; Using BromaIDA 8.0.0 @ https:;github.com/Stazzical/BromaIDA ; Using bindings at commit ba9f177b at Thu Jul 16 22:52:06 2026 from https:;github.com/geode-sdk/bindings ; mov [rsp-8+arg_8], rbx ; +0x0, 0x1400caec0 mov [rsp-8+arg_10], rsi ; +0x5, 0x1400caec5 mov [rsp-8+arg_18], rdi ; +0xa, 0x1400caeca push rbp ; +0xf, 0x1400caecf push r14 ; +0x10, 0x1400caed0 push r15 ; +0x12, 0x1400caed2 lea rbp, [rsp-47h] ; +0x14, 0x1400caed4 sub rsp, 0B0h ; +0x19, 0x1400caed9 mov rax, cs:__security_cookie ; +0x20, 0x1400caee0 xor rax, rsp ; +0x27, 0x1400caee7 mov [rbp+57h+var_20], rax ; +0x2a, 0x1400caeea mov rsi, rcx ; +0x2e, 0x1400caeee mov rcx, [rcx+200h] ; +0x31, 0x1400caef1 test rcx, rcx ; +0x38, 0x1400caef8 jz short loc_1400CAF0E ; +0x3b, 0x1400caefb mov rax, [rcx] ; +0x3d, 0x1400caefd mov rdx, [rsi+150h] ; +0x40, 0x1400caf00 call qword ptr [rax] ; +0x47, 0x1400caf07 jmp loc_1400CB271 ; +0x49, 0x1400caf09 mov rbx, [rsi+150h] ; +0x4e, 0x1400caf0e test rbx, rbx ; +0x55, 0x1400caf15 jz loc_1400CB271 ; +0x58, 0x1400caf18 call MusicDownloadManager__sharedState ; +0x5e, 0x1400caf1e mov rcx, rax ; +0x63, 0x1400caf23 mov r8d, [rbx+140h] ; +0x66, 0x1400caf26 lea rdx, [rbp+57h+Src] ; +0x6d, 0x1400caf2d call MusicDownloadManager__pathForSong ; +0x71, 0x1400caf31 nop ; +0x76, 0x1400caf36 mov rcx, cs:qword_1406C2E88 ; +0x77, 0x1400caf37 test rcx, rcx ; +0x7e, 0x1400caf3e jnz short loc_1400CAF71 ; +0x81, 0x1400caf41 mov ecx, 888h; Size ; +0x83, 0x1400caf43 call ??2@YAPEAX_K@Z; operator new(unsigned __int64) ; +0x88, 0x1400caf48 mov [rbp+57h+var_68], rax ; +0x8d, 0x1400caf4d mov rcx, rax ; +0x91, 0x1400caf51 call FMODAudioEngine__FMODAudioEngine ; +0x94, 0x1400caf54 nop ; +0x99, 0x1400caf59 mov cs:qword_1406C2E88, rax ; +0x9a, 0x1400caf5a mov rdx, [rax] ; +0xa1, 0x1400caf61 mov rcx, rax ; +0xa4, 0x1400caf64 call qword ptr [rdx+48h] ; +0xa7, 0x1400caf67 mov rcx, cs:qword_1406C2E88 ; +0xaa, 0x1400caf6a xor edx, edx ; +0xb1, 0x1400caf71 call FMODAudioEngine__isMusicPlaying_1 ; +0xb3, 0x1400caf73 xor r15d, r15d ; +0xb8, 0x1400caf78 test al, al ; +0xbb, 0x1400caf7b jz loc_1400CB0D7 ; +0xbd, 0x1400caf7d lea rax, [rbp+57h+var_88] ; +0xc3, 0x1400caf83 mov [rbp+57h+var_68], rax ; +0xc7, 0x1400caf87 xorps xmm0, xmm0 ; +0xcb, 0x1400caf8b movups [rbp+57h+var_88], xmm0 ; +0xce, 0x1400caf8e mov [rbp+57h+var_78], r15 ; +0xd2, 0x1400caf92 mov [rbp+57h+var_70], r15 ; +0xd6, 0x1400caf96 lea r14, [rbp+57h+Src] ; +0xda, 0x1400caf9a cmp [rbp+57h+var_48], 0Fh ; +0xde, 0x1400caf9e cmova r14, [rbp+57h+Src] ; +0xe3, 0x1400cafa3 mov rdi, [rbp+57h+var_50] ; +0xe8, 0x1400cafa8 mov rbx, 7FFFFFFFFFFFFFFFh ; +0xec, 0x1400cafac cmp rdi, rbx ; +0xf6, 0x1400cafb6 ja loc_1400CB29A ; +0xf9, 0x1400cafb9 mov [rbp+57h+var_70], 0Fh ; +0xff, 0x1400cafbf cmp rdi, 0Fh ; +0x107, 0x1400cafc7 ja short loc_1400CAFDB ; +0x10b, 0x1400cafcb mov [rbp+57h+var_78], rdi ; +0x10d, 0x1400cafcd movups xmm0, xmmword ptr [r14] ; +0x111, 0x1400cafd1 movups [rbp+57h+var_88], xmm0 ; +0x115, 0x1400cafd5 jmp short loc_1400CB01B ; +0x119, 0x1400cafd9 mov rax, rdi ; +0x11b, 0x1400cafdb or rax, 0Fh ; +0x11e, 0x1400cafde cmp rax, rbx ; +0x122, 0x1400cafe2 ja short loc_1400CAFF6 ; +0x125, 0x1400cafe5 mov rbx, rax ; +0x127, 0x1400cafe7 mov ecx, 16h ; +0x12a, 0x1400cafea cmp rax, rcx ; +0x12f, 0x1400cafef cmovb rbx, rcx ; +0x132, 0x1400caff2 lea rcx, [rbx+1] ; +0x136, 0x1400caff6 call sub_14003AA10 ; +0x13a, 0x1400caffa mov qword ptr [rbp+57h+var_88], rax ; +0x13f, 0x1400cafff mov [rbp+57h+var_78], rdi ; +0x143, 0x1400cb003 mov [rbp+57h+var_70], rbx ; +0x147, 0x1400cb007 lea r8, [rdi+1]; Size ; +0x14b, 0x1400cb00b mov rdx, r14; Src ; +0x14f, 0x1400cb00f mov rcx, rax; void * ; +0x152, 0x1400cb012 call memcpy ; +0x155, 0x1400cb015 nop ; +0x15a, 0x1400cb01a mov rcx, cs:qword_1406C2E88 ; +0x15b, 0x1400cb01b test rcx, rcx ; +0x162, 0x1400cb022 jnz short loc_1400CB055 ; +0x165, 0x1400cb025 mov ecx, 888h; Size ; +0x167, 0x1400cb027 call ??2@YAPEAX_K@Z; operator new(unsigned __int64) ; +0x16c, 0x1400cb02c mov [rbp+57h+var_90], rax ; +0x171, 0x1400cb031 mov rcx, rax ; +0x175, 0x1400cb035 call FMODAudioEngine__FMODAudioEngine ; +0x178, 0x1400cb038 nop ; +0x17d, 0x1400cb03d mov cs:qword_1406C2E88, rax ; +0x17e, 0x1400cb03e mov rdx, [rax] ; +0x185, 0x1400cb045 mov rcx, rax ; +0x188, 0x1400cb048 call qword ptr [rdx+48h] ; +0x18b, 0x1400cb04b mov rcx, cs:qword_1406C2E88 ; +0x18e, 0x1400cb04e lea rdx, [rbp+57h+var_88] ; +0x195, 0x1400cb055 call FMODAudioEngine__isMusicPlaying ; +0x199, 0x1400cb059 test al, al ; +0x19e, 0x1400cb05e jnz short loc_1400CB0D7 ; +0x1a0, 0x1400cb060 mov rbx, cs:qword_1406C2E88 ; +0x1a2, 0x1400cb062 test rbx, rbx ; +0x1a9, 0x1400cb069 jnz short loc_1400CB09C ; +0x1ac, 0x1400cb06c mov ecx, 888h; Size ; +0x1ae, 0x1400cb06e call ??2@YAPEAX_K@Z; operator new(unsigned __int64) ; +0x1b3, 0x1400cb073 mov [rbp+57h+var_90], rax ; +0x1b8, 0x1400cb078 mov rcx, rax ; +0x1bc, 0x1400cb07c call FMODAudioEngine__FMODAudioEngine ; +0x1bf, 0x1400cb07f nop ; +0x1c4, 0x1400cb084 mov cs:qword_1406C2E88, rax ; +0x1c5, 0x1400cb085 mov rdx, [rax] ; +0x1cc, 0x1400cb08c mov rcx, rax ; +0x1cf, 0x1400cb08f call qword ptr [rdx+48h] ; +0x1d2, 0x1400cb092 mov rbx, cs:qword_1406C2E88 ; +0x1d5, 0x1400cb095 cmp qword ptr [rbx+228h], 0 ; +0x1dc, 0x1400cb09c jz short loc_1400CB0B3 ; +0x1e4, 0x1400cb0a4 mov rcx, [rbx+228h] ; +0x1e6, 0x1400cb0a6 call cs:?stop@ChannelControl@FMOD@@QEAA?AW4FMOD_RESULT@@XZ; FMOD::ChannelControl::stop(void) ; +0x1ed, 0x1400cb0ad lea rcx, [rbx+428h] ; +0x1f3, 0x1400cb0b3 call sub_14005E0D0 ; +0x1fa, 0x1400cb0ba lea rcx, [rbx+468h] ; +0x1ff, 0x1400cb0bf call sub_14005E0D0 ; +0x206, 0x1400cb0c6 lea rcx, [rbx+4A8h] ; +0x20b, 0x1400cb0cb call sub_14005E0D0 ; +0x212, 0x1400cb0d2 mov rcx, cs:qword_1406C2E88 ; +0x217, 0x1400cb0d7 test rcx, rcx ; +0x21e, 0x1400cb0de jnz short loc_1400CB111 ; +0x221, 0x1400cb0e1 mov ecx, 888h; Size ; +0x223, 0x1400cb0e3 call ??2@YAPEAX_K@Z; operator new(unsigned __int64) ; +0x228, 0x1400cb0e8 mov [rbp+57h+var_90], rax ; +0x22d, 0x1400cb0ed mov rcx, rax ; +0x231, 0x1400cb0f1 call FMODAudioEngine__FMODAudioEngine ; +0x234, 0x1400cb0f4 nop ; +0x239, 0x1400cb0f9 mov cs:qword_1406C2E88, rax ; +0x23a, 0x1400cb0fa mov rdx, [rax] ; +0x241, 0x1400cb101 mov rcx, rax ; +0x244, 0x1400cb104 call qword ptr [rdx+48h] ; +0x247, 0x1400cb107 mov rcx, cs:qword_1406C2E88 ; +0x24a, 0x1400cb10a xor edx, edx ; +0x251, 0x1400cb111 call FMODAudioEngine__isMusicPlaying_1 ; +0x253, 0x1400cb113 test al, al ; +0x258, 0x1400cb118 jz short loc_1400CB196 ; +0x25a, 0x1400cb11a mov rbx, cs:qword_1406C2E88 ; +0x25c, 0x1400cb11c test rbx, rbx ; +0x263, 0x1400cb123 jnz short loc_1400CB156 ; +0x266, 0x1400cb126 mov ecx, 888h; Size ; +0x268, 0x1400cb128 call ??2@YAPEAX_K@Z; operator new(unsigned __int64) ; +0x26d, 0x1400cb12d mov [rbp+57h+var_90], rax ; +0x272, 0x1400cb132 mov rcx, rax ; +0x276, 0x1400cb136 call FMODAudioEngine__FMODAudioEngine ; +0x279, 0x1400cb139 nop ; +0x27e, 0x1400cb13e mov cs:qword_1406C2E88, rax ; +0x27f, 0x1400cb13f mov rdx, [rax] ; +0x286, 0x1400cb146 mov rcx, rax ; +0x289, 0x1400cb149 call qword ptr [rdx+48h] ; +0x28c, 0x1400cb14c mov rbx, cs:qword_1406C2E88 ; +0x28f, 0x1400cb14f cmp qword ptr [rbx+228h], 0 ; +0x296, 0x1400cb156 jz short loc_1400CB16D ; +0x29e, 0x1400cb15e mov rcx, [rbx+228h] ; +0x2a0, 0x1400cb160 call cs:?stop@ChannelControl@FMOD@@QEAA?AW4FMOD_RESULT@@XZ; FMOD::ChannelControl::stop(void) ; +0x2a7, 0x1400cb167 lea rcx, [rbx+428h] ; +0x2ad, 0x1400cb16d call sub_14005E0D0 ; +0x2b4, 0x1400cb174 lea rcx, [rbx+468h] ; +0x2b9, 0x1400cb179 call sub_14005E0D0 ; +0x2c0, 0x1400cb180 lea rcx, [rbx+4A8h] ; +0x2c5, 0x1400cb185 call sub_14005E0D0 ; +0x2cc, 0x1400cb18c jmp loc_1400CB25A ; +0x2d1, 0x1400cb191 mov rbx, [rsi+150h] ; +0x2d6, 0x1400cb196 test rbx, rbx ; +0x2dd, 0x1400cb19d jz loc_1400CB25A ; +0x2e0, 0x1400cb1a0 lea rax, [rbp+57h+var_88] ; +0x2e6, 0x1400cb1a6 mov [rbp+57h+var_90], rax ; +0x2ea, 0x1400cb1aa call MusicDownloadManager__sharedState ; +0x2ee, 0x1400cb1ae mov rcx, rax ; +0x2f3, 0x1400cb1b3 mov r8d, [rbx+140h] ; +0x2f6, 0x1400cb1b6 lea rdx, [rbp+57h+var_40] ; +0x2fd, 0x1400cb1bd call MusicDownloadManager__pathForSong ; +0x301, 0x1400cb1c1 nop ; +0x306, 0x1400cb1c6 cmp qword ptr [rax+18h], 0Fh ; +0x307, 0x1400cb1c7 jbe short loc_1400CB1D1 ; +0x30c, 0x1400cb1cc mov rax, [rax] ; +0x30e, 0x1400cb1ce xorps xmm0, xmm0 ; +0x311, 0x1400cb1d1 movups [rbp+57h+var_88], xmm0 ; +0x314, 0x1400cb1d4 mov [rbp+57h+var_78], r15 ; +0x318, 0x1400cb1d8 mov [rbp+57h+var_70], r15 ; +0x31c, 0x1400cb1dc mov r8, 0FFFFFFFFFFFFFFFFh ; +0x320, 0x1400cb1e0 nop word ptr [rax+rax+00000000h] ; +0x327, 0x1400cb1e7 inc r8 ; +0x330, 0x1400cb1f0 cmp byte ptr [rax+r8], 0 ; +0x333, 0x1400cb1f3 jnz short loc_1400CB1F0 ; +0x338, 0x1400cb1f8 mov rdx, rax ; +0x33a, 0x1400cb1fa lea rcx, [rbp+57h+var_88] ; +0x33d, 0x1400cb1fd call sub_14003A930 ; +0x341, 0x1400cb201 nop ; +0x346, 0x1400cb206 mov rcx, cs:qword_1406C2E88 ; +0x347, 0x1400cb207 test rcx, rcx ; +0x34e, 0x1400cb20e jnz short loc_1400CB241 ; +0x351, 0x1400cb211 mov ecx, 888h; Size ; +0x353, 0x1400cb213 call ??2@YAPEAX_K@Z; operator new(unsigned __int64) ; +0x358, 0x1400cb218 mov [rbp+57h+var_68], rax ; +0x35d, 0x1400cb21d mov rcx, rax ; +0x361, 0x1400cb221 call FMODAudioEngine__FMODAudioEngine ; +0x364, 0x1400cb224 nop ; +0x369, 0x1400cb229 mov cs:qword_1406C2E88, rax ; +0x36a, 0x1400cb22a mov rdx, [rax] ; +0x371, 0x1400cb231 mov rcx, rax ; +0x374, 0x1400cb234 call qword ptr [rdx+48h] ; +0x377, 0x1400cb237 mov rcx, cs:qword_1406C2E88 ; +0x37a, 0x1400cb23a xorps xmm3, xmm3 ; +0x381, 0x1400cb241 xor r8d, r8d ; +0x384, 0x1400cb244 lea rdx, [rbp+57h+var_88] ; +0x387, 0x1400cb247 call FMODAudioEngine__playMusic ; +0x38b, 0x1400cb24b nop ; +0x390, 0x1400cb250 lea rcx, [rbp+57h+var_40] ; +0x391, 0x1400cb251 call sub_14003A830 ; +0x395, 0x1400cb255 call MusicDownloadManager__sharedState ; +0x39a, 0x1400cb25a mov rcx, rax ; +0x39f, 0x1400cb25f call MusicDownloadManager__songStateChanged ; +0x3a2, 0x1400cb262 nop ; +0x3a7, 0x1400cb267 lea rcx, [rbp+57h+Src] ; +0x3a8, 0x1400cb268 call sub_14003A830 ; +0x3ac, 0x1400cb26c mov rcx, [rbp+57h+var_20] ; +0x3b1, 0x1400cb271 xor rcx, rsp; StackCookie ; +0x3b5, 0x1400cb275 call __security_check_cookie ; +0x3b8, 0x1400cb278 lea r11, [rsp+0C0h+var_10] ; +0x3bd, 0x1400cb27d mov rbx, [r11+28h] ; +0x3c5, 0x1400cb285 mov rsi, [r11+30h] ; +0x3c9, 0x1400cb289 mov rdi, [r11+38h] ; +0x3cd, 0x1400cb28d mov rsp, r11 ; +0x3d1, 0x1400cb291 pop r15 ; +0x3d4, 0x1400cb294 pop r14 ; +0x3d6, 0x1400cb296 pop rbp ; +0x3d8, 0x1400cb298 retn ; +0x3d9, 0x1400cb299 call sub_140007B50 ; +0x3da, 0x1400cb29a align 20h ; +0x3df, 0x1400cb29f