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 fjcym11 · Dec 22, 2012 at 10:57 PM · cubeworldborder

Cannot make a world edge

I have created 4 cubes on the edge of the terrain, making each cube the right length of the terrain to create a world border but when my character controller tries to walk into the cube it walks straight through and off the terrain, does anyone have any scripts/ tips on how to fix this?

Comment
Add comment
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

3 Replies

· Add your reply
  • Sort: 
avatar image
3

Answer by Piflik · Dec 23, 2012 at 12:14 AM

Don't move your character using transform.Translate() (or transform.position). This ignores collision.

Comment
Add comment · Show 6 · 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 Bunny83 · Dec 23, 2012 at 12:54 AM 0
Share

It would be great when you add that when he uses the CharacterController component that he has to move it with it's $$anonymous$$ove of Simple$$anonymous$$ove function ;)

avatar image fjcym11 · Dec 23, 2012 at 08:25 AM 0
Share

I'm a bit rusty on how to use unity so how do i check both those things? thanks

avatar image Nanity · Dec 23, 2012 at 08:59 AM 0
Share

http://docs.unity3d.com/Documentation/ScriptReference/CharacterController.$$anonymous$$ove.html

avatar image fjcym11 · Dec 23, 2012 at 07:10 PM 0
Share

i don't have either transform.Translate() or transform.position in my character controller

avatar image Nanity · Dec 24, 2012 at 09:33 AM 0
Share

The movement script would be very helpful in this case, otherwise these are all blind guesses.

Show more comments
avatar image
0

Answer by sparkzbarca · Dec 22, 2012 at 10:58 PM

cubes need colliders. Select the box then on top go to component-> physics -> box collider.

Assuming of course your using the default character which has a rigidbody etc so it can collide.

Comment
Add comment · Show 2 · 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 fjcym11 · Dec 22, 2012 at 11:18 PM 0
Share

the controller has a rigidbody and the cubes all have box colliders

avatar image Bunny83 · Dec 23, 2012 at 12:52 AM 0
Share

If he uses a CharacterController he doesn't need a Rigidbody. The CharacterController is a replacement for a rigidbody which is not affected by the physics system. The CC uses it's own collixion detection. However this works only when you use the $$anonymous$$ove or Simple$$anonymous$$ove function to move it. Also a CC, unlike a Rigidbody, can only collide with it's own capsule.

avatar image
0

Answer by Zbyl · Dec 23, 2012 at 12:03 AM

Maybe the player and the boxes are in layers that don't collide? See: http://docs.unity3d.com/Documentation/Components/LayerBasedCollision.html

Maybe your character controller travels too fast? Has too thick or too thin "skin"? Maybe the boxes are too thin?

Comment
Add comment · Show 2 · 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 fjcym11 · Dec 23, 2012 at 01:34 AM 0
Share

In a hope to make things easier, im using the default first person controller

avatar image fjcym11 · Dec 23, 2012 at 04:33 AM 0
Share

ive made the boxes x: 100 and my character controller can still walk through it and they are on the same layer

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

14 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

Related Questions

Multiple Cars not working 1 Answer

Generating Meshes Is Slow 1 Answer

cube based enging 1 Answer

Collision with specific object... 2 Answers

Box collider doesnt detect collision 0 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