Function at 0x4055a0
Capabilities:
Reference sql statements

Disassembly:
push ebp
mov ebp, esp
mov eax, 0x103c
call fcn.004187e0
mov eax, dword [0x421018]
xor eax, ebp
mov dword [ebp - 4], eax
mov eax, dword [ebp + 8]
movzx ecx, word [eax + 4]
mov eax, dword [eax + 8]
push ebx
push esi
push edi
push ecx
mov word [ebp - 0x1030], cx
mov ebx, 0x14
xor esi, esi
push str.SELECT_TOP_100__FROM_MuCastle_REG_SIEGE_WHERE_MAP_SVR_GROUP_d_ORDER_BY_SEQ_NUM_ASC
mov ecx, 0x4ed8c0
mov byte [ebp - 0x1038], 0xc2
mov byte [ebp - 0x1035], 0x83
mov dword [ebp - 0x1024], ebx
mov dword [ebp - 0x102c], eax
mov dword [ebp - 0x1028], esi
call fcn.00414e40
add esp, 8
test al, al
je 0x4057bd
mov edx, dword [0x4ed8cc]
push edx
call dword [sym.imp.ODBC32.dll_SQLFetch]
cmp ax, 0x64
je 0x4057b8
lea edi, [ebp - 0xff4]
push 9
lea eax, [ebp - 0x1020]
push eax
push str.REG_SIEGE_GUILD
call fcn.00415170
xor ecx, ecx
xor esi, esi
cmp cx, word [0x4ed934]
jge 0x40567c
mov ebx, 0x4ed936
nop
push ebx
push str.REG_MARKS
call dword [sym.imp.MSVCR100.dll__stricmp]
add esp, 8
test eax, eax
je 0x405677
movsx edx, word [0x4ed934]
inc esi
add ebx, 0x1e
cmp esi, edx
jl 0x405650
or eax, 0xffffffff
jmp 0x405694
cmp esi, 0xffffffff
jne 0x405681
or eax, 0xffffffff
jmp 0x405694
shl esi, 0xd
add esi, 0x4ee4ee
push esi
call dword [sym.imp.MSVCR100.dll_atoi]
add esp, 4
mov dword [ebp - 0x1014], eax
xor eax, eax
xor esi, esi
cmp ax, word [0x4ed934]
jge 0x4056dc
mov ebx, 0x4ed936
lea esp, [esp]
push ebx
push str.IS_GIVEUP
call dword [sym.imp.MSVCR100.dll__stricmp]
add esp, 8
test eax, eax
je 0x4056d7
movsx ecx, word [0x4ed934]
inc esi
add ebx, 0x1e
cmp esi, ecx
jl 0x4056b0
or eax, 0xffffffff
jmp 0x4056f4
cmp esi, 0xffffffff
jne 0x4056e1
or eax, 0xffffffff
jmp 0x4056f4
shl esi, 0xd
add esi, 0x4ee4ee
push esi
call dword [sym.imp.MSVCR100.dll_atoi]
add esp, 4
xor edx, edx
xor esi, esi
mov dword [ebp - 0x1010], eax
cmp dx, word [0x4ed934]
jge 0x40573c
mov ebx, 0x4ed936
lea esp, [esp]
push ebx
push str.SEQ_NUM
call dword [sym.imp.MSVCR100.dll__stricmp]
add esp, 8
test eax, eax
je 0x405737
movsx eax, word [0x4ed934]
inc esi
add ebx, 0x1e
cmp esi, eax
jl 0x405710
or eax, 0xffffffff
jmp 0x405754
cmp esi, 0xffffffff
jne 0x405741
or eax, 0xffffffff
jmp 0x405754
shl esi, 0xd
add esi, 0x4ee4ee
push esi
call dword [sym.imp.MSVCR100.dll_atoi]
add esp, 4
mov ecx, dword [ebp - 0x1020]
mov edx, dword [ebp - 0x101c]
mov ebx, dword [ebp - 0x1024]
inc dword [ebp - 0x1028]
mov dword [edi], ecx
mov ecx, dword [ebp - 0x1018]
mov dword [edi + 4], edx
mov edx, dword [ebp - 0x1014]
mov dword [edi + 8], ecx
mov ecx, dword [ebp - 0x1010]
mov dword [edi + 0xc], edx
mov edx, dword [0x4ed8cc]
mov dword [edi + 0x10], ecx
mov dword [edi + 0x14], eax
add ebx, 0x18
push edx
mov dword [ebp - 0x100c], eax
mov dword [ebp - 0x1024], ebx
add edi, 0x18
call dword [sym.imp.ODBC32.dll_SQLFetch]
cmp ax, 0x64
jne 0x40562a
mov esi, 1
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 ecx, dword [ebp - 0x1030]
mov edx, ebx
shr edx, 8
mov byte [ebp - 0x1037], dl
mov edx, dword [ebp - 0x102c]
mov dword [ebp - 0x1000], ecx
mov byte [ebp - 0x1036], bl
mov eax, dword [ebp - 0x1038]
lea ecx, [ebp - 0x1008]
mov dword [ebp - 0xffc], edx
mov edx, dword [ebp + 0xc]
mov dword [ebp - 0x1008], eax
mov eax, dword [ebp - 0x1028]
push ecx
push edx
mov dword [ebp - 0x1004], esi
mov dword [ebp - 0xff8], eax
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 8