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 Michael 16 · May 14, 2011 at 04:42 PM · collisiondestroyoncollisionenter

collide with everything except for me

I made an ice plate that have a collision with everything. When something touch it - it disappear (breaks) in 0.5 seconds.

The problem is that when my "helper" (character that helps in the game), an enemy or even bullets touch it - it desappear BUT when I touch it (the main character) nothing happen!

How I make the ice disappear when everyting, including me, touch it?

here is my code if something wrong there:

function OnCollisionEnter () 
 {
     Destroy(gameObject, 0.5);
 }

(thats all the code)

Sorry for poor english :)

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

1 Reply

· Add your reply
  • Sort: 
avatar image
0

Answer by lil_billy · May 14, 2011 at 04:48 PM

because its ice try OnCollisionStay

Comment
Add comment · Show 5 · 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 FLASHDENMARK · May 14, 2011 at 04:53 PM 0
Share

What do you mean "Because its ice" ?

avatar image Michael 16 · May 14, 2011 at 05:40 PM 0
Share

It don't works...

avatar image lil_billy · May 15, 2011 at 06:50 AM 0
Share

so im not good with debug logs i just use print statements

try putting this in the function parameter (collision : Collision) and above destroy put this: print(collision);

then check the error box at the bottom run your character into the sucker and see if it actually recognizes the players collider if not try attaching a freaking cube to the players feet as a child give it a collider and a script that has it ignore all colliders so it ignores all collisions but everything else wont ignore it

avatar image Michael 16 · May 15, 2011 at 12:06 PM 0
Share

There is no collision with the character!!! now I will try to attach the cube...

avatar image Michael 16 · May 15, 2011 at 01:04 PM 0
Share

Even if it attached as a child don't works!!! There-Is-No-Collision-With-The-Character!!!!!

$$anonymous$$aybe it because of the CharacterController? It the only thing that have this and don't have any mesh colliders. so might be that the problem? It not like I go through the ice, it just nothing happen when I walk on it, it like another thing to walk on...

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

No one has followed this question yet.

Related Questions

2 objects collide, need to destroy one 2 Answers

Have bullets be destroyed when they collide with ANY collider 0 Answers

Help with collisions and destroy please 1 Answer

Colliders Events 1 Answer

Destroying object when player walks over it 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