In our Grabber component we log an error if PhysicsHandle
couldn’t be initialized during BeginPlay
.
I don’t see the point of adding null pointer checks later on in the code. If you don’t have a PhysicsHandle
at this point, you have a problem with your code anyway. The null check just obfuscates the problem, making it both harder to detect and harder to debug.
I can understand that in some very complex projects you might want some non essential parts of your game to fail gracefully instead of crashing, but for our minigame, what’s the value of keeping it running if grabbing the items doesn’t work ?