-
-
Notifications
You must be signed in to change notification settings - Fork 136
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
Null AudioSources, Crash on StoreInteraction assuming Item and Store item not working. #1444
Conversation
Check if source is an item
Need to remove null audioSources if it was destroyed through being a child to a parent gameobject.
Previously was broken, but can now right click and store item into a container
Fixes 1 and 2 seem fine, but on further testing, variations 3. related to the store action still is acting strangely in the sense that its storing multiple items on the same slot. |
Fix to items not taking new slots.
Mentioned issues are now solved, for toolboxes with testing. Items correctly add to new slots. |
… Viewer Did code cleanup structure recommended.
Fixed crash for when an inventory is open and you die. Hands can no longer be accessed. Fixed error with all inventories, there was no position check adding an item at position 0,400 would work just fine. Changed code style to follow as mentioned by iamteapot. |
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.
lgtm
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.
Nice
Summary
Null AudioSources & Crash on hand not being item
AudioSources when used from the pool and assigned to be a child of an object in the world can be destroyed.
The function
FindAvailableAudioSource
never cleaned its list or checked for null AudioSources which caused an exception when being assigned a null one.For StoreInteraction it did not check if the source item actually was an item, and caused an exception interacting with a ID card with its own hand, for example.
Fixed the radial store option not working for toolbox specifically.
PR checklist
Testing