Function at 0x1005e970
Capabilities:
Get geographical location
Resolve function by parsing pe exports

Disassembly:
push ebx
mov ebx, esp
sub esp, 8
and esp, 0xfffffff8
add esp, 4
push ebp
mov ebp, dword [ebx + 4]
mov dword [esp + 4], ebp
mov ebp, esp
sub esp, 0x70
mov eax, dword [0x10167080]
xor eax, ebp
mov dword [ebp - 4], eax
push esi
mov esi, dword [0x1021abec]
push edi
mov edi, 0x3a
mov eax, dword [esi + 0x199c]
mov byte [eax + 0x78], 1
mov eax, dword [esi + 0x199c]
movss xmm0, dword [eax + 0x1ac]
addss xmm0, dword [0x10151ae0]
movss dword [eax + 0x1ac], xmm0
addss xmm0, dword [eax + 0xc]
addss xmm0, dword [eax + 0x1b4]
movss dword [eax + 0xc4], xmm0
mov eax, dword [esi + 0x199c]
mov byte [eax + 0x78], 1
mov eax, dword [esi + 0x199c]
cmp byte [eax + 0x7b], 0
jne 0x1005eda2
mov ecx, dword [eax + 0x1bc]
xor edx, edx
mov eax, dword [eax + 0x1c4]
push dword [eax + ecx*4 - 4]
mov ecx, str.General_Settings
call fcn.1006c490
add esp, 4
cmp dword [esi + 0x19bc], eax
jne 0x1005ea24
mov dword [esi + 0x19c4], eax
cmp dword [esi + 0x19c0], eax
jne 0x1005ea33
mov byte [esi + 0x19cf], 1
push 0
push str.General_Settings
mov edx, edi
mov ecx, eax
call fcn.100913f0
add esp, 8
test al, al
je 0x1005eda2
mov ecx, dword [0x1021abec]
mov eax, dword [ecx + 0x199c]
mov byte [eax + 0x78], 1
mov eax, dword [ecx + 0x199c]
movss xmm0, dword [eax + 0x1ac]
addss xmm0, dword [0x10151ae0]
movss dword [eax + 0x1ac], xmm0
addss xmm0, dword [eax + 0xc]
addss xmm0, dword [eax + 0x1b4]
movss dword [eax + 0xc4], xmm0
mov eax, dword [ecx + 0x199c]
mov byte [eax + 0x78], 1
mov eax, dword [ecx + 0x199c]
cmp byte [eax + 0x7b], 0
jne 0x1005eb0c
movss xmm1, dword [eax + 0xc8]
lea ecx, [ebp - 0x30]
movss xmm3, dword [eax + 0xc4]
movaps xmm0, xmm1
addss xmm0, dword [0x10151ac0]
movaps xmm2, xmm3
movss dword [ebp - 0x10], xmm1
xorps xmm4, xmm4
movss dword [ebp - 0x14], xmm3
addss xmm2, xmm4
movss dword [ebp - 8], xmm0
subss xmm0, xmm1
xorps xmm1, xmm1
movss dword [ebp - 0xc], xmm2
subss xmm2, xmm3
movss dword [ebp - 0x2c], xmm0
movss dword [ebp - 0x30], xmm2
call fcn.1006ecd0
push 0
xor edx, edx
lea ecx, [ebp - 0x14]
call fcn.1006edf0
add esp, 4
push str.fx_enable
call fcn.100658f0
add esp, 4
mov ecx, str.Enable_FX
lea edx, [eax + 0xc]
call fcn.10082720
push str.r_drawdecals
call fcn.100658f0
add esp, 4
mov ecx, str.Enable_Decals
lea edx, [eax + 0xc]
call fcn.10082720
xor ecx, ecx
call fcn.1006efa0
test al, al
je 0x1005eb76
mov eax, dword [0x1021abec]
cmp byte [eax + 0xec], cl
jne 0x1005eb76
movss xmm0, dword [eax + 0x19b4]
comiss xmm0, dword [0x101519fc]
jbe 0x1005eb76
push str.Assign_material_categories_Decal_and_Dynamic_Decal_to_all_decal_surfaces_nTip:_You_can_disable_Stochachstic_Alpha_Blending_to_select_decals_within_the_world
call fcn.100772c0
add esp, 4
push str.rtx_hacks
call fcn.100658f0
add esp, 4
mov ecx, str.Skybox_hack
lea edx, [eax + 0xc]
call fcn.10082720
xor ecx, ecx
call fcn.1006efa0
test al, al
je 0x1005ebc6
mov eax, dword [0x1021abec]
cmp byte [eax + 0xec], cl
jne 0x1005ebc6
movss xmm0, dword [eax + 0x19b4]
comiss xmm0, dword [0x101519fc]
jbe 0x1005ebc6
push str.Replaces_the_skybox_with_a_placeholder_texture_that_can_be_set_as_sky._nIt_s_recommended_to_keep_this_enabled_
call fcn.100772c0
add esp, 4
push str.rtx_extend_smodel_drawing
call fcn.100658f0
add esp, 4
mov ecx, str.Increase_static_model_limit
lea edx, [eax + 0xc]
call fcn.10082720
xor ecx, ecx
call fcn.1006efa0
test al, al
je 0x1005ec16
mov eax, dword [0x1021abec]
cmp byte [eax + 0xec], cl
jne 0x1005ec16
movss xmm0, dword [eax + 0x19b4]
comiss xmm0, dword [0x101519fc]
jbe 0x1005ec16
push str.The_game_has_a_hard_limit_on_how_many_static_models_it_can_draw_at_once__warning_print_in_console_._nEnabling_this_setting_will_disable_that_limit_but_might_cause_instability.
call fcn.100772c0
add esp, 4
mov edx, dword [0x1020d3a0]
test edx, edx
je 0x1005ec66
add edx, 0xc
mov ecx, str.Disable_Entity_Culling
call fcn.10082720
xor ecx, ecx
call fcn.1006efa0
test al, al
je 0x1005ec66
mov eax, dword [0x1021abec]
cmp byte [eax + 0xec], cl
jne 0x1005ec66
movss xmm0, dword [eax + 0x19b4]
comiss xmm0, dword [0x101519fc]
jbe 0x1005ec66
mov eax, dword [0x1020d3a0]
push dword [eax + 4]
call fcn.100772c0
add esp, 4
mov edx, dword [0x1020d3a4]
test edx, edx
je 0x1005ece4
mov eax, dword [0x1021f0dc]
add edx, 0xc
push ecx
mov dword [esp], 0x3f800000
mov dword [ebp - 0x3c], 3
mov ecx, dword [edx]
mov dword [ebp - 0x34], 0
push dword [eax + ecx*4]
lea eax, [ebp - 0x3c]
mov ecx, str.World_Culling
push eax
lea eax, [ebp - 0x34]
push eax
push edx
xor edx, edx
call fcn.10085a10
add esp, 0x14
xor ecx, ecx
call fcn.1006efa0
test al, al
je 0x1005ece4
mov eax, dword [0x1021abec]
cmp byte [eax + 0xec], cl
jne 0x1005ece4
movss xmm0, dword [eax + 0x19b4]
comiss xmm0, dword [0x101519fc]
jbe 0x1005ece4
mov eax, dword [0x1020d3a4]
push dword [eax + 4]
call fcn.100772c0
add esp, 4
mov ecx, dword [0x1021abec]
mov eax, dword [ecx + 0x199c]
mov byte [eax + 0x78], 1
mov eax, dword [ecx + 0x199c]
movss xmm0, dword [eax + 0x1ac]
subss xmm0, dword [0x10151ae0]
movss dword [eax + 0x1ac], xmm0
addss xmm0, dword [eax + 0xc]
addss xmm0, dword [eax + 0x1b4]
movss dword [eax + 0xc4], xmm0
mov eax, dword [ecx + 0x199c]
mov byte [eax + 0x78], 1
mov eax, dword [ecx + 0x199c]
cmp byte [eax + 0x7b], 0
jne 0x1005eda2
movss xmm1, dword [eax + 0xc8]
lea ecx, [ebp - 0x30]
movss xmm3, dword [eax + 0xc4]
movaps xmm0, xmm1
addss xmm0, dword [0x10151ac0]
movaps xmm2, xmm3
movss dword [ebp - 0x10], xmm1
xorps xmm4, xmm4
movss dword [ebp - 0x14], xmm3
addss xmm2, xmm4
movss dword [ebp - 8], xmm0
subss xmm0, xmm1
xorps xmm1, xmm1
movss dword [ebp - 0xc], xmm2
subss xmm2, xmm3
movss dword [ebp - 0x2c], xmm0
movss dword [ebp - 0x30], xmm2
call fcn.1006ecd0
push 0
xor edx, edx
lea ecx, [ebp - 0x14]
call fcn.1006edf0
add esp, 4
mov esi, dword [0x1021abec]
mov eax, dword [esi + 0x199c]
mov byte [eax + 0x78], 1
mov eax, dword [esi + 0x199c]
cmp byte [eax + 0x7b], 0
jne 0x1005fba4
mov ecx, dword [eax + 0x1bc]
xor edx, edx
mov eax, dword [eax + 0x1c4]
push dword [eax + ecx*4 - 4]
mov ecx, str.Skybox
call fcn.1006c490
add esp, 4
cmp dword [esi + 0x19bc], eax
jne 0x1005edef
mov dword [esi + 0x19c4], eax
cmp dword [esi + 0x19c0], eax
jne 0x1005edfe
mov byte [esi + 0x19cf], 1
push 0
push str.Skybox
mov edx, edi
mov ecx, eax
call fcn.100913f0
add esp, 8
test al, al
je 0x1005fba4
mov ecx, dword [0x1021abec]
mov eax, dword [ecx + 0x199c]
mov byte [eax + 0x78], 1
mov eax, dword [ecx + 0x199c]
movss xmm0, dword [eax + 0x1ac]
addss xmm0, dword [0x10151ae0]
movss dword [eax + 0x1ac], xmm0
addss xmm0, dword [eax + 0xc]
addss xmm0, dword [eax + 0x1b4]
movss dword [eax + 0xc4], xmm0
mov eax, dword [ecx + 0x199c]
mov byte [eax + 0x78], 1
mov eax, dword [ecx + 0x199c]
cmp byte [eax + 0x7b], 0
jne 0x1005eed7
movss xmm1, dword [eax + 0xc8]
lea ecx, [ebp - 0x30]
movss xmm3, dword [eax + 0xc4]
movaps xmm0, xmm1
addss xmm0, dword [0x10151ac0]
movaps xmm2, xmm3
movss dword [ebp - 0x10], xmm1
xorps xmm4, xmm4
movss dword [ebp - 0x14], xmm3
addss xmm2, xmm4
movss dword [ebp - 8], xmm0
subss xmm0, xmm1
xorps xmm1, xmm1
movss dword [ebp - 0xc], xmm2
subss xmm2, xmm3
movss dword [ebp - 0x2c], xmm0
movss dword [ebp - 0x30], xmm2
call fcn.1006ecd0
push 0
xor edx, edx
lea ecx, [ebp - 0x14]
call fcn.1006edf0
add esp, 4
push 0
lea edx, [ebp - 0x30]
mov dword [ebp - 0x30], 0
mov ecx, str.Hill
mov dword [ebp - 0x2c], 0
call fcn.10080c50
add esp, 4
test al, al
je 0x1005ef02
xor ecx, ecx
call fcn.10061250
movss xmm1, dword [0x1013df50]
xorps xmm0, xmm0
call fcn.100770c0
push 0
lea edx, [ebp - 0x30]
mov dword [ebp - 0x30], 0
mov ecx, str.Desert
mov dword [ebp - 0x2c], 0
call fcn.10080c50
add esp, 4
test al, al
je 0x1005ef40
mov ecx, 1
call fcn.10061250
movss xmm1, dword [0x1013df50]
xorps xmm0, xmm0
call fcn.100770c0
push 0
lea edx, [ebp - 0x30]
mov dword [ebp - 0x30], 0
mov ecx, str.City
mov dword [ebp - 0x2c], 0
call fcn.10080c50
add esp, 4
test al, al
je 0x1005ef7e
mov ecx, 2
call fcn.10061250
movss xmm1, dword [0x1013df50]
xorps xmm0, xmm0
call fcn.100770c0
push 0
lea edx, [ebp - 0x30]
mov dword [ebp - 0x30], 0
mov ecx, str.Night
mov dword [ebp - 0x2c], 0
call fcn.10080c50
add esp, 4
test al, al
je 0x1005efbc
mov ecx, 3
call fcn.10061250
movss xmm1, dword [0x1013df50]
xorps xmm0, xmm0
call fcn.100770c0
push 0
lea edx, [ebp - 0x30]
mov dword [ebp - 0x30], 0
mov ecx, str.Overcast
mov dword [ebp - 0x2c], 0
call fcn.10080c50
add esp, 4
test al, al
je 0x1005f1c1
call fcn.10061060
mov dword [ebp - 0x3c], str.rtx_skysphere_overcast
test al, al
je 0x1005f02d
mov eax, dword [ebp - 0x3c]
call dword [0x1014938c]
mov ecx, dword [0x1021e3bc]
mov word [ecx + 0x168], ax
movsx ecx, ax
mov eax, dword [0x1021e3bc]
mov dword [eax + 0x88], ecx
jmp 0x1005f1b7
mov eax, dword [ebp - 0x3c]
call dword [0x1014938c]
mov si, ax
call dword [0x10167f30]
mov dword [0x1021e3bc], eax
mov cx, word [0x1406f00]
mov word [eax + 0x170], cx
mov ecx, dword [0x1021e3bc]
mov word [ecx + 0x168], si
mov eax, dword [0x1021e3bc]
movsx ecx, si
mov dword [eax + 0x88], ecx
mov eax, dword [0x1021e3bc]
mov byte [eax + 0xf6], 4
mov eax, dword [0x1021e3bc]
mov byte [eax + 0xf4], 1
mov eax, dword [0x1021e3bc]
test eax, eax
je 0x1005f1a6
movss xmm0, dword [0x1021e3a8]
movss dword [eax + 0x18], xmm0
movss xmm0, dword [0x1021e3ac]
movss dword [eax + 0x1c], xmm0
movss xmm0, dword [0x1021e3b0]
movss dword [eax + 0x20], xmm0
mov dword [eax + 0xc], 0
mov dword [eax + 0x10], 0
mov dword [eax + 0x14], 0
mov dword [eax + 0x24], 0
mov dword [eax + 0x28], 0
mov dword [eax + 0x2c], 0
movss xmm0, dword [0x1021e3a8]
movss dword [eax + 0x13c], xmm0
movss xmm0, dword [0x1021e3ac]
movss dword [eax + 0x140], xmm0
movss xmm0, dword [0x1021e3b0]
movss dword [eax + 0x144], xmm0
mov eax, dword [0x1021e3bc]
test eax, eax
je 0x1005f1a6
movss xmm0, dword [0x1021e7c8]
movss dword [eax + 0x3c], xmm0
movss xmm0, dword [0x1021e7cc]
movss dword [eax + 0x40], xmm0
movss xmm0, dword [0x1021e7d0]
movss dword [eax + 0x44], xmm0
mov dword [eax + 0x30], 0
mov dword [eax + 0x34], 0
mov dword [eax + 0x38], 0
mov dword [eax + 0x48], 0
mov dword [eax + 0x4c], 0
mov dword [eax + 0x50], 0
movss xmm0, dword [0x1021e7c8]
movss dword [eax + 0x148], xmm0
movss xmm0, dword [0x1021e7cc]
movss dword [eax + 0x14c], xmm0
movss xmm0, dword [0x1021e7d0]
movss dword [eax + 0x150], xmm0
mov eax, dword [0x1021e3bc]
push eax
call dword [0x10167f34]
add esp, 4
mov byte [0x1021e3b8], 1
mov dword [0x1021e3b4], 4
movss xmm1, dword [0x1013df50]
xorps xmm0, xmm0
call fcn.100770c0
push 0
lea edx, [ebp - 0x30]
mov dword [ebp - 0x30], 0
mov ecx, str.Sunset
mov dword [ebp - 0x2c], 0
call fcn.10080c50
add esp, 4
test al, al
je 0x1005f3c6
call fcn.10061060
mov dword [ebp - 0x3c], str.rtx_skysphere_sunset_clouds
test al, al
je 0x1005f232
mov eax, dword [ebp - 0x3c]
call dword [0x1014938c]
mov ecx, dword [0x1021e3bc]
mov word [ecx + 0x168], ax
movsx ecx, ax
mov eax, dword [0x1021e3bc]
mov dword [eax + 0x88], ecx
jmp 0x1005f3bc
mov eax, dword [ebp - 0x3c]
call dword [0x1014938c]
mov si, ax
call dword [0x10167f30]
mov dword [0x1021e3bc], eax
mov cx, word [0x1406f00]
mov word [eax + 0x170], cx
mov ecx, dword [0x1021e3bc]
mov word [ecx + 0x168], si
mov eax, dword [0x1021e3bc]
movsx ecx, si
mov dword [eax + 0x88], ecx
mov eax, dword [0x1021e3bc]
mov byte [eax + 0xf6], 4
mov eax, dword [0x1021e3bc]
mov byte [eax + 0xf4], 1
mov eax, dword [0x1021e3bc]
test eax, eax
je 0x1005f3ab
movss xmm0, dword [0x1021e3a8]
movss dword [eax + 0x18], xmm0
movss xmm0, dword [0x1021e3ac]
movss dword [eax + 0x1c], xmm0
movss xmm0, dword [0x1021e3b0]
movss dword [eax + 0x20], xmm0
mov dword [eax + 0xc], 0
mov dword [eax + 0x10], 0
mov dword [eax + 0x14], 0
mov dword [eax + 0x24], 0
mov dword [eax + 0x28], 0
mov dword [eax + 0x2c], 0
movss xmm0, dword [0x1021e3a8]
movss dword [eax + 0x13c], xmm0
movss xmm0, dword [0x1021e3ac]
movss dword [eax + 0x140], xmm0
movss xmm0, dword [0x1021e3b0]
movss dword [eax + 0x144], xmm0
mov eax, dword [0x1021e3bc]
test eax, eax
je 0x1005f3ab
movss xmm0, dword [0x1021e7c8]
movss dword [eax + 0x3c], xmm0
movss xmm0, dword [0x1021e7cc]
movss dword [eax + 0x40], xmm0
movss xmm0, dword [0x1021e7d0]
movss dword [eax + 0x44], xmm0
mov dword [eax + 0x30], 0
mov dword [eax + 0x34], 0
mov dword [eax + 0x38], 0
mov dword [eax + 0x48], 0
mov dword [eax + 0x4c], 0
mov dword [eax + 0x50], 0
movss xmm0, dword [0x1021e7c8]
movss dword [eax + 0x148], xmm0
movss xmm0, dword [0x1021e7cc]
movss dword [eax + 0x14c], xmm0
movss xmm0, dword [0x1021e7d0]
movss dword [eax + 0x150], xmm0
mov eax, dword [0x1021e3bc]
push eax
call dword [0x10167f34]
add esp, 4
mov byte [0x1021e3b8], 1
mov dword [0x1021e3b4], 5
call fcn.10061060
test al, al
je 0x1005f67f
mov ecx, dword [0x1021abec]
mov eax, dword [ecx + 0x199c]
mov byte [eax + 0x78], 1
mov eax, dword [ecx + 0x199c]
lea esi, [eax + 0x17c]
mov dword [ebp - 0x3c], eax
mov dword [eax + 0x168], 0x42b40000
mov edi, dword [esi + 4]
mov ecx, dword [esi]
cmp ecx, edi
jne 0x1005f42a
inc ecx
test edi, edi
je 0x1005f415
mov eax, edi
cdq
sub eax, edx
sar eax, 1
add eax, edi
jmp 0x1005f41a
mov eax, 8
cmp eax, ecx
cmovg ecx, eax
push ecx
mov ecx, esi
call fcn.1007efa0
mov eax, dword [ebp - 0x3c]
mov edx, dword [esi]
mov ecx, dword [esi + 8]
mov eax, dword [eax + 0x168]
push ecx
mov dword [esp], 0x3f800000
mov dword [ecx + edx*4], eax
lea eax, [ebp - 0x3c]
movss xmm3, dword [0x10151940]
mov edx, 4
inc dword [esi]
mov ecx, str.Sky_Scale
push str._.0f
push eax
lea eax, [ebp - 0x34]
mov dword [ebp - 0x34], 0x3f800000
push eax
push 0x10168554
mov dword [ebp - 0x3c], 0x461c4000
call fcn.10084a10
mov ecx, dword [0x1021abec]
add esp, 0x14
mov eax, dword [ecx + 0x199c]
mov byte [eax + 0x78], 1
mov ecx, dword [ecx + 0x199c]
mov edx, dword [ecx + 0x17c]
sub edx, 1
mov dword [ecx + 0x17c], edx
jne 0x1005f4ad
movss xmm0, dword [ecx + 0x21c]
jmp 0x1005f4b9
mov eax, dword [ecx + 0x184]
movss xmm0, dword [eax + edx*4 - 4]
movss dword [ecx + 0x168], xmm0
mov edx, 0x1021e7d4
mov ecx, str.Auto_Rotation
call fcn.10082720
movss xmm1, dword [0x1013df50]
xorps xmm0, xmm0
call fcn.100770c0
mov ecx, dword [0x1021abec]
mov eax, dword [ecx + 0x199c]
mov byte [eax + 0x78], 1
mov eax, dword [ecx + 0x199c]
lea esi, [eax + 0x17c]
mov dword [ebp - 0x3c], eax
mov dword [eax + 0x168], 0x42b40000
mov edi, dword [esi + 4]
mov ecx, dword [esi]
cmp ecx, edi
jne 0x1005f537
inc ecx
test edi, edi
je 0x1005f522
mov eax, edi
cdq
sub eax, edx
sar eax, 1
add eax, edi
jmp 0x1005f527
mov eax, 8
cmp eax, ecx
cmovg ecx, eax
push ecx
mov ecx, esi
call fcn.1007efa0
mov eax, dword [ebp - 0x3c]
mov edx, dword [esi]
mov ecx, dword [esi + 8]
mov eax, dword [eax + 0x168]
push ecx
mov dword [esp], 0x3f800000
mov dword [ecx + edx*4], eax
lea eax, [ebp - 0x3c]
movss xmm3, dword [0x10151940]
mov edx, 4
inc dword [esi]
mov ecx, str.Speed
push str._.2f
push eax
lea eax, [ebp - 0x34]
mov dword [ebp - 0x34], 0x3c23d70a
push eax
push 0x10168a18
mov dword [ebp - 0x3c], 0x41200000
call fcn.10084a10
mov ecx, dword [0x1021abec]
add esp, 0x14
mov eax, dword [ecx + 0x199c]
mov byte [eax + 0x78], 1
mov ecx, dword [ecx + 0x199c]
mov edx, dword [ecx + 0x17c]
sub edx, 1
mov dword [ecx + 0x17c], edx
jne 0x1005f5ba
movss xmm0, dword [ecx + 0x21c]
jmp 0x1005f5c6
mov eax, dword [ecx + 0x184]
movss xmm0, dword [eax + edx*4 - 4]
mov edx, dword [0x1020d3bc]
movss dword [ecx + 0x168], xmm0
test edx, edx
je 0x1005f5e5
add edx, 0xc
mov ecx, str.Follow_player
call fcn.10082720
push ecx
mov dword [esp], 0x3f800000
lea eax, [ebp - 0x3c]
push str._.2f
push eax
lea eax, [ebp - 0x34]
mov dword [ebp - 0x34], 0xc3b40000
push eax
push ecx
mov dword [esp], 0x3f800000
mov edx, 4
push 3
push 0x1021e3a8
mov ecx, str.Sphere_Origin
mov dword [ebp - 0x3c], 0x43b40000
call fcn.100852d0
add esp, 0x1c
test al, al
je 0x1005f632
call fcn.10061110
push ecx
mov dword [esp], 0x3f800000
lea eax, [ebp - 0x3c]
push str._.2f
push eax
lea eax, [ebp - 0x34]
mov dword [ebp - 0x34], 0xff7fffff
push eax
push ecx
mov dword [esp], 0x3e800000
mov edx, 4
push 3
push 0x1021e7c8
mov ecx, str.Sphere_Rotation
mov dword [ebp - 0x3c], 0x7f7fffff
call fcn.100852d0
add esp, 0x1c
test al, al
je 0x1005f67f
call fcn.10061110
cmp dword [0x1020d3b0], 0
je 0x1005fae6
mov esi, dword [0x1021abec]
mov eax, dword [esi + 0x199c]
mov byte [eax + 0x78], 1
mov eax, dword [esi + 0x199c]
cmp byte [eax + 0x7b], 0
jne 0x1005fae6
mov ecx, dword [eax + 0x1bc]
xor edx, edx
mov eax, dword [eax + 0x1c4]
push dword [eax + ecx*4 - 4]
mov ecx, str.Additional_Sky_Marking
call fcn.1006c490
add esp, 4
cmp dword [esi + 0x19bc], eax
jne 0x1005f6d9
mov dword [esi + 0x19c4], eax
cmp dword [esi + 0x19c0], eax
jne 0x1005f6e8
mov byte [esi + 0x19cf], 1
push 0
push str.Additional_Sky_Marking
mov edx, 0x1a
mov ecx, eax
call fcn.100913f0
add esp, 8
test al, al
je 0x1005fae6
mov edx, dword [0x1020d3b0]
mov ecx, str.Enable_Additional_Sky_Marking
lea edx, [edx + 0xc]
call fcn.10082720
mov esi, dword [0x1020d3b0]
test al, al
je 0x1005f72d
mov al, byte [esi + 0xc]
mov byte [esi + 0x1c], al
mov byte [esi + 0xb], 1
xor ecx, ecx
call fcn.1006efa0
test al, al
je 0x1005f769
mov eax, dword [0x1021abec]
cmp byte [eax + 0xec], cl
jne 0x1005f769
movss xmm0, dword [eax + 0x19b4]
comiss xmm0, dword [0x101519fc]
jbe 0x1005f769
push str.This_can_be_used_to_tell_iw3xo_about_any_custom_skies_it_might_not_have_picked_up_for_replacement
call fcn.100772c0
mov esi, dword [0x1020d3b0]
add esp, 4
cmp byte [esi + 0xc], 0
je 0x1005fae6
mov ecx, dword [0x1021abec]
mov eax, dword [ecx + 0x199c]
mov byte [eax + 0x78], 1
mov eax, dword [ecx + 0x199c]
cmp byte [eax + 0x7b], 0
jne 0x1005f7f4
movss xmm1, dword [eax + 0xc8]
lea ecx, [ebp - 0x30]
movss xmm3, dword [eax + 0xc4]
movaps xmm0, xmm1
addss xmm0, dword [0x10151ac0]
movaps xmm2, xmm3
movss dword [ebp - 0x10], xmm1
xorps xmm4, xmm4
movss dword [ebp - 0x14], xmm3
addss xmm2, xmm4
movss dword [ebp - 8], xmm0
subss xmm0, xmm1
xorps xmm1, xmm1
movss dword [ebp - 0xc], xmm2
subss xmm2, xmm3
movss dword [ebp - 0x2c], xmm0
movss dword [ebp - 0x30], xmm2
call fcn.1006ecd0
push 0
xor edx, edx
lea ecx, [ebp - 0x14]
call fcn.1006edf0
add esp, 4
push str.Map_Material_List
call fcn.1007fea0
mov ecx, dword [0x1021abec]
add esp, 4
cmp dword [0x1016ce9c], 0xf
mov edx, 0x1016ce88
cmova edx, dword [0x1016ce88]
mov eax, dword [ecx + 0x199c]
push 0
push 0
push 0x104000
movss xmm0, dword [eax + 0x14]
lea eax, [ebp - 0x30]
subss xmm0, dword [0x10151b40]
push eax
push dword [0x1016ce98]
movss dword [ebp - 0x30], xmm0
movss xmm0, dword [ecx + 0x18bc]
mov ecx, str.map_mat_list
mulss xmm0, dword [0x10151af8]
movss dword [ebp - 0x2c], xmm0
call fcn.10088cf0
mov eax, dword [0x1021abec]
lea edx, [ebp - 0x30]
add esp, 0x14
mov ecx, str.Refresh_List
mov eax, dword [eax + 0x199c]
push 0
mov dword [ebp - 0x2c], 0x41f00000
movss xmm0, dword [eax + 0x14]
subss xmm0, dword [0x10151b40]
movss dword [ebp - 0x30], xmm0
call fcn.10080c50
add esp, 4
test al, al
jne 0x1005f8aa
cmp dword [0x1016ce98], 0
jne 0x1005f8af
call fcn.10060d70
mov ecx, dword [0x1021abec]
mov eax, dword [ecx + 0x199c]
mov byte [eax + 0x78], 1
mov eax, dword [ecx + 0x199c]
cmp byte [eax + 0x7b], 0
jne 0x1005f930
movss xmm1, dword [eax + 0xc8]
lea ecx, [ebp - 0x30]
movss xmm3, dword [eax + 0xc4]
movaps xmm0, xmm1
addss xmm0, dword [0x10151ac0]
movaps xmm2, xmm3
movss dword [ebp - 0x10], xmm1
xorps xmm4, xmm4
movss dword [ebp - 0x14], xmm3
addss xmm2, xmm4
movss dword [ebp - 8], xmm0
subss xmm0, xmm1
xorps xmm1, xmm1
movss dword [ebp - 0xc], xmm2
subss xmm2, xmm3
movss dword [ebp - 0x2c], xmm0
movss dword [ebp - 0x30], xmm2
call fcn.1006ecd0
push 0
xor edx, edx
lea ecx, [ebp - 0x14]
call fcn.1006edf0
add esp, 4
cmp dword [0x1020d3b8], 0
je 0x1005fae6
mov eax, dword fs:[0x2c]
mov ecx, dword [0x1016f87c]
mov ecx, dword [eax + ecx*4]
mov eax, dword [0x1021f0e8]
cmp eax, dword [ecx + 4]
jle 0x1005f98e
push 0x1021f0e8
call fcn.100d92a4
add esp, 4
cmp dword [0x1021f0e8], 0xffffffff
jne 0x1005f98e
mov eax, dword [0x1020d3b8]
push 0x1021f0e8
mov eax, dword [eax + 0xc]
cmp byte [eax], 0
setne byte [0x1021f0ec]
call fcn.100d9253
add esp, 4
push str.Sky_Materials__editable_._Format__string_string_string_..._
call fcn.1007fea0
mov ecx, dword [0x1021abec]
add esp, 4
mov edx, 0x1021e3c8
mov eax, dword [ecx + 0x199c]
push 0
push 0
push 0x100000
movss xmm0, dword [eax + 0x14]
lea eax, [ebp - 0x30]
subss xmm0, dword [0x10151b40]
push eax
push 0x400
movss dword [ebp - 0x30], xmm0
movss xmm0, dword [ecx + 0x18bc]
mov ecx, str.edit_mats
mulss xmm0, dword [0x10151a9c]
movss dword [ebp - 0x2c], xmm0
call fcn.10088cf0
add esp, 0x14
mov dword [ebp - 0x30], 0
lea edx, [ebp - 0x30]
mov dword [ebp - 0x2c], 0
mov ecx, str.Refresh
push 0
call fcn.10080c50
add esp, 4
test al, al
mov al, byte [0x1021f0ec]
je 0x1005fa1f
test al, al
jne 0x1005fa2c
cmp byte [0x1021e3c0], 0
jne 0x1005fa6c
test al, al
je 0x1005fa6c
push 0x400
push 0
push 0x1021e3c8
mov byte [0x1021e3c0], 1
call fcn.100db190
mov eax, dword [0x1020d3b8]
add esp, 0xc
mov edx, dword [eax + 0xc]
mov ecx, edx
lea esi, [ecx + 1]
mov al, byte [ecx]
inc ecx
test al, al
jne 0x1005fa54
sub ecx, esi
push ecx
push edx
push 0x1021e3c8
call fcn.100dab50
add esp, 0xc
movss xmm1, dword [0x1013df50]
xorps xmm0, xmm0
call fcn.100770c0
push 0
lea edx, [ebp - 0x30]
mov dword [ebp - 0x30], 0
mov ecx, str.Apply
mov dword [ebp - 0x2c], 0
call fcn.10080c50
add esp, 4
test al, al
je 0x1005fae6
push 0x1021e3c8
push str.set_rtx_sky_materials__s
call fcn.10069130
push eax
push 0
push 0
mov eax, 0x4f9ab0
call eax
add esp, 0xc
mov ecx, 0x1021e3c8
mov edx, esp
lea esi, [ecx + 1]
mov dword [edx], 0x1021e3c8
nop
mov al, byte [ecx]
inc ecx
test al, al
jne 0x1005fad0
sub ecx, esi
mov dword [edx + 4], ecx
xor cl, cl
call fcn.10059270
add esp, 8
mov ecx, dword [0x1021abec]
mov eax, dword [ecx + 0x199c]
mov byte [eax + 0x78], 1
mov eax, dword [ecx + 0x199c]
movss xmm0, dword [eax + 0x1ac]
subss xmm0, dword [0x10151ae0]
movss dword [eax + 0x1ac], xmm0
addss xmm0, dword [eax + 0xc]
addss xmm0, dword [eax + 0x1b4]
movss dword [eax + 0xc4], xmm0
mov eax, dword [ecx + 0x199c]
mov byte [eax + 0x78], 1
mov eax, dword [ecx + 0x199c]
cmp byte [eax + 0x7b], 0
jne 0x1005fba4
movss xmm1, dword [eax + 0xc8]
lea ecx, [ebp - 0x30]
movss xmm3, dword [eax + 0xc4]
movaps xmm0, xmm1
addss xmm0, dword [0x10151ac0]
movaps xmm2, xmm3
movss dword [ebp - 0x10], xmm1
xorps xmm4, xmm4
movss dword [ebp - 0x14], xmm3
addss xmm2, xmm4
movss dword [ebp - 8], xmm0
subss xmm0, xmm1
xorps xmm1, xmm1
movss dword [ebp - 0xc], xmm2
subss xmm2, xmm3
movss dword [ebp - 0x2c], xmm0
movss dword [ebp - 0x30], xmm2
call fcn.1006ecd0
push 0
xor edx, edx
lea ecx, [ebp - 0x14]
call fcn.1006edf0
add esp, 4
mov esi, dword [0x1021abec]
mov eax, dword [esi + 0x199c]
mov byte [eax + 0x78], 1
mov eax, dword [esi + 0x199c]
cmp byte [eax + 0x7b], 0
jne 0x10060669
mov ecx, dword [eax + 0x1bc]
xor edx, edx
mov eax, dword [eax + 0x1c4]
push dword [eax + ecx*4 - 4]
mov ecx, str.Debug_Light
call fcn.1006c490
add esp, 4
cmp dword [esi + 0x19bc], eax
jne 0x1005fbf1
mov dword [esi + 0x19c4], eax
cmp dword [esi + 0x19c0], eax
jne 0x1005fc00
mov byte [esi + 0x19cf], 1
push 0
push str.Debug_Light
mov edx, 0x1a
mov ecx, eax
call fcn.100913f0
add esp, 8
test al, al
je 0x10060669
mov ecx, dword [0x1021abec]
mov eax, dword [ecx + 0x199c]
mov byte [eax + 0x78], 1
mov eax, dword [ecx + 0x199c]
movss xmm0, dword [eax + 0x1ac]
addss xmm0, dword [0x10151ae0]
movss dword [eax + 0x1ac], xmm0
addss xmm0, dword [eax + 0xc]
addss xmm0, dword [eax + 0x1b4]
movss dword [eax + 0xc4], xmm0
mov eax, dword [ecx + 0x199c]
mov byte [eax + 0x78], 1
mov eax, dword [ecx + 0x199c]
cmp byte [eax + 0x7b], 0
jne 0x1005fcdc
movss xmm1, dword [eax + 0xc8]
lea ecx, [ebp - 0x30]
movss xmm3, dword [eax + 0xc4]
movaps xmm0, xmm1
addss xmm0, dword [0x10151ac0]
movaps xmm2, xmm3
movss dword [ebp - 0x10], xmm1
xorps xmm4, xmm4
movss dword [ebp - 0x14], xmm3
addss xmm2, xmm4
movss dword [ebp - 8], xmm0
subss xmm0, xmm1
xorps xmm1, xmm1
movss dword [ebp - 0xc], xmm2
subss xmm2, xmm3
movss dword [ebp - 0x2c], xmm0
movss dword [ebp - 0x30], xmm2
call fcn.1006ecd0
push 0
xor edx, edx
lea ecx, [ebp - 0x14]
call fcn.1006edf0
add esp, 4
mov ecx, dword [0x1021abec]
xor edx, edx
mov dword [ebp - 0x3c], edx
mov edi, 0x10168588
nop dword [eax]
mov esi, dword [ecx + 0x199c]
mov ecx, dword [esi + 0x1bc]
add esi, 0x1bc
mov dword [ebp - 0x34], edx
mov edx, 4
mov eax, dword [esi + 8]
push dword [eax + ecx*4 - 4]
lea ecx, [ebp - 0x34]
call fcn.1006c490
mov ecx, dword [esi]
add esp, 4
mov dword [ebp - 0x34], eax
mov eax, dword [esi + 4]
cmp ecx, eax
jne 0x1005fd49
inc ecx
test eax, eax
je 0x1005fd37
cdq
sub eax, edx
sar eax, 1
add eax, dword [esi + 4]
jmp 0x1005fd3c
mov eax, 8
cmp eax, ecx
cmovg ecx, eax
push ecx
mov ecx, esi
call fcn.1007efa0
mov ecx, dword [esi]
mov eax, dword [esi + 8]
push dword [ebp - 0x3c]
mov edx, dword [ebp - 0x34]
push str.Light__d
mov dword [eax + ecx*4], edx
inc dword [esi]
call fcn.10069130
mov esi, dword [0x1021abec]
add esp, 8
mov dword [ebp - 0x34], eax
mov ecx, dword [esi + 0x199c]
mov byte [ecx + 0x78], 1
mov eax, dword [esi + 0x199c]
cmp byte [eax + 0x7b], 0
jne 0x10060589
mov ecx, dword [eax + 0x1bc]
xor edx, edx
mov eax, dword [eax + 0x1c4]
push dword [eax + ecx*4 - 4]
mov ecx, dword [ebp - 0x34]
call fcn.1006c490
add esp, 4
cmp dword [esi + 0x19bc], eax
jne 0x1005fdb4
mov dword [esi + 0x19c4], eax
cmp dword [esi + 0x19c0], eax
jne 0x1005fdc3
mov byte [esi + 0x19cf], 1
cmp dword [ebp - 0x3c], 0
mov ecx, 0x3a
push 0
push dword [ebp - 0x34]
mov edx, 0x1a
cmove edx, ecx
mov ecx, eax
call fcn.100913f0
add esp, 8
test al, al
je 0x10060589
lea esi, [edi - 0x30]
mov byte [ebp - 0x44], 0
mov edx, esi
mov ecx, str.Spawn_light
call fcn.10082720
test al, al
je 0x1005ff0f
cmp byte [edi - 0x2d], 0
mov byte [ebp - 0x44], 1
je 0x1005ff0b
mov esi, dword [0x10167dd8]
mov dword [edi - 0xc], 0x40400000
mov dword [edi - 8], 0x43fa0000
mov eax, dword [esi + 0x46158]
mov dword [edi - 0x24], eax
mov eax, dword [esi + 0x4615c]
mov dword [edi - 0x20], eax
movss xmm0, dword [esi + 0x46160]
addss xmm0, dword [0x10151b4c]
movss dword [edi - 0x1c], xmm0
cmp dword [edi - 0x28], 2
jne 0x1005ff08
movss xmm0, dword [esi + 0x46248]
mulss xmm0, dword [0x10151948]
movss dword [ebp - 0x34], xmm0
call fcn.1000e560
movss dword [ebp - 0x40], xmm0
movss dword [0x1061f108], xmm0
movss xmm0, dword [ebp - 0x34]
call fcn.1000e540
movss dword [0x1061f10c], xmm0
movss xmm0, dword [esi + 0x46244]
mulss xmm0, dword [0x10151948]
movss dword [ebp - 0x34], xmm0
call fcn.1000e560
movss dword [ebp - 0x38], xmm0
movss dword [0x1061f110], xmm0
movss xmm0, dword [ebp - 0x34]
call fcn.1000e540
lea eax, [edi - 4]
movaps xmm2, xmm0
movss dword [0x1061f114], xmm2
lea esi, [edi - 0x30]
test eax, eax
je 0x1005ff0b
movss xmm0, dword [ebp - 0x40]
movaps xmm1, xmm2
mulss xmm1, dword [0x1061f10c]
mulss xmm0, xmm2
movss dword [edi - 4], xmm1
movss dword [edi], xmm0
movss xmm0, dword [ebp - 0x38]
xorps xmm0, xmmword [0x10151fb0]
movss dword [edi + 4], xmm0
jmp 0x1005ff0b
lea esi, [edi - 0x30]
mov byte [edi - 0x2d], 0
cmp byte [esi], 0
jne 0x1005ff76
mov eax, dword [edi - 0x28]
lea ecx, [edi - 0x28]
push ecx
mov dword [esp], 0x3f800000
xor edx, edx
mov dword [ebp - 0x28], str.None
mov dword [ebp - 0x24], str.Point
mov dword [ebp - 0x20], str.Spot
mov dword [ebp - 0x1c], str.Directional
push dword [ebp + eax*4 - 0x28]
lea eax, [ebp - 0x38]
mov dword [ebp - 0x38], 3
push eax
lea eax, [ebp - 0x40]
mov dword [ebp - 0x40], 1
push eax
push ecx
mov ecx, str.Type
call fcn.10085a10
add esp, 0x14
test al, al
je 0x1005ff92
mov byte [edi - 0x2d], 1
mov byte [ebp - 0x44], 1
jmp 0x1005ff92
movss xmm1, dword [0x1013df50]
xorps xmm0, xmm0
call fcn.100770c0
xor edx, edx
mov ecx, str.__Turn_off_the_light_to_change_the_light_type.
call fcn.1007f800
cmp byte [edi - 0x30], 0
je 0x10060589
cmp dword [edi - 0x28], 3
je 0x100601b5
push ecx
mov dword [esp], 0x3f800000
lea eax, [ebp - 0x38]
push str._.3f
push eax
lea eax, [ebp - 0x40]
mov dword [ebp - 0x40], 0
push eax
push ecx
mov dword [esp], 0x3e800000
lea esi, [edi - 0x24]
push 3
push esi
mov edx, 4
mov dword [ebp - 0x38], 0
mov ecx, str.Position
call fcn.100852d0
add esp, 0x1c
lea edx, [ebp - 0x30]
xorps xmm0, xmm0
mov ecx, esi
movlpd qword [ebp - 0x30], xmm0
call fcn.10068d70
test al, al
je 0x100601b5
mov esi, dword [0x1021abec]
lea eax, [ebp - 0x5c]
movsd xmm0, qword [ebp - 0x30]
xorps xmm3, xmm3
movss xmm2, dword [0x10151acc]
push 8
push ecx
movss dword [ebp - 0x5c], xmm0
lea ecx, [esi + 0x1be4]
movss xmm0, dword [ebp - 0x2c]
mov dword [esp], 0x40afede0
push eax
movss dword [ebp - 0x58], xmm0
call fcn.100a8c20
push ecx
mov dword [esp], 0x40800000
lea eax, [esi + 0x1c38]
push 1
push 0xff00ff00
push dword [eax]
lea ecx, [esi + 0x1be4]
mov dword [ebp - 0x38], eax
push dword [esi + 0x1c40]
call fcn.100a7b30
mov esi, dword [ebp - 0x38]
mov ecx, dword [esi + 4]
test ecx, ecx
jns 0x1006008e
mov eax, ecx
cdq
sub eax, edx
sar eax, 1
add eax, ecx
xor ecx, ecx
test eax, eax
cmovg ecx, eax
push ecx
mov ecx, esi
call fcn.1007f620
mov dword [esi], 0
cmp dword [edi - 0x28], 2
jne 0x100601b5
movss xmm1, dword [edi - 4]
xorps xmm0, xmm0
movlpd qword [ebp - 0x4c], xmm0
movss dword [ebp - 0x38], xmm0
movss xmm0, dword [edi]
mulss xmm1, xmm1
mulss xmm0, xmm0
addss xmm0, xmm1
movss xmm1, dword [edi + 4]
mulss xmm1, xmm1
addss xmm0, xmm1
call fcn.10004780
ucomiss xmm0, dword [0x1013df4c]
lahf
test ah, 0x44
jnp 0x10060107
movss xmm1, dword [0x101519fc]
divss xmm1, xmm0
movss xmm0, dword [edi - 4]
movss xmm2, dword [edi]
movss xmm3, dword [edi + 4]
mulss xmm0, xmm1
mulss xmm2, xmm1
mulss xmm3, xmm1
jmp 0x10060112
movss xmm0, dword [ebp - 0x38]
movaps xmm2, xmm0
movaps xmm3, xmm0
movss xmm1, dword [0x10151b08]
lea edx, [ebp - 0x4c]
mulss xmm0, xmm1
lea ecx, [ebp - 0x10]
mulss xmm2, xmm1
addss xmm0, dword [edi - 0x24]
mulss xmm3, xmm1
addss xmm2, dword [edi - 0x20]
addss xmm3, dword [edi - 0x1c]
movss dword [ebp - 0x10], xmm0
movss dword [ebp - 0xc], xmm2
movss dword [ebp - 8], xmm3
call fcn.10068d70
test al, al
je 0x100601a1
movss xmm0, dword [ebp - 0x4c]
lea eax, [ebp - 0x64]
push ecx
mov ecx, dword [0x1021abec]
movss dword [ebp - 0x64], xmm0
add ecx, 0x1be4
movss xmm0, dword [ebp - 0x48]
mov dword [esp], 0x40800000
movss dword [ebp - 0x60], xmm0
movsd xmm0, qword [ebp - 0x30]
push 0xffff8000
push eax
movss dword [ebp - 0x6c], xmm0
lea eax, [ebp - 0x6c]
movss xmm0, dword [ebp - 0x2c]
push eax
movss dword [ebp - 0x68], xmm0
call fcn.100a9350
movss xmm2, dword [0x10151b08]
lea eax, [edi - 0x30]
sub esp, 0x10
push eax
call fcn.10060a70
cmp dword [edi - 0x28], 1
jle 0x1006026c
push ecx
mov dword [esp], 0x3f800000
lea eax, [ebp - 0x38]
push str._.3f
push eax
lea eax, [ebp - 0x40]
mov dword [ebp - 0x40], 0
push eax
push ecx
mov dword [esp], 0x3d4ccccd
lea eax, [edi - 4]
push 3
push eax
mov edx, 4
mov dword [ebp - 0x38], 0
mov ecx, str.Direction
call fcn.100852d0
mov ecx, dword [ebp - 0x44]
add esp, 0x1c
test al, al
movzx ecx, cl
mov esi, 1
cmovne ecx, esi
cmp byte [edi - 0x2f], 0
mov dword [ebp - 0x44], ecx
je 0x10060271
push ecx
mov dword [esp], 0x3f800000
lea eax, [ebp - 0x38]
push str._.3f
push eax
lea eax, [ebp - 0x40]
mov dword [ebp - 0x40], 0
push eax
push ecx
mov dword [esp], 0x3d4ccccd
lea eax, [edi + 8]
push 3
push eax
lea edx, [esi + 3]
mov dword [ebp - 0x38], 0
mov ecx, str.Direction_Offset
call fcn.100852d0
mov ecx, dword [ebp - 0x44]
add esp, 0x1c
test al, al
movzx ecx, cl
cmovne ecx, esi
mov byte [ebp - 0x44], cl
jmp 0x10060271
mov esi, 1
mov eax, dword [edi - 0x28]
cmp eax, 3
je 0x10060373
cmp eax, 2
jne 0x10060324
movss xmm3, dword [0x10151988]
lea eax, [ebp - 0x38]
push ecx
mov dword [esp], 0x3f800000
mov edx, 4
push str._.3f
push eax
lea eax, [ebp - 0x40]
mov dword [ebp - 0x40], 0
push eax
lea eax, [edi + 0x14]
mov dword [ebp - 0x38], 0
push eax
mov ecx, str.Inner_Angle
call fcn.10084a10
mov ecx, dword [ebp - 0x44]
test al, al
movss xmm3, dword [0x10151988]
lea eax, [ebp - 0x38]
movzx ecx, cl
mov edx, 4
cmovne ecx, esi
mov dword [esp + 0x10], 0x3f800000
add esp, 0x10
mov dword [ebp - 0x34], ecx
mov ecx, str.Outer_Angle
mov dword [ebp - 0x40], 0
mov dword [ebp - 0x38], 0
push str._.3f
push eax
lea eax, [ebp - 0x40]
push eax
lea eax, [edi + 0x18]
push eax
call fcn.10084a10
mov ecx, dword [ebp - 0x34]
add esp, 0x14
test al, al
movzx ecx, cl
cmovne ecx, esi
mov byte [ebp - 0x44], cl
movss xmm3, dword [0x10151988]
lea eax, [ebp - 0x38]
push ecx
mov dword [esp], 0x3f800000
mov edx, 4
push str._.3f
push eax
lea eax, [ebp - 0x40]
mov dword [ebp - 0x40], 0
push eax
lea eax, [edi - 8]
mov dword [ebp - 0x38], 0
push eax
mov ecx, str.Range
call fcn.10084a10
mov ecx, dword [ebp - 0x44]
add esp, 0x14
test al, al
movzx ecx, cl
cmovne ecx, esi
mov byte [ebp - 0x44], cl
push 0x1000002
lea edx, [edi - 0x18]
mov ecx, str.Color
call fcn.1008c1a0
mov ecx, dword [ebp - 0x44]
test al, al
movss xmm3, dword [0x10151960]
lea eax, [ebp - 0x38]
mov dword [esp], 0x3f800000
mov edx, 4
push str._.3f
push eax
movzx ecx, cl
lea eax, [ebp - 0x40]
cmovne ecx, esi
mov dword [ebp - 0x40], 0
push eax
lea eax, [edi - 0xc]
mov dword [ebp - 0x34], ecx
push eax
mov ecx, str.Color_Scale
mov dword [ebp - 0x38], 0
call fcn.10084a10
mov ecx, dword [ebp - 0x34]
add esp, 0x14
test al, al
movzx ecx, cl
cmovne ecx, esi
cmp dword [edi - 0x28], 3
mov dword [ebp - 0x34], ecx
je 0x10060539
lea edx, [edi - 0x2f]
mov ecx, str.Attach_light_to_head
call fcn.10082720
test al, al
je 0x10060400
mov byte [edi - 0x2e], 0
movss xmm1, dword [0x10151b08]
xorps xmm0, xmm0
call fcn.100770c0
lea edx, [edi - 0x2e]
mov ecx, str.Attach_light_to_weapon
call fcn.10082720
test al, al
je 0x10060425
mov byte [edi - 0x2f], 0
push 0
lea edx, [ebp - 0x54]
mov dword [ebp - 0x54], 0
mov ecx, str.Move_light_to_player
mov dword [ebp - 0x50], 0
call fcn.10080c50
add esp, 4
test al, al
je 0x10060536
mov esi, dword [0x10167dd8]
mov eax, dword [esi + 0x46158]
mov dword [edi - 0x24], eax
mov eax, dword [esi + 0x4615c]
mov dword [edi - 0x20], eax
movss xmm0, dword [esi + 0x46160]
addss xmm0, dword [0x10151b4c]
movss dword [edi - 0x1c], xmm0
cmp dword [edi - 0x28], 1
jle 0x10060536
movss xmm0, dword [esi + 0x46248]
mulss xmm0, dword [0x10151948]
movss dword [ebp - 0x38], xmm0
call fcn.1000e560
movss dword [ebp - 0x48], xmm0
movss dword [0x1061f108], xmm0
movss xmm0, dword [ebp - 0x38]
call fcn.1000e540
movss dword [ebp - 0x40], xmm0
movss dword [0x1061f10c], xmm0
movss xmm0, dword [esi + 0x46244]
mulss xmm0, dword [0x10151948]
movss dword [ebp - 0x38], xmm0
call fcn.1000e560
movss dword [ebp - 0x2c], xmm0
movss dword [0x1061f110], xmm0
movss xmm0, dword [ebp - 0x38]
call fcn.1000e540
mov ecx, dword [ebp - 0x34]
lea eax, [edi - 4]
movaps xmm1, xmm0
movss dword [0x1061f114], xmm1
test eax, eax
je 0x10060539
movss xmm0, dword [ebp - 0x40]
mulss xmm0, xmm1
movss dword [edi - 4], xmm0
movss xmm0, dword [ebp - 0x48]
mulss xmm0, xmm1
movss dword [edi], xmm0
movss xmm0, dword [ebp - 0x2c]
xorps xmm0, xmmword [0x10151fb0]
movss dword [edi + 4], xmm0
jmp 0x10060539
mov ecx, dword [ebp - 0x34]
test cl, cl
je 0x10060589
mov eax, dword [edi - 0x28]
sub eax, 1
je 0x10060577
sub eax, 1
je 0x10060563
sub eax, 1
jne 0x10060577
movss xmm0, dword [edi + 4]
addss xmm0, dword [0x1015190c]
movss dword [edi + 4], xmm0
jmp 0x10060589
movss xmm0, dword [edi + 0x18]
addss xmm0, dword [0x1015190c]
movss dword [edi + 0x18], xmm0
jmp 0x10060589
movss xmm0, dword [edi - 0x1c]
addss xmm0, dword [0x1015190c]
movss dword [edi - 0x1c], xmm0
mov ecx, dword [0x1021abec]
add edi, 0x4c
mov edx, dword [ebp - 0x3c]
inc edx
mov dword [ebp - 0x3c], edx
mov eax, dword [ecx + 0x199c]
dec dword [eax + 0x1bc]
cmp edi, 0x10168a48
jl 0x1005fcf0
mov eax, dword [ecx + 0x199c]
mov byte [eax + 0x78], 1
mov eax, dword [ecx + 0x199c]
movss xmm0, dword [eax + 0x1ac]
subss xmm0, dword [0x10151ae0]
movss dword [eax + 0x1ac], xmm0
addss xmm0, dword [eax + 0xc]
addss xmm0, dword [eax + 0x1b4]
movss dword [eax + 0xc4], xmm0
mov eax, dword [ecx + 0x199c]
mov byte [eax + 0x78], 1
mov eax, dword [ecx + 0x199c]
cmp byte [eax + 0x7b], 0
jne 0x10060669
movss xmm1, dword [eax + 0xc8]
lea ecx, [ebp - 0x54]
movss xmm3, dword [eax + 0xc4]
movaps xmm0, xmm1
addss xmm0, dword [0x10151ac0]
movaps xmm2, xmm3
movss dword [ebp - 0x24], xmm1
xorps xmm4, xmm4
movss dword [ebp - 0x28], xmm3
addss xmm2, xmm4
movss dword [ebp - 0x1c], xmm0
subss xmm0, xmm1
xorps xmm1, xmm1
movss dword [ebp - 0x20], xmm2
subss xmm2, xmm3
movss dword [ebp - 0x50], xmm0
movss dword [ebp - 0x54], xmm2
call fcn.1006ecd0
push 0
xor edx, edx
lea ecx, [ebp - 0x28]
call fcn.1006edf0
add esp, 4
mov esi, dword [0x1021abec]
mov eax, dword [esi + 0x199c]
mov byte [eax + 0x78], 1
mov eax, dword [esi + 0x199c]
cmp byte [eax + 0x7b], 0
jne 0x10060a4f
mov ecx, dword [eax + 0x1bc]
xor edx, edx
mov eax, dword [eax + 0x1c4]
push dword [eax + ecx*4 - 4]
mov ecx, 0x1014908c
call fcn.1006c490
add esp, 4
cmp dword [esi + 0x19bc], eax
jne 0x100606b6
mov dword [esi + 0x19c4], eax
cmp dword [esi + 0x19c0], eax
jne 0x100606c5
mov byte [esi + 0x19cf], 1
push 0
push 0x1014908c
mov edx, 0x3a
mov ecx, eax
call fcn.100913f0
add esp, 8
test al, al
je 0x10060a4f
mov ecx, dword [0x1021abec]
mov eax, dword [ecx + 0x199c]
mov byte [eax + 0x78], 1
mov eax, dword [ecx + 0x199c]
movss xmm0, dword [eax + 0x1ac]
addss xmm0, dword [0x10151ae0]
movss dword [eax + 0x1ac], xmm0
addss xmm0, dword [eax + 0xc]
addss xmm0, dword [eax + 0x1b4]
movss dword [eax + 0xc4], xmm0
mov eax, dword [ecx + 0x199c]
mov byte [eax + 0x78], 1
mov eax, dword [ecx + 0x199c]
cmp byte [eax + 0x7b], 0
jne 0x100607a1
movss xmm1, dword [eax + 0xc8]
lea ecx, [ebp - 0x54]
movss xmm3, dword [eax + 0xc4]
movaps xmm0, xmm1
addss xmm0, dword [0x10151ac0]
movaps xmm2, xmm3
movss dword [ebp - 0x24], xmm1
xorps xmm4, xmm4
movss dword [ebp - 0x28], xmm3
addss xmm2, xmm4
movss dword [ebp - 0x1c], xmm0
subss xmm0, xmm1
xorps xmm1, xmm1
movss dword [ebp - 0x20], xmm2
subss xmm2, xmm3
movss dword [ebp - 0x50], xmm0
movss dword [ebp - 0x54], xmm2
call fcn.1006ecd0
push 0
xor edx, edx
lea ecx, [ebp - 0x28]
call fcn.1006edf0
add esp, 4
push str.r_lodScaleRigid
call fcn.100658f0
add esp, 4
mov esi, eax
push str.r_lodBiasRigid
call fcn.100658f0
add esp, 4
mov edi, eax
push str.r_lodScaleSkinned
call fcn.100658f0
add esp, 4
mov dword [ebp - 0x38], eax
push str.r_lodBiasSkinned
call fcn.100658f0
movss xmm3, dword [0x10151960]
mov edx, 4
mov dword [ebp - 0x40], eax
mov ecx, str.r_lodScaleRigid
mov dword [esp], 0x3f800000
lea eax, [ebp - 0x2c]
push str._.3f
push eax
lea eax, [ebp - 0x48]
mov dword [ebp - 0x48], 0
push eax
lea eax, [esi + 0xc]
mov dword [ebp - 0x2c], 0
push eax
call fcn.10084a10
movss xmm3, dword [0x10151960]
lea eax, [ebp - 0x2c]
add esp, 0x10
mov edx, 4
mov ecx, str.r_lodBiasRigid
mov dword [ebp - 0x48], 0
mov dword [ebp - 0x2c], 0
mov dword [esp], 0x3f800000
push str._.3f
push eax
lea eax, [ebp - 0x48]
push eax
lea eax, [edi + 0xc]
push eax
call fcn.10084a10
movss xmm3, dword [0x10151960]
lea eax, [ebp - 0x2c]
add esp, 0x10
mov edx, 4
mov ecx, str.r_lodScaleSkinned
mov dword [ebp - 0x48], 0
mov dword [ebp - 0x2c], 0
mov dword [esp], 0x3f800000
push str._.3f
push eax
lea eax, [ebp - 0x48]
push eax
mov eax, dword [ebp - 0x38]
add eax, 0xc
push eax
call fcn.10084a10
movss xmm3, dword [0x10151960]
lea eax, [ebp - 0x2c]
add esp, 0x10
mov edx, 4
mov ecx, str.r_lodBiasSkinned
mov dword [ebp - 0x48], 0
mov dword [ebp - 0x2c], 0
mov dword [esp], 0x3f800000
push str._.3f
push eax
lea eax, [ebp - 0x48]
push eax
mov eax, dword [ebp - 0x40]
add eax, 0xc
push eax
call fcn.10084a10
add esp, 0x14
mov dword [ebp - 0x18], str.High
mov dword [ebp - 0x14], str.Medium
mov dword [ebp - 0x10], 0x1013f940
mov dword [ebp - 0xc], str.Lowest
push str.r_forceLod
mov dword [ebp - 8], str.None
mov dword [ebp - 0x2c], 4
mov dword [ebp - 0x48], 0
call fcn.100658f0
mov ecx, dword [eax + 0xc]
add eax, 0xc
mov dword [esp], 0x3f800000
xor edx, edx
push dword [ebp + ecx*4 - 0x18]
lea ecx, [ebp - 0x2c]
push ecx
lea ecx, [ebp - 0x48]
push ecx
push eax
mov ecx, str.Force_LOD
call fcn.10085a10
mov edx, dword [0x1020d3a8]
add esp, 0x14
mov ecx, str.Force_second_lowest_LOD
lea edx, [edx + 0xc]
call fcn.10082720
xor ecx, ecx
call fcn.1006efa0
mov ecx, dword [0x1021abec]
test al, al
je 0x1006099a
cmp byte [ecx + 0xec], 0
jne 0x1006099a
movss xmm0, dword [ecx + 0x19b4]
comiss xmm0, dword [0x101519fc]
jbe 0x1006099a
mov eax, dword [0x1020d3a8]
push dword [eax + 4]
call fcn.100772c0
mov ecx, dword [0x1021abec]
add esp, 4
mov eax, dword [ecx + 0x199c]
mov byte [eax + 0x78], 1
mov eax, dword [ecx + 0x199c]
movss xmm0, dword [eax + 0x1ac]
subss xmm0, dword [0x10151ae0]
movss dword [eax + 0x1ac], xmm0
addss xmm0, dword [eax + 0xc]
addss xmm0, dword [eax + 0x1b4]
movss dword [eax + 0xc4], xmm0
mov eax, dword [ecx + 0x199c]
mov byte [eax + 0x78], 1
mov eax, dword [ecx + 0x199c]
cmp byte [eax + 0x7b], 0
jne 0x10060a4f
movss xmm4, dword [eax + 0xc4]
lea ecx, [ebp - 0x54]
movss xmm2, dword [eax + 0xc8]
movaps xmm3, xmm4
xorps xmm1, xmm1
movss dword [ebp - 0x28], xmm4
movaps xmm0, xmm2
movss dword [ebp - 0x24], xmm2
addss xmm0, dword [0x10151ac0]
addss xmm3, xmm1
movss dword [ebp - 0x1c], xmm0
subss xmm0, xmm2
movss dword [ebp - 0x20], xmm3
subss xmm3, xmm4
movss dword [ebp - 0x50], xmm0
movss dword [ebp - 0x54], xmm3
call fcn.1006ecd0
push 0
xor edx, edx
lea ecx, [ebp - 0x28]
call fcn.1006edf0
add esp, 4
mov ecx, dword [ebp - 4]
pop edi
xor ecx, ebp
pop esi
call fcn.100d8e9a
mov esp, ebp
pop ebp
mov esp, ebx
pop ebx
ret