Search Unity

  1. Unity 2019.2 is now released.
    Dismiss Notice

running soldier collider

Discussion in 'Physics' started by boolfone, Feb 1, 2015.

  1. boolfone

    boolfone

    Joined:
    Oct 2, 2014
    Posts:
    289
    I have a scene with a running soldier in it:

    Screen Shot 2015-02-01 at 5.58.56 PM.png

    I was wondering if it is possible to have the collider change with the soldier's movement?

    For instance, I might want a bullet shot between his legs to miss him.

    Thanks.
     
  2. mayursojitra

    mayursojitra

    Joined:
    Jan 20, 2015
    Posts:
    2
    use edge collider
    i hope it'll work
     
  3. Billy4184

    Billy4184

    Joined:
    Jul 7, 2014
    Posts:
    4,663
    You'll either have to use a mesh collider directly from the soldier model or go and make a simpler model of the soldier and use that as the mesh collider.
     
  4. boolfone

    boolfone

    Joined:
    Oct 2, 2014
    Posts:
    289
    Is there a way to make the mesh collider follow the soldier's movements?

    Here is what it does right now:



    Thanks.
     
  5. Billy4184

    Billy4184

    Joined:
    Jul 7, 2014
    Posts:
    4,663
    The bones are what matter, you have to put the collider on the bones. However, judging by the look of your video, the amount of polygons on that collider will have a horrific impact on your performance and be a waste of processing power. You could probably put a box collider on each bone and it would still look good. Otherwise create a VERY simple humanoid form in Blender or something and use the mesh as a collider.
     
  6. Kavorka

    Kavorka

    Joined:
    Sep 15, 2012
    Posts:
    237