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 /
This post has been wikified, any user with enough reputation can edit it.
avatar image
0
Question by IKilledKenny_2 · Apr 04, 2015 at 09:28 PM · rigidbodycontrollercharacter controller

Move Character Controller

Hello Unity3D.I have a problem with my character controller.My problem is that the character controller that i have assigned to the my characters whenever i add for to the character controller to move the character forward the character controllers moves forward but it doesn't stick the the position that i have assigned to.For example.My character is suppose to move forward the the opponent and then its suppose to stop by the opponent. but when i move the character controller from the new position the character controller starts from point (A).If anyone knows why this happens?Can you please tell me how i can fix this?Or a different way to move the character controller to the opponent smoothly?

Ps. Heres the Script var myTransform : Transform;
function Awake() { myTransform = transform; }

 function Start()
 {
  
 target = GameObject.FindWithTag("Dummy").transform;
  
 }
 
 
 function Update ()
 
 {
 
     if(Input.GetKeyDown("c")) {
     animation.Play("Genzu_Palm");    
     Instantiate(Genzu,spawn.transform.position,spawn.transform.rotation);
     myTransform.rigidbody.AddForce(transform.forward * 500, ForceMode.Impulse);
     Switch();
 
     }
 
 }    
 
 function Switch()
 
 {
     yield WaitForSeconds(2.5);
         animation.Play("Genzu_Palm_Part_2");
         myTransform.rigidbody.velocity = new Vector3(0,0,0);
         Switch2();
             
 }        
     
 function Switch2()
 {
     yield WaitForSeconds(.5);
         animation.Play("Genzu_Palm_Part_3");
         
 }        
     
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 Cherno · Apr 04, 2015 at 09:51 PM 0
Share

CharacterControllers are NOT meant to be used with rigidbodies.

avatar image IKilledKenny_2 · Apr 04, 2015 at 11:15 PM 0
Share

I took off the rigidbody but now the character doesnt move at all.Do you know why?

 controller.move(transform.forward * 400, Force$$anonymous$$ode.Impulse);
avatar image Cherno · Apr 05, 2015 at 12:18 AM 1
Share

There is a Script in the Standard Assets in one of the CC folders, "FPS Input", use that as a base.

avatar image IKilledKenny_2 · Apr 06, 2015 at 11:56 PM 0
Share

I figure out the problem by myself.But Thank You for your time =D

0 Replies

· Add your reply
  • Sort: 

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

Ethereal Character Controller 2 Answers

Rigidbody vs. Character Controller 2 Answers

Rigidbody bumping when going down slopes 3 Answers

turn on and off character controller 0 Answers

Do character controllers work with dynamic gravity? 1 Answer


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