Ejemplo n.º 1
0
 public void DefaultBodyPosition()
 {
     body             = BodyPosture.Stand;
     lookingDirection = transform.right;
     animManager.StartLookStraightAnim();
     physics.SetMovementFactor(physics.groundMovementFactor);
     AdaptColliderStanding();
 }
Ejemplo n.º 2
0
 private void Crouch()
 {
     body             = BodyPosture.Crouch;
     lookingDirection = transform.right;
     animManager.StartCrouchAnim();
     physics.SetMovementFactor(crouchSpeedFactor);
     AdaptColliderCrouching();
 }
Ejemplo n.º 3
0
 public void Jump()
 {
     if (body == BodyPosture.Crouch)
     {
         LookDown();
     }
     body = BodyPosture.Stand;
     if (Mathf.Abs(physics.GetVelocityX()) > 0)
     {
         if (physics.JumpHighVel())
         {
             timeUtils.FrameDelay(animManager.StartHighVelJumpAnim);
         }
     }
     else
     {
         if (physics.JumpLowVel())
         {
             timeUtils.FrameDelay(animManager.StartLowVelJumpAnim);
         }
     }
     AdaptColliderStanding();
 }
Ejemplo n.º 4
0
 /// <summary>姿勢を設定する</summary>
 /// <param name="posture">姿勢</param>
 public void SetPosture(BodyPosture posture)
 {
     //姿勢を設定
     Posture = posture;
     //各部位の熱伝達率[W/(m2 K)]を姿勢に応じた値に更新
     foreach (Nodes bp in parts.Keys) parts[bp].updatePosture();
 }