Function at 0x408f70
Capabilities:
Initialize winsock library

Disassembly:
push ebp
mov ebp, esp
and esp, 0xfffffff8
sub esp, 0x52c
mov eax, dword [0x4a3300]
xor eax, esp
mov dword [esp + 0x528], eax
push ebx
push esi
push edi
xor eax, eax
push 0x18e
push eax
mov word [esp + 0x270], ax
lea eax, [esp + 0x272]
push eax
call fcn.00453200
add esp, 0xc
lea eax, [esp + 0x268]
push eax
push 0x202
call dword [sym.imp.WS2_32.dll_WSAStartup]
test eax, eax
je 0x408fe8
push 0x4820b4
call fcn.00401630
add esp, 4
xor eax, eax
pop edi
pop esi
pop ebx
mov ecx, dword [esp + 0x528]
xor ecx, esp
call fcn.004524fc
mov esp, ebp
pop ebp
ret
cmp dword [0x4a7b14], 0
je 0x408fd1
push 0x63
lea eax, [esp + 0x4cd]
mov byte [esp + 0x4cc], 0
push 0
push eax
call fcn.00453200
add esp, 0xc
mov byte [esp + 0x10], 0
lea eax, [esp + 0x11]
push 0x257
push 0
push eax
call fcn.00453200
add esp, 0xc
lea edx, [esp + 0x10]
lea ecx, [esp + 0x4c8]
call fcn.0040d520
test eax, eax
jne 0x40905e
push 0x4820e8
call fcn.00401630
add esp, 4
xor eax, eax
pop edi
pop esi
pop ebx
mov ecx, dword [esp + 0x528]
xor ecx, esp
call fcn.004524fc
mov esp, ebp
pop ebp
ret
call fcn.0040d6c0
test eax, eax
jne 0x40908b
push 0x482118
call fcn.00401630
add esp, 4
xor eax, eax
pop edi
pop esi
pop ebx
mov ecx, dword [esp + 0x528]
xor ecx, esp
call fcn.004524fc
mov esp, ebp
pop ebp
ret
call fcn.004058c0
call fcn.004057c0
mov ecx, dword [0x4a7898]
test eax, eax
mov ebx, 1
cmove ecx, ebx
mov dword [0x4a7898], ecx
call fcn.00405840
cmp eax, ebx
jne 0x4090bc
mov dword [0x4a7b10], ebx
jmp 0x4090d3
cmp dword [0x4a7b10], 0
jne 0x4090d3
call fcn.00405ec0
cmp eax, 1
je 0x408fd1
push 0x63
lea eax, [esp + 0x465]
mov byte [esp + 0x464], 0
push 0
push eax
call fcn.00453200
lea ecx, [esp + 0x46c]
add esp, 0xc
dec ecx
mov al, byte [ecx + 1]
lea ecx, [ecx + 1]
test al, al
jne 0x4090f7
mov eax, dword [str.GlobaliGameDX_01_]
mov edx, 0x727624
mov dword [ecx], eax
mov esi, edx
mov eax, dword [0x482150]
mov dword [ecx + 4], eax
mov eax, dword [0x482154]
mov dword [ecx + 8], eax
mov eax, dword [0x482158]
mov dword [ecx + 0xc], eax
mov ax, word [0x48215c]
mov word [ecx + 0x10], ax
mov al, byte [0x48215e]
mov byte [ecx + 0x12], al
lea esp, [esp]
mov al, byte [edx]
inc edx
test al, al
jne 0x409140
lea edi, [esp + 0x460]
sub edx, esi
dec edi
mov al, byte [edi + 1]
inc edi
test al, al
jne 0x409151
mov ecx, edx
mov byte [esp + 0x3f8], al
shr ecx, 2
lea eax, [esp + 0x3f9]
rep movsd dword es:[edi], dword [esi]
mov ecx, edx
push 0x63
and ecx, 3
push 0
rep movsb byte es:[edi], byte [esi]
push eax
call fcn.00453200
lea ecx, [esp + 0x404]
add esp, 0xc
dec ecx
lea ebx, [ebx]
mov al, byte [ecx + 1]
lea ecx, [ecx + 1]
test al, al
jne 0x409190
mov eax, dword [str.GlobaliGameDX_02_]
mov edx, 0x727624
mov dword [ecx], eax
mov esi, edx
mov eax, dword [0x4820a4]
mov dword [ecx + 4], eax
mov eax, dword [0x4820a8]
mov dword [ecx + 8], eax
mov eax, dword [0x4820ac]
mov dword [ecx + 0xc], eax
mov ax, word [0x4820b0]
mov word [ecx + 0x10], ax
mov al, byte [0x4820b2]
mov byte [ecx + 0x12], al
mov al, byte [edx]
inc edx
test al, al
jne 0x4091d2
lea edi, [esp + 0x3f8]
sub edx, esi
dec edi
mov al, byte [edi + 1]
inc edi
test al, al
jne 0x4091e3
mov ecx, edx
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, edx
lea edx, [esp + 0x460]
and ecx, 3
rep movsb byte es:[edi], byte [esi]
mov ecx, 0x4a7b18
call fcn.00405770
test eax, eax
jne 0x409262
cmp dword [0x4a7b10], eax
jne 0x408fd1
lea eax, [esp + 0x3f8]
push eax
push 0
push 1
call dword [sym.imp.KERNEL32.dll_OpenMutexA]
mov esi, eax
test esi, esi
je 0x408fd1
push esi
call dword [sym.imp.KERNEL32.dll_ReleaseMutex]
push esi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
xor ecx, ecx
call fcn.004070a0
xor eax, eax
pop edi
pop esi
pop ebx
mov ecx, dword [esp + 0x528]
xor ecx, esp
call fcn.004524fc
mov esp, ebp
pop ebp
ret
mov eax, dword [0x4a7b14]
test eax, eax
je 0x409274
push str._STS_DUILIB_CreateLoadWnd
call eax
call eax
xor edx, edx
mov ecx, 0x408f50
call fcn.0040a100
test eax, eax
jne 0x4092a8
push 0x482160
call fcn.00401630
add esp, 4
xor eax, eax
pop edi
pop esi
pop ebx
mov ecx, dword [esp + 0x528]
xor ecx, esp
call fcn.004524fc
mov esp, ebp
pop ebp
ret
mov ecx, dword [esp + 0x534]
mov eax, ebx
pop edi
pop esi
pop ebx
xor ecx, esp
call fcn.004524fc
mov esp, ebp
pop ebp
ret