-
Notifications
You must be signed in to change notification settings - Fork 22
Feature/physx conversion tool #175
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
base: master
Are you sure you want to change the base?
Conversation
FilipAlg
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Added some suggestions for using unity utilities where possible. Formatting seems to fail, you can try running dotnet format whitespace --folder . in the AGXUnity dir to replicate this, most likely due to it not running with any defines.
I've also recently added support for Unity Test Framework so it would be great if you could add some test cases to verify that everything is working properly
| ConvertObjects( m_physXAssets ); | ||
| } | ||
|
|
||
| using ( new UndoCollapseBlock( "Convert Selected Prefab Assets" ) ) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Have you tested that this works with immutable and/or nested prefabs?
|
|
||
| newObject.isStatic = asset.gameObject.isStatic; | ||
|
|
||
| var colliderScale = asset.gameObject.transform.lossyScale; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It's not clear to me that this works in all cases, have you tried with nested scales and/or rotated objects at different nesting levels?
| Mesh readableMesh = new Mesh(); | ||
| readableMesh.vertices = physXMesh.sharedMesh.vertices; | ||
| readableMesh.triangles = physXMesh.sharedMesh.triangles; | ||
| agxMesh.AddSourceObject( readableMesh ); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Does this case work across reloads and such? I vaguely remember trying something similar and it not yielding the desired results
First version of conversion tool