Function at 0x402df0
Capabilities:
Reference sql statements

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x124
mov eax, dword [0x422008]
xor eax, ebp
mov dword [ebp - 4], eax
mov edx, dword [ebp + 8]
push esi
mov dword [ebp - 0x120], 0x181801c2
mov byte [ebp - 0x11c], 4
movzx eax, word [edx + 4]
mov ecx, dword [edx + 0x14]
movq xmm0, qword [edx + 6]
mov word [ebp - 0x11a], ax
movzx eax, word [edx + 0xe]
mov word [ebp - 0x110], ax
mov al, byte [edx + 0x10]
mov byte [ebp - 0x10e], al
mov eax, dword [edx + 0x18]
mov dword [ebp - 0x108], eax
movzx eax, word [edx + 0x1c]
push ecx
mov word [ebp - 0x104], ax
mov al, byte [edx + 0x1e]
push str.SELECT__FROM_CashShopInventory_WHERE_BaseItemCode_d
push 0x422408
movq qword [ebp - 0x118], xmm0
mov byte [ebp - 0x10d], 0
mov dword [ebp - 0x10c], ecx
mov byte [ebp - 0x102], al
call fcn.00414eb0
add esp, 0xc
test al, al
je 0x403084
push dword [0x422414]
call dword [sym.imp.ODBC32.dll_SQLFetch]
cmp ax, 0x64
je 0x403084
push str.BaseItemCode
call fcn.00415100
mov esi, dword [sym.imp.api_ms_win_crt_convert_l1_1_0.dll_atoi]
cmp eax, 0xffffffff
jne 0x402ebc
or eax, 0xffffffff
jmp 0x402eca
shl eax, 0xd
add eax, 0x423036
push eax
call esi
add esp, 4
push str.MainItemCode
mov dword [ebp - 0x100], eax
call fcn.00415100
cmp eax, 0xffffffff
jne 0x402ee3
or eax, eax
jmp 0x402ef1
shl eax, 0xd
add eax, 0x423036
push eax
call esi
add esp, 4
push str.PackageMainIndex
mov dword [ebp - 0xfc], eax
call fcn.00415100
cmp eax, 0xffffffff
jne 0x402f0a
or eax, eax
jmp 0x402f18
shl eax, 0xd
add eax, 0x423036
push eax
call esi
add esp, 4
push str.ProductBaseIndex
mov dword [ebp - 0xf8], eax
call fcn.00415100
cmp eax, 0xffffffff
jne 0x402f31
or eax, eax
jmp 0x402f3f
shl eax, 0xd
add eax, 0x423036
push eax
call esi
add esp, 4
push str.ProductMainIndex
mov dword [ebp - 0xf4], eax
call fcn.00415100
cmp eax, 0xffffffff
jne 0x402f58
or eax, eax
jmp 0x402f66
shl eax, 0xd
add eax, 0x423036
push eax
call esi
add esp, 4
push str.CoinValue
mov dword [ebp - 0xf0], eax
call fcn.00415100
cmp eax, 0xffffffff
jne 0x402f85
movss xmm0, dword [0x41f360]
jmp 0x402fa5
shl eax, 0xd
add eax, 0x423036
push eax
call dword [sym.imp.api_ms_win_crt_convert_l1_1_0.dll_atof]
fstp dword [ebp - 0x124]
movss xmm0, dword [ebp - 0x124]
add esp, 4
cvtps2pd xmm0, xmm0
push str.ProductType
movsd qword [ebp - 0xe8], xmm0
call fcn.00415100
cmp eax, 0xffffffff
jne 0x402fc3
or eax, eax
jmp 0x402fd1
shl eax, 0xd
add eax, 0x423036
push eax
call esi
add esp, 4
push str.GiftName
mov byte [ebp - 0xe0], al
call fcn.00415100
mov esi, dword [sym.imp.api_ms_win_crt_string_l1_1_0.dll_strncpy_s]
cmp eax, 0xffffffff
jne 0x403009
xorps xmm0, xmm0
mov word [ebp - 0xd7], 0
movq qword [ebp - 0xdf], xmm0
mov byte [ebp - 0xd5], 0
jmp 0x403022
shl eax, 0xd
push 0xa
add eax, 0x423036
push eax
lea eax, [ebp - 0xdf]
push 0xb
push eax
call esi
add esp, 0x10
push str.GiftText
call fcn.00415100
cmp eax, 0xffffffff
jne 0x403049
push 0xc8
lea eax, [ebp - 0xd4]
push 0
push eax
call sub.VCRUNTIME140.dll_memset
add esp, 0xc
jmp 0x403068
shl eax, 0xd
push 0xc7
add eax, 0x423036
push eax
lea eax, [ebp - 0xd4]
push 0xc8
push eax
call esi
add esp, 0x10
push dword [0x422414]
call dword [sym.imp.ODBC32.dll_SQLCloseCursor]
push 2
push dword [0x422414]
call dword [sym.imp.ODBC32.dll_SQLFreeStmt]
jmp 0x4030a5
push dword [0x422414]
call dword [sym.imp.ODBC32.dll_SQLCloseCursor]
push 2
push dword [0x422414]
call dword [sym.imp.ODBC32.dll_SQLFreeStmt]
mov byte [ebp - 0x10d], 1
push 0x118
lea eax, [ebp - 0x120]
push eax
push dword [ebp + 0xc]
call fcn.004163f0
mov ecx, dword [ebp - 4]
xor ecx, ebp
pop esi
call fcn.00417e1d
mov esp, ebp
pop ebp
ret 8