Function at 0x52c980
Capabilities:
Resolve function by parsing pe exports

Disassembly:
push ebp
mov ebp, esp
and esp, 0xfffffff8
push 0xffffffffffffffff
push 0x6432ab
mov eax, dword fs:[0]
push eax
mov dword fs:[0], esp
sub esp, 0xc8
mov eax, dword [ebp + 0x14]
push ebx
push esi
xor ebx, ebx
cmp eax, ebx
mov esi, ecx
push edi
mov dword [esp + 0xc4], esi
mov dword [esp + 0xa0], ebx
je 0x52c9d7
lea ecx, [esi + 0x4c]
mov dword [esi + 4], 0x65de48
call fcn.0040b080
mov dword [esp + 0xa0], 1
mov eax, dword [esi + 4]
mov ecx, dword [eax + 4]
mov dword [esi + ecx + 4], vtable.Interface.0
mov edx, dword [esi + 4]
mov dword [esi], vtable.EffectBase.1.0
mov eax, dword [edx + 4]
mov dword [eax + esi + 4], vtable.EffectBase.0
mov ecx, dword [esi + 4]
mov dword [esi], vtable.SplashEffect.1.0
mov edx, dword [ecx + 4]
mov dword [edx + esi + 4], vtable.SplashEffect.0
mov dword [esi + 8], 0x447a0000
mov dword [esi + 0xc], 0x3d23d70a
lea edi, [esi + 0x14]
mov dword [edi], 0x6580c8
mov dword [edi + 4], ebx
mov eax, dword [edi]
mov ecx, dword [eax + 4]
mov dword [esp + 0xdc], 2
mov dword [ecx + edi + 4], ebx
lea ebx, [esi + 0x20]
mov dword [ebx], 0x6580c8
xor eax, eax
mov dword [ebx + 4], eax
mov edx, dword [ebx]
mov ecx, dword [edx + 4]
mov dword [ecx + ebx + 4], eax
mov dword [esi + 0x2c], eax
mov dword [esi + 0x30], eax
mov dword [esi + 0x34], eax
sub esp, 0x18
mov ecx, esp
mov dword [esp + 0x2c], esp
lea edx, [esp + 0x2b]
push edx
push str.splash_remover
mov byte [esp + 0xfc], 0xd
call fcn.00403db0
lea eax, [esp + 0x8c]
push eax
mov ecx, 0x6bfa98
call fcn.004a1c40
push eax
mov ecx, edi
mov byte [esp + 0xe0], 0xe
call fcn.0049ab80
lea ecx, [esp + 0x74]
mov byte [esp + 0xdc], 0xd
call fcn.0049ac10
sub esp, 0x18
mov ecx, esp
mov dword [esp + 0x2c], esp
lea edx, [esp + 0x2b]
push edx
push str.splash_dot
call fcn.00403db0
lea eax, [esp + 0x8c]
push eax
mov ecx, 0x6bfa98
call fcn.004a1c40
push eax
mov ecx, ebx
mov byte [esp + 0xe0], 0xf
call fcn.0049ab80
lea ecx, [esp + 0x74]
mov byte [esp + 0xdc], 0xd
call fcn.0049ac10
mov ebx, dword [ebp + 0xc]
xor edi, edi
mov dword [esi + 0x48], edi
mov eax, dword [ebx]
mov ecx, dword [ebx + 4]
mov dword [esp + 0x1c], edi
mov dword [esp + 0x20], edi
sub ecx, eax
sar ecx, 3
test ecx, ecx
mov ecx, edi
jbe 0x52cb79
lea esp, [esp]
mov edx, dword [esp + 0x1c]
mov dword [esp + 0x24], edx
mov edx, dword [eax + edi*8 + 4]
mov dword [esp + 0x28], ecx
fld dword [esp + 0x28]
mov ecx, dword [eax + edi*8]
mov dword [esp + 0x18], edx
fadd dword [esp + 0x18]
sub esp, 8
mov dword [esp + 0x1c], ecx
fstp dword [esp + 4]
lea ecx, [esp + 0x34]
fld dword [esp + 0x2c]
fadd dword [esp + 0x1c]
fstp dword [esp]
call fcn.00406d90
mov eax, dword [esp + 0x2c]
mov edx, dword [ebx + 4]
mov ecx, dword [esp + 0x30]
mov dword [esp + 0x1c], eax
mov eax, dword [ebx]
sub edx, eax
inc edi
sar edx, 3
cmp edi, edx
jb 0x52cb20
mov eax, dword [ebx + 4]
sub eax, dword [ebx]
sar eax, 3
test eax, eax
mov dword [esp + 0x14], eax
fild dword [esp + 0x14]
jge 0x52cb93
fadd dword [0x6532d4]
fdivr dword [0x6532d8]
mov edx, dword [esp + 0x1c]
mov dword [esp + 0x30], ecx
lea ecx, [esp + 0x2c]
mov dword [esp + 0x2c], edx
fstp dword [esp + 0x14]
mov eax, dword [esp + 0x14]
push eax
push eax
lea eax, [esp + 0x24]
push eax
call fcn.0048dbe0
lea ecx, [esp + 0x63]
push ecx
lea ecx, [esp + 0x84]
mov byte [esp + 0xe0], 0x10
call fcn.0041bc10
mov eax, dword [ebx]
mov edx, dword [eax]
mov eax, dword [eax + 4]
mov ecx, dword [esp + 0x20]
mov edi, dword [esp + 0x1c]
mov dword [esp + 0x28], eax
fld dword [esp + 0x28]
mov dword [esp + 0x18], ecx
fsub dword [esp + 0x18]
sub esp, 8
mov dword [esp + 0x2c], edx
fstp dword [esp + 4]
mov dword [esp + 0x1c], edi
fld dword [esp + 0x2c]
lea ecx, [esp + 0x1c]
fsub dword [esp + 0x1c]
mov byte [esp + 0xe4], 0x12
fstp dword [esp]
call fcn.00406d90
fld dword [esp + 0x14]
fmul dword [esp + 0x14]
fld dword [esp + 0x18]
fmul dword [esp + 0x18]
faddp st(1)
fst dword [esp + 0x14]
fsqrt
fcomp dword [0x6532d8]
fnstsw ax
test ah, 5
jp 0x52cc4f
mov dword [esp + 0x50], 0
jmp 0x52cc9a
mov eax, dword [ebx]
mov edx, dword [eax]
mov eax, dword [eax + 4]
mov ecx, dword [esp + 0x20]
mov dword [esp + 0x28], eax
fld dword [esp + 0x28]
mov dword [esp + 0x54], ecx
fsub dword [esp + 0x54]
sub esp, 8
mov dword [esp + 0x2c], edx
fstp dword [esp + 4]
mov dword [esp + 0x58], edi
fld dword [esp + 0x2c]
lea ecx, [esp + 0x6c]
fsub dword [esp + 0x58]
fstp dword [esp]
call fcn.00406d90
lea ecx, [esp + 0x64]
call fcn.0052d460
fstp dword [esp + 0x50]
mov eax, dword [ebx]
mov edx, dword [ebx + 4]
sub edx, eax
sar edx, 3
xor edi, edi
test edx, edx
jbe 0x52ceb1
mov ecx, dword [esp + 0x1c]
mov edx, dword [esp + 0x20]
mov dword [esp + 0x38], ecx
mov dword [esp + 0x3c], edx
mov edi, edi
mov edx, dword [eax + edi*8 + 4]
mov ecx, dword [eax + edi*8]
mov dword [esp + 0x28], edx
fld dword [esp + 0x28]
fsub dword [esp + 0x3c]
sub esp, 8
mov dword [esp + 0x2c], ecx
lea ecx, [esp + 0x48]
fstp dword [esp + 4]
fld dword [esp + 0x2c]
fsub dword [esp + 0x40]
fstp dword [esp]
call fcn.00406d90
fld dword [esp + 0x40]
fmul dword [esp + 0x40]
fld dword [esp + 0x44]
fmul dword [esp + 0x44]
faddp st(1)
fsqrt
fst dword [esp + 0x78]
fcomp dword [0x654e5c]
fnstsw ax
test ah, 0x41
jne 0x52ce7e
fld dword [esp + 0x14]
sub esp, 8
fsqrt
fcomp dword [0x6532d8]
fnstsw ax
test ah, 5
mov eax, dword [ebx]
jp 0x52cdc4
mov ecx, dword [eax + edi*8]
mov edx, dword [eax + edi*8 + 4]
mov eax, dword [esp + 0x24]
mov dword [esp + 0xac], ecx
mov ecx, dword [esp + 0x28]
mov dword [esp + 0xb0], edx
fld dword [esp + 0xb0]
mov dword [esp + 0xa4], ecx
fsub dword [esp + 0xa4]
mov dword [esp + 0xa0], eax
lea ecx, [esp + 0xbc]
fstp dword [esp + 4]
fld dword [esp + 0xac]
fsub dword [esp + 0xa0]
fstp dword [esp]
call fcn.00406d90
mov edx, dword [esp + 0xb8]
mov eax, dword [esp + 0xb4]
push edx
push eax
push 0
push 0x3f800000
lea ecx, [esp + 0xcc]
call fcn.00406d90
mov ecx, eax
call fcn.0052d510
fstp dword [esp + 0x74]
jmp 0x52ce86
mov ecx, dword [eax]
mov edx, dword [eax + 4]
mov dword [esp + 0x74], ecx
mov ecx, dword [eax + edi*8]
mov dword [esp + 0x78], edx
mov edx, dword [eax + edi*8 + 4]
mov eax, dword [esp + 0x24]
mov dword [esp + 0xb4], ecx
mov ecx, dword [esp + 0x28]
mov dword [esp + 0xb8], edx
fld dword [esp + 0xb8]
mov dword [esp + 0x64], ecx
fsub dword [esp + 0x64]
mov dword [esp + 0x60], eax
lea ecx, [esp + 0x6c]
fstp dword [esp + 4]
fld dword [esp + 0xb4]
fsub dword [esp + 0x60]
fstp dword [esp]
call fcn.00406d90
mov edx, dword [esp + 0x6c]
mov eax, dword [esp + 0x70]
mov ecx, dword [esp + 0x1c]
mov dword [esp + 0x48], edx
mov edx, dword [esp + 0x20]
mov dword [esp + 0x4c], eax
fld dword [esp + 0x4c]
mov dword [esp + 0x30], edx
fsub dword [esp + 0x30]
sub esp, 8
mov dword [esp + 0x34], ecx
fstp dword [esp + 4]
lea ecx, [esp + 0xd0]
fld dword [esp + 0x50]
fsub dword [esp + 0x34]
fstp dword [esp]
call fcn.00406d90
mov eax, dword [esp + 0x68]
mov ecx, dword [esp + 0x64]
push eax
push ecx
lea ecx, [esp + 0xd0]
call fcn.0052d510
fstp dword [esp + 0x74]
jmp 0x52ce86
mov dword [esp + 0x74], 0x3dcccccd
lea edx, [esp + 0x74]
push edx
lea ecx, [esp + 0x84]
mov dword [esp + 0x80], edi
call fcn.0052d8d0
mov eax, dword [ebx]
mov ecx, dword [ebx + 4]
sub ecx, eax
inc edi
sar ecx, 3
cmp edi, ecx
jb 0x52ccc0
call fcn.006122e1
and eax, 0x80000001
jns 0x52cec2
dec eax
or eax, 0xfffffffe
inc eax
jne 0x52cedb
mov edx, dword [esp + 0x84]
mov eax, dword [esp + 0x80]
push 0x52d390
push edx
push eax
jmp 0x52cef0
mov ecx, dword [esp + 0x84]
mov edx, dword [esp + 0x80]
push 0x52d3b0
push ecx
push edx
call fcn.0052dba0
add esp, 0xc
lea eax, [esp + 0x37]
push eax
lea ecx, [esp + 0x90]
call fcn.0041bc10
mov ecx, dword [ebx + 4]
sub ecx, dword [ebx]
xor eax, eax
sar ecx, 3
test ecx, ecx
mov byte [esp + 0xdc], 0x13
mov dword [esp + 0x40], eax
jbe 0x52d0d5
mov edx, dword [esp + 0x1c]
mov ecx, dword [esp + 0x20]
mov dword [esp + 0x2c], edx
mov dword [esp + 0x30], ecx
mov dword [esp + 0x38], eax
jmp 0x52cf41
mov eax, dword [esp + 0x38]
mov ecx, dword [esp + 0x80]
fld dword [esp + 0x50]
fadd dword [eax + ecx]
lea eax, [eax + ecx + 4]
sub esp, 8
lea ecx, [esp + 0xc4]
fld st(0)
fsin
fxch st(1)
fcos
fstp dword [esp + 0x1c]
fmul dword [eax]
fstp dword [esp + 4]
fld dword [esp + 0x1c]
fmul dword [eax]
fstp dword [esp]
call fcn.00406d90
mov edx, dword [eax]
fld dword [esp + 0x30]
mov eax, dword [eax + 4]
mov dword [esp + 0x4c], eax
fadd dword [esp + 0x4c]
sub esp, 8
mov dword [esp + 0x50], edx
fstp dword [esp + 4]
lea ecx, [esp + 0x6c]
fld dword [esp + 0x34]
fadd dword [esp + 0x50]
fstp dword [esp]
call fcn.00406d90
mov ecx, dword [esi + 0x34]
mov eax, dword [esi + 0x30]
lea edi, [esi + 0x2c]
cmp eax, ecx
lea ecx, [esp + 0x64]
je 0x52cfd3
push ecx
push eax
call fcn.004473c0
mov eax, dword [edi + 4]
add esp, 8
add eax, 8
mov dword [edi + 4], eax
jmp 0x52cfea
push 1
push 1
lea edx, [esp + 0x1b]
push edx
push ecx
push eax
mov ecx, edi
mov byte [esp + 0x27], 0
call fcn.0052d8c0
mov eax, dword [esp + 0x40]
test eax, eax
jbe 0x52d050
mov edi, dword [edi]
mov edx, dword [edi + eax*8]
mov ecx, dword [edi + eax*8 + 4]
mov dword [esp + 0x6c], edx
mov edx, dword [edi + eax*8 - 8]
mov eax, dword [edi + eax*8 - 4]
mov dword [esp + 0x70], ecx
fld dword [esp + 0x70]
mov dword [esp + 0x5c], eax
fsub dword [esp + 0x5c]
sub esp, 8
mov dword [esp + 0x60], edx
fstp dword [esp + 4]
lea ecx, [esp + 0x24]
fld dword [esp + 0x74]
fsub dword [esp + 0x60]
fstp dword [esp]
call fcn.00406d90
fld dword [esp + 0x1c]
fmul dword [esp + 0x1c]
fld dword [esp + 0x20]
fmul dword [esp + 0x20]
faddp st(1)
fsqrt
fadd dword [esi + 0x48]
fstp dword [esi + 0x48]
mov edx, dword [esp + 0x38]
mov ecx, dword [esp + 0x80]
mov ecx, dword [edx + ecx + 8]
mov eax, dword [ebx]
mov edx, dword [esp + 0x94]
lea eax, [eax + ecx*8]
mov ecx, dword [esp + 0x90]
cmp ecx, edx
je 0x52d093
push eax
push ecx
call fcn.004473c0
mov eax, dword [esp + 0x98]
add esp, 8
add eax, 8
mov dword [esp + 0x90], eax
jmp 0x52d0af
push 1
push 1
lea edx, [esp + 0x1b]
push edx
push eax
push ecx
lea ecx, [esp + 0xa0]
mov byte [esp + 0x27], 0
call fcn.0052d8c0
mov ecx, dword [ebx + 4]
mov edx, dword [ebx]
mov eax, dword [esp + 0x40]
mov edi, dword [esp + 0x38]
sub ecx, edx
inc eax
add edi, 0xc
sar ecx, 3
cmp eax, ecx
mov dword [esp + 0x40], eax
mov dword [esp + 0x38], edi
jb 0x52cf3d
lea edx, [esp + 0x8c]
push edx
mov ecx, ebx
call fcn.0052d700
fld dword [esi + 0x48]
fdiv dword [esi + 8]
mov dword [esp + 0x14], 0x3e4ccccd
fmul dword [ebp + 8]
fst dword [esp + 0x1c]
fcomp dword [0x65c0b4]
fnstsw ax
test ah, 5
lea eax, [esp + 0x14]
jnp 0x52d10e
lea eax, [esp + 0x1c]
fld dword [eax]
mov ebx, dword [ebp + 0x10]
fst dword [esi + 0x3c]
fstp dword [esi + 0x40]
mov eax, dword [ebx + 4]
mov ecx, dword [ebx]
cmp ecx, eax
je 0x52d13c
mov edi, eax
sub edi, eax
je 0x52d137
push edi
push eax
push ecx
call fcn.00611870
add esp, 0xc
add eax, edi
jmp 0x52d139
mov eax, ecx
mov dword [ebx + 4], eax
mov ecx, dword [ebp + 0xc]
mov edx, dword [ecx + 4]
sub edx, dword [ecx]
xor eax, eax
sar edx, 3
test edx, edx
mov dword [esp + 0x40], 0
mov dword [esp + 0x50], eax
jbe 0x52d2b8
jmp 0x52d163
mov eax, dword [esp + 0x50]
test eax, eax
jbe 0x52d1c8
mov ecx, dword [esi + 0x2c]
mov edx, dword [ecx + eax*8]
mov dword [esp + 0x2c], edx
mov edx, dword [ecx + eax*8 + 4]
mov dword [esp + 0x30], edx
fld dword [esp + 0x30]
mov edx, dword [ecx + eax*8 - 8]
mov eax, dword [ecx + eax*8 - 4]
mov dword [esp + 0x4c], eax
fsub dword [esp + 0x4c]
sub esp, 8
mov dword [esp + 0x50], edx
fstp dword [esp + 4]
lea ecx, [esp + 0x2c]
fld dword [esp + 0x34]
fsub dword [esp + 0x50]
fstp dword [esp]
call fcn.00406d90
fld dword [esp + 0x24]
fmul dword [esp + 0x24]
fld dword [esp + 0x28]
fmul dword [esp + 0x28]
faddp st(1)
fsqrt
fadd dword [esp + 0x40]
fstp dword [esp + 0x40]
fld dword [esi + 0x48]
mov edi, dword [ebx + 4]
fadd dword [esi + 8]
mov eax, dword [ebx + 8]
cmp edi, eax
lea ecx, [ebx + 8]
fdivr dword [esp + 0x40]
fmul dword [esi + 0x3c]
fstp dword [esp + 0x1c]
je 0x52d1f9
test edi, edi
je 0x52d1f0
mov ecx, dword [esp + 0x1c]
mov dword [edi], ecx
add dword [ebx + 4], 4
jmp 0x52d29a
mov eax, dword [ebx]
mov edx, edi
sub edx, eax
sar edx, 2
cmp edx, 1
mov dword [esp + 0x14], 1
mov dword [esp + 0x38], edx
lea eax, [esp + 0x14]
jb 0x52d21b
lea eax, [esp + 0x38]
mov eax, dword [eax]
add eax, edx
lea edx, [esp + 0x14]
push edx
push eax
mov dword [esp + 0x1c], eax
call fcn.005b8aa0
mov edx, eax
mov eax, dword [ebx]
sub edi, eax
mov dword [esp + 0x38], edx
je 0x52d24d
push edi
push eax
push edx
call fcn.00611870
mov edx, dword [esp + 0x44]
add esp, 0xc
add eax, edi
jmp 0x52d250
mov eax, edx
nop
mov ecx, dword [esp + 0x1c]
mov dword [eax], ecx
mov ecx, dword [ebx + 8]
lea edi, [eax + 4]
mov eax, dword [ebx]
sub ecx, eax
sar ecx, 2
test eax, eax
je 0x52d28b
shl ecx, 2
cmp ecx, 0x80
jbe 0x52d27d
push eax
call fcn.00611869
add esp, 4
jmp 0x52d287
push ecx
push eax
call fcn.005d6970
add esp, 8
mov edx, dword [esp + 0x38]
mov eax, dword [esp + 0x14]
lea eax, [edx + eax*4]
mov dword [ebx], edx
mov dword [ebx + 4], edi
mov dword [ebx + 8], eax
mov ecx, dword [ebp + 0xc]
mov edx, dword [ecx + 4]
mov edi, dword [ecx]
mov eax, dword [esp + 0x50]
sub edx, edi
inc eax
sar edx, 3
cmp eax, edx
mov dword [esp + 0x50], eax
jb 0x52d15f
mov eax, dword [ebx + 4]
cmp eax, dword [ebx + 8]
je 0x52d2cf
test eax, eax
je 0x52d2c9
mov ecx, dword [esi + 0x3c]
mov dword [eax], ecx
add dword [ebx + 4], 4
jmp 0x52d2e4
push 1
push 1
lea edx, [esp + 0x3f]
push edx
lea ecx, [esi + 0x3c]
push ecx
push eax
mov ecx, ebx
call fcn.0041cb60
call fcn.006122e1
mov dword [esp + 0x14], eax
fild dword [esp + 0x14]
mov eax, dword [esi + 0xc]
push 1
fmul dword [0x65afe4]
push 0xffffffffffffff9b
sub esp, 0x18
mov ecx, esp
mov dword [esi + 0x10], eax
lea eax, [ecx + 0x10]
fstp dword [esi + 0x38]
mov dword [esi + 0x44], 0
mov dword [esp + 0x34], esp
mov dword [eax], ecx
mov dword [esp + 0x34], ecx
mov dword [ecx + 0x14], eax
push 0x662214
push str.lighting_run
mov byte [esp + 0x104], 0x14
call fcn.00403b50
mov ecx, 0x16c7860
mov byte [esp + 0xfc], 0x13
call fcn.0046b8b0
lea ecx, [esp + 0x8c]
mov byte [esp + 0xdc], 0x12
call fcn.004c5b70
lea ecx, [esp + 0x80]
mov byte [esp + 0xdc], 0xd
call fcn.0052d640
mov ecx, dword [esp + 0xd4]
pop edi
mov eax, esi
pop esi
mov dword fs:[0], ecx
pop ebx
mov esp, ebp
pop ebp
ret 0x10