Function at 0x40d910
Capabilities:
Reference sql statements

Disassembly:
push ebx
mov ebx, esp
sub esp, 8
and esp, 0xfffffff8
add esp, 4
push ebp
mov ebp, dword [ebx + 4]
mov dword [esp + 4], ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x42f380
mov eax, dword fs:[0]
push eax
push ebx
sub esp, 0xc8
mov eax, dword [0x43e040]
xor eax, ebp
mov dword [ebp - 0x14], eax
push esi
push edi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov dword [ebp - 0x9c], edx
mov edx, ecx
mov dword [ebp - 0x94], edx
movzx eax, word [edx + 4]
lea edi, [edx + 0x11]
movq xmm0, qword [edx + 6]
mov word [ebp - 0xd4], ax
movzx eax, word [edx + 0xe]
mov word [ebp - 0xca], ax
mov al, byte [edx + 0x10]
mov byte [ebp - 0xc8], al
movzx eax, word [edi + 8]
mov word [ebp - 0xbf], ax
mov al, byte [edi + 0xa]
movq qword [ebp - 0xd2], xmm0
movq xmm0, qword [edi]
mov byte [ebp - 0xbd], al
xor eax, eax
mov word [ebp - 0xd8], 0x3ac1
mov byte [ebp - 0xd6], 2
movq qword [ebp - 0xc7], xmm0
mov cl, byte [edi + eax]
cmp cl, 0x20
je 0x40da54
cmp cl, 0x22
je 0x40da54
cmp cl, 0x27
je 0x40da54
inc eax
cmp eax, 0xb
jl 0x40d9c0
mov esi, dword [0x43eac0]
cmp esi, dword [0x43eac4]
je 0x40da09
nop
push esi
push edi
call fcn.00418c30
add esp, 8
test eax, eax
jne 0x40da54
add esi, 0x20
cmp esi, dword [0x43eac4]
jne 0x40d9f0
sub esp, 0x18
mov ecx, esp
mov dword [ebp - 0x98], esp
push str._a_zA_Z0_9___
call fcn.00401f90
sub esp, 0x18
mov dword [ebp - 4], 0
mov ecx, esp
push edi
call fcn.00401f90
push 0
mov dword [ebp - 4], 0xffffffff
call fcn.00405100
test al, al
jne 0x40da4b
cmp dword [0x5d26fc], 0
je 0x40da54
mov byte [ebp - 0x89], 1
jmp 0x40da5b
mov byte [ebp - 0x89], 0
mov esi, dword [ebp - 0x94]
movaps xmm0, xmmword [0x43a5b0]
push 0x6e
push 0
mov al, byte [esi + 0x1c]
mov byte [ebp - 0xba], al
mov eax, 1
mov word [ebp - 0xa0], ax
lea eax, [ebp - 0x88]
push eax
mov byte [ebp - 0xbb], 0
movups xmmword [ebp - 0xb9], xmm0
movq qword [ebp - 0xa9], xmm0
call fcn.004190e0
add esp, 0xc
cmp byte [ebp - 0x89], 0
je 0x40df19
lea eax, [esi + 6]
push eax
push str.SELECT__FROM_AccountCharacter_WHERE_Id_s
push 0x43edd8
call fcn.00414960
add esp, 0xc
test al, al
je 0x40df19
push dword [0x43ede4]
call dword [sym.imp.ODBC32.dll_SQLFetch]
cmp ax, 0x64
je 0x40df19
push str.GameID1
call fcn.00414bb0
cmp eax, 0xffffffff
je 0x40db12
shl eax, 0xd
push 0xa
add eax, 0x4405be
push eax
lea eax, [ebp - 0x88]
push 0xb
push eax
call fcn.004211ed
add esp, 0x10
push str.GameID2
call fcn.00414bb0
cmp eax, 0xffffffff
jne 0x40db35
xorps xmm0, xmm0
mov word [ebp - 0x75], 0
movq qword [ebp - 0x7d], xmm0
mov byte [ebp - 0x73], 0
jmp 0x40db4e
shl eax, 0xd
push 0xa
add eax, 0x4405be
push eax
lea eax, [ebp - 0x7d]
push 0xb
push eax
call fcn.004211ed
add esp, 0x10
push str.GameID3
call fcn.00414bb0
cmp eax, 0xffffffff
jne 0x40db71
xorps xmm0, xmm0
mov word [ebp - 0x6a], 0
movq qword [ebp - 0x72], xmm0
mov byte [ebp - 0x68], 0
jmp 0x40db8a
shl eax, 0xd
push 0xa
add eax, 0x4405be
push eax
lea eax, [ebp - 0x72]
push 0xb
push eax
call fcn.004211ed
add esp, 0x10
push str.GameID4
call fcn.00414bb0
cmp eax, 0xffffffff
jne 0x40dbad
xorps xmm0, xmm0
mov word [ebp - 0x5f], 0
movq qword [ebp - 0x67], xmm0
mov byte [ebp - 0x5d], 0
jmp 0x40dbc6
shl eax, 0xd
push 0xa
add eax, 0x4405be
push eax
lea eax, [ebp - 0x67]
push 0xb
push eax
call fcn.004211ed
add esp, 0x10
push str.GameID5
call fcn.00414bb0
cmp eax, 0xffffffff
jne 0x40dbe9
xorps xmm0, xmm0
mov word [ebp - 0x54], 0
movq qword [ebp - 0x5c], xmm0
mov byte [ebp - 0x52], 0
jmp 0x40dc02
shl eax, 0xd
push 0xa
add eax, 0x4405be
push eax
lea eax, [ebp - 0x5c]
push 0xb
push eax
call fcn.004211ed
add esp, 0x10
push str.GameID6
call fcn.00414bb0
cmp eax, 0xffffffff
jne 0x40dc25
xorps xmm0, xmm0
mov word [ebp - 0x49], 0
movq qword [ebp - 0x51], xmm0
mov byte [ebp - 0x47], 0
jmp 0x40dc3e
shl eax, 0xd
push 0xa
add eax, 0x4405be
push eax
lea eax, [ebp - 0x51]
push 0xb
push eax
call fcn.004211ed
add esp, 0x10
push str.GameID7
call fcn.00414bb0
cmp eax, 0xffffffff
jne 0x40dc61
xorps xmm0, xmm0
mov word [ebp - 0x3e], 0
movq qword [ebp - 0x46], xmm0
mov byte [ebp - 0x3c], 0
jmp 0x40dc7a
shl eax, 0xd
push 0xa
add eax, 0x4405be
push eax
lea eax, [ebp - 0x46]
push 0xb
push eax
call fcn.004211ed
add esp, 0x10
push str.GameID8
call fcn.00414bb0
cmp eax, 0xffffffff
jne 0x40dc9d
xorps xmm0, xmm0
mov word [ebp - 0x33], 0
movq qword [ebp - 0x3b], xmm0
mov byte [ebp - 0x31], 0
jmp 0x40dcb6
shl eax, 0xd
push 0xa
add eax, 0x4405be
push eax
lea eax, [ebp - 0x3b]
push 0xb
push eax
call fcn.004211ed
add esp, 0x10
push str.GameID9
call fcn.00414bb0
cmp eax, 0xffffffff
jne 0x40dcd9
xorps xmm0, xmm0
mov word [ebp - 0x28], 0
movq qword [ebp - 0x30], xmm0
mov byte [ebp - 0x26], 0
jmp 0x40dcf2
shl eax, 0xd
push 0xa
add eax, 0x4405be
push eax
lea eax, [ebp - 0x30]
push 0xb
push eax
call fcn.004211ed
add esp, 0x10
push str.GameID10
call fcn.00414bb0
cmp eax, 0xffffffff
jne 0x40dd15
xorps xmm0, xmm0
mov word [ebp - 0x1d], 0
movq qword [ebp - 0x25], xmm0
mov byte [ebp - 0x1b], 0
jmp 0x40dd2e
shl eax, 0xd
push 0xa
add eax, 0x4405be
push eax
lea eax, [ebp - 0x25]
push 0xb
push eax
call fcn.004211ed
add esp, 0x10
push dword [0x43ede4]
call dword [sym.imp.ODBC32.dll_SQLCloseCursor]
push 2
push dword [0x43ede4]
call dword [sym.imp.ODBC32.dll_SQLFreeStmt]
xor eax, eax
lea esi, [ebp - 0x88]
mov dword [ebp - 0x90], eax
nop word [eax + eax]
push 0x436e74
push esi
call fcn.0041b220
add esp, 8
test eax, eax
mov eax, dword [ebp - 0x90]
je 0x40dd93
inc eax
add esi, 0xb
mov dword [ebp - 0x90], eax
cmp eax, 0xa
jl 0x40dd60
mov byte [ebp - 0xbc], 2
jmp 0x40df3a
mov byte [ebp - 0xbb], al
movzx eax, al
mov dword [ebp - 0x98], eax
cmp eax, dword [0x5d2700]
jge 0x40de3a
mov eax, dword [ebp - 0x94]
add eax, 6
push eax
push str.SELECT_MaxCharacter_FROM_AccountCharacter_WHERE_Id_s
push 0x43edd8
call fcn.00414960
add esp, 0xc
test al, al
je 0x40de46
push dword [0x43ede4]
call dword [sym.imp.ODBC32.dll_SQLFetch]
cmp ax, 0x64
je 0x40de46
push str.MaxCharacter
call fcn.00414bb0
cmp eax, 0xffffffff
jne 0x40ddf7
mov dword [ebp - 0x90], eax
jmp 0x40de0e
shl eax, 0xd
add eax, 0x4405be
push eax
call fcn.0041de3e
add esp, 4
mov dword [ebp - 0x90], eax
push dword [0x43ede4]
mov esi, dword [sym.imp.ODBC32.dll_SQLCloseCursor]
call esi
mov ecx, dword [sym.imp.ODBC32.dll_SQLFreeStmt]
push 2
push dword [0x43ede4]
call ecx
mov eax, dword [ebp - 0x98]
cmp eax, dword [ebp - 0x90]
jl 0x40de64
mov byte [ebp - 0xbc], 2
jmp 0x40df3a
push dword [0x43ede4]
mov esi, dword [sym.imp.ODBC32.dll_SQLCloseCursor]
call esi
mov ecx, dword [sym.imp.ODBC32.dll_SQLFreeStmt]
push 2
push dword [0x43ede4]
call ecx
mov ecx, dword [ebp - 0x94]
movzx eax, byte [ecx + 0x1c]
push eax
push edi
lea eax, [ecx + 6]
push eax
push str.EXEC_WZ_CreateCharacter__s__s__d
push 0x43edd8
call fcn.00414960
add esp, 0x14
test al, al
je 0x40df0f
push dword [0x43ede4]
call dword [sym.imp.ODBC32.dll_SQLFetch]
cmp ax, 0x64
je 0x40df0f
push 0x4405be
call fcn.0041de3e
add esp, 4
mov byte [ebp - 0xbc], al
push dword [0x43ede4]
call esi
push 2
push dword [0x43ede4]
call dword [sym.imp.ODBC32.dll_SQLFreeStmt]
cmp byte [ebp - 0xbc], 1
jne 0x40df3a
mov eax, dword [ebp - 0x94]
add eax, 6
push eax
mov eax, dword [ebp - 0x98]
push edi
inc eax
push eax
push str.UPDATE_AccountCharacter_SET_GameID_d_s_WHERE_Id_s
push 0x43edd8
call fcn.00414960
add esp, 0x14
push dword [0x43ede4]
call esi
push 2
push dword [0x43ede4]
call dword [sym.imp.ODBC32.dll_SQLFreeStmt]
jmp 0x40df3a
push dword [0x43ede4]
call esi
jmp 0x40df25
push dword [0x43ede4]
call dword [sym.imp.ODBC32.dll_SQLCloseCursor]
push 2
push dword [0x43ede4]
call dword [sym.imp.ODBC32.dll_SQLFreeStmt]
mov byte [ebp - 0xbc], 0
movzx eax, byte [ebp - 0xd7]
push eax
lea eax, [ebp - 0xd8]
push eax
push dword [ebp - 0x9c]
call fcn.00416260
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
mov ecx, dword [ebp - 0x14]
xor ecx, ebp
call fcn.004178c7
mov esp, ebp
pop ebp
mov esp, ebx
pop ebx
ret