Awesome
Piranha
A simple tool to make rigidbodies swarm a mesh in Unity.
Works on Mesh Filters and Skinned Mesh Renderers.
Setup
- Add the
PiranhaTarget
component to a game object with a Mesh Filter or Skinned Mesh Renderer. - Drag any rigidbodies you want to swarm the target into the
Piranhas
list. - Hit play!
Options
- Increase
Force
to change how attracted the rigidbodies are to the target. - Change the
Activation Mode
toDistance
to prevent rigidbodies from swarming the target unless they are within theActivation Distance
.