Function at 0x41a070
Capabilities:
Read .ini file

Disassembly:
sub esp, 0x1c
push ebx
push ebp
push esi
mov dword [esp + 0x10], ecx
push edi
mov ecx, 0x7cb478
mov byte [esp + 0x13], 0
call fcn.004d51b0
mov edi, dword [sym.imp.KERNEL32.dll_GetPrivateProfileStringA]
push str..Morrowind.ini
push 0x200
mov esi, eax
push esi
push 0x7c6180
push str.Cell_0
push str.PreLoad
call edi
mov eax, dword [0x7c67e0]
mov ecx, dword [eax]
push esi
call fcn.004ba9b0
mov ecx, dword [0x7c67dc]
mov dword [ecx + 0x32c], eax
mov eax, dword [0x7c67dc]
mov ecx, dword [eax + 0x32c]
xor ebx, ebx
cmp ecx, ebx
je 0x41a0dd
mov byte [esp + 0x13], 1
push str..Morrowind.ini
push 0x200
push esi
push 0x7c6180
push str.Starting_Cell
push str.General
mov dword [eax + 0x32c], ebx
call edi
mov ebp, dword [sym.imp.KERNEL32.dll_GetPrivateProfileIntA]
or ecx, 0xffffffff
xor eax, eax
mov edi, esi
repne scasb al, byte es:[edi]
not ecx
dec ecx
je 0x41a253
mov ecx, dword [0x7c67dc]
cmp dword [ecx + 0x364], ebx
je 0x41a240
call fcn.0040ff20
test eax, eax
je 0x41a1ef
mov ecx, dword [0x7c67dc]
call fcn.0040ff20
mov edx, dword [eax + 0x10]
shr edx, 0xa
test dl, 1
je 0x41a1ef
mov ecx, dword [0x7c67dc]
call fcn.0040ff20
mov edx, dword [eax]
mov ecx, eax
call dword [edx + 0xac]
test al, al
jne 0x41a1ef
mov eax, dword [0x7c67dc]
mov ecx, dword [eax + 0x35c]
cmp ecx, ebx
je 0x41a181
call fcn.004098d0
mov ecx, dword [0x7c67dc]
mov ecx, dword [ecx + 0x364]
push 0x3f800000
call fcn.004098f0
mov edx, dword [0x7c67dc]
mov ecx, dword [edx + 0x364]
call fcn.00409890
mov eax, dword [0x7c67dc]
lea ecx, [eax + 0x2c0]
mov eax, dword [eax + 0xa0]
mov dword [esp + 0x18], eax
mov dword [esp + 0x1c], ebx
fild qword [esp + 0x18]
fstp dword [ecx + 8]
call fcn.00404960
mov eax, dword [0x7c67dc]
mov edx, dword [eax + 0xa0]
mov dword [esp + 0x18], edx
mov dword [esp + 0x1c], ebx
fild qword [esp + 0x18]
lea ecx, [eax + 0x134]
fstp dword [ecx + 8]
jmp 0x41a23b
mov eax, dword [0x7c67dc]
mov ecx, dword [eax + 0x35c]
cmp ecx, ebx
je 0x41a203
call fcn.00409890
mov ecx, dword [0x7c67dc]
mov ecx, dword [ecx + 0x364]
call fcn.004098d0
mov edx, dword [0x7c67dc]
lea ecx, [edx + 0x2c0]
mov edi, 0x42960000
mov dword [ecx + 8], edi
call fcn.00404960
mov eax, dword [0x7c67dc]
lea ecx, [eax + 0x134]
mov dword [ecx + 8], edi
call fcn.00404960
mov ecx, dword [0x7c67e0]
mov ecx, dword [ecx]
push esi
call fcn.004ba9b0
jmp 0x41a3c2
push str..Morrowind.ini
push ebx
push str.Starting_Grid_X
push str.General
call ebp
push str..Morrowind.ini
push ebx
push str.Starting_Grid_Y
push str.General
mov esi, eax
call ebp
test esi, esi
mov ebx, eax
jne 0x41a287
test ebx, ebx
je 0x41a3ce
mov ecx, dword [0x7c67dc]
mov eax, dword [ecx + 0x364]
xor edi, edi
cmp eax, edi
je 0x41a3b3
call fcn.0040ff20
test eax, eax
je 0x41a362
mov ecx, dword [0x7c67dc]
call fcn.0040ff20
mov eax, dword [eax + 0x10]
shr eax, 0xa
test al, 1
je 0x41a362
mov ecx, dword [0x7c67dc]
call fcn.0040ff20
mov edx, dword [eax]
mov ecx, eax
call dword [edx + 0xac]
test al, al
jne 0x41a362
mov eax, dword [0x7c67dc]
mov ecx, dword [eax + 0x35c]
cmp ecx, edi
je 0x41a2f4
call fcn.004098d0
mov ecx, dword [0x7c67dc]
mov ecx, dword [ecx + 0x364]
push 0x3f800000
call fcn.004098f0
mov edx, dword [0x7c67dc]
mov ecx, dword [edx + 0x364]
call fcn.00409890
mov eax, dword [0x7c67dc]
lea ecx, [eax + 0x2c0]
mov eax, dword [eax + 0xa0]
mov dword [esp + 0x18], eax
mov dword [esp + 0x1c], edi
fild qword [esp + 0x18]
fstp dword [ecx + 8]
call fcn.00404960
mov eax, dword [0x7c67dc]
mov edx, dword [eax + 0xa0]
mov dword [esp + 0x18], edx
mov dword [esp + 0x1c], edi
fild qword [esp + 0x18]
lea ecx, [eax + 0x134]
fstp dword [ecx + 8]
jmp 0x41a3ae
mov eax, dword [0x7c67dc]
mov ecx, dword [eax + 0x35c]
cmp ecx, edi
je 0x41a376
call fcn.00409890
mov ecx, dword [0x7c67dc]
mov ecx, dword [ecx + 0x364]
call fcn.004098d0
mov edx, dword [0x7c67dc]
lea ecx, [edx + 0x2c0]
mov edi, 0x42960000
mov dword [ecx + 8], edi
call fcn.00404960
mov eax, dword [0x7c67dc]
lea ecx, [eax + 0x134]
mov dword [ecx + 8], edi
call fcn.00404960
mov ecx, dword [0x7c67e0]
mov ecx, dword [ecx]
push ebx
push esi
call fcn.004baa10
mov edx, dword [0x7c67dc]
mov dword [edx + 0x32c], eax
mov eax, dword [0x7c67dc]
mov ecx, dword [eax + 0x32c]
test ecx, ecx
jne 0x41a449
mov cl, byte [esp + 0x13]
test cl, cl
je 0x41a449
mov byte [eax + 0xd6], 1
mov eax, dword [0x7c67dc]
mov byte [eax + 0xd4], 1
mov ecx, dword [0x7c67dc]
push 0
mov byte [ecx + 0xd5], 0
call fcn.005fc540
xor edx, edx
mov dx, word [0x7d4f10]
push edx
call fcn.00595370
push eax
call fcn.00595350
mov eax, dword [0x7c67dc]
mov ecx, dword [eax + 0x50]
mov eax, dword [ecx + 0x14]
add esp, 0xc
cmp eax, 0xffffffff
jne 0x41a6f6
push 0
push 0
call fcn.00408620
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x1c
ret
mov ecx, dword [esp + 0x14]
call fcn.00419a90
push str.Loading_Starting_Cell
call fcn.00477fa0
mov ecx, dword [0x7c67dc]
mov edx, dword [ecx + 0xc0]
mov dword [edx + 0x34], 0xbf800000
mov ecx, dword [0x7c67dc]
add esp, 4
call fcn.0040ff20
mov ecx, eax
call fcn.0052c9b0
mov eax, dword [0x7c67dc]
mov ecx, dword [eax + 0x32c]
test ecx, ecx
je 0x41a6be
call fcn.004e22f0
test al, al
mov ecx, dword [0x7c67dc]
je 0x41a5c2
mov ecx, dword [ecx + 0x32c]
call fcn.004e2320
test al, al
jne 0x41a4c7
mov edx, dword [0x7c67dc]
mov ecx, dword [edx + 0x58]
call fcn.00440870
mov eax, dword [0x7c67dc]
mov ecx, dword [eax + 0x32c]
call fcn.004dd650
mov ecx, dword [0x7c67dc]
mov ecx, dword [ecx + 0x32c]
push 1
push str.DoorMarker
call fcn.004dbbc0
test eax, eax
jne 0x41a527
mov edx, dword [0x7c67dc]
mov ecx, dword [edx + 0x32c]
push 1
push 0x54415453
call fcn.004dbef0
test eax, eax
jne 0x41a527
mov eax, dword [0x7c67dc]
mov ecx, dword [eax + 0x32c]
call fcn.004dbb80
test eax, eax
je 0x41a5b0
mov ecx, dword [0x7c67dc]
mov edx, dword [eax + 0x38]
lea esi, [eax + 0x38]
mov eax, dword [ecx + 0x130]
mov dword [eax + 0x30], edx
mov ecx, dword [esi + 4]
add eax, 0x30
mov dword [eax + 4], ecx
mov edx, dword [esi + 8]
mov dword [eax + 8], edx
mov eax, dword [0x7c67dc]
mov eax, dword [eax + 0x15c]
mov ecx, dword [esi]
add eax, 0x30
mov dword [eax], ecx
mov edx, dword [esi + 4]
mov dword [eax + 4], edx
mov ecx, dword [esi + 8]
mov dword [eax + 8], ecx
mov ecx, dword [0x7c67dc]
call fcn.0040ff20
mov edx, dword [eax]
push esi
mov ecx, eax
call dword [edx + 0x40]
mov eax, dword [0x7c67dc]
mov ecx, dword [eax + 0x32c]
push esi
push ecx
mov ecx, dword [0x7c67e0]
call fcn.00489050
mov edx, dword [0x7c67dc]
xor eax, eax
mov al, byte [edx + 0xd9]
push eax
call fcn.0041c780
add esp, 4
jmp 0x41a6be
push str.Cannot_start_in_an_empty_interior_cell_
call fcn.00476e20
add esp, 4
jmp 0x41a6be
mov eax, dword [ecx + 0x130]
mov edx, dword [eax + 0x30]
add eax, 0x30
mov dword [esp + 0x20], edx
mov edx, dword [eax + 4]
mov dword [esp + 0x24], edx
mov eax, dword [eax + 8]
mov dword [esp + 0x28], eax
mov ecx, dword [ecx + 0x32c]
call fcn.004db9d0
mov ecx, dword [0x7c67dc]
shl eax, 0xd
mov dword [esp + 0x14], eax
fild dword [esp + 0x14]
fstp dword [esp + 0x20]
mov ecx, dword [ecx + 0x32c]
call fcn.004db9f0
push str..Morrowind.ini
shl eax, 0xd
mov dword [esp + 0x18], eax
fild dword [esp + 0x18]
push 0x1000
push str.Starting_Offset_X
push str.General
fstp dword [esp + 0x34]
call ebp
push str..Morrowind.ini
push 0x1000
push str.Starting_Offset_Y
push str.General
mov dword [esp + 0x24], eax
call ebp
fild dword [esp + 0x14]
mov edx, dword [0x7c67dc]
mov dword [esp + 0x18], eax
fadd dword [esp + 0x20]
fst dword [esp + 0x20]
fild dword [esp + 0x18]
fadd dword [esp + 0x24]
fstp dword [esp + 0x24]
mov eax, dword [edx + 0x130]
add eax, 0x30
fstp dword [eax]
mov ecx, dword [esp + 0x24]
mov dword [eax + 4], ecx
mov edx, dword [esp + 0x28]
mov dword [eax + 8], edx
mov eax, dword [0x7c67dc]
mov eax, dword [eax + 0x15c]
mov ecx, dword [esp + 0x20]
add eax, 0x30
mov dword [eax], ecx
mov edx, dword [esp + 0x24]
mov dword [eax + 4], edx
mov ecx, dword [esp + 0x28]
mov dword [eax + 8], ecx
mov ecx, dword [0x7c67dc]
call fcn.0040ff20
mov edx, dword [eax]
lea ecx, [esp + 0x20]
push ecx
mov ecx, eax
call dword [edx + 0x40]
mov edx, dword [0x7c67dc]
mov eax, dword [edx + 0x130]
mov ecx, dword [0x7c67e0]
push 0
add eax, 0x30
push eax
call fcn.00485610
mov ecx, dword [0x7c67dc]
mov ecx, dword [ecx + 0x5c]
call fcn.00563ce0
push str.Done_Loading_Starting_Cell
call fcn.00477fa0
add esp, 4
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x1c
ret