Wayback Machinekoobas.hobune.stream
May JUN Jul
Previous capture 12 Next capture
2021 2022 2023
1 capture
12 Jun 22 - 12 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 TheEasterHazy · Sep 18, 2011 at 09:41 PM · errornullreferenceexceptionnull

NullReferenceException: Object reference not set to an instance of an object

NullReferenceException: Object reference not set to an instance of an object Boo.Lang.Runtime.RuntimeServices.GetDispatcher (System.Object target, System.String cacheKeyName, System.Type[] cacheKeyTypes, Boo.Lang.Runtime.DynamicDispatching.DispatcherFactory factory) Boo.Lang.Runtime.RuntimeServices.GetDispatcher (System.Object target, System.Object[] args, System.String cacheKeyName, Boo.Lang.Runtime.DynamicDispatching.DispatcherFactory factory) Boo.Lang.Runtime.RuntimeServices.GetProperty (System.Object target, System.String name) UnityScript.Lang.UnityRuntimeServices.GetProperty (System.Object target, System.String name) CharackterKontrolle.Update () (at Assets/CharackterKontrolle.js:10)

Here is my script... what did i do wrong? Hier ist mein script... was habe ich falsch gemacht?

var gehen = 3.0; var laufen = 1.5; var DrehSpeed = 200.0;

function Update () {

var Rotation = Input.GetAxis("Horizontal")*DrehSpeed; transform.Rotate(0,Rotation*Time.delta.Time, 1);

var Speed = Input.GetAxis("Vertical")*gehen;

if(Input.GetKey("left shift")) {

Speed*=laufen;

}

var Kontrolle : CharacterController = GetComponent(CharacterController); var Vorwaerts = transform.TransformDirection(Vector3.forward); Kontrolle.SimpleMove(Vorwaerts*Speed);

, Ich }

This script is suppost to let my Player Character walk and turn...

Dieser script ist da um meinen Player Charackter gehen und drehen zu lassen...

Hello, It would be really amazing if somebody could tell me what I did wrong and how i could do it better...

Hallo, Es wäre wirklich Toll wenn mir jemand sagen könnte was ich falsch geamcht habe und wie ich das besser machen könnte...


I hope for a quick answer... Thank you!

Ich hoffe auf eine schnelle Antwort... Vielen Dank"

Comment
Add comment · Show 7
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 TheEasterHazy · Sep 19, 2011 at 05:04 AM -1
Share

hmm, still doesnt workk, now I get this Error $$anonymous$$essage...

NullReferenceException: Object reference not set to an instance of an object Boo.Lang.Runtime.RuntimeServices.GetDispatcher (System.Object target, System.String cache$$anonymous$$eyName, System.Type[] cache$$anonymous$$eyTypes, Boo.Lang.Runtime.DynamicDispatching.DispatcherFactory factory) Boo.Lang.Runtime.RuntimeServices.GetDispatcher (System.Object target, System.Object[] args, System.String cache$$anonymous$$eyName, Boo.Lang.Runtime.DynamicDispatching.DispatcherFactory factory) Boo.Lang.Runtime.RuntimeServices.GetProperty (System.Object target, System.String name) UnityScript.Lang.UnityRuntimeServices.GetProperty (System.Object target, System.String name) Charackter$$anonymous$$ontrolle.Update () (at Assets/Charackter$$anonymous$$ontrolle.js:10)

The same one isnt it? well my character Controller now is with my gameobject... ; / hmmm

avatar image TheEasterHazy · Sep 19, 2011 at 05:04 AM -1
Share

Hey, well I has my gameobject selected when I made a new Character Controller... isnt that the only thing I need to do?. If not please tell me how I can do that...

Sorry Im still "new" to Unity...

Thank You!

avatar image TheEasterHazy · Sep 19, 2011 at 05:04 AM -1
Share

Well I was on my gameobject wehen I made a character Controller... isnt that the only thing I need to do, if not please tell me how I do that...

Sorry Im still "new" to unity ;D

Thank you

avatar image Kiloblargh · Jul 15, 2013 at 05:26 PM 0
Share

Edit your question or post comments. Don't respond to answers with new answers that aren't answers.

avatar image clunk47 · Jul 15, 2013 at 07:45 PM 0
Share

Please, someone close this question! lol

Show more comments

2 Replies

· Add your reply
  • Sort: 
avatar image
1

Answer by Ludiares.du · Sep 18, 2011 at 09:52 PM

Make sure you've got a character controller attached to the game object

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
avatar image
1

Answer by Clunk · Sep 19, 2011 at 05:43 AM

Change Input.GetKey("Left Shift") to Input.GetKey(KeyCode.LeftShift);

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

6 People are following this question.

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

Related Questions

What is wrong with my script? 1 Answer

Simple Script getting Errors. 1 Answer

When Is This Script Destroyed? 1 Answer

Have null errors 1 Answer

NullReferenceException Error 6 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