stride icon indicating copy to clipboard operation
stride copied to clipboard

[Physics] Adding margins to convex hull colliders (Issue1577)

Open dloe opened this issue 1 year ago • 1 comments

PR Details

Allow specification of margin for collider shapes. Shows to be useful for ConvexHull colliders.

Description

Margin property now able to be set on ConvexHull collider shape. Added margin getter and setting vars onto ConvexHullColliderShape as well as the viewable field in the properties box for the user to adjust. The base class ColliderShape contains where margin is defined as recommened so all collider shapes can potentially benefit from the new variable.

Related Issue

Link to issue: https://github.com/stride3d/stride/issues/1577

Link to initial discussion: https://github.com/stride3d/stride/discussions/1574

Motivation and Context

Originally reported as a missing field that solves an issue related to a test project not being able to adjust the corresponding collider. This margin not being able to be adjusted was causing unintended collisions and not allowing the user to be able to properly set up their ConvexHullCollider properties to fix the problem in the property box.

For additonal testing, I made a fork of the users orignal project that showcases the issue here: https://github.com/dloe/StrideEngineIssue1577_RigidBodyPhysicsBugProject

Types of changes

  • [ ] Docs change / refactoring / dependency upgrade
  • [ ] Bug fix (non-breaking change which fixes an issue)
  • [x ] New feature (non-breaking change which adds functionality)
  • [ ] Breaking change (fix or feature that would cause existing functionality to change)

Checklist

  • [ ] My change requires a change to the documentation.
  • [ ] I have added tests to cover my changes.
  • [ ] All new and existing tests passed.
  • [x ] I have built and run the editor to try this change out.

dloe avatar May 20 '24 22:05 dloe

@dotnet-policy-service agree

@dloe please read the following Contributor License Agreement(CLA). If you agree with the CLA, please reply with the following information.

@dotnet-policy-service agree [company="{your company}"]

Options:

  • (default - no company specified) I have sole ownership of intellectual property rights to my Submissions and I am not making Submissions in the course of work for my employer.
@dotnet-policy-service agree
  • (when company given) I am making Submissions in the course of work for my employer (or my employer has intellectual property rights in my Submissions by contract or applicable law). I have permission from my employer to make Submissions and enter into this Agreement on behalf of my employer. By signing below, the defined term “You” includes me and my employer.
@dotnet-policy-service agree company="Microsoft"

Contributor License Agreement

dloe avatar May 21 '24 02:05 dloe

Looks good, thanks a bunch !

Eideren avatar May 22 '24 22:05 Eideren