I've used OnColliderEnter() for behavior when "object with script attached" comes into contact with "something else". For example, do you attach OnColliderEnter() to the controller to determine that "other object" and "other object" come into contact?
I'm sorry that the question is hard to understand...
I want to know if I can handle OnColliderEnter() for other objects when I want to manage everything in the controller class.
unity3d
You cannot take it directly.
(Of course, you can implement collision determination by yourself without using Collider, but that's different from what you intended, right?)
Therefore, if you want to write the logic of the collision on the controller,
1. Write the logic of the collision on the controller side (assume HandleCollisions())
2. Call Controller::HandleCollisions() in OnColliderEnter() of the actual gameObject to which the collider is attached
must be
915 When building Fast API+Uvicorn environment with PyInstaller, console=False results in an error
611 GDB gets version error when attempting to debug with the Presense SDK (IDE)
618 Uncaught (inpromise) Error on Electron: An object could not be cloned
572 rails db:create error: Could not find mysql2-0.5.4 in any of the sources
© 2024 OneMinuteCode. All rights reserved.