Function at 0x409280
Capabilities:
Reference sql statements

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x97c
mov eax, dword [0x421018]
xor eax, ebp
mov dword [ebp - 4], eax
mov eax, dword [ebp + 8]
movzx ecx, word [eax + 4]
mov edx, dword [eax + 6]
push ebx
push esi
lea esi, [eax + 6]
mov eax, dword [esi + 4]
mov word [ebp - 0x96c], cx
movzx ecx, word [esi + 8]
push edi
mov dword [ebp - 0x96a], edx
mov dl, byte [esi + 0xa]
mov word [ebp - 0x962], cx
push esi
push str.SELECT_Id_FROM_AccountCharacter_WHERE_Id_s
mov ecx, 0x4ed8c0
mov byte [ebp - 0x970], 0xc2
mov byte [ebp - 0x96d], 1
mov dword [ebp - 0x958], 0x16
mov dword [ebp - 0x97c], esi
mov dword [ebp - 0x966], eax
mov byte [ebp - 0x960], dl
call fcn.00414e40
add esp, 8
test al, al
je 0x409332
mov eax, dword [0x4ed8cc]
push eax
call dword [sym.imp.ODBC32.dll_SQLFetch]
cmp ax, 0x64
je 0x409332
mov ecx, dword [0x4ed8cc]
push ecx
call dword [sym.imp.ODBC32.dll_SQLCloseCursor]
mov edx, dword [0x4ed8cc]
push 2
push edx
call dword [sym.imp.ODBC32.dll_SQLFreeStmt]
jmp 0x409377
mov eax, dword [0x4ed8cc]
mov ebx, dword [sym.imp.ODBC32.dll_SQLCloseCursor]
push eax
call ebx
mov ecx, dword [0x4ed8cc]
mov edi, dword [sym.imp.ODBC32.dll_SQLFreeStmt]
push 2
push ecx
call edi
push esi
push str.INSERT_INTO_AccountCharacter__Id__VALUES___s_
mov ecx, 0x4ed8c0
call fcn.00414e40
mov edx, dword [0x4ed8cc]
add esp, 8
push edx
call ebx
mov eax, dword [0x4ed8cc]
push 2
push eax
call edi
push 0x37
lea ecx, [ebp - 0x3c]
push 0
push ecx
call sub.MSVCR100.dll_memset
push esi
push str.SELECT__FROM_AccountCharacter_WHERE_Id_s
mov ecx, 0x4ed8c0
call fcn.00414e40
mov edx, dword [0x4ed8cc]
add esp, 0x14
push edx
call dword [sym.imp.ODBC32.dll_SQLFetch]
push str.MoveCnt
mov ebx, 0x4ed8c0
call fcn.00415000
push str.ExtClass
mov byte [ebp - 0x95f], al
call fcn.00415000
push str.ExtWarehouse
mov byte [ebp - 0x95e], al
call fcn.00415000
mov byte [ebp - 0x95d], al
push 0xb
lea eax, [ebp - 0x3c]
push eax
push str.GameID1
call fcn.00415170
push 0xb
lea ecx, [ebp - 0x31]
push ecx
push str.GameID2
call fcn.00415170
push 0xb
lea edx, [ebp - 0x26]
push edx
push str.GameID3
call fcn.00415170
push 0xb
lea eax, [ebp - 0x1b]
push eax
push str.GameID4
call fcn.00415170
push 0xb
lea ecx, [ebp - 0x10]
push ecx
push str.GameID5
call fcn.00415170
mov edx, dword [0x4ed8cc]
push edx
call dword [sym.imp.ODBC32.dll_SQLCloseCursor]
mov eax, dword [0x4ed8cc]
push 2
push eax
call dword [sym.imp.ODBC32.dll_SQLFreeStmt]
xor ebx, ebx
lea ecx, [ebp - 0x8e6]
lea edi, [ebp - 0x3c]
mov byte [ebp - 0x95c], 0
mov dword [ebp - 0x978], ebx
mov dword [ebp - 0x954], ecx
mov dword [ebp - 0x974], edi
jmp 0x409470
cmp byte [edi], 0
je 0x409766
push edi
push esi
push str.SELECT_cLevel_Class_Inventory_CtlCode_FROM_Character_WHERE_AccountID_s_AND_Name_s
mov ecx, 0x4ed8c0
call fcn.00414e40
add esp, 0xc
test al, al
je 0x40974b
mov edx, dword [0x4ed8cc]
push edx
call dword [sym.imp.ODBC32.dll_SQLFetch]
cmp ax, 0x64
je 0x40974b
mov eax, dword [edi]
mov ecx, dword [edi + 4]
mov dx, word [edi + 8]
mov dword [ebp - 0x94b], eax
mov al, byte [edi + 0xa]
mov byte [ebp - 0x94c], bl
push str.cLevel
mov ebx, 0x4ed8c0
mov dword [ebp - 0x947], ecx
mov word [ebp - 0x943], dx
mov byte [ebp - 0x941], al
call fcn.00415000
push str.Class
mov word [ebp - 0x940], ax
call fcn.00415000
push 0xc0
lea ecx, [ebp - 0xfc]
push ecx
push str.Inventory
mov byte [ebp - 0x93e], al
call fcn.00415200
push str.CtlCode
call fcn.00415000
mov edx, dword [0x4ed8cc]
push edx
mov byte [ebp - 0x93d], al
call dword [sym.imp.ODBC32.dll_SQLCloseCursor]
mov eax, dword [0x4ed8cc]
push 2
push eax
call dword [sym.imp.ODBC32.dll_SQLFreeStmt]
push 0x3c
mov ebx, 0xff
lea ecx, [ebp - 0x93c]
push ebx
push ecx
call sub.MSVCR100.dll_memset
add esp, 0xc
lea eax, [ebp - 0x93b]
lea ecx, [ebp - 0xfc]
mov esi, 3
mov dl, byte [ecx]
cmp dl, bl
jne 0x40958b
test byte [ecx + 7], 0x80
je 0x40958b
mov dl, byte [ecx + 9]
and dl, 0xf0
cmp dl, 0xf0
jne 0x409589
mov dword [eax - 1], 0xffffffff
mov byte [eax + 3], bl
jmp 0x4095a9
mov dl, byte [ecx]
mov byte [eax - 1], dl
movzx edx, byte [ecx + 1]
mov byte [eax], dl
movzx edx, byte [ecx + 7]
mov byte [eax + 1], dl
movzx edx, byte [ecx + 8]
mov byte [eax + 2], dl
movzx edx, byte [ecx + 9]
mov byte [eax + 3], dl
mov dl, byte [ecx + 0x10]
cmp dl, bl
jne 0x4095d2
test byte [ecx + 0x17], 0x80
je 0x4095d2
mov bl, byte [ecx + 0x19]
and bl, 0xf0
cmp bl, 0xf0
mov ebx, 0xff
jne 0x4095d2
mov dword [eax + 4], 0xffffffff
mov byte [eax + 8], bl
jmp 0x4095f1
mov byte [eax + 4], dl
movzx edx, byte [ecx + 0x11]
mov byte [eax + 5], dl
movzx edx, byte [ecx + 0x17]
mov byte [eax + 6], dl
movzx edx, byte [ecx + 0x18]
mov byte [eax + 7], dl
movzx edx, byte [ecx + 0x19]
mov byte [eax + 8], dl
mov dl, byte [ecx + 0x20]
cmp dl, bl
jne 0x40961a
test byte [ecx + 0x27], 0x80
je 0x40961a
mov bl, byte [ecx + 0x29]
and bl, 0xf0
cmp bl, 0xf0
mov ebx, 0xff
jne 0x40961a
mov dword [eax + 9], 0xffffffff
mov byte [eax + 0xd], bl
jmp 0x409639
mov byte [eax + 9], dl
movzx edx, byte [ecx + 0x21]
mov byte [eax + 0xa], dl
movzx edx, byte [ecx + 0x27]
mov byte [eax + 0xb], dl
movzx edx, byte [ecx + 0x28]
mov byte [eax + 0xc], dl
movzx edx, byte [ecx + 0x29]
mov byte [eax + 0xd], dl
mov dl, byte [ecx + 0x30]
cmp dl, bl
jne 0x409662
test byte [ecx + 0x37], 0x80
je 0x409662
mov bl, byte [ecx + 0x39]
and bl, 0xf0
cmp bl, 0xf0
mov ebx, 0xff
jne 0x409662
mov dword [eax + 0xe], 0xffffffff
mov byte [eax + 0x12], bl
jmp 0x409681
mov byte [eax + 0xe], dl
movzx edx, byte [ecx + 0x31]
mov byte [eax + 0xf], dl
movzx edx, byte [ecx + 0x37]
mov byte [eax + 0x10], dl
movzx edx, byte [ecx + 0x38]
mov byte [eax + 0x11], dl
movzx edx, byte [ecx + 0x39]
mov byte [eax + 0x12], dl
add ecx, 0x40
add eax, 0x14
dec esi
jne 0x409566
push edi
push str.SELECT_G_Status_FROM_GuildMember_WHERE_Name_s
mov ecx, 0x4ed8c0
call fcn.00414e40
add esp, 8
test al, al
je 0x4096ea
mov eax, dword [0x4ed8cc]
push eax
call dword [sym.imp.ODBC32.dll_SQLFetch]
cmp ax, 0x64
je 0x4096ea
push str.G_Status
mov ebx, 0x4ed8c0
call fcn.00415000
mov ecx, dword [0x4ed8cc]
push ecx
mov byte [ebp - 0x900], al
call dword [sym.imp.ODBC32.dll_SQLCloseCursor]
mov edx, dword [0x4ed8cc]
push 2
push edx
call dword [sym.imp.ODBC32.dll_SQLFreeStmt]
jmp 0x40970b
mov eax, dword [0x4ed8cc]
push eax
call dword [sym.imp.ODBC32.dll_SQLCloseCursor]
mov ecx, dword [0x4ed8cc]
push 2
push ecx
call dword [sym.imp.ODBC32.dll_SQLFreeStmt]
mov byte [ebp - 0x900], bl
mov edi, dword [ebp - 0x954]
mov ebx, dword [ebp - 0x978]
mov ecx, 0x13
lea esi, [ebp - 0x94c]
rep movsd dword es:[edi], dword [esi]
mov eax, 0x4e
add dword [ebp - 0x958], eax
add dword [ebp - 0x954], eax
inc byte [ebp - 0x95c]
movsw word es:[edi], word [esi]
mov edi, dword [ebp - 0x974]
mov esi, dword [ebp - 0x97c]
jmp 0x409766
mov edx, dword [0x4ed8cc]
push edx
call dword [sym.imp.ODBC32.dll_SQLCloseCursor]
mov eax, dword [0x4ed8cc]
push 2
push eax
call dword [sym.imp.ODBC32.dll_SQLFreeStmt]
inc ebx
add edi, 0xb
mov dword [ebp - 0x978], ebx
mov dword [ebp - 0x974], edi
cmp ebx, 5
jl 0x409470
mov ebx, dword [ebp - 0x958]
mov eax, dword [ebp - 0x96c]
mov ecx, ebx
shr ecx, 8
mov byte [ebp - 0x96f], cl
mov ecx, dword [ebp - 0x968]
mov byte [ebp - 0x96e], bl
mov edx, dword [ebp - 0x970]
mov dword [ebp - 0x8fc], edx
mov edx, dword [ebp - 0x964]
mov dword [ebp - 0x8f8], eax
mov eax, dword [ebp - 0x960]
mov dword [ebp - 0x8f0], edx
lea edx, [ebp - 0x8fc]
mov dword [ebp - 0x8ec], eax
mov eax, dword [ebp + 0xc]
mov dword [ebp - 0x8f4], ecx
mov cx, word [ebp - 0x95c]
push edx
push eax
mov word [ebp - 0x8e8], cx
call fcn.00416c00
mov ecx, dword [ebp - 4]
pop edi
pop esi
xor ecx, ebp
pop ebx
call fcn.00417d4a
mov esp, ebp
pop ebp
ret