// File: wrighteagle2d[P]wrighteaglebase/Debug/../src/VisualSystem.cpp
// Function: VisualSystem::RaisePlayer(int, double)
void VisualSystem::RaisePlayer(ObjectIndex unum, double eva) {
  if (unum == 0 || !mpWorldState->GetPlayer(unum).IsAlive() ||
      unum == mpSelfState->GetUnum()) {
    return;
  }

  if (eva < FLOAT_EPS) {
    double dis = mpInfoState->GetPositionInfo().GetPlayerDistToPlayer(
        mpSelfState->GetUnum(), unum);
    if (dis < 3.0) {
      eva = 6.0;
    } else if (dis < 6.0) {
      eva = 5.0;
    } else if (dis < 20.0) {
      eva = 10.0;
    } else if (dis < 40.0) {
      eva = 26.0;
    } else {
      eva = 50.0;
    }
  }

  VisualRequest *vr = GetVisualRequest(unum);
  vr->mFreq = Min(vr->mFreq, eva);

  if (mpWorldState->GetPlayer(unum).GetPosConf() < FLOAT_EPS) {
    if (eva <= 2) {
      RaiseForgotObject(unum);
    }
  }

  PlayMode pm = mpWorldState->GetPlayMode();
  if (((/*pm == PM_Our_Penalty_Setup ||*/ pm == PM_Our_Penalty_Ready ||
        pm == PM_Our_Penalty_Taken) &&
       mpWorldState->GetPlayer(unum).IsGoalie()) ||
      (-unum == mpInfoState->GetPositionInfo().GetTeammateOffsideLineOpp() &&
       mpAgent->GetFormation().GetMyRole().mLineType == LT_Forward &&
       eva <= mpWorldState->GetPlayer(unum).GetPosDelay())) {
    RaiseForgotObject(unum);
  }
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x60, %rsp
movq %rdi, -0x8(%rbp)
movl %esi, -0xc(%rbp)
movsd %xmm0, -0x18(%rbp)
movq -0x8(%rbp), %rax
movq %rax, -0x38(%rbp)
cmpl $0x0, -0xc(%rbp)
je 0xa62fd
movq -0x38(%rbp), %rax
movq 0x10(%rax), %rdi
leaq -0xc(%rbp), %rsi
callq 0x23eb0
movq %rax, %rdi
callq 0x23f20
testb $0x1, %al
jne 0xa62e1
jmp 0xa62fd
movq -0x38(%rbp), %rax
movl -0xc(%rbp), %ecx
movl %ecx, -0x3c(%rbp)
movq 0x20(%rax), %rdi
callq 0x1b470
movl %eax, %ecx
movl -0x3c(%rbp), %eax
cmpl %ecx, %eax
jne 0xa6302
jmp 0xa6510
movsd 0x1acfe(%rip), %xmm0    # 0xc1008
ucomisd -0x18(%rbp), %xmm0
jbe 0xa63da
movq -0x38(%rbp), %rax
movq 0x28(%rax), %rdi
callq 0x49590
movq %rax, %rcx
movq -0x38(%rbp), %rax
movq %rcx, -0x48(%rbp)
movq 0x20(%rax), %rdi
callq 0x1b470
movq -0x48(%rbp), %rdi
movl %eax, %esi
movl -0xc(%rbp), %edx
callq 0x7efb0
movsd (%rax), %xmm0
movsd %xmm0, -0x20(%rbp)
movsd 0x1b863(%rip), %xmm0    # 0xc1bb8
ucomisd -0x20(%rbp), %xmm0
jbe 0xa636b
movsd 0x1bd64(%rip), %xmm0    # 0xc20c8
movsd %xmm0, -0x18(%rbp)
jmp 0xa63d8
movsd 0x1bd55(%rip), %xmm0    # 0xc20c8
ucomisd -0x20(%rbp), %xmm0
jbe 0xa6389
movsd 0x1b5ee(%rip), %xmm0    # 0xc1970
movsd %xmm0, -0x18(%rbp)
jmp 0xa63d6
movsd 0x1cb27(%rip), %xmm0    # 0xc2eb8
ucomisd -0x20(%rbp), %xmm0
jbe 0xa63a7
movsd 0x1b358(%rip), %xmm0    # 0xc16f8
movsd %xmm0, -0x18(%rbp)
jmp 0xa63d4
movsd 0x1cb21(%rip), %xmm0    # 0xc2ed0
ucomisd -0x20(%rbp), %xmm0
jbe 0xa63c5
movsd 0x1b992(%rip), %xmm0    # 0xc1d50
movsd %xmm0, -0x18(%rbp)
jmp 0xa63d2
movsd 0x1ba3b(%rip), %xmm0    # 0xc1e08
movsd %xmm0, -0x18(%rbp)
jmp 0xa63d4
jmp 0xa63d6
jmp 0xa63d8
jmp 0xa63da
movq -0x38(%rbp), %rdi
movl -0xc(%rbp), %esi
callq 0xa9430
movq %rax, -0x28(%rbp)
movq -0x28(%rbp), %rdi
addq $0x18, %rdi
leaq -0x18(%rbp), %rsi
callq 0x12a60
movq %rax, %rcx
movq -0x38(%rbp), %rax
movsd (%rcx), %xmm0
movq -0x28(%rbp), %rcx
movsd %xmm0, 0x18(%rcx)
movq 0x10(%rax), %rdi
leaq -0xc(%rbp), %rsi
callq 0x23eb0
movq %rax, %rdi
addq $0x8, %rdi
callq 0x1d930
movsd 0x1abd8(%rip), %xmm0    # 0xc1008
ucomisd (%rax), %xmm0
jbe 0xa6453
movsd 0x1b072(%rip), %xmm0    # 0xc14b0
ucomisd -0x18(%rbp), %xmm0
jb 0xa6451
movq -0x38(%rbp), %rdi
movl -0xc(%rbp), %esi
callq 0xa4ac0
jmp 0xa6453
movq -0x38(%rbp), %rax
movq 0x10(%rax), %rdi
callq 0x10ed0
movl %eax, -0x2c(%rbp)
cmpl $0xf, -0x2c(%rbp)
je 0xa646f
cmpl $0x10, -0x2c(%rbp)
jne 0xa648c
movq -0x38(%rbp), %rax
movq 0x10(%rax), %rdi
leaq -0xc(%rbp), %rsi
callq 0x23eb0
movq %rax, %rdi
callq 0x1d780
testb $0x1, %al
jne 0xa6504
movq -0x38(%rbp), %rax
xorl %ecx, %ecx
subl -0xc(%rbp), %ecx
movl %ecx, -0x4c(%rbp)
movq 0x28(%rax), %rdi
callq 0x49590
movq %rax, %rdi
callq 0x26520
movq %rax, %rcx
movl -0x4c(%rbp), %eax
cmpl (%rcx), %eax
jne 0xa6510
movq -0x38(%rbp), %rax
movq 0x8(%rax), %rdi
callq 0x1a4c0
movq %rax, %rdi
callq 0x3d5f0
cmpl $0x3, 0x8(%rax)
jne 0xa6510
movq -0x38(%rbp), %rax
movsd -0x18(%rbp), %xmm0
movsd %xmm0, -0x58(%rbp)
movq 0x10(%rax), %rdi
leaq -0xc(%rbp), %rsi
callq 0x23eb0
movq %rax, %rdi
addq $0x8, %rdi
callq 0x1ddd0
movsd -0x58(%rbp), %xmm1
cvtsi2sd %eax, %xmm0
ucomisd %xmm1, %xmm0
jb 0xa6510
movq -0x38(%rbp), %rdi
movl -0xc(%rbp), %esi
callq 0xa4ac0
addq $0x60, %rsp
popq %rbp
retq
nopw %cs:(%rax,%rax)