Wayback Machinekoobas.hobune.stream
May JUN Jul
Previous capture 13 Next capture
2021 2022 2023
1 capture
13 Jun 22 - 13 Jun 22
sparklines
Close Help
  • Products
  • Solutions
  • Made with Unity
  • Learning
  • Support & Services
  • Community
  • Asset Store
  • Get Unity

UNITY ACCOUNT

You need a Unity Account to shop in the Online and Asset Stores, participate in the Unity Community and manage your license portfolio. Login Create account
  • Blog
  • Forums
  • Answers
  • Evangelists
  • User Groups
  • Beta Program
  • Advisory Panel

Navigation

  • Home
  • Products
  • Solutions
  • Made with Unity
  • Learning
  • Support & Services
  • Community
    • Blog
    • Forums
    • Answers
    • Evangelists
    • User Groups
    • Beta Program
    • Advisory Panel

Unity account

You need a Unity Account to shop in the Online and Asset Stores, participate in the Unity Community and manage your license portfolio. Login Create account

Language

  • Chinese
  • Spanish
  • Japanese
  • Korean
  • Portuguese
  • Ask a question
  • Spaces
    • Default
    • Help Room
    • META
    • Moderators
    • Topics
    • Questions
    • Users
    • Badges
  • Home /
avatar image
0
Question by CubePhysics · Dec 15, 2013 at 04:51 PM · animationcharactercontrollerriggingthird-personmixamo

need help with animations for third person controller

Im working a on a Lord of the rings fantasy meets minecraft survival type of game (voxel survival) and i finished a character with a mixamo rig with a standing, running and jumping animation. I set up the character with in the Unity scene editor by replacing the capsule in the First person controller with my player model and I pulled the camera out of the model and made it third person. I also adjusted the model in the character controller collision capsule thing. Everything works perfectly but I just need to know how to attach the animations (running, standing/idle and jumping) with the character controller movements. Can someone please help thx :)

also can someone help explain what legacy is?

Comment
Add comment · Show 4
10 |3000 characters needed characters left characters exceeded
▼
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Viewable by all users
avatar image el-santia93 · Dec 16, 2013 at 02:46 PM 0
Share

do you mean you want to be able to call the animations from the character controller movements script? or do you want to attach the animations to the charecter itself

avatar image CubePhysics · Dec 16, 2013 at 03:01 PM 0
Share

I want the character to play the animation while its running and standing etc. Im using the first person controller and just want to attach the animation while its moving etc.

avatar image zicreation111 · Dec 16, 2013 at 03:34 PM 0
Share

looks like a nice idEA

avatar image CubePhysics · Dec 16, 2013 at 05:05 PM 0
Share

Yeah but can you help me

2 Replies

· Add your reply
  • Sort: 
avatar image
0

Answer by iast999 · Dec 16, 2013 at 05:41 PM

How about this? Your character will animated when run to left,right,front and back. But you need to make the animation first and make it legacy. When the character stand it will in "idle".

 using UnityEngine;
 using System.Collections;
 
 public class PlayerAnimation : MonoBehaviour {
     Animation animasi;
 
     void Start () {
     animasi = GetComponentInChildren<Animation>();
 
     }
     
     // Update is called once per frame
     void Update () {
     float v = Input.GetAxisRaw("Vertical");
     float h = Input.GetAxisRaw("Horizontal");
         
         if(v >0){
             animasi.Blend("runFront");
         }else if(v < 0){
             animasi.Blend("runBack");
         }else if(h > 0){
             animasi.Blend("runRight");
         }else if(h < 0){
             animasi.Blend("runLeft");
         }else{
             animasi.Blend("idle");
         }
     }
 }
 
Comment
Add comment · Show 3 · Share
10 |3000 characters needed characters left characters exceeded
▼
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Viewable by all users
avatar image CubePhysics · Dec 16, 2013 at 06:27 PM 0
Share

Thanks for the script but im a bit confused here. I was trying to add the animation to the player but it said something in the inspector about legacy and you mentioned it above, what does it mean (ive been really struggling with animations in unity) I put a picture below so you can help me with what to do alt text

untitled.jpg (384.4 kB)
avatar image CubePhysics · Dec 16, 2013 at 06:30 PM 0
Share

also what component do i add to which part of the player : armature, parent, mesh

avatar image iast999 · Dec 17, 2013 at 09:40 AM 0
Share

When you move your model 3D with the animation to unity, on the $$anonymous$$odel Import Setting(Click your model from Assets) choose Rig. On the Animation Type, choose Legacy and store in Root Node. This will make you can edit the 3D animation. You do not need to add any component, Animation will included to your 3D.

avatar image
0

Answer by batubara · Jul 10, 2015 at 08:36 AM

using UnityEngine; using System.Collections;

public class PlayerAnimation : MonoBehaviour { Animation animasi;

  void Start () {
  animasi = GetComponentInChildren<Animation>();
 
  }
  
  // Update is called once per frame
  void Update () {
  float v = Input.GetAxisRaw("Vertical");
  float h = Input.GetAxisRaw("Horizontal");
      
      if(v >0){
          animasi.Blend("runFront");
      }else if(v < 0){
          animasi.Blend("runBack");
      }else if(h > 0){
          animasi.Blend("runRight");
      }else if(h < 0){
          animasi.Blend("runLeft");
      }else{
          animasi.Blend("idle");
      }
  }

}

Comment
Add comment · Share
10 |3000 characters needed characters left characters exceeded
▼
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Viewable by all users

Your answer

Hint: You can notify a user about this post by typing @username

Up to 2 attachments (including images) can be used with a maximum of 524.3 kB each and 1.0 MB total.

Follow this Question

Answers Answers and Comments

20 People are following this question.

avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image

Related Questions

Android ARCore build 0 Answers

[CLOSED] {Solved} small problem with Mixamo animation 1 Answer

Animation not playing correctly. 1 Answer

Everything works in Maximo but exporting it to Unity will give me problems.. 0 Answers

Why are my animations not working correctly? 4 Answers


Enterprise
Social Q&A

Social
Subscribe on YouTube social-youtube Follow on LinkedIn social-linkedin Follow on Twitter social-twitter Follow on Facebook social-facebook Follow on Instagram social-instagram

Footer

  • Purchase
    • Products
    • Subscription
    • Asset Store
    • Unity Gear
    • Resellers
  • Education
    • Students
    • Educators
    • Certification
    • Learn
    • Center of Excellence
  • Download
    • Unity
    • Beta Program
  • Unity Labs
    • Labs
    • Publications
  • Resources
    • Learn platform
    • Community
    • Documentation
    • Unity QA
    • FAQ
    • Services Status
    • Connect
  • About Unity
    • About Us
    • Blog
    • Events
    • Careers
    • Contact
    • Press
    • Partners
    • Affiliates
    • Security
Copyright © 2020 Unity Technologies
  • Legal
  • Privacy Policy
  • Cookies
  • Do Not Sell My Personal Information
  • Cookies Settings
"Unity", Unity logos, and other Unity trademarks are trademarks or registered trademarks of Unity Technologies or its affiliates in the U.S. and elsewhere (more info here). Other names or brands are trademarks of their respective owners.
  • Anonymous
  • Sign in
  • Create
  • Ask a question
  • Spaces
  • Default
  • Help Room
  • META
  • Moderators
  • Explore
  • Topics
  • Questions
  • Users
  • Badges