Battle mech - Creating damage model

Поділитися
Вставка
  • Опубліковано 26 січ 2025

КОМЕНТАРІ • 9

  • @ロボ軍団作りたい人
    @ロボ軍団作りたい人 2 місяці тому +3

    Mech Warrior?😃😃😃

    • @amirhm6459
      @amirhm6459  2 місяці тому

      @@ロボ軍団作りたい人 yeah similar tank walker mech style

  • @zao7035
    @zao7035 2 місяці тому +3

    Are the individual body parts separate objects attached to a invisible skeleton? or is this some kind of shader magic?

    • @amirhm6459
      @amirhm6459  2 місяці тому +2

      @@zao7035 It is shader, only use one skinned mesh, one material instance and one skeleton. The booleans to turn on off is from the shader.

    • @zao7035
      @zao7035 2 місяці тому

      @@amirhm6459 Interesting, but how does the mech know which body part should be taking damage? And how does the bullet know if it should ignore arms that has already been destroyed?

    • @amirhm6459
      @amirhm6459  2 місяці тому

      @@zao7035 Great question, I make the system as individual components. There is bullet components, health components with colliders for each body parts, and shader component. Each body parts have individual colliders parented to the armature bones. The bullet can detect collision with the body colliders only, when the collision happens, the bullet will call the collider component to perform damage based of the bullet power. The body collider also will set the shader parameters if the body part health is below zero. It definitely takes more time to setup system like this, but I found component based system is very scalable in long terms and every change or upgrade on the component will not make other components broken

    • @amirhm6459
      @amirhm6459  2 місяці тому

      And to make the bullet not detecting if the body part is broken. Simply I deactivate the collider in health component when the health component is below zero. Specific for chest health component if the health of this below zero, will triggering the death sequence

    • @zao7035
      @zao7035 2 місяці тому

      @@amirhm6459 Thank you for sharing, I made a similar system a while back using an entirely opposite approach, I used separate mesh for separate body part, and I used inheritance instead of composition. And I now have a sudden urge to rewrite my entire project...