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

Disassembly:
sub esp, 0x5c
mov eax, dword [0x6a2d00]
mov ecx, dword [eax + 0x174]
xor edx, edx
test ecx, ecx
setl dl
push ebx
push ebp
push esi
mov esi, dword [eax + 0xa4]
push edi
mov edi, dword [eax + 0x80]
sub edx, 1
and edx, ecx
mov ecx, dword [eax + 0x7c]
mov dword [esp + 0x34], edx
xor edx, edx
test ecx, ecx
setl dl
push 0
mov dword [esp + 0x18], 0
mov dword [esp + 0x34], esi
mov dword [esp + 0x40], edi
mov dword [esp + 0x44], esi
mov dword [esp + 0x5c], edi
sub edx, 1
and edx, ecx
mov dword [esp + 0x3c], edx
mov edx, dword [eax + 0xa8]
mov eax, dword [eax + 0x78]
mov dword [esp + 0x48], edx
xor edx, edx
test eax, eax
setl dl
mov dword [esp + 0x60], esi
sub edx, 1
and edx, eax
xor eax, eax
test ecx, ecx
setl al
mov dword [esp + 0x4c], edx
sub eax, 1
and eax, ecx
mov dword [esp + 0x58], eax
call sym.convertifd.exe_MFontSetMode
mov eax, dword [0x6a2d00]
mov ecx, dword [eax + 0x70]
mov edx, dword [eax + 0x74]
push 1
mov dword [esp + 0x30], ecx
mov dword [esp + 0x34], edx
call sym.convertifd.exe_MFontSetMode
mov eax, dword [0x6a2d00]
mov ecx, dword [eax + 0x70]
mov edx, dword [eax + 0xa0]
mov eax, dword [esp + 0x78]
mov edi, dword [esp + 0x7c]
push eax
push edi
mov dword [esp + 0x5c], ecx
mov dword [esp + 0x60], edx
call sym.convertifd.exe_PointToEntity
mov ebp, eax
mov eax, dword [ebp]
mov ecx, dword [ebp + 4]
shr eax, 1
push ecx
and eax, 1
push edi
mov dword [esp + 0x38], ebp
mov dword [esp + 0x34], eax
call sym.convertifd.exe_PointToEntity
add esp, 0x18
cmp dword [ebp + 0x20], 0
mov ebx, eax
mov dword [esp + 0x60], ebx
jne 0x495f5b
push edi
push 0xb
push 0
call sym.convertifd.exe_AddEntity
add esp, 0xc
test eax, eax
mov dword [ebp + 0x20], eax
jl 0x495fb6
push 1
push edi
push eax
call sym.convertifd.exe_HideEntity
add esp, 0xc
mov edx, dword [ebp + 0x20]
push edx
push edi
call sym.convertifd.exe_PointToEntity
mov esi, eax
call sym.convertifd.exe_GetTableGroupName
push eax
push esi
call sym.convertifd.exe_StrcpyFarToFar
mov eax, dword [ebx]
mov dword [esi + 0x18], eax
mov ecx, dword [ebx + 4]
mov ebx, dword [esp + 0x88]
mov eax, dword [esi + 0x24]
add ebx, ebx
add esp, 0x10
add ebx, ebx
test eax, eax
mov dword [esi + 0x1c], ecx
jne 0x495feb
push ebx
push 1
lea edx, [esp + 0x2c]
push 4
push edx
call sym.convertifd.exe_UtMTable
add esp, 0x10
test eax, eax
jne 0x495fc0
mov eax, dword [ebp + 0x1c]
push edi
push eax
call sym.convertifd.exe_DeleteEntity
add esp, 8
pop edi
pop esi
pop ebp
xor eax, eax
pop ebx
add esp, 0x5c
ret
mov ecx, dword [esp + 0x78]
mov edx, dword [esp + 0x24]
shl ecx, 4
push ecx
push 0
push edx
call fcn.00511e90
mov eax, dword [esp + 0x30]
add esp, 0xc
mov dword [esi + 0x24], eax
mov dword [esp + 0x1c], 1
jmp 0x4960ea
mov dword [esp + 0x10], eax
mov eax, dword [esi + 0x20]
lea ecx, [ebx - 1]
cmp eax, ecx
jge 0x49604d
lea ecx, [esp + 0x10]
push ebx
push ecx
call sym.convertifd.exe_UtATable
add esp, 8
test eax, eax
jne 0x496022
mov edx, dword [ebp + 0x20]
push edi
push edx
call sym.convertifd.exe_DeleteEntity
add esp, 8
pop edi
pop esi
pop ebp
xor eax, eax
pop ebx
add esp, 0x5c
ret
mov eax, dword [esi + 0x20]
mov edx, dword [esp + 0x10]
mov ecx, ebx
sub ecx, eax
add ecx, ecx
add ecx, ecx
push ecx
lea eax, [edx + eax*4]
push 0
push eax
call fcn.00511e90
add esp, 0xc
mov dword [esp + 0x1c], 1
jmp 0x4960e3
cmp eax, ebx
jl 0x4960ea
push ebx
push 1
lea edx, [esp + 0x18]
push 4
push edx
call sym.convertifd.exe_UtMTable
add esp, 0x10
test eax, eax
jne 0x496082
mov eax, dword [ebp + 0x20]
push edi
push eax
call sym.convertifd.exe_DeleteEntity
add esp, 8
pop edi
pop esi
pop ebp
xor eax, eax
pop ebx
add esp, 0x5c
ret
mov ecx, dword [esp + 0x78]
mov edx, dword [esi + 0x24]
mov eax, dword [esp + 0x10]
shl ecx, 4
push ecx
push edx
push eax
call fcn.005154f0
lea ecx, [ebx - 1]
add esp, 0xc
cmp ecx, dword [esi + 0x20]
mov dword [esp + 0x18], ecx
jge 0x4960d7
mov dword [esp + 0x1c], 1
nop
mov edx, dword [esi + 0x24]
mov eax, dword [edx + ecx*4]
cdq
xor eax, edx
sub eax, edx
je 0x4960cb
push edi
push eax
call sym.convertifd.exe_DeleteEntity
mov ecx, dword [esp + 0x20]
add esp, 8
add ecx, 1
cmp ecx, dword [esi + 0x20]
mov dword [esp + 0x18], ecx
jl 0x4960b0
mov eax, dword [esi + 0x24]
push eax
call sym.convertifd.exe_UtFTable
add esp, 4
mov ecx, dword [esp + 0x10]
mov dword [esi + 0x24], ecx
mov ecx, dword [esp + 0x60]
mov eax, dword [ecx + 8]
sub eax, dword [ecx]
add ebx, 0xffffffff
cdq
idiv dword [esp + 0x78]
mov dword [ebp + 0x10], eax
mov dword [esi + 0x20], ebx
call sym.convertifd.exe_SetAutoFieldName
cmp dword [esp + 0x78], 0
mov dword [esp + 0x18], 0
jle 0x4965ca
mov ebx, 4
mov dword [esp + 0x64], 2
mov dword [esp + 0x24], ebx
jmp 0x496134
mov ebx, dword [esp + 0x24]
mov edx, dword [esi + 0x24]
mov eax, dword [edx + ebx - 4]
test eax, eax
lea ecx, [edx + ebx - 4]
jne 0x4961aa
push edi
push 5
push eax
call sym.convertifd.exe_AddEntity
mov ecx, dword [esi + 0x24]
mov dword [ebx + ecx - 4], eax
mov edx, dword [esi + 0x24]
mov eax, dword [ebx + edx - 4]
add esp, 0xc
test eax, eax
jl 0x495fb6
push eax
push edi
call sym.convertifd.exe_PointToEntity
mov ecx, dword [esp + 0x30]
mov edx, dword [esp + 0x34]
mov dword [eax + 0x1c], ecx
mov ecx, dword [esp + 0x38]
mov dword [eax + 0x20], edx
mov edx, dword [esp + 0x3c]
mov dword [eax + 0x3c], ecx
mov dword [eax + 0x24], 5
mov dword [eax + 0x44], edx
mov byte [eax + 8], 0
mov dword [eax + 0x40], 0xffffffff
mov ecx, dword [ebp + 0x10]
add esp, 8
add ecx, dword [esp + 0x14]
mov dword [esp + 0x10], ecx
jmp 0x4961f7
cdq
xor eax, edx
sub eax, edx
mov dword [ecx], eax
mov eax, dword [esi + 0x24]
mov ecx, dword [eax + ebx - 4]
push ecx
push edi
call sym.convertifd.exe_PointToEntity
mov edx, dword [eax + 0x1c]
mov ecx, dword [eax + 0x20]
mov dword [esp + 0x30], edx
mov edx, dword [eax + 0x3c]
mov dword [esp + 0x34], ecx
mov ecx, dword [eax + 0x44]
add esp, 8
cmp dword [esp + 0x1c], 0
mov dword [esp + 0x30], edx
mov dword [esp + 0x34], ecx
je 0x4961ee
mov ecx, dword [ebp + 0x10]
add ecx, dword [esp + 0x14]
jmp 0x4961f3
mov ecx, dword [eax + 0xc]
add ecx, dword [eax]
mov dword [esp + 0x10], ecx
mov edx, dword [esp + 0x14]
sub ecx, edx
mov dword [eax], edx
mov dword [eax + 4], 0
mov dword [eax + 0xc], ecx
mov edx, dword [ebp + 8]
mov dword [eax + 0x10], edx
mov dword [eax + 0x58], 1
mov eax, dword [esi + 0x24]
push 1
mov dword [esp + 0x6c], ecx
mov ecx, dword [eax + ebx - 4]
push edi
push ecx
call sym.convertifd.exe_HideEntity
mov edx, dword [esi + 0x24]
mov eax, dword [edx + ebx]
lea ecx, [edx + ebx]
add esp, 0xc
test eax, eax
jne 0x496286
push edi
push 2
push eax
call sym.convertifd.exe_AddEntity
mov ecx, dword [esi + 0x24]
mov dword [ebx + ecx], eax
mov edx, dword [esi + 0x24]
mov eax, dword [ebx + edx]
add esp, 0xc
test eax, eax
jl 0x495fb6
push eax
push edi
call sym.convertifd.exe_PointToEntity
mov ecx, dword [esp + 0x40]
mov edx, dword [esp + 0x44]
mov dword [eax + 0x14], ecx
mov ecx, dword [esp + 0x48]
mov dword [eax + 0x10], edx
mov edx, dword [esp + 0x4c]
mov dword [eax + 0x20], ecx
mov ecx, dword [esp + 0x50]
mov dword [eax + 0x24], edx
mov dword [eax + 0x18], ecx
jmp 0x4962bd
cdq
xor eax, edx
sub eax, edx
mov dword [ecx], eax
mov edx, dword [esi + 0x24]
mov eax, dword [edx + ebx]
push eax
push edi
call sym.convertifd.exe_PointToEntity
mov ecx, dword [eax + 0x14]
mov edx, dword [eax + 0x10]
mov dword [esp + 0x40], ecx
mov ecx, dword [eax + 0x20]
mov dword [esp + 0x44], edx
mov edx, dword [eax + 0x24]
mov dword [esp + 0x48], ecx
mov ecx, dword [eax + 0x18]
mov dword [esp + 0x4c], edx
mov dword [esp + 0x50], ecx
mov edx, dword [esp + 0x1c]
mov ecx, dword [esp + 0x18]
mov dword [eax], edx
mov edx, dword [esp + 0x28]
mov dword [eax + 8], ecx
mov dword [eax + 4], 0
mov ecx, dword [edx + 8]
add esp, 8
mov dword [eax + 0xc], ecx
mov edx, dword [esi + 0x24]
mov eax, dword [edx + ebx]
push 1
push edi
push eax
call sym.convertifd.exe_HideEntity
mov ecx, dword [esi + 0x24]
add ebx, 4
mov eax, dword [ecx + ebx]
add ecx, ebx
add esp, 0xc
test eax, eax
jne 0x496351
push edi
push 5
push eax
call sym.convertifd.exe_AddEntity
mov edx, dword [esi + 0x24]
mov dword [ebx + edx], eax
mov eax, dword [esi + 0x24]
mov eax, dword [ebx + eax]
add esp, 0xc
test eax, eax
jl 0x495fb6
push eax
push edi
call sym.convertifd.exe_PointToEntity
mov ecx, dword [esp + 0x54]
mov ebp, eax
mov eax, dword [esp + 0x58]
add esp, 8
xor edx, edx
mov dword [ebp + 0x1c], ecx
mov dword [ebp + 0x20], edx
mov dword [ebp + 0x24], eax
mov dword [ebp + 0x3c], edx
mov dword [ebp + 0x44], edx
mov dword [ebp + 0x40], 0xffffffff
mov byte [ebp + 8], 1
jmp 0x49637a
cdq
xor eax, edx
sub eax, edx
mov dword [ecx], eax
mov ecx, dword [esi + 0x24]
mov edx, dword [ecx + ebx]
push edx
push edi
call sym.convertifd.exe_PointToEntity
mov ebp, eax
mov eax, dword [ebp + 0x1c]
mov ecx, dword [ebp + 0x24]
add esp, 8
mov dword [esp + 0x4c], eax
mov dword [esp + 0x50], ecx
xor edx, edx
mov eax, dword [esp + 0x14]
mov ecx, dword [esp + 0x20]
mov dword [ebp], eax
test byte [ecx], 4
je 0x49638f
mov eax, dword [ecx + 8]
jmp 0x496391
xor eax, eax
mov dword [ebp + 4], eax
mov eax, dword [esp + 0x68]
mov dword [ebp + 0xc], eax
test byte [ecx], 1
je 0x4963a8
mov ecx, dword [ecx + 0xc]
mov dword [ebp + 0x10], ecx
jmp 0x4963ab
mov dword [ebp + 0x10], edx
cmp dword [esp + 0x1c], edx
je 0x4963b4
mov dword [ebp + 0x5c], edx
lea edx, [ebp + 0x14]
push edx
mov edx, dword [ebp + 0x1c]
lea ecx, [ebp + 0x5c]
push ecx
push eax
push edx
call sym.convertifd.exe_SetTableFieldWidth
mov eax, dword [esp + 0x30]
add esp, 0x10
test byte [eax], 1
je 0x4963f2
mov eax, dword [ebp + 0x28]
lea ecx, [ebp + 0x18]
push ecx
mov ecx, dword [ebp + 0x10]
lea edx, [ebp + 0x58]
push edx
mov edx, dword [ebp + 0x1c]
push eax
push ecx
push edx
call sym.convertifd.exe_SetTableFieldHeight
add esp, 0x14
xor eax, eax
jmp 0x4963fa
xor eax, eax
mov dword [ebp + 0x58], eax
mov dword [ebp + 0x18], eax
cmp dword [ebp + 0x40], eax
jge 0x4964c3
mov ecx, dword [0x6a2d00]
mov dword [ecx + 0x184], eax
mov edx, dword [0x6a2d00]
mov dword [edx + 0x14c], eax
mov ecx, dword [0x6a2d00]
mov dword [ecx + 0x150], eax
mov edx, dword [0x6a2d00]
mov dword [edx + 0x158], eax
mov ecx, dword [0x6a2d00]
mov dword [ecx + 0x128], eax
mov edx, dword [0x6a2d00]
mov dword [edx + 0x170], eax
mov ecx, dword [0x6a2d00]
mov dword [ecx + 0x160], eax
mov edx, dword [0x6a2d00]
mov dword [edx + 0x210], eax
mov ecx, dword [0x6a2d00]
mov dword [ecx + 0x168], eax
mov edx, dword [0x6a2d00]
mov dword [edx + 0x19c], eax
mov ecx, dword [0x6a2d00]
mov dword [ecx + 0x1d8], eax
mov edx, dword [0x6a2d00]
mov dword [edx + 0x1e0], eax
mov ecx, dword [0x6a2d00]
mov dword [ecx + 0x1e4], eax
mov edx, dword [0x6a2d00]
push 0x270a
mov dword [edx + 0x1f4], eax
call sym.convertifd.exe_CreateFieldStructure
add esp, 4
test eax, eax
mov dword [ebp + 0x40], eax
jl 0x495fb6
mov eax, dword [esi + 0x24]
mov ecx, dword [eax + ebx]
push 1
push edi
push ecx
call sym.convertifd.exe_HideEntity
mov edx, dword [esp + 0x84]
add edx, 0xffffffff
add esp, 0xc
add ebx, 4
cmp dword [esp + 0x18], edx
jge 0x496593
mov eax, dword [esi + 0x24]
lea ecx, [eax + ebx]
mov eax, dword [ecx]
test eax, eax
jne 0x496536
push edi
push 1
push eax
call sym.convertifd.exe_AddEntity
mov ecx, dword [esi + 0x24]
mov dword [ebx + ecx], eax
mov edx, dword [esi + 0x24]
mov eax, dword [ebx + edx]
add esp, 0xc
test eax, eax
jl 0x495fb6
push eax
push edi
call sym.convertifd.exe_PointToEntity
mov ecx, dword [esp + 0x5c]
mov edx, dword [esp + 0x60]
mov dword [eax + 0x14], ecx
mov ecx, dword [esp + 0x64]
mov dword [eax + 0x10], edx
mov dword [eax + 0x1c], ecx
jmp 0x49655f
cdq
xor eax, edx
sub eax, edx
mov dword [ecx], eax
mov edx, dword [esi + 0x24]
mov eax, dword [edx + ebx]
push eax
push edi
call sym.convertifd.exe_PointToEntity
mov ecx, dword [eax + 0x14]
mov edx, dword [eax + 0x10]
mov dword [esp + 0x5c], ecx
mov ecx, dword [eax + 0x1c]
mov dword [esp + 0x60], edx
mov dword [esp + 0x64], ecx
mov ebp, dword [esp + 0x18]
mov ecx, dword [esp + 0x68]
mov dword [eax + 8], ebp
mov dword [eax], ebp
mov dword [eax + 4], 0
mov edx, dword [ecx + 0xc]
sub edx, dword [ecx + 4]
add esp, 8
mov dword [eax + 0xc], edx
mov eax, dword [esi + 0x24]
mov ecx, dword [eax + ebx]
push 1
push edi
push ecx
call sym.convertifd.exe_HideEntity
add esp, 0xc
jmp 0x496597
mov ebp, dword [esp + 0x10]
mov ecx, dword [esp + 0x64]
add dword [esp + 0x24], 0x10
lea eax, [ecx + 1]
mov dword [esi + 0x20], eax
mov eax, dword [esp + 0x18]
add eax, 1
add ecx, 4
cmp eax, dword [esp + 0x78]
mov dword [esp + 0x14], ebp
mov ebp, dword [esp + 0x20]
mov dword [esp + 0x18], eax
mov dword [esp + 0x64], ecx
jl 0x496130
mov edx, dword [esp + 0x78]
pop edi
pop esi
mov dword [ebp + 0x14], edx
pop ebp
mov eax, 1
pop ebx
add esp, 0x5c
ret