https://github.com/vrlabs/particle-driver
A legacy method for animating on particle death.
https://github.com/vrlabs/particle-driver
Last synced: 28 days ago
JSON representation
A legacy method for animating on particle death.
- Host: GitHub
- URL: https://github.com/vrlabs/particle-driver
- Owner: VRLabs
- License: mit
- Created: 2021-10-18T13:28:09.000Z (over 4 years ago)
- Default Branch: main
- Last Pushed: 2024-04-24T14:07:35.000Z (about 2 years ago)
- Last Synced: 2024-04-24T17:24:47.335Z (about 2 years ago)
- Homepage:
- Size: 39 MB
- Stars: 0
- Watchers: 3
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# Particle Driver
[](https://github.com/VRLabs/Particle-Driver/releases/latest)
[](https://github.com/VRLabs/Particle-Driver/blob/main/LICENSE)
[](https://unity3d.com/unity/whats-new/2019.4.31)
[](https://vrchat.com/home/download)
[](https://discord.vrlabs.dev/)
[](https://patreon.vrlabs.dev/)
A legacy method for animating on particle death that uses the [Layer Weight Tool](https://github.com/VRLabs/Layer-Weight-Tool)
## This package is depreated! If you want to drive a parameter on world or player collision, [get the new package here](https://github.com/VRLabs/Collision-Detection)
---
## How it works
* The ``Particle Driver Stay Active.controller`` continuously enables ``Particle System`` to re-enable the particle system immediately after it's been disabled.
* The ``Particle System`` object is disabled on collision via [Stop Action](https://docs.unity3d.com/ScriptReference/ParticleSystemStopAction.html). When re-enabled, the ``Particle Driver Weight.controller`` will reset.
* ``Weight.controller`` uses [Animator Layer Control](https://docs.vrchat.com/docs/state-behaviors) to change the weight of the ``Particle Driver`` layer based on its weight.
* The ``ParticleDeath`` parameter value is multiplied by the weight and can be used as a transition condition.
## Install guide
https://github.com/VRLabs/Particle-Driver/assets/76777936/6733fdd6-53b6-43ad-90cd-a43dea06bacc
* Merge the Animator Controller ``Particle Driver FX`` to your own FX Controller, using the [Avatars 3.0 Manager](https://github.com/VRLabs/Avatars-3.0-Manager) tool.
* Drag & drop the ``Particle Driver`` prefab into the base of your Hierarchy.
* Right click and unpack the prefab, then drag & drop it onto your avatar.
* Adjust the transforms of ``Particle System`` and ``Collider`` as needed.
* In the ``Resources/Animations/Particle Driver Weight`` controller, in the ``Max Weight`` and ``Min Weight`` animation state, change the ``Index`` to the index of the ``Particle Driver`` Layer on your FX Controller
* The top layer is index 0, the second layer is index 1, etc.
## How to use
* When the Collider is colliding with the Particle, the ``ParticleDriver/IsColliding`` parameter will be set to ``True``, otherwise, it will be set to ``False``.
## Performance stats
```c++
Colliders: 1
Particle Systems: 1
FX Animator Layers: 1
Sub Animators: 2
```
## Hierarchy layout
```html
Particle Driver
|-Particle System
|-Collider
```
## Contributors
* [lin](https://github.com/oofdesu)
## License
Particle Driver is available as-is under MIT. For more information see [LICENSE](https://github.com/VRLabs/Particle-Driver/blob/main/LICENSE).
[
](https://vrlabs.dev "VRLabs")
[
](https://discord.vrlabs.dev/ "VRLabs")
[
](https://patreon.vrlabs.dev/ "VRLabs")
[
](https://twitter.com/vrlabsdev "VRLabs")