• Hi Guest!

    We are extremely excited to announce the release of our first Beta for VaM2, the next generation of Virt-A-Mate which is currently in development.
    To participate in the Beta, a subscription to the Entertainer or Creator Tier is required. Once subscribed, download instructions can be found here.

    Click here for information and guides regarding the VaM2 beta. Join our Discord server for more announcements and community discussion about VaM2.
CuaGpuColliders

Plugins + Scripts CuaGpuColliders

Download [<1 MB]

Foost

Well-known member
Featured Contributor
Joined
Sep 23, 2024
Messages
117
Reactions
534
Foost submitted a new resource:

CuaGpuColliders - Adds GPU colliders to CUA objects, allowing them to interact with clothes and hair

A simple plugin that enabled CUA atoms to collider with VAM clothing and hair.

To use the plugin, just add CuaGpuColliders.clist to a CUA atom.

When attached to a CUA atom, it automatically creates GPU colliders for any sphere and capsule colliders it can find in the asset.
It will do nothing if the asset has only box or mesh colliders, those are not supported by GPU colliders.

The plugin has nothing to configure, but you can check its custom UI for an overview...

Read more about this resource...
 
any chance for a session plugin to automatically add this to cuas? Great plugin btw
 
Any chance this could also work for colliding with floors?

VAM's GPU colliders work only with sphere and capsule colliders. Unfortunately floors will most likely use box colliders, or even worse, probably just one big mesh collider for the whole asset.

At some point I'd like to create another addon that would let you place GPU colliders freely, including a grid of capsules roughly approximating a box. But you'd have to place those manually.
 
any chance for a session plugin to automatically add this to cuas? Great plugin btw

I am personally not a fan of those "add to everything" plugins. Especially since this addon won't work with way too many CUAs which just slap one mesh collider onto everything. But maybe one day...
 
I noticed it's not compatible with Stopper's CUA Controllers. I'm guessing it has something to do with how Stopper handles the CUA, as there's a noticable asset reload when initializing it.
This is the error message your plugin throws:
!> CustomUnityAsset: Expected the CUA object to have one active child with the loaded asset, but it has 2 childern in total and at least two active.
I don't know how much work it'd be to fix. Since honestly, Stopper's plugin is still experimental. So might not be worth the time fixing it for now.
 
I noticed it's not compatible with Stopper's CUA Controllers. I'm guessing it has something to do with how Stopper handles the CUA, as there's a noticable asset reload when initializing it.
This is the error message your plugin throws:

I don't know how much work it'd be to fix. Since honestly, Stopper's plugin is still experimental. So might not be worth the time fixing it for now.

Thanks for the report. I'll at least have a look if I find some time. This error message means that there are multiple objects loaded in the CUA hierarchy when I get the notification about asset change, so my plugin has no idea which one to use for the GPU colliders. This happens even with the normal VAM's CUA loader when switching assets from one assetbundle. I implemented a workaround for that, so it might be not so hard to extend it for this case, who knows. I wanted to play some more with his plugins anyway :)
 
Hey!
I've been struggling with CUA hair, going through models, and I thought your plugin might do the trick.
On paper, I just have to open the hair asset bundle in Unity, add a capsule collider, save the changes, and be done with it. But oh boy, extracting the asset bundle and using Unity aren't that simple! So I'm wondering if you've got a simpler way to add a collider so my CUA hair acts as intended.
 
Hey!
I've been struggling with CUA hair, going through models, and I thought your plugin might do the trick.
On paper, I just have to open the hair asset bundle in Unity, add a capsule collider, save the changes, and be done with it. But oh boy, extracting the asset bundle and using Unity aren't that simple! So I'm wondering if you've got a simpler way to add a collider so my CUA hair acts as intended.
Not really, no. But also this plugin is all about adding GPU colliders to existing standard colliders, that won't help you with CUA hair at all I am afraid. Unless you need character clothes or non-CUA hair to collide with your CUA hair, that's all GPU colliders are about. Also GPU colliders can't receive any physics impulses, they just move with the colliders they are create from, and then cloth/hair collide with them, that's all.
 
Great plugin! Though for the longest time I've been struggling with creating a nice collider surface for the build in SimSheet, sadly due to the nature of the shape of spheres / capsules it makes it virtually impossible to create a proper surface flat for example for a bed, it will always result in like a "ribbed mattress" due to the capsules forced ratio shape. (you can mitigate it by using hundreds of capsules I guess, but this is a horrible solution)

There has to be some kind of solution or workaround in creating a (near) flat surface that supports gpu colliders, I guess the capsule's relative sizes are locked because if altered it wouldn't technically be a "capsule" anymore, still, there has to be a way to maybe force deform it and retain gpu collider support? hmm.
 
Last edited:
Great plugin! Though for the longest time I've been struggling with creating a nice collider surface for the build in SimSheet, sadly due to the nature of the shape of spheres / capsules it makes it virtually impossible to create a proper surface flat for example for a bed, it will always result in like a "ribbed mattress" due to the capsules forced ratio shape. (you can mitigate it by using hundreds of capsules I guess, but this is a horrible solution)

There has to be some kind of solution or workaround in creating a (near) flat surface that supports gpu colliders, I guess the capsule's relative sizes are locked because if altered it wouldn't technically be a "capsule" anymore, still, there has to be a way to maybe force deform it and retain gpu collider support? hmm.
Unfortunately, there is no clean solution, other than rewriting VAM's compute shaders to support box GPU colliders as well, or even better, SDF colliders. Hopefully VAM2 will be better in this regard. You can't stretch the capsules, they are always cylinders with spherical caps. You can just make them thinner and add a LOT of them, intersecting each other. The shape still won't be flat.

Another option for a bed is to use the plane collider. I.e. add the slate atom to the scene, align it with the bed's top, and hide the visual. But the plane GPU collider is infinite, so you can't then really have any cloth or hair anywhere else in the scene intersecting the bed's plane.
 
Unfortunately, there is no clean solution, other than rewriting VAM's compute shaders to support box GPU colliders as well, or even better, SDF colliders. Hopefully VAM2 will be better in this regard. You can't stretch the capsules, they are always cylinders with spherical caps. You can just make them thinner and add a LOT of them, intersecting each other. The shape still won't be flat.

Another option for a bed is to use the plane collider. I.e. add the slate atom to the scene, align it with the bed's top, and hide the visual. But the plane GPU collider is infinite, so you can't then really have any cloth or hair anywhere else in the scene intersecting the bed's plane.
Is it perhaps possible to create Capsule colliders that ONLY collide with the simsheet but does not collide with a person atom?
So that the person atom itself can retain it's regular collider interaction with the mesh/box box colliders of the bed CUA, and essentially ignores the added capsules?

*
(Like with regular build-in vam capsules, you can disable the "collison" tickbox under the "physics object tab", and it will then only collide with the simsheet/clothes/hair and ignore the person atom's body (which is great))
 
Last edited:
Is it perhaps possible to create Capsule colliders that ONLY collide with the simsheet but does not collide with a person atom?
So that the person atom itself can retain it's regular collider interaction with the mesh/box box colliders of the bed CUA, and essentially ignores the added capsules?
At technical level, yes. You can create GPU colliders without standard colliders. In code, not in VAM's UI. So someone would have to write a plugin that would let you place GPU colliders freely in the scene. I might have a look at that at some point :unsure:

Edit: Actually, you can do that in VAM UI already - add the standard capsule, turn off its physics and collisions. That still leaves GPU colliders enabled for some weird reason ; a bug imo, but useful one. Then set its alpha to -1 to hide. But you got me thinking and I actually already started working on something more useful.
 
Last edited:
Is it perhaps possible to create Capsule colliders that ONLY collide with the simsheet but does not collide with a person atom?
So that the person atom itself can retain it's regular collider interaction with the mesh/box box colliders of the bed CUA, and essentially ignores the added capsules?

*
(Like with regular build-in vam capsules, you can disable the "collison" tickbox under the "physics object tab", and it will then only collide with the simsheet/clothes/hair and ignore the person atom's body (which is great))
 
Works perfect, exactly what I was looking for, cheers!

A minor side question which is perhaps not related to said colliders per se, but I noticed that the build in SIM Sheet stops working (it becomes a flat piece of cloth, bassically it's physics get's disabled) whenever the male or female has one of the various bodyhairs equipped, for example; pick any of Kemenate beards / body hair / pubes, "equip" it on the person atom, and the SIM sheet's physics will stop working, unequip the hair and the physics of the SIM sheet instantly work again..

The same applies to females and various pubic hairs, however not on all of them, i'm a bit confused by this issue and was wondering if others experience the same.

(I attached 2 images, one of how the SIM sheet "should" look like, and 1 where it turns into a flat plane the moment "Chest 05" hair is equipped on the male)
 

Attachments

  • Screenshot 2025-05-27 001809.png
    Screenshot 2025-05-27 001809.png
    1 MB · Views: 0
  • Screenshot 2025-05-27 001828.png
    Screenshot 2025-05-27 001828.png
    1.1 MB · Views: 0
Works perfect, exactly what I was looking for, cheers!

A minor side question which is perhaps not related to said colliders per se, but I noticed that the build in SIM Sheet stops working (it becomes a flat piece of cloth, bassically it's physics get's disabled) whenever the male or female has one of the various bodyhairs equipped, for example; pick any of Kemenate beards / body hair / pubes, "equip" it on the person atom, and the SIM sheet's physics will stop working, unequip the hair and the physics of the SIM sheet instantly work again..

The same applies to females and various pubic hairs, however not on all of them, i'm a bit confused by this issue and was wondering if others experience the same.

(I attached 2 images, one of how the SIM sheet "should" look like, and 1 where it turns into a flat plane the moment "Chest 05" hair is equipped on the male)
Huh that's interesting. Perhaps there is a limit on how many GPU colliders/sim items can be in the scene. And by adding hair with enough strands, there is no room left to sim the sheet.

Is it happening without the fake-box GPU colliders? If you reduce the overlap, or increase the box height to increase the radius and therefore reduce the amount of capsules filling the box, does that help?
 
Huh that's interesting. Perhaps there is a limit on how many GPU colliders/sim items can be in the scene. And by adding hair with enough strands, there is no room left to sim the sheet.

Is it happening without the fake-box GPU colliders? If you reduce the overlap, or increase the box height to increase the radius and therefore reduce the amount of capsules filling the box, does that help?
It happens regardless of the fake-box gpu colliders.

Even having an empty scene with just one male person atom, and 1 SIM Sheet, results in the same behaviour when just 1 piece of the problematic hair is "equipped".

* The implication that there's an invisible limit to the amount of total GPU colliders that can run in a scene based on the amount of strands is interesting to me, and would explain the issue perfectly.
It just remains me with the question if there's a way to force the SIM Sheet into a higher priority, bassically I rather have the SIM Sheet behave normally vs the random strands of body hair / pubes which it I guess currently prioritizes...


**
What puzzles me though, is why ONLY body hair / pubes affect the SIM Sheet seemingly, I don't think I ever seen a piece of "head hair" that has made the SIM Sheet not work, it's like ALWAYS the body/face hair / pubes....
Though visually the head hair has way more strands I feel like... which makes no sense.
 
Last edited:
Maybe it's just a bug, I have no idea really. You can try turning off Sim for the pubes/body hair, it might help. If it does not, I really don't know what might be happening.
 
Back
Top Bottom