Function at 0x40f970
Capabilities:
Reference sql statements

Disassembly:
push ebp
mov ebp, esp
sub esp, 0xb1c
mov eax, dword [0x446040]
xor eax, ebp
mov dword [ebp - 4], eax
movzx eax, word [ecx + 4]
xorps xmm0, xmm0
push ebx
movups xmmword [ebp - 0xb0f], xmm0
push esi
movq xmm0, qword [ecx + 6]
mov dword [ebp - 0xaf0], ecx
add ecx, 6
push edi
mov word [ebp - 0xb0c], ax
push ecx
movzx eax, word [ecx + 8]
mov word [ebp - 0xb02], ax
mov al, byte [ecx + 0xa]
push str.SELECT_Id_FROM_AccountCharacter_WHERE_Id_s
push 0x446e50
mov dword [ebp - 0xb1c], edx
mov dword [ebp - 0xaff], 0
mov byte [ebp - 0xafb], 0
mov byte [ebp - 0xb10], 0xc2
mov byte [ebp - 0xb0d], 1
mov dword [ebp - 0xae8], 0x16
mov dword [ebp - 0xaec], ecx
movq qword [ebp - 0xb0a], xmm0
mov byte [ebp - 0xb00], al
call fcn.0041ad10
mov ebx, dword [sym.imp.ODBC32.dll_SQLFetch]
add esp, 0xc
mov dword [ebp - 0xae4], ebx
test al, al
je 0x40fa4d
push dword [0x446e5c]
call ebx
cmp ax, 0x64
je 0x40fa4d
push dword [0x446e5c]
mov esi, dword [sym.imp.ODBC32.dll_SQLCloseCursor]
mov dword [ebp - 0xaf4], esi
call esi
mov edi, dword [sym.imp.ODBC32.dll_SQLFreeStmt]
mov dword [ebp - 0xaf8], edi
jmp 0x40fa97
push dword [0x446e5c]
mov esi, dword [sym.imp.ODBC32.dll_SQLCloseCursor]
mov dword [ebp - 0xaf4], esi
call esi
mov edi, dword [sym.imp.ODBC32.dll_SQLFreeStmt]
push 2
push dword [0x446e5c]
mov dword [ebp - 0xaf8], edi
call edi
push dword [ebp - 0xaec]
push str.INSERT_INTO_AccountCharacter__Id__VALUES___s_
push 0x446e50
call fcn.0041ad10
add esp, 0xc
push dword [0x446e5c]
call esi
push 2
push dword [0x446e5c]
call edi
push 0x6e
lea eax, [ebp - 0x78]
push 0
push eax
call fcn.0041f490
add esp, 0xc
push dword [ebp - 0xaec]
push str.SELECT__FROM_AccountCharacter_WHERE_Id_s
push 0x446e50
call fcn.0041ad10
add esp, 0xc
push dword [0x446e5c]
call ebx
push str.MoveCnt
call fcn.0041af60
cmp eax, 0xffffffff
jne 0x40fae4
or eax, eax
jmp 0x40faf5
shl eax, 0xd
add eax, 0x447a7e
push eax
call fcn.0042417e
add esp, 4
push str.ExtClass
mov byte [ebp - 0xaff], al
call fcn.0041af60
cmp eax, 0xffffffff
jne 0x40fb0e
or eax, eax
jmp 0x40fb1f
shl eax, 0xd
add eax, 0x447a7e
push eax
call fcn.0042417e
add esp, 4
push str.ExtWarehouse
mov byte [ebp - 0xafe], al
call fcn.0041af60
cmp eax, 0xffffffff
jne 0x40fb38
or eax, eax
jmp 0x40fb49
shl eax, 0xd
add eax, 0x447a7e
push eax
call fcn.0042417e
add esp, 4
push str.GameID1
mov byte [ebp - 0xafd], al
call fcn.0041af60
cmp eax, 0xffffffff
je 0x40fb77
shl eax, 0xd
push 0xa
add eax, 0x447a7e
push eax
lea eax, [ebp - 0x78]
push 0xb
push eax
call fcn.0042752d
add esp, 0x10
push str.GameID2
call fcn.0041af60
cmp eax, 0xffffffff
jne 0x40fb9a
xorps xmm0, xmm0
mov word [ebp - 0x65], 0
movq qword [ebp - 0x6d], xmm0
mov byte [ebp - 0x63], 0
jmp 0x40fbb3
shl eax, 0xd
push 0xa
add eax, 0x447a7e
push eax
lea eax, [ebp - 0x6d]
push 0xb
push eax
call fcn.0042752d
add esp, 0x10
push str.GameID3
call fcn.0041af60
cmp eax, 0xffffffff
jne 0x40fbd6
xorps xmm0, xmm0
mov word [ebp - 0x5a], 0
movq qword [ebp - 0x62], xmm0
mov byte [ebp - 0x58], 0
jmp 0x40fbef
shl eax, 0xd
push 0xa
add eax, 0x447a7e
push eax
lea eax, [ebp - 0x62]
push 0xb
push eax
call fcn.0042752d
add esp, 0x10
push str.GameID4
call fcn.0041af60
cmp eax, 0xffffffff
jne 0x40fc12
xorps xmm0, xmm0
mov word [ebp - 0x4f], 0
movq qword [ebp - 0x57], xmm0
mov byte [ebp - 0x4d], 0
jmp 0x40fc2b
shl eax, 0xd
push 0xa
add eax, 0x447a7e
push eax
lea eax, [ebp - 0x57]
push 0xb
push eax
call fcn.0042752d
add esp, 0x10
push str.GameID5
call fcn.0041af60
cmp eax, 0xffffffff
jne 0x40fc4e
xorps xmm0, xmm0
mov word [ebp - 0x44], 0
movq qword [ebp - 0x4c], xmm0
mov byte [ebp - 0x42], 0
jmp 0x40fc67
shl eax, 0xd
push 0xa
add eax, 0x447a7e
push eax
lea eax, [ebp - 0x4c]
push 0xb
push eax
call fcn.0042752d
add esp, 0x10
push str.GameID6
call fcn.0041af60
cmp eax, 0xffffffff
jne 0x40fc8a
xorps xmm0, xmm0
mov word [ebp - 0x39], 0
movq qword [ebp - 0x41], xmm0
mov byte [ebp - 0x37], 0
jmp 0x40fca3
shl eax, 0xd
push 0xa
add eax, 0x447a7e
push eax
lea eax, [ebp - 0x41]
push 0xb
push eax
call fcn.0042752d
add esp, 0x10
push str.GameID7
call fcn.0041af60
cmp eax, 0xffffffff
jne 0x40fcc6
xorps xmm0, xmm0
mov word [ebp - 0x2e], 0
movq qword [ebp - 0x36], xmm0
mov byte [ebp - 0x2c], 0
jmp 0x40fcdf
shl eax, 0xd
push 0xa
add eax, 0x447a7e
push eax
lea eax, [ebp - 0x36]
push 0xb
push eax
call fcn.0042752d
add esp, 0x10
push str.GameID8
call fcn.0041af60
cmp eax, 0xffffffff
jne 0x40fd02
xorps xmm0, xmm0
mov word [ebp - 0x23], 0
movq qword [ebp - 0x2b], xmm0
mov byte [ebp - 0x21], 0
jmp 0x40fd1b
shl eax, 0xd
push 0xa
add eax, 0x447a7e
push eax
lea eax, [ebp - 0x2b]
push 0xb
push eax
call fcn.0042752d
add esp, 0x10
push str.GameID9
call fcn.0041af60
cmp eax, 0xffffffff
jne 0x40fd3e
xorps xmm0, xmm0
mov word [ebp - 0x18], 0
movq qword [ebp - 0x20], xmm0
mov byte [ebp - 0x16], 0
jmp 0x40fd57
shl eax, 0xd
push 0xa
add eax, 0x447a7e
push eax
lea eax, [ebp - 0x20]
push 0xb
push eax
call fcn.0042752d
add esp, 0x10
push str.GameID10
call fcn.0041af60
cmp eax, 0xffffffff
jne 0x40fd7a
xorps xmm0, xmm0
mov word [ebp - 0xd], 0
movq qword [ebp - 0x15], xmm0
mov byte [ebp - 0xb], 0
jmp 0x40fd93
shl eax, 0xd
push 0xa
add eax, 0x447a7e
push eax
lea eax, [ebp - 0x15]
push 0xb
push eax
call fcn.0042752d
add esp, 0x10
push dword [0x446e5c]
call esi
push 2
push dword [0x446e5c]
call edi
xor al, al
mov dword [ebp - 0xad8], 0xff
push 0x13c
mov byte [ebp - 0xad9], al
mov byte [ebp - 0xafc], al
lea eax, [ebp - 0xad4]
push 0
push eax
call fcn.0041f490
add esp, 0xc
lea ecx, [ebp - 0x922]
xor eax, eax
mov dword [ebp - 0xb14], ecx
lea ebx, [ebp - 0x78]
mov dword [ebp - 0xae0], eax
mov dword [ebp - 0xb18], ebx
cmp byte [ebx], 0
je 0x410222
push ebx
push dword [ebp - 0xaec]
push str.SELECT_cLevel_Class_Inventory_CtlCode_ResetCount_MasterResetCount_FROM_Character_WHERE_AccountID_s_AND_Name_s
push 0x446e50
call fcn.0041ad10
add esp, 0x10
test al, al
je 0x41020a
push dword [0x446e5c]
call dword [ebp - 0xae4]
cmp ax, 0x64
je 0x41020a
mov eax, dword [ebp - 0xae0]
movq xmm0, qword [ebx]
mov byte [ebp - 0x998], al
mov ax, word [ebx + 8]
mov word [ebp - 0x98f], ax
mov al, byte [ebx + 0xa]
push str.cLevel
movq qword [ebp - 0x997], xmm0
mov byte [ebp - 0x98d], al
call fcn.0041af60
cmp eax, 0xffffffff
jne 0x40fe6f
or eax, eax
jmp 0x40fe80
shl eax, 0xd
add eax, 0x447a7e
push eax
call fcn.0042417e
add esp, 4
push str.Class
mov word [ebp - 0x98c], ax
call fcn.0041af60
cmp eax, 0xffffffff
jne 0x40fe9a
or eax, eax
jmp 0x40feab
shl eax, 0xd
add eax, 0x447a7e
push eax
call fcn.0042417e
add esp, 4
mov byte [ebp - 0x98a], al
lea eax, [ebp - 0x138]
push 0xc0
push eax
push str.Inventory
call fcn.0041afb0
push str.CtlCode
call fcn.0041af60
cmp eax, 0xffffffff
jne 0x40feda
or eax, eax
jmp 0x40feeb
shl eax, 0xd
add eax, 0x447a7e
push eax
call fcn.0042417e
add esp, 4
push str.ResetCount
mov byte [ebp - 0x989], al
call fcn.0041af60
cmp eax, 0xffffffff
jne 0x40ff04
or eax, eax
jmp 0x40ff15
shl eax, 0xd
add eax, 0x447a7e
push eax
call fcn.0042417e
add esp, 4
push str.MasterResetCount
mov dword [ebp - 0x948], eax
call fcn.0041af60
cmp eax, 0xffffffff
jne 0x40ff2e
or eax, eax
jmp 0x40ff3f
shl eax, 0xd
add eax, 0x447a7e
push eax
call fcn.0042417e
add esp, 4
push dword [0x446e5c]
mov dword [ebp - 0x944], eax
call esi
push 2
push dword [0x446e5c]
call edi
push 0x3c
lea eax, [ebp - 0x988]
push 0xff
push eax
call fcn.0041f490
add esp, 0xc
lea esi, [ebp - 0x987]
xor edi, edi
lea edx, [ebp - 0x131]
nop dword [eax + eax]
mov cl, byte [edx - 7]
cmp cl, 0xff
jne 0x40ffa2
cmp byte [edx], 0
jge 0x40ffa2
mov al, byte [edx + 2]
and al, 0xf0
cmp al, 0xf0
jne 0x40ffa2
or al, cl
or bl, cl
or ah, cl
or ch, cl
or cl, cl
jmp 0x40ffad
mov al, byte [edx + 2]
mov bl, byte [edx + 1]
mov ah, byte [edx]
mov ch, byte [edx - 6]
mov byte [esi - 1], cl
mov byte [esi], ch
mov byte [esi + 1], ah
mov byte [esi + 2], bl
mov byte [esi + 3], al
cmp edi, 7
ja 0x40ffef
movzx ecx, byte [edx - 4]
movzx eax, byte [edx - 3]
shl ecx, 8
or ecx, eax
movzx eax, byte [edx - 2]
shl ecx, 8
or ecx, eax
movzx eax, byte [edx - 1]
shl ecx, 8
or ecx, eax
mov eax, dword [ebp - 0xae0]
lea eax, [edi + eax*8]
mov dword [ebp + eax*4 - 0xad8], ecx
inc edi
add esi, 5
add edx, 0x10
cmp edi, 0xc
jl 0x40ff80
mov ebx, dword [ebp - 0xb18]
push ebx
push str.SELECT_G_Status_FROM_GuildMember_WHERE_Name_s
push 0x446e50
call fcn.0041ad10
add esp, 0xc
test al, al
je 0x410074
push dword [0x446e5c]
call dword [ebp - 0xae4]
cmp ax, 0x64
je 0x410074
push str.G_Status
call fcn.0041af60
cmp eax, 0xffffffff
jne 0x41003d
or eax, eax
jmp 0x41004e
shl eax, 0xd
add eax, 0x447a7e
push eax
call fcn.0042417e
add esp, 4
push dword [0x446e5c]
mov esi, dword [ebp - 0xaf4]
mov byte [ebp - 0x94c], al
call esi
mov edi, dword [ebp - 0xaf8]
push 2
push dword [0x446e5c]
call edi
jmp 0x410099
push dword [0x446e5c]
mov esi, dword [ebp - 0xaf4]
call esi
mov edi, dword [ebp - 0xaf8]
push 2
push dword [0x446e5c]
call edi
mov byte [ebp - 0x94c], 0xff
xor eax, eax
mov word [ebp - 0x940], ax
mov eax, dword [ebp - 0xaf0]
cmp byte [eax + 0x11], 1
jne 0x41011a
push ebx
push str.SELECT_MasterLevel_FROM_MasterSkillTree_WHERE_Name_s
push 0x446e50
call fcn.0041ad10
add esp, 0xc
test al, al
je 0x410102
push dword [0x446e5c]
call dword [ebp - 0xae4]
cmp ax, 0x64
je 0x410102
push str.MasterLevel
call fcn.0041af60
cmp eax, 0xffffffff
jne 0x4100ea
or eax, eax
jmp 0x4100fb
shl eax, 0xd
add eax, 0x447a7e
push eax
call fcn.0042417e
add esp, 4
mov word [ebp - 0x940], ax
push dword [0x446e5c]
call esi
push 2
push dword [0x446e5c]
call edi
mov eax, dword [ebp - 0xaf0]
cmp byte [eax + 0x11], 1
mov dword [ebp - 0x93c], 0
jne 0x41018f
push ebx
push str.SELECT_Quest_FROM_CustomQuest_WHERE_Name_s
push 0x446e50
call fcn.0041ad10
add esp, 0xc
test al, al
je 0x41017d
push dword [0x446e5c]
call dword [ebp - 0xae4]
cmp ax, 0x64
je 0x41017d
push str.Quest
call fcn.0041af60
cmp eax, 0xffffffff
jne 0x410166
or eax, eax
jmp 0x410177
shl eax, 0xd
add eax, 0x447a7e
push eax
call fcn.0042417e
add esp, 4
mov dword [ebp - 0x93c], eax
push dword [0x446e5c]
call esi
push 2
push dword [0x446e5c]
call edi
mov ecx, dword [ebp - 0xb14]
movups xmm0, xmmword [ebp - 0x998]
mov edx, dword [ebp - 0xae8]
mov al, byte [ebp - 0xad9]
add edx, 0x60
movups xmmword [ecx], xmm0
mov dword [ebp - 0xae8], edx
movups xmm0, xmmword [ebp - 0x988]
movups xmmword [ecx + 0x10], xmm0
movups xmm0, xmmword [ebp - 0x978]
movups xmmword [ecx + 0x20], xmm0
movups xmm0, xmmword [ebp - 0x968]
movups xmmword [ecx + 0x30], xmm0
movups xmm0, xmmword [ebp - 0x958]
movups xmmword [ecx + 0x40], xmm0
movups xmm0, xmmword [ebp - 0x948]
movups xmmword [ecx + 0x50], xmm0
add ecx, 0x60
inc al
mov byte [ebp - 0xad9], al
mov byte [ebp - 0xafc], al
mov eax, dword [ebp - 0xae0]
mov dword [ebp - 0xb14], ecx
jmp 0x410228
push dword [0x446e5c]
call esi
push 2
push dword [0x446e5c]
call edi
mov eax, dword [ebp - 0xae0]
mov edx, dword [ebp - 0xae8]
inc eax
add ebx, 0xb
mov dword [ebp - 0xae0], eax
mov dword [ebp - 0xb18], ebx
cmp eax, 0xa
jl 0x40fdf0
mov ebx, dword [ebp - 0xb1c]
mov eax, edx
shr eax, 8
mov byte [ebp - 0xb0f], al
mov eax, dword [ebp - 0xb00]
mov dword [ebp - 0x928], eax
mov ax, word [ebp - 0xafc]
mov word [ebp - 0x924], ax
lea eax, [ebp - 0x938]
push edx
mov byte [ebp - 0xb0e], dl
movups xmm0, xmmword [ebp - 0xb10]
push eax
push ebx
movups xmmword [ebp - 0x938], xmm0
call fcn.0041c350
mov eax, dword [ebp - 0xaf0]
lea esi, [ebp - 0xad8]
sub esp, 0x140
mov ecx, 0x50
mov edi, esp
rep movsd dword es:[edi], dword [esi]
movzx edx, word [eax + 4]
mov ecx, ebx
push dword [ebp - 0xaec]
call fcn.00415cc0
mov ecx, dword [ebp - 4]
add esp, 0x144
xor ecx, ebp
pop edi
pop esi
pop ebx
call fcn.0041dc7d
mov esp, ebp
pop ebp
ret