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 Ryujose · Jan 22, 2015 at 11:09 PM · colliderplayerparticlesdetectionshoot

How to detect a collider in a particle?

Hello community.

I need to know how I can collide a particle with a GameObject with some detection collider added on it.

Example:

I've an enemy who's shoot is a constant particle. And I need to collide it on my player.

I'm completely lost, what method can I use?

Thanks in advance.

Regards.

Comment
Add comment · Show 2
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 khos85 · Jan 22, 2015 at 11:18 PM 0
Share

I think you can set the simulation space option to world space not local space, then it will work, also enable collision and set the parameters there, all of these things I refer to are for the particle system. Hope that helps

avatar image khos85 · Jan 22, 2015 at 11:21 PM 1
Share

I made a quick video for you, see youtube link:https://www.youtube.com/watch?v=oZ5rAo$$anonymous$$j7cA&feature=youtu.be

4 Replies

· Add your reply
  • Sort: 
avatar image
1

Answer by cdrandin · Jan 22, 2015 at 11:18 PM

How complex is the particle? Can it be characterized as a ray? Don't try to do collision per particle that is being emitted. That is completely overkill!

Rather incase your particle in some basic primitive collider. If you only care about direction collision use a Ray, if you care about linear spatial collision use a capsule. Just play with which geometry suits your needs.

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 DanSuperGP · Jan 22, 2015 at 11:19 PM

Assuming you're using a Shuriken Particle System, you would use OnParticleCollision.

http://docs.unity3d.com/ScriptReference/MonoBehaviour.OnParticleCollision.html

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
0

Answer by hav_ngs_ru · Jan 22, 2015 at 11:17 PM

http://docs.unity3d.com/ScriptReference/MonoBehaviour.OnParticleCollision.html

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
0

Answer by Ryujose · Jan 24, 2015 at 03:46 AM

I've done some checks with documentation and it doesn't Works.

The thing I'm trying to do is:

I've a group of particles in one particle system. Those particle systems are shooted by an enemy.

And I want it to those particles have effect on my player like a collision with some detection but it doesn't Works.

I've configured the "void OnParticleCollision(GameObject other)" by tag, but in practice it doesn't collide with player.

I've set the colision on true, on inspector. And it do nothing at all.

I've tried to add a box collider or something else but it says is to small to detect it.

I'm using 2D settings for colliders.

Any tips? Thanks for the help.

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

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

Related Questions

Check if player is colliding with top face of box collider? 1 Answer

Collision detection problem 1 Answer

Adding movement speed of Player to 1 Answer

Particle Collision / Trigger not being reported to On_xx Event 1 Answer

NavMesh problem it does not respond corectly 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