Function at 0x40d310
Capabilities:
Resolve function by parsing pe exports

Disassembly:
push 0xffffffffffffffff
push 0x4b3290
mov eax, dword fs:[0]
push eax
mov dword fs:[0], esp
sub esp, 0x64
push ebx
mov ebx, ecx
push ebp
push esi
mov dword [esp + 0x20], ebx
xor ebp, ebp
mov dword [esp + 0x78], ebp
mov dword [esp + 0xc], ebp
lea eax, [esp + 0xc]
mov byte [esp + 0x78], 1
push eax
call fcn.0040d1b0
test al, al
jne 0x40d3c6
push str.Cannot_GetScript
lea ecx, [esp + 0x8c]
call fcn.00491a3a
push eax
lea ecx, [esp + 0x88]
push str.JSCall_Error:_n
push ecx
mov byte [esp + 0x84], 2
call fcn.00491cd5
push eax
lea ecx, [ebx + 8]
mov byte [esp + 0x7c], 3
call fcn.00491b05
lea ecx, [esp + 0x84]
mov byte [esp + 0x78], 2
call fcn.004919cc
lea ecx, [esp + 0x88]
mov byte [esp + 0x78], 1
call fcn.004919cc
mov eax, dword [esp + 0xc]
mov byte [esp + 0x78], 0
cmp eax, ebp
je 0x40d6ab
mov edx, dword [eax]
push eax
call dword [edx + 8]
jmp 0x40d6ab
mov eax, dword [esp + 0x80]
push 0xffffffffffffffff
push eax
call fcn.0040d750
add esp, 8
mov dword [esp + 0x10], eax
mov eax, dword [esp + 0xc]
lea edx, [esp + 0x18]
push edx
push 0x800
lea edx, [esp + 0x18]
push 1
mov dword [esp + 0x24], ebp
mov ecx, dword [eax]
push edx
push 0x4c9280
push eax
mov byte [esp + 0x90], 4
call dword [ecx + 0x14]
cmp eax, ebp
jge 0x40d4ac
push eax
lea eax, [esp + 0x18]
push eax
call fcn.0040ced0
add esp, 8
mov eax, dword [eax]
lea ecx, [esp + 0x88]
push eax
mov byte [esp + 0x7c], 5
call fcn.00491a3a
push eax
lea ecx, [esp + 0x88]
push str.JSCall_Error:_n
push ecx
mov byte [esp + 0x84], 6
call fcn.00491cd5
push eax
lea ecx, [ebx + 8]
mov byte [esp + 0x7c], 7
call fcn.00491b05
lea ecx, [esp + 0x84]
mov byte [esp + 0x78], 6
call fcn.004919cc
lea ecx, [esp + 0x88]
mov byte [esp + 0x78], 5
call fcn.004919cc
lea ecx, [esp + 0x14]
mov byte [esp + 0x78], 4
call fcn.004919cc
mov edx, dword [esp + 0x10]
push edx
call dword [sym.imp.OLEAUT32.dll_SysStringLen]
mov eax, dword [esp + 0xc]
mov byte [esp + 0x78], 0
cmp eax, ebp
je 0x40d6ab
jmp 0x40d6a5
mov edx, dword [esp + 0x84]
xor eax, eax
mov dword [esp + 0x30], eax
push edi
mov esi, dword [edx + 8]
mov dword [esp + 0x38], eax
mov ecx, esi
mov dword [esp + 0x3c], eax
shl ecx, 4
push ecx
mov dword [esp + 0x2c], esi
mov dword [esp + 0x44], eax
mov dword [esp + 0x40], esi
call fcn.0049170d
add esp, 4
cmp esi, ebp
mov dword [esp + 0x34], eax
jle 0x40d583
xor edi, edi
lea ebx, [esi - 1]
mov dword [esp + 0x18], esi
mov ecx, dword [esp + 0x88]
lea edx, [esp + 0x20]
push ebx
push edx
call fcn.0040d7a0
mov eax, dword [eax]
push 0xffffffffffffffff
push eax
mov byte [esp + 0x84], 8
call fcn.0040d750
mov esi, eax
add esp, 8
mov dword [esp + 0x30], esi
lea ecx, [esp + 0x20]
mov byte [esp + 0x7c], 0xa
call fcn.004919cc
mov eax, dword [esp + 0x34]
lea ebp, [edi + eax + 8]
test ebp, ebp
je 0x40d54d
push esi
call dword [sym.imp.OLEAUT32.dll_VariantInit]
push eax
push esi
call dword [sym.imp.OLEAUT32.dll_SysReAllocStringLen]
mov dword [ebp], eax
mov ecx, dword [esp + 0x34]
push esi
mov byte [esp + 0x80], 4
mov word [edi + ecx], 8
call dword [sym.imp.OLEAUT32.dll_SysStringLen]
mov eax, dword [esp + 0x18]
dec ebx
add edi, 0x10
dec eax
mov dword [esp + 0x18], eax
jne 0x40d4f4
mov ebx, dword [esp + 0x24]
mov esi, dword [esp + 0x28]
xor ebp, ebp
mov ecx, 8
xor eax, eax
lea edi, [esp + 0x54]
mov dword [esp + 0x40], ebp
rep stosd dword es:[edi], eax
mov word [esp + 0x44], bp
lea ecx, [esp + 0x2c]
mov eax, dword [esp + 0x10]
push ecx
lea ecx, [esp + 0x58]
push ecx
lea ecx, [esp + 0x4c]
push ecx
lea ecx, [esp + 0x40]
push ecx
mov ecx, dword [esp + 0x2c]
push 1
push ebp
mov dword [esp + 0x44], 0xffffffff
mov edx, dword [eax]
push 0x4c9280
push ecx
push eax
mov byte [esp + 0xa0], 0xb
call dword [edx + 0x18]
test esi, esi
mov ebp, eax
jle 0x40d5f1
xor edi, edi
mov edx, dword [esp + 0x34]
mov eax, dword [edi + edx + 8]
push eax
call dword [sym.imp.OLEAUT32.dll_SysStringLen]
add edi, 0x10
dec esi
jne 0x40d5dc
mov ecx, dword [esp + 0x34]
push ecx
call fcn.00491736
add esp, 4
test ebp, ebp
pop edi
jge 0x40d6d5
lea edx, [esp + 0x24]
push ebp
push edx
call fcn.0040ced0
add esp, 8
mov eax, dword [eax]
lea ecx, [esp + 0x88]
push eax
mov byte [esp + 0x7c], 0xc
call fcn.00491a3a
push eax
lea eax, [esp + 0x88]
push str.JSCall_Error:_n
push eax
mov byte [esp + 0x84], 0xd
call fcn.00491cd5
push eax
lea ecx, [ebx + 8]
mov byte [esp + 0x7c], 0xe
call fcn.00491b05
lea ecx, [esp + 0x84]
mov byte [esp + 0x78], 0xd
call fcn.004919cc
lea ecx, [esp + 0x88]
mov byte [esp + 0x78], 0xc
call fcn.004919cc
lea ecx, [esp + 0x24]
mov byte [esp + 0x78], 0xb
call fcn.004919cc
lea ecx, [esp + 0x40]
push ecx
call dword [sym.imp.OLEAUT32.dll_VariantCopy]
mov edx, dword [esp + 0x10]
push edx
call dword [sym.imp.OLEAUT32.dll_SysStringLen]
mov eax, dword [esp + 0xc]
mov byte [esp + 0x78], 0
test eax, eax
je 0x40d6ab
mov ecx, dword [eax]
push eax
call dword [ecx + 8]
lea ecx, [esp + 0x80]
mov dword [esp + 0x78], 0xffffffff
call fcn.004919cc
pop esi
pop ebp
xor al, al
pop ebx
mov ecx, dword [esp + 0x64]
mov dword fs:[0], ecx
add esp, 0x70
ret 0xc
mov esi, dword [esp + 0x88]
test esi, esi
je 0x40d6f8
lea edx, [esp + 0x40]
push edx
push esi
call dword [sym.imp.OLEAUT32.dll_VariantCopyInd]
test eax, eax
jge 0x40d6f8
mov word [esi], 0xa
mov dword [esi + 8], eax
lea eax, [esp + 0x40]
push eax
call dword [sym.imp.OLEAUT32.dll_VariantCopy]
mov ecx, dword [esp + 0x10]
push ecx
call dword [sym.imp.OLEAUT32.dll_SysStringLen]
mov eax, dword [esp + 0xc]
mov byte [esp + 0x78], 0
test eax, eax
je 0x40d721
mov edx, dword [eax]
push eax
call dword [edx + 8]
lea ecx, [esp + 0x80]
mov dword [esp + 0x78], 0xffffffff
call fcn.004919cc
mov ecx, dword [esp + 0x70]
pop esi
pop ebp
mov al, 1
pop ebx
mov dword fs:[0], ecx
add esp, 0x70
ret 0xc