This plugin lets you easily add as many CPU and/or GPU colliders to your scene as you want.
Does the scene asset you would like to use lack colliders somewhere? Add CPU colliders, which collide with other rigid body objects such as the person body model.
Do you have characters with long hair or clothes and they keep clipping through the furniture in the poses you would like to use? Add GPU colliders, those collide with simulated hair and clothes.
The custom colliders are meant to be used for environment collisions. The plugin won't magically turn CUA objects into properly configured dynamic physical objects - objects that would bounce off other physical surfaces ; the CUA creator would have to set them up correctly in Unity.
Then configure the collider in the plugin's settings.
If you want to, you can add multiple instances of the plugin to the same object, one for each collider.
This is where all the collider's properties are configured. The supported shapes are:
You can enable CPU and/or GPU collisions for the colliders. CPU colliders interact with other rigid physical objects, such as character bodies. GPU colliders interact with simulated hair and clothes.
Box Notes:
VAM does not natively support GPU box colliders. If GPU Collider is enabled for the Box Shape, the plugin will approximate the shape by filling it with capsules. The box's height defines the diameter of the capsules, so keep that relatively low. You can choose the orientation in which the capsules will be placed inside the box:
Plane Notes:
The plane collider is not supported as a CPU collider, ticking that checkbox will do nothing. Be aware that the Plane GPU collider is infinite. While for visualization purposes it's rendered as a square, it stretches into infinity. Any cloth or hair crossing the in-front/behind plane's boundaries will collide with the plane. The front of the plane is indicated by the object's up axis (green).
It's a good choice for a room's floor, as long as there are no levels below it. Or even for walls/ceiling, assuming you need GPU colliders there at all. In most cases, it's not a good choice for the top of a sofa or a bed, since it will also collide with any hair and cloth that's next to the furniture, if it crosses its above/below boundary. Consider using the box emulated by capsules for objects like beds instead. But the plane might look and perform better and cause no issues in your scene, if all the hair/cloth action happens only on top of the furniture item.
Motion
On the Motion tab, you can define up to 10 motions for the collider. A motion will move the collider from its Starting Position to the Target Position. It can be used to push things where they should be. It is mostly useful for GPU-only colliders, since exact position of simulated hair or clothes is not saved with poses, a little push can help with configuring the pose as it should look.
A motion is defined by:
The motion module uses the same preset system as DildoLanguage or SexyFluids. You can save or load the presets, and copy-paste them. Copy-paste uses the system clipboard and will work even between different instances of the plugin.
You can test-run the selected motion using the Run Queued or Run Immediately buttons. These differ if there is another motion already running: the Queued option will schedule the new motion to run after the currently active motion finishes, the Immediately option will run the new motion... immediately. You can also start the motions from triggers, the actions are also called Run Queued and Run Immediately.
For example videos of how a motion could be used to help your posing, see the v2 update description. It includes two example videos:
In addition to that, the collider's axes are drawn when the Position tab is active. If there is no local position, these will align with the object's controller graphics, so you might not even notice them.
GPU box warning: Changing any of the size properties of a Box shape collider leads to all the internal capsules being recreated, if the box has GPU collisions enabled. For performance reasons, avoid animating those properties.[/SPOILER]
Does the scene asset you would like to use lack colliders somewhere? Add CPU colliders, which collide with other rigid body objects such as the person body model.
Do you have characters with long hair or clothes and they keep clipping through the furniture in the poses you would like to use? Add GPU colliders, those collide with simulated hair and clothes.
The custom colliders are meant to be used for environment collisions. The plugin won't magically turn CUA objects into properly configured dynamic physical objects - objects that would bounce off other physical surfaces ; the CUA creator would have to set them up correctly in Unity.
Usage
Add CustomCollider.cslist to any atom in the scene. The collider will be placed relative to that atom's position. If you want to freely place a collider in the scene, the best choice is to use the Empty atom from VAM's Misc category.Then configure the collider in the plugin's settings.
If you want to, you can add multiple instances of the plugin to the same object, one for each collider.
Shape
This is where all the collider's properties are configured. The supported shapes are:
- Sphere
- Capsule (cylinder with sphere caps, oriented along one of the three local axes of the object)
- Box
- Plane
You can enable CPU and/or GPU collisions for the colliders. CPU colliders interact with other rigid physical objects, such as character bodies. GPU colliders interact with simulated hair and clothes.
Box Notes:
VAM does not natively support GPU box colliders. If GPU Collider is enabled for the Box Shape, the plugin will approximate the shape by filling it with capsules. The box's height defines the diameter of the capsules, so keep that relatively low. You can choose the orientation in which the capsules will be placed inside the box:
- Auto: Automatically choose between Width or Length, depending on which is higher. This way the lowest possible amount of capsules will be used to fill the box, which is in general good for performance. But it might not necessarily achieve the best behavior for your scene and pose.
- Length: The capsules will be oriented along the forward (blue) axis of the object.
- Width: The capsules will be oriented along the right (red) axis of the object.
- Length+Width: Capsules in both directions will be used to fill the box.
Plane Notes:
The plane collider is not supported as a CPU collider, ticking that checkbox will do nothing. Be aware that the Plane GPU collider is infinite. While for visualization purposes it's rendered as a square, it stretches into infinity. Any cloth or hair crossing the in-front/behind plane's boundaries will collide with the plane. The front of the plane is indicated by the object's up axis (green).
It's a good choice for a room's floor, as long as there are no levels below it. Or even for walls/ceiling, assuming you need GPU colliders there at all. In most cases, it's not a good choice for the top of a sofa or a bed, since it will also collide with any hair and cloth that's next to the furniture, if it crosses its above/below boundary. Consider using the box emulated by capsules for objects like beds instead. But the plane might look and perform better and cause no issues in your scene, if all the hair/cloth action happens only on top of the furniture item.
Position
The Position tab lets you move and rotate the collider relative to the atom it's attached to. This specifies the Default Position of the collider.Motion
On the Motion tab, you can define up to 10 motions for the collider. A motion will move the collider from its Starting Position to the Target Position. It can be used to push things where they should be. It is mostly useful for GPU-only colliders, since exact position of simulated hair or clothes is not saved with poses, a little push can help with configuring the pose as it should look.A motion is defined by:
- Starting Position: previewed in blue outline when the tab is active
- Target Position: previewed in green outline when the tab is active
- The interpolator to move the collider from the Starting to the Target Position
- The motion duration
- Options to enable CPU or GPU Collider when the motion starts
- Options to disable CPU or GPU Collider after the motion reaches the target
The motion module uses the same preset system as DildoLanguage or SexyFluids. You can save or load the presets, and copy-paste them. Copy-paste uses the system clipboard and will work even between different instances of the plugin.
You can test-run the selected motion using the Run Queued or Run Immediately buttons. These differ if there is another motion already running: the Queued option will schedule the new motion to run after the currently active motion finishes, the Immediately option will run the new motion... immediately. You can also start the motions from triggers, the actions are also called Run Queued and Run Immediately.
For example videos of how a motion could be used to help your posing, see the v2 update description. It includes two example videos:
- How to fix hair clipping through a surface when a pose is loaded, even if the surface has a collider
- How to tweak positioning of simmed clothing, which spawns in its default position when a pose is loaded
Visualization
Each collider is visualized in two ways:- Wireframe: white lines, can be seen through other objects. Let's you see where the collider is placed even if it's inside another object.
- Solid: blue shape, respecting visibility. Let's you see where the collider protrudes out of visual geometry.
In addition to that, the collider's axes are drawn when the Position tab is active. If there is no local position, these will align with the object's controller graphics, so you might not even notice them.
Triggers
Most of the collider settings are exposed and can be controlled from VAM's trigger system. Disabling the whole plugin can be also used to disable its collider.GPU box warning: Changing any of the size properties of a Box shape collider leads to all the internal capsules being recreated, if the box has GPU collisions enabled. For performance reasons, avoid animating those properties.[/SPOILER]