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

Unexpected optimization with regard to "Pickup PB Gimmick" #61

Closed
jerryzmtz opened this issue Nov 2, 2023 · 2 comments
Closed

Unexpected optimization with regard to "Pickup PB Gimmick" #61

jerryzmtz opened this issue Nov 2, 2023 · 2 comments

Comments

@jerryzmtz
Copy link

Don't know whether it is possible to be detected automatically, but it seems that a PB setup like this (Screenshot 1) will break unexpectedly, when you enable "Delete Unused Components" or "Delete Unused GameObjects"

Delete Unused Components (Screenshot 2): Will delete the PB which is useful for pickup.
Delete Unused GameObjects (Screenshot 3): Will delete intermediate object which is referred by the PB. In this case, it is "GlassesObj"

This setup is usually useful for "Pickup" related gimmicks, with which one could pickup a MeshRender to some extent. It needs to put a MeshRender under a bone. eg. Bone1/Bone2/MeshRender.

Screenshot1
image_2023-11-02_19-07-14
image_2023-11-02_19-08-06

@d4rkc0d3r
Copy link
Owner

Delete Unused Components (Screenshot 2): Will delete the PB which is useful for pickup.

This is a pretty straight forward bug on my side. The dependency check only added game objects on moving transforms of the PB and since the glasses obj is in the ignore list it doesn't see it. This is ofc just wrong logic on my implementation, it should add all child components as dependencies.

Delete Unused GameObjects (Screenshot 3): Will delete intermediate object which is referred by the PB. In this case, it is "GlassesObj"

Yup I forgot to add the PB ignore transforms to the list of used game objects. In that screenshot I also see it deleting Bone02 which I can't actually explain, unlike the GlassesObj which shouldn't get deleted since its referenced. Bone02 should still be in the list of game objects moved by the phys bone so dunno why it disappears.

Thanks for the detailed bug report!

@d4rkc0d3r
Copy link
Owner

should be fixed with 3.2.2

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

No branches or pull requests

2 participants