// File: /workspace/github_cpp_makefile_star2_O2/wrighteagle2d[P]wrighteaglebase/Debug/../src/WorldState.cpp
// Function: WorldStateUpdater::UpdateWorldState()
void WorldStateUpdater::UpdateWorldState() {
  /**更新场上的状态*/
  UpdateFieldInfo();

  if (PlayerParam::instance().isCoach() ||
      PlayerParam::instance().isTrainer() || mpObserver->mReceiveFullstateMsg) {
    if (mpObserver->mReceiveFullstateMsg) {
      SelfState().SetIsAlive(true);
      SelfState().UpdateIsSensed(true); // “真正”的自己
    }

    if (mpObserver->OurSide() == 'l') { // server发过来的信息坐标与自己一致
      Ball().UpdatePos(mpObserver->Ball_Fullstate().GetPos(), 0, 1.0);
      Ball().UpdateVel(mpObserver->Ball_Fullstate().GetVel(), 0, 1.0);

      for (Unum i = 1; i <= TEAMSIZE; i++) {
        Teammate(i).SetIsAlive(mpObserver->Teammate_Fullstate(i).IsAlive());
        Teammate(i).UpdatePlayerType(mpObserver->GetTeammateType(i));
        Teammate(i).UpdatePos(mpObserver->Teammate_Fullstate(i).GetPos(), 0,
                              1.0);
        Teammate(i).UpdateVel(mpObserver->Teammate_Fullstate(i).GetVel(), 0,
                              1.0);
        Teammate(i).UpdateBodyDir(
            mpObserver->Teammate_Fullstate(i).GetBodyDir(), 0, 1.0);
        Teammate(i).UpdateNeckDir(
            mpObserver->Teammate_Fullstate(i).GetNeckDir(), 0, 1.0);
        Teammate(i).UpdateCardType(
            mpObserver->Teammate_Fullstate(i).GetCardType());
        // TODO: arm, tackle lying等，暂时不用 -- TODO

        Opponent(i).SetIsAlive(mpObserver->Opponent_Fullstate(i).IsAlive());
        Opponent(i).UpdatePos(mpObserver->Opponent_Fullstate(i).GetPos(), 0,
                              1.0);
        Opponent(i).UpdateVel(mpObserver->Opponent_Fullstate(i).GetVel(), 0,
                              1.0);
        Opponent(i).UpdateBodyDir(
            mpObserver->Opponent_Fullstate(i).GetBodyDir(), 0, 1.0);
        Opponent(i).UpdateNeckDir(
            mpObserver->Opponent_Fullstate(i).GetNeckDir(), 0, 1.0);
        Opponent(i).UpdateCardType(
            mpObserver->Opponent_Fullstate(i).GetCardType());

        if (mpObserver->mReceiveFullstateMsg) {
          Teammate(i).UpdatePlayerType(
              mpObserver->Teammate_Fullstate(i).GetPlayerType());
          Teammate(i).UpdateStamina(
              mpObserver->Teammate_Fullstate(i).GetStamina());
          Teammate(i).UpdateEffort(
              mpObserver->Teammate_Fullstate(i).GetEffort());
          Teammate(i).UpdateRecovery(
              mpObserver->Teammate_Fullstate(i).GetRecovery());
          Teammate(i).UpdateCapacity(
              mpObserver->Teammate_Fullstate(i).GetCapacity());

          Opponent(i).UpdatePlayerType(
              mpObserver->Opponent_Fullstate(i).GetPlayerType());
          Opponent(i).UpdateStamina(
              mpObserver->Opponent_Fullstate(i).GetStamina());
          Opponent(i).UpdateEffort(
              mpObserver->Opponent_Fullstate(i).GetEffort());
          Opponent(i).UpdateRecovery(
              mpObserver->Opponent_Fullstate(i).GetRecovery());
          Opponent(i).UpdateCapacity(
              mpObserver->Opponent_Fullstate(i).GetCapacity());
        }
      }
    } else { // server发过来的信息坐标与自己相反，因为代码里总是假设自己在左边
      Ball().UpdatePos(mpObserver->Ball_Fullstate().GetPos() * -1.0, 0, 1.0);
      Ball().UpdateVel(mpObserver->Ball_Fullstate().GetVel() * -1.0, 0, 1.0);

      for (Unum i = 1; i <= TEAMSIZE; i++) {
        Teammate(i).SetIsAlive(mpObserver->Teammate_Fullstate(i).IsAlive());
        Teammate(i).UpdatePlayerType(mpObserver->GetTeammateType(i));
        Teammate(i).UpdatePos(mpObserver->Teammate_Fullstate(i).GetPos() * -1.0,
                              0, 1.0);
        Teammate(i).UpdateVel(mpObserver->Teammate_Fullstate(i).GetVel() * -1.0,
                              0, 1.0);
        Teammate(i).UpdateBodyDir(
            GetNormalizeAngleDeg(
                mpObserver->Teammate_Fullstate(i).GetBodyDir() + 180.0),
            0, 1.0);
        Teammate(i).UpdateNeckDir(
            GetNormalizeAngleDeg(
                mpObserver->Teammate_Fullstate(i).GetNeckDir() + 180.0),
            0, 1.0);
        Teammate(i).UpdateCardType(
            mpObserver->Teammate_Fullstate(i).GetCardType());
        // TODO: arm, tackle 等，暂时不用

        Opponent(i).SetIsAlive(mpObserver->Opponent_Fullstate(i).IsAlive());

        Opponent(i).UpdatePos(mpObserver->Opponent_Fullstate(i).GetPos() * -1.0,
                              0, 1.0);
        Opponent(i).UpdateVel(mpObserver->Opponent_Fullstate(i).GetVel() * -1.0,
                              0, 1.0);
        Opponent(i).UpdateBodyDir(
            GetNormalizeAngleDeg(
                mpObserver->Opponent_Fullstate(i).GetBodyDir() + 180.0),
            0, 1.0);
        Opponent(i).UpdateNeckDir(
            GetNormalizeAngleDeg(
                mpObserver->Opponent_Fullstate(i).GetNeckDir() + 180.0),
            0, 1.0);
        Opponent(i).UpdateCardType(
            mpObserver->Opponent_Fullstate(i).GetCardType());
      }
    }

    if (mpWorldState->GetTeammateGoalieUnum() > 0)
      Teammate(mpWorldState->GetTeammateGoalieUnum()).UpdateIsGoalie(true);
    if (mpWorldState->GetOpponentGoalieUnum() > 0)
      Opponent(mpWorldState->GetOpponentGoalieUnum()).UpdateIsGoalie(true);
    UpdateActionInfo();
  } else {
    // this procedure updates history state and there is a similar procedure in
    // UpdateFromAudio but updates current state.
    if (mpObserver->Ball_Fullstate().GetPosDelay() == 0) {
      WorldState &history = *mpWorldState->mpHistory->GetHistory(1);
      history.Ball().UpdatePos(mpObserver->Ball_Fullstate().GetPos(), 0, 1.0);
      history.Ball().UpdateGuessedTimes(0);
      history.Ball().UpdateVel(mpObserver->Ball_Fullstate().GetVel(), 0, 1.0);
      history.Ball().UpdatePosEps(0);
      history.Ball().UpdateVelEps(0);

      for (Unum i = 1; i <= TEAMSIZE; i++) {
        history.Teammate(i).SetIsAlive(
            mpObserver->Teammate_Fullstate(i).IsAlive());
        history.Teammate(i).UpdatePos(
            mpObserver->Teammate_Fullstate(i).GetPos(), 0, 1.0);
        history.Teammate(i).UpdateGuessedTimes(0);
        history.Teammate(i).UpdateVel(
            mpObserver->Teammate_Fullstate(i).GetVel(), 0, 1.0);
        history.Teammate(i).UpdatePosEps(0);
        history.Teammate(i).UpdateVelEps(0);
        history.Teammate(i).UpdateBodyDir(
            mpObserver->Teammate_Fullstate(i).GetBodyDir(), 0, 1.0);
        history.Teammate(i).UpdateNeckDir(
            mpObserver->Teammate_Fullstate(i).GetNeckDir(), 0, 1.0);
        if (i != mSelfUnum) {
          history.Teammate(i).UpdateStamina(
              mpObserver->Teammate_Fullstate(i).GetStamina());
          history.Teammate(i).UpdateCapacity(
              mpObserver->Teammate_Fullstate(i).GetCapacity());
        }

        history.Opponent(i).SetIsAlive(
            mpObserver->Opponent_Fullstate(i).IsAlive());
        history.Opponent(i).UpdatePlayerType(
            mpObserver->Opponent_Fullstate(i).GetPlayerType());
        history.Opponent(i).UpdatePos(
            mpObserver->Opponent_Fullstate(i).GetPos(), 0, 1.0);
        history.Opponent(i).UpdateGuessedTimes(0);
        history.Opponent(i).UpdateVel(
            mpObserver->Opponent_Fullstate(i).GetVel(), 0, 1.0);
        history.Opponent(i).UpdatePosEps(0);
        history.Opponent(i).UpdateVelEps(0);
        history.Opponent(i).UpdateBodyDir(
            mpObserver->Opponent_Fullstate(i).GetBodyDir());
        history.Opponent(i).UpdateNeckDir(
            mpObserver->Opponent_Fullstate(i).GetNeckDir());
        history.Opponent(i).UpdateStamina(
            mpObserver->Opponent_Fullstate(i).GetStamina());
        history.Opponent(i).UpdateCapacity(
            mpObserver->Opponent_Fullstate(i).GetCapacity());
      }
    }

    //更新所有的delay delay加上1 conf乘以1
    AutoDelay(1);

    //更新所有人的player_type和is_goalie
    for (int i = 1; i <= TEAMSIZE; i++) {
      Teammate(i).UpdatePlayerType(mpObserver->GetTeammateType(i));
      //			Opponent(i).UpdatePlayerType(mpObserver->GetOpponentType(i));
      //// 在UpdateFromAudio中更新,在此不更新

      Teammate(i).UpdateIsGoalie(false);
      Opponent(i).UpdateIsGoalie(false);
    }

    if (mpWorldState->GetTeammateGoalieUnum() > 0)
      Teammate(mpWorldState->GetTeammateGoalieUnum()).UpdateIsGoalie(true);
    if (mpWorldState->GetOpponentGoalieUnum() > 0)
      Opponent(mpWorldState->GetOpponentGoalieUnum()).UpdateIsGoalie(true);
    //	int id =	TimeTest::instance().Begin("before");
    //更新自己的听觉信息
    UpdateFromAudio();

    //预测一周期
    EstimateWorld();

    if (mpObserver->IsNewSight()) {
      UpdateSightDelay();
    }
    /*	TimeTest::instance().End(id);
            id = TimeTest::instance().Begin("test");
            TimeTest::instance().End(id);
            id = TimeTest::instance().Begin("middle");*/
    //更新自己的信息
    UpdateSelfInfo();

    if (mpObserver->IsNewSight()) {
      //更新所有可见的队员的信息
      UpdateKnownPlayers();

      //更新所有未知号码的球员
      UpdateUnknownPlayers();

      //更新球的信息
      UpdateBallInfo();

      EstimateToNow();
    }
    /*	TimeTest::instance().End(id);

            id = TimeTest::instance().Begin("end");*/
    /**处理碰撞*/
    UpdateInfoWhenCollided();

    //根据playmode更新确定的位置
    UpdateInfoFromPlayMode();

    //重新评估各球员的置信度 及置球员的生死
    EvaluateConf();

    //更新Action的信息
    UpdateActionInfo();

    MaintainPlayerStamina();

    MaintainConsistency();
    //	TimeTest::instance().End(id);
    //
  }
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x18, %rsp
movq %rdi, %rbx
callq 0x4da9a
callq 0x38d94
cmpb $0x1, 0x31a5(%rax)
jne 0x4ca06
movq (%rbx), %rsi
jmp 0x4ca21
callq 0x38d94
movq (%rbx), %rsi
cmpb $0x0, 0x31a6(%rax)
jne 0x4ca21
cmpb $0x1, 0x8(%rsi)
jne 0x4d10f
cmpb $0x1, 0x8(%rsi)
jne 0x4ca43
movslq 0x14(%rbx), %rax
movq 0x8(%rbx), %rcx
imulq $0x178, %rax, %rax      # imm = 0x178
movb $0x1, %dl
movb %dl, 0x42(%rax,%rcx)
movb %dl, 0xa6(%rax,%rcx)
movq 0x8(%rbx), %rdi
addq $0x30, %rdi
cmpb $0x6c, 0x29(%rsi)
jne 0x4cd86
addq $0x3578, %rsi           # imm = 0x3578
xorl %r15d, %r15d
movsd 0xa5e1(%rip), %xmm0     # 0x57048
xorl %edx, %edx
callq 0xde1c
movq 0x8(%rbx), %rdi
addq $0x30, %rdi
movl $0x35a0, %esi           # imm = 0x35A0
addq (%rbx), %rsi
xorl %edx, %edx
movsd 0xa5c0(%rip), %xmm0     # 0x57048
callq 0xdde8
pushq $0xf
popq %r14
movl $0xa8, %r13d
movl $0x10d0, %r12d          # imm = 0x10D0
cmpq $0x1028, %r15           # imm = 0x1028
je 0x4d0be
movq 0x8(%rbx), %rdi
addq %r15, %rdi
addq %r13, %rdi
movq (%rbx), %rax
movzbl 0x36fa(%rax,%r15), %esi
callq 0x381ec
movq 0x8(%rbx), %rdi
addq %r15, %rdi
addq %r13, %rdi
movq (%rbx), %rax
movq %r14, -0x40(%rbp)
movl (%rax,%r14,4), %esi
callq 0x38238
movq 0x8(%rbx), %rdi
addq %r15, %rdi
addq %r13, %rdi
movq (%rbx), %rax
leaq (%rax,%r15), %rsi
addq $0x35f0, %rsi           # imm = 0x35F0
xorl %edx, %edx
movsd 0xa547(%rip), %xmm0     # 0x57048
callq 0xde1c
movq 0x8(%rbx), %rdi
addq %r15, %rdi
addq %r13, %rdi
movq (%rbx), %rax
leaq (%rax,%r15), %rsi
addq $0x3618, %rsi           # imm = 0x3618
xorl %edx, %edx
movsd 0xa520(%rip), %xmm0     # 0x57048
callq 0xdde8
movq 0x8(%rbx), %rdi
addq %r15, %rdi
addq %r13, %rdi
movq (%rbx), %rax
movsd 0x3698(%rax,%r15), %xmm0
xorl %esi, %esi
movsd 0xa4fa(%rip), %xmm1     # 0x57048
callq 0x382a6
movq 0x8(%rbx), %r14
addq %r15, %r14
addq %r13, %r14
movq (%rbx), %rax
leaq (%rax,%r15), %rdi
addq $0x3680, %rdi           # imm = 0x3680
callq 0xd40e
movq %r14, %rdi
xorl %esi, %esi
movsd 0xa4cb(%rip), %xmm1     # 0x57048
callq 0x382f8
movq (%rbx), %rax
movq 0x8(%rbx), %rdi
movl 0x3758(%rax,%r15), %ecx
movl 0x218(%rdi,%r15), %edx
testl %edx, %edx
je 0x4cba7
cmpl $0x2, %ecx
jne 0x4cbaf
cmpl $0x1, %edx
jne 0x4cbaf
movl %ecx, 0x218(%rdi,%r15)
addq %r15, %rdi
addq %r12, %rdi
movzbl 0x4722(%rax,%r15), %esi
callq 0x381ec
movq 0x8(%rbx), %rdi
addq %r15, %rdi
addq %r12, %rdi
movq (%rbx), %rax
leaq (%rax,%r15), %rsi
addq $0x4618, %rsi           # imm = 0x4618
xorl %edx, %edx
movsd 0xa463(%rip), %xmm0     # 0x57048
callq 0xde1c
movq 0x8(%rbx), %rdi
addq %r15, %rdi
addq %r12, %rdi
movq (%rbx), %rax
leaq (%rax,%r15), %rsi
addq $0x4640, %rsi           # imm = 0x4640
xorl %edx, %edx
movsd 0xa43c(%rip), %xmm0     # 0x57048
callq 0xdde8
movq 0x8(%rbx), %rdi
addq %r15, %rdi
addq %r12, %rdi
movq (%rbx), %rax
movsd 0x46c0(%rax,%r15), %xmm0
xorl %esi, %esi
movsd 0xa416(%rip), %xmm1     # 0x57048
callq 0x382a6
movq 0x8(%rbx), %r14
addq %r15, %r14
addq %r12, %r14
movq (%rbx), %rax
leaq (%rax,%r15), %rdi
addq $0x46a8, %rdi           # imm = 0x46A8
callq 0xd40e
movq %r14, %rdi
xorl %esi, %esi
movsd 0xa3e7(%rip), %xmm1     # 0x57048
callq 0x382f8
movq (%rbx), %rax
movq 0x8(%rbx), %rcx
movl 0x4780(%rax,%r15), %edx
movl 0x1240(%rcx,%r15), %esi
testl %esi, %esi
je 0x4cc8b
cmpl $0x2, %edx
jne 0x4cc93
cmpl $0x1, %esi
jne 0x4cc93
movl %edx, 0x1240(%rcx,%r15)
cmpb $0x1, 0x8(%rax)
movq -0x40(%rbp), %r14
jne 0x4cd77
leaq (%rcx,%r15), %rdi
addq $0xa8, %rdi
movl 0x36fc(%rax,%r15), %esi
callq 0x38238
movq (%rbx), %rax
movq 0x8(%rbx), %rcx
movsd 0x3660(%rax,%r15), %xmm0
leaq (%rcx,%r15), %rdi
addq $0x10d0, %rdi           # imm = 0x10D0
movsd %xmm0, -0xfb0(%rdi)
movsd 0x3668(%rax,%r15), %xmm0
movsd %xmm0, -0xfa8(%rdi)
movsd 0x3678(%rax,%r15), %xmm0
movsd %xmm0, -0xf98(%rdi)
movsd 0x3670(%rax,%r15), %xmm0
movsd %xmm0, -0xfa0(%rdi)
movl 0x4724(%rax,%r15), %esi
callq 0x38238
movq (%rbx), %rax
movq 0x8(%rbx), %rcx
movsd 0x4688(%rax,%r15), %xmm0
movsd %xmm0, 0x1148(%rcx,%r15)
movsd 0x4690(%rax,%r15), %xmm0
movsd %xmm0, 0x1150(%rcx,%r15)
movsd 0x46a0(%rax,%r15), %xmm0
movsd %xmm0, 0x1160(%rcx,%r15)
movsd 0x4698(%rax,%r15), %xmm0
movsd %xmm0, 0x1158(%rcx,%r15)
addq $0x178, %r15            # imm = 0x178
incq %r14
jmp 0x4ca9d
movups 0x3578(%rsi), %xmm0
xorps 0xa28c(%rip), %xmm0     # 0x57020
leaq -0x38(%rbp), %r14
movups %xmm0, (%r14)
xorl %r12d, %r12d
movsd 0xa2a1(%rip), %xmm0     # 0x57048
movq %r14, %rsi
xorl %edx, %edx
callq 0xde1c
movq 0x8(%rbx), %rdi
addq $0x30, %rdi
movq (%rbx), %rax
movups 0x35a0(%rax), %xmm0
xorps 0xa256(%rip), %xmm0     # 0x57020
movups %xmm0, (%r14)
leaq -0x38(%rbp), %rsi
xorl %edx, %edx
movsd 0xa26c(%rip), %xmm0     # 0x57048
callq 0xdde8
pushq $0xf
popq %r15
cmpq $0x1028, %r12           # imm = 0x1028
je 0x4d0be
movq 0x8(%rbx), %rdi
addq %r12, %rdi
movl $0xa8, %r14d
addq %r14, %rdi
movq (%rbx), %rax
movzbl 0x36fa(%rax,%r12), %esi
callq 0x381ec
movq 0x8(%rbx), %rdi
addq %r12, %rdi
addq %r14, %rdi
movq (%rbx), %rax
movq %r15, -0x40(%rbp)
movl (%rax,%r15,4), %esi
callq 0x38238
movq 0x8(%rbx), %rdi
addq %r12, %rdi
addq %r14, %rdi
movq (%rbx), %rax
movups 0x35f0(%rax,%r12), %xmm0
movaps 0xa1d6(%rip), %xmm1     # 0x57020
xorps %xmm1, %xmm0
movups %xmm0, -0x38(%rbp)
leaq -0x38(%rbp), %r13
movq %r13, %rsi
xorl %edx, %edx
movsd 0xa1e6(%rip), %xmm0     # 0x57048
callq 0xde1c
movq 0x8(%rbx), %rdi
addq %r12, %rdi
addq %r14, %rdi
movq (%rbx), %rax
movups 0x3618(%rax,%r12), %xmm0
xorps 0xa19c(%rip), %xmm0     # 0x57020
movups %xmm0, -0x38(%rbp)
movq %r13, %rsi
xorl %edx, %edx
movsd 0xa1b3(%rip), %xmm0     # 0x57048
callq 0xdde8
movq 0x8(%rbx), %r15
addq %r12, %r15
addq %r14, %r15
movq (%rbx), %rax
movsd 0x3698(%rax,%r12), %xmm0
movsd 0xa1af(%rip), %xmm1     # 0x57068
addsd %xmm1, %xmm0
movabsq $-0x3f99800000000000, %rax # imm = 0xC066800000000000
movq %rax, -0x38(%rbp)
movq %r13, %rdi
callq 0xd305
movq %r15, %rdi
xorl %esi, %esi
movsd 0xa168(%rip), %xmm1     # 0x57048
callq 0x382a6
movq 0x8(%rbx), %r15
addq %r12, %r15
addq %r14, %r15
movq (%rbx), %rax
leaq (%rax,%r12), %rdi
addq $0x3680, %rdi           # imm = 0x3680
callq 0xd40e
addsd 0xa15e(%rip), %xmm0     # 0x57068
movabsq $-0x3f99800000000000, %rax # imm = 0xC066800000000000
movq %rax, -0x38(%rbp)
movq %r13, %rdi
callq 0xd305
movq %r15, %rdi
xorl %esi, %esi
movsd 0xa11b(%rip), %xmm1     # 0x57048
callq 0x382f8
movq (%rbx), %rax
movq 0x8(%rbx), %rdi
movl 0x3758(%rax,%r12), %ecx
movl 0x218(%rdi,%r12), %edx
testl %edx, %edx
je 0x4cf57
cmpl $0x2, %ecx
jne 0x4cf5f
cmpl $0x1, %edx
jne 0x4cf5f
movl %ecx, 0x218(%rdi,%r12)
addq %r12, %rdi
movl $0x10d0, %r13d          # imm = 0x10D0
addq %r13, %rdi
movzbl 0x4722(%rax,%r12), %esi
callq 0x381ec
movq 0x8(%rbx), %rdi
addq %r12, %rdi
addq %r13, %rdi
movq (%rbx), %rax
movups 0x4618(%rax,%r12), %xmm0
movaps 0xa08a(%rip), %xmm1     # 0x57020
xorps %xmm1, %xmm0
movups %xmm0, -0x38(%rbp)
leaq -0x38(%rbp), %r14
movq %r14, %rsi
xorl %edx, %edx
movsd 0xa09a(%rip), %xmm0     # 0x57048
callq 0xde1c
movq 0x8(%rbx), %rdi
addq %r12, %rdi
addq %r13, %rdi
movq (%rbx), %rax
movups 0x4640(%rax,%r12), %xmm0
xorps 0xa050(%rip), %xmm0     # 0x57020
movups %xmm0, -0x38(%rbp)
movq %r14, %rsi
xorl %edx, %edx
movsd 0xa067(%rip), %xmm0     # 0x57048
callq 0xdde8
movq 0x8(%rbx), %r15
addq %r12, %r15
addq %r13, %r15
movq (%rbx), %rax
movsd 0x46c0(%rax,%r12), %xmm0
movsd 0xa063(%rip), %xmm1     # 0x57068
addsd %xmm1, %xmm0
movabsq $-0x3f99800000000000, %rax # imm = 0xC066800000000000
movq %rax, -0x38(%rbp)
movq %r14, %rdi
callq 0xd305
movq %r15, %rdi
xorl %esi, %esi
movsd 0xa01c(%rip), %xmm1     # 0x57048
callq 0x382a6
movq 0x8(%rbx), %r15
addq %r12, %r15
addq %r13, %r15
movq (%rbx), %rax
leaq (%rax,%r12), %rdi
addq $0x46a8, %rdi           # imm = 0x46A8
callq 0xd40e
addsd 0xa012(%rip), %xmm0     # 0x57068
movabsq $-0x3f99800000000000, %rax # imm = 0xC066800000000000
movq %rax, -0x38(%rbp)
movq %r14, %rdi
callq 0xd305
movq %r15, %rdi
xorl %esi, %esi
movsd 0x9fcf(%rip), %xmm1     # 0x57048
callq 0x382f8
movq (%rbx), %rcx
movq 0x8(%rbx), %rax
movl 0x4780(%rcx,%r12), %ecx
movl 0x1240(%rax,%r12), %edx
testl %edx, %edx
je 0x4d0a3
cmpl $0x2, %ecx
jne 0x4d0ab
cmpl $0x1, %edx
jne 0x4d0ab
movl %ecx, 0x1240(%rax,%r12)
addq $0x178, %r12            # imm = 0x178
movq -0x40(%rbp), %r15
incq %r15
jmp 0x4cde5
movq 0x8(%rbx), %rax
movl 0x2110(%rax), %ecx
testl %ecx, %ecx
jle 0x4d0dd
decl %ecx
imulq $0x178, %rcx, %rcx      # imm = 0x178
movb $0x1, 0x21d(%rax,%rcx)
movl 0x2114(%rax), %ecx
testl %ecx, %ecx
jle 0x4d0f8
decl %ecx
imulq $0x178, %rcx, %rcx      # imm = 0x178
movb $0x1, 0x1245(%rax,%rcx)
movq %rbx, %rdi
callq 0x4d4a6
addq $0x18, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
cmpl $0x0, 0x3588(%rsi)
je 0x4d246
pushq $0x1
popq %rsi
movq %rbx, %rdi
callq 0x4db58
movq $-0x1028, %r14          # imm = 0xEFD8
xorl %r15d, %r15d
xorl %r12d, %r12d
movq 0x8(%rbx), %rax
testq %r14, %r14
je 0x4d176
leaq (%rax,%r14), %rdi
addq $0x10d0, %rdi           # imm = 0x10D0
movq (%rbx), %rax
movl 0x3c(%rax,%r12), %esi
callq 0x38238
movq 0x8(%rbx), %rax
movb %r15b, 0x1245(%rax,%r14)
movb %r15b, 0x226d(%rax,%r14)
addq $0x178, %r14            # imm = 0x178
addq $0x4, %r12
jmp 0x4d134
movl 0x2110(%rax), %ecx
testl %ecx, %ecx
jle 0x4d191
decl %ecx
imulq $0x178, %rcx, %rcx      # imm = 0x178
movb $0x1, 0x21d(%rax,%rcx)
movl 0x2114(%rax), %ecx
testl %ecx, %ecx
jle 0x4d1ac
decl %ecx
imulq $0x178, %rcx, %rcx      # imm = 0x178
movb $0x1, 0x1245(%rax,%rcx)
movq %rbx, %rdi
callq 0x4dc52
movq %rbx, %rdi
xorl %esi, %esi
xorl %edx, %edx
callq 0x4e6e6
movq (%rbx), %rax
cmpb $0x1, 0x3382(%rax)
jne 0x4d1d4
movq %rbx, %rdi
callq 0x4e71c
movq %rbx, %rdi
callq 0x4e774
movq (%rbx), %rax
cmpb $0x1, 0x3382(%rax)
jne 0x4d208
movq %rbx, %rdi
callq 0x4ec10
movq %rbx, %rdi
callq 0x4ecba
movq %rbx, %rdi
callq 0x4f864
movq %rbx, %rdi
callq 0x50702
movq %rbx, %rdi
callq 0x507c4
movq %rbx, %rdi
callq 0x50a20
movq %rbx, %rdi
callq 0x50f8a
movq %rbx, %rdi
callq 0x4d4a6
movq %rbx, %rdi
callq 0x51098
movq %rbx, %rdi
addq $0x18, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
jmp 0x514c4
addq $0x3578, %rsi           # imm = 0x3578
movq 0x8(%rbx), %rax
movq 0x8(%rax), %rcx
movl 0x14b90(%rcx), %eax
addl $0x9, %eax
pushq $0xa
popq %rdi
cltd
idivl %edi
movslq %edx, %rax
imulq $0x2128, %rax, %rax     # imm = 0x2128
leaq (%rcx,%rax), %r15
leaq (%rcx,%rax), %r14
addq $0x30, %r14
xorl %r12d, %r12d
movsd 0x9dc3(%rip), %xmm0     # 0x57048
movq %r14, %rdi
xorl %edx, %edx
callq 0xde1c
andl $0x0, 0x70(%r14)
movl $0x35a0, %esi           # imm = 0x35A0
addq (%rbx), %rsi
movq %r14, %rdi
xorl %edx, %edx
movsd 0x9d9f(%rip), %xmm0     # 0x57048
callq 0xdde8
andq $0x0, 0x28(%r14)
andq $0x0, 0x50(%r14)
pushq $0x1
popq %r13
cmpq $0x1028, %r12           # imm = 0x1028
je 0x4d11c
leaq (%r15,%r12), %r14
addq $0xa8, %r14
movq (%rbx), %rax
movzbl 0x36fa(%rax,%r12), %esi
movq %r14, %rdi
callq 0x381ec
movq (%rbx), %rax
leaq (%rax,%r12), %rsi
addq $0x35f0, %rsi           # imm = 0x35F0
movq %r14, %rdi
xorl %edx, %edx
movsd 0x9d45(%rip), %xmm0     # 0x57048
callq 0xde1c
andl $0x0, 0x70(%r14)
movq (%rbx), %rax
leaq (%rax,%r12), %rsi
addq $0x3618, %rsi           # imm = 0x3618
movq %r14, %rdi
xorl %edx, %edx
movsd 0x9d20(%rip), %xmm0     # 0x57048
callq 0xdde8
andq $0x0, 0x28(%r14)
andq $0x0, 0x50(%r14)
movq (%rbx), %rax
movsd 0x3698(%rax,%r12), %xmm0
movq %r14, %rdi
xorl %esi, %esi
movsd 0x9cf7(%rip), %xmm1     # 0x57048
callq 0x382a6
movq (%rbx), %rax
leaq (%rax,%r12), %rdi
addq $0x3680, %rdi           # imm = 0x3680
callq 0xd40e
movq %r14, %rdi
xorl %esi, %esi
movsd 0x9cd2(%rip), %xmm1     # 0x57048
callq 0x382f8
movl 0x14(%rbx), %ecx
movq (%rbx), %rax
cmpq %rcx, %r13
je 0x4d3ae
movsd 0x3660(%rax,%r12), %xmm0
movsd %xmm0, 0x120(%r15,%r12)
movsd 0x3670(%rax,%r12), %xmm0
movsd %xmm0, 0x130(%r15,%r12)
leaq (%r15,%r12), %r14
addq $0x10d0, %r14           # imm = 0x10D0
movzbl 0x4722(%rax,%r12), %esi
movq %r14, %rdi
callq 0x381ec
movq (%rbx), %rax
movl 0x4724(%rax,%r12), %esi
movq %r14, %rdi
callq 0x38238
movq (%rbx), %rax
leaq (%rax,%r12), %rsi
addq $0x4618, %rsi           # imm = 0x4618
movq %r14, %rdi
xorl %edx, %edx
movsd 0x9c50(%rip), %xmm0     # 0x57048
callq 0xde1c
andl $0x0, 0x70(%r14)
movq (%rbx), %rax
leaq (%rax,%r12), %rsi
addq $0x4640, %rsi           # imm = 0x4640
movq %r14, %rdi
xorl %edx, %edx
movsd 0x9c2b(%rip), %xmm0     # 0x57048
callq 0xdde8
andq $0x0, 0x28(%r14)
andq $0x0, 0x50(%r14)
movq (%rbx), %rax
movsd 0x46c0(%rax,%r12), %xmm0
movq %r14, %rdi
xorl %esi, %esi
movsd 0x9c02(%rip), %xmm1     # 0x57048
callq 0x382a6
movq (%rbx), %rax
leaq (%rax,%r12), %rdi
addq $0x46a8, %rdi           # imm = 0x46A8
callq 0xd40e
movq %r14, %rdi
xorl %esi, %esi
movsd 0x9bdd(%rip), %xmm1     # 0x57048
callq 0x382f8
movq (%rbx), %rax
movsd 0x4688(%rax,%r12), %xmm0
movsd %xmm0, 0x78(%r14)
movsd 0x4698(%rax,%r12), %xmm0
movsd %xmm0, 0x88(%r14)
incq %r13
addq $0x178, %r12            # imm = 0x178
jmp 0x4d2bc
nop