Function at 0x40a880
Capabilities:
Reference sql statements

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x44b20a
mov eax, dword fs:[0]
push eax
mov dword fs:[0], esp
sub esp, 0xf0
mov eax, dword [0x461fe4]
push ebx
push esi
push edi
mov edi, ecx
mov dword [ebp - 0x10], esp
mov dword [ebp - 0x18], edi
mov dword [ebp - 0x14], eax
mov eax, dword [edi + 0x14]
mov dword [ebp - 4], 0
mov ecx, dword [eax]
mov edx, dword [eax + 4]
add eax, 4
mov dword [ebp - 0x50], edx
add eax, 4
mov dword [ebp - 0x24], eax
mov eax, dword [edi + 0x1c]
cmp ecx, eax
je 0x40a900
push 0x45ff40
lea ecx, [edi + 0x60]
call fcn.004313ab
lea ecx, [ebp - 0x14]
mov dword [ebp - 4], 0xffffffff
call fcn.00431222
mov ecx, dword [ebp - 0xc]
pop edi
pop esi
mov dword fs:[0], ecx
pop ebx
mov esp, ebp
pop ebp
ret
mov eax, dword [0x4661b0]
test eax, eax
jne 0x40a913
push 0x80004003
call fcn.0042d648
mov esi, dword [0x4661b0]
lea ecx, [ebp - 0x28]
push ecx
push esi
mov eax, dword [esi]
call dword [eax + 0x44]
test eax, eax
jge 0x40a933
push 0x45f148
push esi
push eax
call fcn.0042d656
mov edx, dword [edi + 0x80]
lea eax, [ebp - 0x14]
push edx
push str.DELETE_FROM_FCFH_ROOMIMG_WHERE_BLDGID___d
push eax
mov byte [ebp - 4], 1
call fcn.0042dd0d
add esp, 0xc
lea ecx, [ebp - 0x14]
push 0
push 0
call fcn.00402890
push ecx
mov ecx, esp
mov dword [ebp - 0x28], esp
push eax
call fcn.004028c0
mov ecx, 0x4661b0
mov byte [ebp - 4], 2
call fcn.0040b0d0
lea ecx, [ebp - 0x1c]
mov byte [ebp - 4], 1
push ecx
mov ecx, eax
call fcn.0040b4d0
lea ecx, [ebp - 0x1c]
call fcn.004027e0
mov edx, dword [edi + 0x80]
lea eax, [ebp - 0x14]
push edx
push str.SELECT__FROM_FCFH_ROOMIMG_WHERE_BLDGID___d
push eax
call fcn.0042dd0d
mov eax, dword [ebp - 0x14]
add esp, 0xc
mov esi, eax
mov word [ebp - 0x48], 8
push eax
call fcn.0042d6f5
test eax, eax
mov dword [ebp - 0x40], eax
jne 0x40a9ca
test esi, esi
je 0x40a9ca
push 0x8007000e
call fcn.0042d648
mov eax, dword [0x4661b0]
mov word [ebp - 0x38], 9
mov dword [ebp - 0x30], eax
mov bl, 3
mov ecx, dword [eax]
push eax
mov byte [ebp - 4], bl
call dword [ecx + 4]
mov eax, dword [edi + 0x32c]
add edi, 0x32c
test eax, eax
mov byte [ebp - 4], 4
jne 0x40aa01
push 0x80004003
call fcn.0042d648
mov ecx, dword [ebp - 0x38]
push 1
push 2
push 2
sub esp, 0x10
mov esi, dword [edi]
mov eax, esp
sub esp, 0x10
mov edx, dword [esi]
mov dword [eax], ecx
mov ecx, dword [ebp - 0x34]
mov dword [eax + 4], ecx
mov ecx, dword [ebp - 0x30]
mov dword [eax + 8], ecx
mov ecx, dword [ebp - 0x2c]
mov dword [eax + 0xc], ecx
mov ecx, dword [ebp - 0x48]
mov eax, esp
push esi
mov dword [eax], ecx
mov ecx, dword [ebp - 0x44]
mov dword [eax + 4], ecx
mov ecx, dword [ebp - 0x40]
mov dword [eax + 8], ecx
mov ecx, dword [ebp - 0x3c]
mov dword [eax + 0xc], ecx
call dword [edx + 0xa0]
test eax, eax
jge 0x40aa5a
push 0x45f358
push esi
push eax
call fcn.0042d656
mov esi, dword [sym.imp.OLEAUT32.dll_VariantCopy]
lea edx, [ebp - 0x38]
push edx
mov byte [ebp - 4], bl
call esi
test eax, eax
jge 0x40aa73
push eax
call fcn.0042d648
lea eax, [ebp - 0x48]
mov byte [ebp - 4], 1
push eax
call esi
test eax, eax
jge 0x40aa87
push eax
call fcn.0042d648
mov dword [ebp - 0x1c], 0
mov ecx, dword [ebp - 0x1c]
mov eax, dword [ebp - 0x50]
cmp ecx, eax
mov eax, dword [edi]
jae 0x40afbc
test eax, eax
jne 0x40aaac
push 0x80004003
call fcn.0042d648
mov eax, dword [0x468e00]
mov edx, dword [0x468e04]
mov esi, dword [edi]
mov ebx, dword [0x468e08]
sub esp, 0x10
mov ecx, eax
mov dword [ebp - 0x74], eax
mov eax, esp
mov edi, edx
mov dword [ebp - 0xe4], ebx
mov ebx, dword [0x468e0c]
mov dword [eax], ecx
mov ecx, dword [ebp - 0xe4]
sub esp, 0x10
mov dword [eax + 4], edi
mov dword [ebp - 0x70], edx
mov edx, dword [esi]
mov dword [eax + 8], ecx
mov ecx, esp
push esi
mov dword [eax + 0xc], ebx
mov eax, dword [ebp - 0x74]
mov dword [ecx], eax
mov eax, edi
mov dword [ecx + 4], eax
mov eax, dword [0x468e08]
mov dword [ecx + 8], eax
mov eax, ebx
mov dword [ecx + 0xc], eax
call dword [edx + 0x78]
test eax, eax
jge 0x40ab1d
push 0x45f358
push esi
push eax
call fcn.0042d656
mov edi, dword [ebp - 0x18]
mov word [ebp - 0x38], 3
mov eax, dword [edi + 0x80]
mov dword [ebp - 0x30], eax
mov bl, 5
push str.BldgID
mov byte [ebp - 4], bl
mov word [ebp - 0x48], 8
call fcn.0042d6f5
test eax, eax
mov dword [ebp - 0x40], eax
jne 0x40ab5e
mov ecx, str.BldgID
test ecx, ecx
je 0x40ab5e
push 0x8007000e
call fcn.0042d648
mov eax, dword [edi + 0x32c]
mov byte [ebp - 4], 6
test eax, eax
jne 0x40ab76
push 0x80004003
call fcn.0042d648
mov ecx, dword [ebp - 0x38]
sub esp, 0x10
mov eax, esp
sub esp, 0x10
mov esi, dword [edi + 0x32c]
mov dword [eax], ecx
mov ecx, dword [ebp - 0x34]
mov edx, dword [esi]
mov dword [eax + 4], ecx
mov ecx, dword [ebp - 0x30]
mov dword [eax + 8], ecx
mov ecx, dword [ebp - 0x2c]
mov dword [eax + 0xc], ecx
mov ecx, dword [ebp - 0x48]
mov eax, esp
push esi
mov dword [eax], ecx
mov ecx, dword [ebp - 0x44]
mov dword [eax + 4], ecx
mov ecx, dword [ebp - 0x40]
mov dword [eax + 8], ecx
mov ecx, dword [ebp - 0x3c]
mov dword [eax + 0xc], ecx
call dword [edx + 0x100]
test eax, eax
jge 0x40abcd
push 0x45f358
push esi
push eax
call fcn.0042d656
lea edx, [ebp - 0x48]
mov byte [ebp - 4], bl
mov ebx, dword [sym.imp.OLEAUT32.dll_VariantCopy]
push edx
call ebx
test eax, eax
jge 0x40abe6
push eax
call fcn.0042d648
lea eax, [ebp - 0x38]
mov byte [ebp - 4], 1
push eax
call ebx
test eax, eax
jge 0x40abfa
push eax
call fcn.0042d648
push str.RoomID
mov word [ebp - 0xa4], 8
call fcn.0042d6f5
test eax, eax
mov dword [ebp - 0x9c], eax
jne 0x40ac2a
mov ecx, str.RoomID
test ecx, ecx
je 0x40ac2a
push 0x8007000e
call fcn.0042d648
mov esi, dword [ebp - 0x24]
mov byte [ebp - 4], 7
push esi
mov word [ebp - 0x94], 8
call fcn.0042d6f5
test eax, eax
mov dword [ebp - 0x8c], eax
jne 0x40ac58
test esi, esi
je 0x40ac58
push 0x8007000e
call fcn.0042d648
mov eax, dword [edi + 0x32c]
mov byte [ebp - 4], 8
test eax, eax
jne 0x40ac70
push 0x80004003
call fcn.0042d648
mov ecx, dword [ebp - 0x94]
sub esp, 0x10
mov eax, esp
sub esp, 0x10
mov edi, dword [edi + 0x32c]
mov dword [eax], ecx
mov ecx, dword [ebp - 0x90]
mov edx, dword [edi]
mov dword [eax + 4], ecx
mov ecx, dword [ebp - 0x8c]
mov dword [eax + 8], ecx
mov ecx, dword [ebp - 0x88]
mov dword [eax + 0xc], ecx
mov ecx, dword [ebp - 0xa4]
mov eax, esp
push edi
mov dword [eax], ecx
mov ecx, dword [ebp - 0xa0]
mov dword [eax + 4], ecx
mov ecx, dword [ebp - 0x9c]
mov dword [eax + 8], ecx
mov ecx, dword [ebp - 0x98]
mov dword [eax + 0xc], ecx
call dword [edx + 0x100]
test eax, eax
jge 0x40acdf
push 0x45f358
push edi
push eax
call fcn.0042d656
lea edx, [ebp - 0x94]
mov byte [ebp - 4], 7
push edx
call ebx
test eax, eax
jge 0x40acf6
push eax
call fcn.0042d648
lea eax, [ebp - 0xa4]
mov byte [ebp - 4], 1
push eax
call ebx
test eax, eax
jge 0x40ad0d
push eax
call fcn.0042d648
mov ebx, dword [esi + 0xb]
add esi, 0xb
add esi, 4
mov word [ebp - 0xb4], 3
mov dword [ebp - 0x24], esi
mov dword [ebp - 0xac], ebx
push str.ImgLen
mov byte [ebp - 4], 9
mov word [ebp - 0x84], 8
call fcn.0042d6f5
test eax, eax
mov dword [ebp - 0x7c], eax
jne 0x40ad59
mov ecx, str.ImgLen
test ecx, ecx
je 0x40ad59
push 0x8007000e
call fcn.0042d648
mov edx, dword [ebp - 0x18]
mov byte [ebp - 4], 0xa
mov eax, dword [edx + 0x32c]
test eax, eax
jne 0x40ad74
push 0x80004003
call fcn.0042d648
mov eax, dword [ebp - 0x18]
sub esp, 0x10
mov edx, esp
sub esp, 0x10
mov edi, dword [eax + 0x32c]
mov eax, dword [ebp - 0xb4]
mov dword [edx], eax
mov eax, dword [ebp - 0xb0]
mov ecx, dword [edi]
mov dword [edx + 4], eax
mov eax, dword [ebp - 0xac]
mov dword [edx + 8], eax
mov eax, dword [ebp - 0xa8]
mov dword [edx + 0xc], eax
mov eax, dword [ebp - 0x84]
mov edx, esp
push edi
mov dword [edx], eax
mov eax, dword [ebp - 0x80]
mov dword [edx + 4], eax
mov eax, dword [ebp - 0x7c]
mov dword [edx + 8], eax
mov eax, dword [ebp - 0x78]
mov dword [edx + 0xc], eax
call dword [ecx + 0x100]
test eax, eax
jge 0x40addd
push 0x45f358
push edi
push eax
call fcn.0042d656
mov edi, dword [sym.imp.OLEAUT32.dll_VariantCopy]
lea ecx, [ebp - 0x84]
push ecx
mov byte [ebp - 4], 9
call edi
test eax, eax
jge 0x40adfa
push eax
call fcn.0042d648
lea edx, [ebp - 0xb4]
mov byte [ebp - 4], 1
push edx
call edi
test eax, eax
jge 0x40ae11
push eax
call fcn.0042d648
lea eax, [ebp - 0xcc]
mov dword [ebp - 0xc8], 0
push eax
push 1
push 0x11
mov dword [ebp - 0xcc], ebx
call dword [sym.imp.OLEAUT32.dll_SafeArrayDestroy]
mov edi, eax
mov dword [ebp - 0x20], 0
mov dword [ebp - 0x28], edi
cmp dword [ebp - 0x20], ebx
jge 0x40ae5a
mov eax, esi
lea ecx, [ebp - 0x20]
push eax
inc esi
push ecx
push edi
mov dword [ebp - 0x24], esi
call dword [sym.imp.OLEAUT32.dll_SafeArrayCopy]
inc dword [ebp - 0x20]
jmp 0x40ae3e
lea edx, [ebp - 0xc4]
mov word [ebp - 0xdc], 0x2011
push edx
mov dword [ebp - 0xd4], edi
call dword [sym.imp.OLEAUT32.dll_VariantClear]
lea eax, [ebp - 0xdc]
lea ecx, [ebp - 0xc4]
push eax
push ecx
call dword [sym.imp.OLEAUT32.dll_VariantCopyInd]
test eax, eax
jge 0x40ae94
push eax
call fcn.0042d648
push str.RoomImg
mov byte [ebp - 4], 0xb
mov word [ebp - 0x64], 8
call fcn.0042d6f5
test eax, eax
mov dword [ebp - 0x5c], eax
jne 0x40aec2
mov edx, str.RoomImg
test edx, edx
je 0x40aec2
push 0x8007000e
call fcn.0042d648
mov eax, dword [ebp - 0x18]
mov byte [ebp - 4], 0xc
lea edi, [eax + 0x32c]
mov eax, dword [eax + 0x32c]
test eax, eax
jne 0x40aee3
push 0x80004003
call fcn.0042d648
mov ecx, dword [edi]
lea edx, [ebp - 0x54]
push edx
call fcn.0040b5f0
mov esi, eax
mov eax, dword [esi]
mov byte [ebp - 4], 0xd
test eax, eax
jne 0x40af04
push 0x80004003
call fcn.0042d648
mov ecx, dword [esi]
lea eax, [ebp - 0x64]
lea edx, [ebp - 0x4c]
push eax
push edx
call fcn.0040b850
mov esi, eax
mov eax, dword [esi]
mov byte [ebp - 4], 0xe
test eax, eax
jne 0x40af29
push 0x80004003
call fcn.0042d648
mov edx, dword [ebp - 0xc4]
sub esp, 0x10
mov esi, dword [esi]
mov ecx, esp
push esi
mov eax, dword [esi]
mov dword [ecx], edx
mov edx, dword [ebp - 0xc0]
mov dword [ecx + 4], edx
mov edx, dword [ebp - 0xbc]
mov dword [ecx + 8], edx
mov edx, dword [ebp - 0xb8]
mov dword [ecx + 0xc], edx
call dword [eax + 0x44]
test eax, eax
jge 0x40af69
push 0x45f8c0
push esi
push eax
call fcn.0042d656
lea ecx, [ebp - 0x4c]
call fcn.004027e0
lea ecx, [ebp - 0x54]
call fcn.004027e0
mov esi, dword [sym.imp.OLEAUT32.dll_VariantCopy]
lea eax, [ebp - 0x64]
push eax
mov byte [ebp - 4], 0xb
call esi
test eax, eax
jge 0x40af93
push eax
call fcn.0042d648
lea ecx, [ebp - 0xc4]
mov byte [ebp - 4], 1
push ecx
call esi
test eax, eax
jge 0x40afaa
push eax
call fcn.0042d648
mov edx, dword [ebp - 0x28]
push edx
call dword [sym.imp.OLEAUT32.dll_SafeArrayGetDim]
inc dword [ebp - 0x1c]
jmp 0x40aa8e
test eax, eax
jne 0x40afca
push 0x80004003
call fcn.0042d648
mov eax, dword [0x468e00]
mov edx, dword [0x468e04]
mov ebx, dword [0x468e08]
sub esp, 0x10
mov ecx, eax
mov dword [ebp - 0x74], eax
mov eax, esp
mov dword [ebp - 0x60], edx
mov dword [ebp - 0x5c], ebx
mov ebx, dword [0x468e0c]
mov dword [eax], ecx
mov ecx, dword [ebp - 0x60]
sub esp, 0x10
mov esi, dword [edi]
mov dword [eax + 4], ecx
mov ecx, dword [ebp - 0x5c]
mov dword [ebp - 0x70], edx
mov edx, dword [esi]
mov dword [eax + 8], ecx
mov ecx, esp
push esi
mov dword [eax + 0xc], ebx
mov eax, dword [ebp - 0x74]
mov dword [ecx], eax
mov eax, dword [ebp - 0x70]
mov dword [ecx + 4], eax
mov eax, dword [0x468e08]
mov dword [ecx + 8], eax
mov eax, ebx
mov dword [ecx + 0xc], eax
call dword [edx + 0xac]
test eax, eax
jge 0x40b03d
push 0x45f358
push esi
push eax
call fcn.0042d656
mov ecx, 0x4661b0
call fcn.0040b0d0
mov ecx, eax
call fcn.0040b590
mov ecx, edi
call fcn.0040b0d0
mov ecx, eax
call fcn.0040b670
mov ecx, dword [ebp - 0x18]
push 0x45febc
add ecx, 0x60
jmp 0x40a8db