Function at 0x51b710
Capabilities:
Access peb ldr_data
Check for peb beingdebugged flag

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x58cab4
mov eax, dword fs:[0]
push eax
mov dword fs:[0], esp
sub esp, 0x260
push ebx
push esi
push edi
mov dword [ebp - 0x10], esp
mov dword [ebp - 4], 0
wait
fild dword [ebp + 8]
mov eax, dword [0x767adc]
imul eax, eax, 0x1c
fld st(0)
mov edx, dword [0x767a74]
fstp dword [eax + edx]
fild dword [ebp + 0xc]
mov eax, dword [0x767adc]
imul eax, eax, 0x1c
fld st(0)
mov edx, dword [0x767a74]
fstp dword [eax + edx + 4]
mov edx, dword [0x767adc]
imul edx, edx, 0x1c
mov eax, 0x3f800000
mov esi, dword [0x767a74]
mov dword [edx + esi + 8], eax
mov edx, dword [0x767adc]
imul edx, edx, 0x1c
mov esi, dword [0x767a74]
mov dword [edx + esi + 0xc], eax
mov esi, dword [0x767adc]
imul esi, esi, 0x1c
mov edx, dword [ebp + 0x38]
mov edi, dword [0x767a74]
mov dword [esi + edi + 0x10], edx
fld qword [ebp + 0x18]
fstp dword [ebp - 0x18]
mov esi, dword [0x767adc]
imul esi, esi, 0x1c
fld dword [ebp - 0x18]
mov edi, dword [0x767a74]
fstp dword [esi + edi + 0x14]
fld qword [ebp + 0x28]
fstp dword [ebp - 0x14]
mov esi, dword [0x767adc]
imul esi, esi, 0x1c
fld dword [ebp - 0x14]
mov edi, dword [0x767a74]
fstp dword [esi + edi + 0x18]
fild dword [ebp + 0x10]
mov esi, dword [0x767adc]
inc esi
imul esi, esi, 0x1c
fld st(0)
mov edi, dword [0x767a74]
fstp dword [esi + edi]
mov esi, dword [0x767adc]
imul esi, esi, 0x1c
fld st(1)
mov edi, dword [0x767a74]
fstp dword [esi + edi + 0x20]
mov esi, dword [0x767adc]
imul esi, esi, 0x1c
mov edi, dword [0x767a74]
mov dword [esi + edi + 0x24], eax
mov esi, dword [0x767adc]
imul esi, esi, 0x1c
mov edi, dword [0x767a74]
mov dword [esi + edi + 0x28], eax
mov esi, dword [0x767adc]
imul esi, esi, 0x1c
mov edi, dword [0x767a74]
mov ebx, dword [ebp + 0x3c]
mov dword [esi + edi + 0x2c], ebx
fld qword [ebp + 0x20]
mov esi, dword [0x767adc]
imul esi, esi, 0x1c
fld st(0)
mov edi, dword [0x767a74]
fstp dword [esi + edi + 0x30]
mov esi, dword [0x767adc]
imul esi, esi, 0x1c
fld dword [ebp - 0x14]
mov edi, dword [0x767a74]
fstp dword [esi + edi + 0x34]
mov esi, dword [0x767adc]
add esi, 2
imul esi, esi, 0x1c
fld st(1)
mov edi, dword [0x767a74]
fstp dword [esi + edi]
fild dword [ebp + 0x14]
fstp dword [ebp - 0x20]
mov esi, dword [0x767adc]
imul esi, esi, 0x1c
fld dword [ebp - 0x20]
mov edi, dword [0x767a74]
fstp dword [esi + edi + 0x3c]
mov esi, dword [0x767adc]
imul esi, esi, 0x1c
mov edi, dword [0x767a74]
mov dword [esi + edi + 0x40], eax
mov esi, dword [0x767adc]
imul esi, esi, 0x1c
mov edi, dword [0x767a74]
mov dword [esi + edi + 0x44], eax
mov edi, dword [0x767adc]
imul edi, edi, 0x1c
mov esi, dword [ebp + 0x40]
mov ebx, dword [0x767a74]
mov dword [edi + ebx + 0x48], esi
mov edi, dword [0x767adc]
imul edi, edi, 0x1c
fld st(0)
mov ebx, dword [0x767a74]
fstp dword [edi + ebx + 0x4c]
fld qword [ebp + 0x30]
fstp dword [ebp - 0x1c]
mov edi, dword [0x767adc]
imul edi, edi, 0x1c
fld dword [ebp - 0x1c]
mov ebx, dword [0x767a74]
fstp dword [edi + ebx + 0x50]
mov edi, dword [0x767adc]
add edi, 3
imul edi, edi, 0x1c
fxch st(1)
mov ebx, dword [0x767a74]
fstp dword [edi + ebx]
mov edi, dword [0x767adc]
imul edi, edi, 0x1c
fld dword [ebp - 0x20]
mov ebx, dword [0x767a74]
fstp dword [edi + ebx + 0x58]
mov edi, dword [0x767adc]
imul edi, edi, 0x1c
mov ebx, dword [0x767a74]
mov dword [edi + ebx + 0x5c], eax
mov edi, dword [0x767adc]
imul edi, edi, 0x1c
mov ebx, dword [0x767a74]
mov dword [edi + ebx + 0x60], eax
mov edi, dword [0x767adc]
imul edi, edi, 0x1c
mov ebx, dword [0x767a74]
mov dword [edi + ebx + 0x64], esi
mov esi, dword [0x767adc]
imul esi, esi, 0x1c
mov edi, dword [0x767a74]
fstp dword [esi + edi + 0x68]
mov esi, dword [0x767adc]
imul esi, esi, 0x1c
fld dword [ebp - 0x1c]
mov edi, dword [0x767a74]
fstp dword [esi + edi + 0x6c]
mov esi, dword [0x767adc]
add esi, 4
imul esi, esi, 0x1c
fld st(1)
mov edi, dword [0x767a74]
fstp dword [esi + edi]
mov esi, dword [0x767adc]
imul esi, esi, 0x1c
fld dword [ebp - 0x20]
mov edi, dword [0x767a74]
fstp dword [esi + edi + 0x74]
mov esi, dword [0x767adc]
imul esi, esi, 0x1c
mov edi, dword [0x767a74]
mov dword [esi + edi + 0x78], eax
mov esi, dword [0x767adc]
imul esi, esi, 0x1c
mov edi, dword [0x767a74]
mov dword [esi + edi + 0x7c], eax
mov esi, dword [0x767adc]
imul esi, esi, 0x1c
mov edi, dword [0x767a74]
mov ebx, dword [ebp + 0x44]
mov dword [esi + edi + 0x80], ebx
mov esi, dword [0x767adc]
imul esi, esi, 0x1c
fld dword [ebp - 0x18]
mov edi, dword [0x767a74]
fstp dword [esi + edi + 0x84]
mov esi, dword [0x767adc]
imul esi, esi, 0x1c
fld dword [ebp - 0x1c]
mov edi, dword [0x767a74]
fstp dword [esi + edi + 0x88]
mov esi, dword [0x767adc]
add esi, 5
imul esi, esi, 0x1c
fxch st(1)
mov edi, dword [0x767a74]
fstp dword [esi + edi]
mov esi, dword [0x767adc]
imul esi, esi, 0x1c
mov edi, dword [0x767a74]
fstp dword [esi + edi + 0x90]
mov esi, dword [0x767adc]
imul esi, esi, 0x1c
mov edi, dword [0x767a74]
mov dword [esi + edi + 0x94], eax
mov esi, dword [0x767adc]
imul esi, esi, 0x1c
mov edi, dword [0x767a74]
mov dword [esi + edi + 0x98], eax
mov eax, dword [0x767adc]
imul eax, eax, 0x1c
mov esi, dword [0x767a74]
mov dword [eax + esi + 0x9c], edx
mov edx, dword [0x767adc]
imul edx, edx, 0x1c
fld dword [ebp - 0x18]
mov eax, dword [0x767a74]
fstp dword [edx + eax + 0xa0]
mov edx, dword [0x767adc]
imul edx, edx, 0x1c
fld dword [ebp - 0x14]
mov eax, dword [0x767a74]
fstp dword [edx + eax + 0xa4]
mov eax, dword [0x767adc]
add eax, 6
mov dword [0x767adc], eax
cmp eax, 0x2580
jne 0x51baff
call fcn.005141d0
jmp 0x51bb0a
test eax, eax
jl 0x51bb25
cmp eax, 0x2580
jg 0x51bb25
wait
mov dword [ebp - 4], 0xffffffff
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 0x40
push 0x5955cf
lea ecx, [ebp - 0xd8]
call fcn.00403cb0
mov byte [ebp - 4], 1
push 0x5955cf
lea ecx, [ebp - 0x148]
call fcn.00403cb0
mov byte [ebp - 4], 2
push str.curVertex
lea ecx, [ebp - 0xa0]
call fcn.00403cb0
mov byte [ebp - 4], 3
push str.bad_current_vertex_number
lea ecx, [ebp - 0x19c]
call fcn.00403cb0
mov byte [ebp - 4], 4
push str.._surfaceDX9.cpp
lea ecx, [ebp - 0x4c]
call fcn.00403cb0
mov byte [ebp - 4], 5
lea ecx, [ebp - 0xd8]
push ecx
push 0
lea edx, [ebp - 0x148]
push edx
mov eax, dword [0x767adc]
push eax
lea ecx, [ebp - 0xa0]
push ecx
lea edx, [ebp - 0x19c]
push edx
push 0x15d
lea eax, [ebp - 0x4c]
push eax
lea ecx, [ebp - 0x1f4]
call fcn.00535de0
push 0x5b7828
lea ecx, [ebp - 0x1f4]
push ecx
call fcn.0053fb12
mov edx, dword [ebp - 0x2c]
mov dword [ebp - 0x24], edx
push 0x5b7838
lea eax, [ebp - 0x24]
push eax
call fcn.0053fb12
push 0x5955cf
lea ecx, [ebp - 0x180]
call fcn.00403cb0
mov byte [ebp - 4], 7
push str._int__v
lea ecx, [ebp - 0x110]
call fcn.00403cb0
mov byte [ebp - 4], 8
push str.exception_occurred
lea ecx, [ebp - 0x1b8]
call fcn.00403cb0
mov byte [ebp - 4], 9
push str.._surfaceDX9.cpp
lea ecx, [ebp - 0x68]
call fcn.00403cb0
mov byte [ebp - 4], 0xa
mov ecx, dword [ebp - 0x28]
push ecx
push 0
lea edx, [ebp - 0x180]
push edx
mov eax, dword [0x767a74]
push eax
lea ecx, [ebp - 0x110]
push ecx
lea edx, [ebp - 0x1b8]
push edx
push 0x164
lea eax, [ebp - 0x68]
push eax
lea ecx, [ebp - 0x230]
call fcn.005360d0
push 0x5b7828
lea ecx, [ebp - 0x230]
push ecx
call fcn.0053fb12
mov ecx, dword [ebp - 0x30]
mov edx, dword [ecx]
call dword [edx + 4]
push eax
lea ecx, [ebp - 0x84]
call fcn.00403cb0
mov byte [ebp - 4], 0xb
push 0x5955cf
lea ecx, [ebp - 0xbc]
call fcn.00403cb0
mov byte [ebp - 4], 0xc
push str._int__v
lea ecx, [ebp - 0xf4]
call fcn.00403cb0
mov byte [ebp - 4], 0xd
push str.standard_exception_occurred
lea ecx, [ebp - 0x12c]
call fcn.00403cb0
mov byte [ebp - 4], 0xe
push str.._surfaceDX9.cpp
lea ecx, [ebp - 0x164]
call fcn.00403cb0
mov byte [ebp - 4], 0xf
lea eax, [ebp - 0x84]
push eax
push 0
lea ecx, [ebp - 0xbc]
push ecx
mov edx, dword [0x767a74]
push edx
lea eax, [ebp - 0xf4]
push eax
lea ecx, [ebp - 0x12c]
push ecx
push 0x164
lea edx, [ebp - 0x164]
push edx
lea ecx, [ebp - 0x26c]
call fcn.00535de0
push 0x5b7828
lea eax, [ebp - 0x26c]
push eax
call fcn.0053fb12
int3