Function at 0x50f9c0
Capabilities:
Get thread local storage value

Disassembly:
sub esp, 8
push ebp
mov ebp, dword [sym.imp.KERNEL32.dll_TlsGetValue]
push esi
push edi
mov edi, ecx
mov esi, dword [edi + 0x74]
mov dword [edi], vtable.hkpWorld.0
test esi, esi
je 0x50fa15
cmp dword [esi + 0xf4], 0
je 0x50f9ff
push dword [0x884adc]
call ebp
push 0x200
push dword [esi + 0xf4]
mov ecx, dword [eax + 0x2c]
mov eax, dword [ecx]
call dword [eax + 8]
push dword [0x884adc]
call ebp
push 0x120
push esi
mov ecx, dword [eax + 0x2c]
mov eax, dword [ecx]
call dword [eax + 8]
mov ecx, dword [edi + 0x4c]
push ebx
call fcn.0045c160
mov esi, dword [edi + 0xbc]
mov ebx, dword [sym.imp.KERNEL32.dll_DeleteCriticalSection]
mov dword [edi + 0x4c], 0
test esi, esi
je 0x50fa55
push esi
call ebx
push dword [0x884adc]
call ebp
push 0x18
push esi
mov ecx, dword [eax + 0x2c]
mov eax, dword [ecx]
call dword [eax + 8]
mov dword [edi + 0xbc], 0
mov esi, dword [edi + 0xc8]
test esi, esi
je 0x50fa7f
push esi
call ebx
push dword [0x884adc]
call ebp
push 0x18
push esi
mov ecx, dword [eax + 0x2c]
mov eax, dword [ecx]
call dword [eax + 8]
mov dword [edi + 0xc8], 0
mov esi, dword [edi + 0xc4]
test esi, esi
je 0x50faa9
push esi
call ebx
push dword [0x884adc]
call ebp
push 0x18
push esi
mov ecx, dword [eax + 0x2c]
mov eax, dword [ecx]
call dword [eax + 8]
mov dword [edi + 0xc4], 0
mov ecx, dword [edi + 0x50]
test ecx, ecx
je 0x50fab5
call fcn.0045c160
mov ecx, edi
mov dword [edi + 0x50], 0
call fcn.00510140
push dword [edi + 0x24]
lea eax, [esp + 0x17]
mov ecx, edi
push eax
call fcn.0050a4e0
push dword [edi + 0x20]
mov dword [edi + 0x24], 0
push edi
call fcn.0052ccc0
mov ecx, dword [edi + 0x20]
add esp, 8
test ecx, ecx
je 0x50faf2
mov eax, dword [ecx]
push 1
call dword [eax]
mov eax, dword [edi + 0x1c8]
xor ebx, ebx
mov dword [edi + 0x20], 0
test eax, eax
jle 0x50fb3a
mov ebp, eax
nop word [eax + eax]
mov eax, dword [edi + 0x1c4]
push edi
mov esi, dword [eax + ebx*4]
mov ecx, esi
mov eax, dword [esi]
call dword [eax + 0x10]
mov ecx, esi
mov dword [esi + 8], 0
call fcn.0045c160
inc ebx
cmp ebx, ebp
jl 0x50fb10
mov ebp, dword [sym.imp.KERNEL32.dll_TlsGetValue]
push edi
call fcn.00528d20
mov ecx, dword [edi + 0x58]
add esp, 4
call fcn.0045c160
mov ecx, dword [edi + 0x80]
mov dword [edi + 0x58], 0
call fcn.0045c160
mov esi, dword [edi + 0x64]
mov dword [edi + 0x80], 0
pop ebx
test esi, esi
je 0x50fb8c
mov ecx, esi
call fcn.006aef70
push dword [0x884adc]
call ebp
push 0x10c
push esi
mov ecx, dword [eax + 0x2c]
mov eax, dword [ecx]
call dword [eax + 8]
mov ecx, dword [edi + 0x1d4]
test ecx, ecx
je 0x50fb9b
call fcn.0045c160
mov ecx, dword [edi + 0x68]
test ecx, ecx
je 0x50fba8
mov eax, dword [ecx]
push 1
call dword [eax]
mov ecx, dword [edi + 0x6c]
test ecx, ecx
je 0x50fbb5
mov eax, dword [ecx]
push 1
call dword [eax]
mov ecx, dword [edi + 0x70]
test ecx, ecx
je 0x50fbc2
mov eax, dword [ecx]
push 1
call dword [eax]
mov ecx, dword [edi + 0x7c]
call fcn.0045c160
mov ecx, dword [edi + 0x84]
call fcn.0045c160
mov eax, dword [edi + 0x78]
mov esi, dword [eax + 0x70]
test esi, esi
je 0x50fbf2
push dword [0x884adc]
call ebp
push 0x10
push esi
mov ecx, dword [eax + 0x2c]
mov eax, dword [ecx]
call dword [eax + 8]
mov esi, dword [edi + 0x78]
test esi, esi
je 0x50fc2d
cmp dword [esi + 0x64], 0
je 0x50fc17
push dword [0x884adc]
call ebp
push 0x200
push dword [esi + 0x64]
mov ecx, dword [eax + 0x2c]
mov eax, dword [ecx]
call dword [eax + 8]
push dword [0x884adc]
call ebp
push 0x80
push esi
mov ecx, dword [eax + 0x2c]
mov eax, dword [ecx]
call dword [eax + 8]
mov ecx, dword [edi + 8]
call fcn.0045c160
mov esi, dword [edi + 0x88]
test esi, esi
je 0x50fc59
mov ecx, esi
call fcn.00538480
push dword [0x884adc]
call ebp
push 0x28
push esi
mov ecx, dword [eax + 0x2c]
mov eax, dword [ecx]
call dword [eax + 8]
mov ecx, dword [edi + 0x5c]
test ecx, ecx
je 0x50fc65
call fcn.0045c160
mov esi, dword [edi + 0x1d0]
test esi, esi
je 0x50fc85
push dword [0x884adc]
call ebp
push 0x204
push esi
mov ecx, dword [eax + 0x2c]
mov eax, dword [ecx]
call dword [eax + 8]
mov eax, dword [edi + 0x1cc]
mov dword [edi + 0x1c8], 0
test eax, eax
js 0x50fcb5
and eax, 0x3fffffff
mov ecx, 0x7d8954
shl eax, 2
push eax
mov eax, dword [0x7d8954]
push dword [edi + 0x1c4]
call dword [eax + 0x10]
mov dword [edi + 0x1c4], 0
mov dword [edi + 0x1cc], connect
mov eax, dword [edi + 0x1c0]
mov dword [edi + 0x1bc], 0
test eax, eax
js 0x50fcf9
and eax, 0x3fffffff
mov ecx, 0x7d8954
shl eax, 2
push eax
mov eax, dword [0x7d8954]
push dword [edi + 0x1b8]
call dword [eax + 0x10]
mov dword [edi + 0x1b8], 0
mov dword [edi + 0x1c0], connect
mov eax, dword [edi + 0x1b4]
mov dword [edi + 0x1b0], 0
test eax, eax
js 0x50fd3d
and eax, 0x3fffffff
mov ecx, 0x7d8954
shl eax, 2
push eax
mov eax, dword [0x7d8954]
push dword [edi + 0x1ac]
call dword [eax + 0x10]
mov dword [edi + 0x1ac], 0
mov dword [edi + 0x1b4], connect
mov eax, dword [edi + 0x1a8]
mov dword [edi + 0x1a4], 0
test eax, eax
js 0x50fd81
and eax, 0x3fffffff
mov ecx, 0x7d8954
shl eax, 2
push eax
mov eax, dword [0x7d8954]
push dword [edi + 0x1a0]
call dword [eax + 0x10]
mov dword [edi + 0x1a0], 0
mov dword [edi + 0x1a8], connect
mov eax, dword [edi + 0x19c]
mov dword [edi + 0x198], 0
test eax, eax
js 0x50fdc5
and eax, 0x3fffffff
mov ecx, 0x7d8954
shl eax, 2
push eax
mov eax, dword [0x7d8954]
push dword [edi + 0x194]
call dword [eax + 0x10]
mov dword [edi + 0x194], 0
mov dword [edi + 0x19c], connect
mov eax, dword [edi + 0x190]
mov dword [edi + 0x18c], 0
test eax, eax
js 0x50fe09
and eax, 0x3fffffff
mov ecx, 0x7d8954
shl eax, 2
push eax
mov eax, dword [0x7d8954]
push dword [edi + 0x188]
call dword [eax + 0x10]
mov dword [edi + 0x188], 0
mov dword [edi + 0x190], connect
mov eax, dword [edi + 0x184]
mov dword [edi + 0x180], 0
test eax, eax
js 0x50fe4d
and eax, 0x3fffffff
mov ecx, 0x7d8954
shl eax, 2
push eax
mov eax, dword [0x7d8954]
push dword [edi + 0x17c]
call dword [eax + 0x10]
mov dword [edi + 0x17c], 0
mov dword [edi + 0x184], connect
mov eax, dword [edi + 0x178]
mov dword [edi + 0x174], 0
test eax, eax
js 0x50fe91
and eax, 0x3fffffff
mov ecx, 0x7d8954
shl eax, 2
push eax
mov eax, dword [0x7d8954]
push dword [edi + 0x170]
call dword [eax + 0x10]
mov dword [edi + 0x170], 0
mov dword [edi + 0x178], connect
mov eax, dword [edi + 0x16c]
mov dword [edi + 0x168], 0
test eax, eax
js 0x50fed5
and eax, 0x3fffffff
mov ecx, 0x7d8954
shl eax, 2
push eax
mov eax, dword [0x7d8954]
push dword [edi + 0x164]
call dword [eax + 0x10]
mov dword [edi + 0x164], 0
mov dword [edi + 0x16c], connect
mov eax, dword [edi + 0x160]
mov dword [edi + 0x15c], 0
test eax, eax
js 0x50ff19
and eax, 0x3fffffff
mov ecx, 0x7d8954
shl eax, 2
push eax
mov eax, dword [0x7d8954]
push dword [edi + 0x158]
call dword [eax + 0x10]
mov dword [edi + 0x158], 0
mov dword [edi + 0x160], connect
mov eax, dword [edi + 0x154]
mov dword [edi + 0x150], 0
test eax, eax
js 0x50ff5d
and eax, 0x3fffffff
mov ecx, 0x7d8954
shl eax, 2
push eax
mov eax, dword [0x7d8954]
push dword [edi + 0x14c]
call dword [eax + 0x10]
mov dword [edi + 0x14c], 0
mov dword [edi + 0x154], connect
mov eax, dword [edi + 0x148]
mov dword [edi + 0x144], 0
test eax, eax
js 0x50ffa1
and eax, 0x3fffffff
mov ecx, 0x7d8954
shl eax, 2
push eax
mov eax, dword [0x7d8954]
push dword [edi + 0x140]
call dword [eax + 0x10]
mov dword [edi + 0x140], 0
mov dword [edi + 0x148], connect
mov eax, dword [edi + 0x13c]
mov dword [edi + 0x138], 0
test eax, eax
js 0x50ffe5
and eax, 0x3fffffff
mov ecx, 0x7d8954
shl eax, 2
push eax
mov eax, dword [0x7d8954]
push dword [edi + 0x134]
call dword [eax + 0x10]
mov dword [edi + 0x134], 0
mov dword [edi + 0x13c], connect
mov eax, dword [edi + 0x130]
mov dword [edi + 0x12c], 0
test eax, eax
js 0x510029
and eax, 0x3fffffff
mov ecx, 0x7d8954
shl eax, 2
push eax
mov eax, dword [0x7d8954]
push dword [edi + 0x128]
call dword [eax + 0x10]
mov dword [edi + 0x128], 0
mov dword [edi + 0x130], connect
mov eax, dword [edi + 0x124]
mov dword [edi + 0x120], 0
test eax, eax
js 0x51006d
and eax, 0x3fffffff
mov ecx, 0x7d8954
shl eax, 2
push eax
mov eax, dword [0x7d8954]
push dword [edi + 0x11c]
call dword [eax + 0x10]
mov dword [edi + 0x11c], 0
mov dword [edi + 0x124], connect
mov ecx, dword [edi + 0x50]
test ecx, ecx
je 0x51008d
call fcn.0045c160
mov dword [edi + 0x50], 0
mov eax, dword [edi + 0x48]
mov dword [edi + 0x44], 0
test eax, eax
js 0x5100bb
and eax, 0x3fffffff
mov ecx, 0x7d8954
shl eax, 2
push eax
mov eax, dword [0x7d8954]
push dword [edi + 0x40]
call dword [eax + 0x10]
mov dword [edi + 0x40], 0
mov dword [edi + 0x48], connect
mov eax, dword [edi + 0x3c]
mov dword [edi + 0x38], 0
test eax, eax
js 0x5100f0
and eax, 0x3fffffff
mov ecx, 0x7d8954
shl eax, 2
push eax
mov eax, dword [0x7d8954]
push dword [edi + 0x34]
call dword [eax + 0x10]
mov dword [edi + 0x34], 0
mov dword [edi + 0x3c], connect
mov eax, dword [edi + 0x30]
mov dword [edi + 0x2c], 0
test eax, eax
js 0x510125
and eax, 0x3fffffff
mov ecx, 0x7d8954
shl eax, 2
push eax
mov eax, dword [0x7d8954]
push dword [edi + 0x28]
call dword [eax + 0x10]
mov dword [edi + 0x28], 0
mov dword [edi + 0x30], connect
mov dword [edi], vtable.hkBaseObject.0
pop edi
pop esi
pop ebp
add esp, 8
ret