You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
In G1, when we pick up an item, its mesh will be automatically destroyed (and the item is put into our inventory). There's also no collision between e.g. a sword in our hand and the world. But when we play in VR, gamers should have the option to enable item collisions for (optional) immersion.
Solution idea
Remote grab: Check if we can disable collisions from GrabStartEvent until GrabEndEvent
Direct grab: When in our hands, the object should become a ghost item without collisions with one of these options:
Once item is grabbed, it will stop collisions for a period of time (e.g. ~2 seconds).
Alternatively, we can do a Physics.Overlap*() check regularly. If there's no Collider returned, we enable the item for collision again.
It might be useful to combine both ideas (e.g. some swords on a shelf in Gomez' warehouse might not collide the first frame(s), but we still can't pull them out of their shelfs except we ghostify them shortly). Please test and decide based on gaming experience.
Add a menu entry to enable/disable this feature. If disabled, items in our hand never collide.
Improved ideas are very welcome. 😃
The text was updated successfully, but these errors were encountered:
JaXt0r
changed the title
Remote grabbing an object should ignore physics until it's in our hands
Item collision v2 - Disable collisions where neccesary
Aug 19, 2024
I tested it with the Physics.OverlapCapsule() and it seems to work fine for all objects. No need for a 2-seconds delay so far. But if needed, we can easily set a Coroutine yield timeout at GUZ.HVR.Components.HVRVobItem.ReEnableCollisionRoutine.ReEnableCollisionRoutine()
Background
In G1, when we pick up an item, its mesh will be automatically destroyed (and the item is put into our inventory). There's also no collision between e.g. a sword in our hand and the world. But when we play in VR, gamers should have the option to enable item collisions for (optional) immersion.
Solution idea
Improved ideas are very welcome. 😃
The text was updated successfully, but these errors were encountered: