Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: Add Primitive Colliders #70

Merged
merged 6 commits into from
May 22, 2023
Merged

feat: Add Primitive Colliders #70

merged 6 commits into from
May 22, 2023

Conversation

mikhail-dcl
Copy link
Collaborator

@mikhail-dcl mikhail-dcl commented May 19, 2023

Closes #36

PBMeshCollider component is taken care of:

  • Created an additional component to hold the parameters required for the systems
  • Created a system that instantiates and takes care of changes in PBMeshCollider and reflects them onto Unity objects
  • Created a system to invalidate the outdated shape and return it to the pool
  • Used UnityComponentPool for Colliders
  • Introduced a meaningful size limit for such pools
  • Took the logic of Cylinder shape generation from the old renderer but cleaned up it heavily and switched to using pools for temporary buffers generation (there is no API to intrude original Mesh buffers)
  • Currently, meshes are generated on the main thread as I don't expect a high restructuring load of primitives. But the logic of generation is thread-agnostic so it will be relatively easy to switch to the thread pool in case of a need
  • For the rest of the shapes used built-in PhysX colliders
  • Updated Arch so now IL2CPP will work fine with non-blittable structures (for more info check Unity support genaray/Arch#100)

Less attention:

  • Introduced physics layers symmetrically to the old renderer
  • Didn't take care of any raycasting components complimenting Colliders as it's out of scope of the PoC

Add a test scene with Box Colliders

Fix scenes lifecycle
Introduce the concept of poolable components providers
Switch Arch to the pure ECS paradigm
Update `Arch.SystemGroups` to support generics
@mikhail-dcl mikhail-dcl requested a review from dalkia May 22, 2023 10:35
@mikhail-dcl mikhail-dcl merged commit 708a094 into main May 22, 2023
2 checks passed
@mikhail-dcl mikhail-dcl deleted the mesh-collider branch May 22, 2023 12:56
Kinerius pushed a commit that referenced this pull request Feb 20, 2024
* Add Primitive Colliders
* Update SourceGen to respect default arguments
* Add a launch panel to test scenes at runtime
* Introduce the concept of poolable components providers
* Switch Arch to the pure ECS paradigm
* Update `Arch.SystemGroups` to support generics
* Update Readme
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Colliders Loading
2 participants