Basically I have a character, when it hits a block it sticks to it and gravity stops taking a hold. When it's pulled away it unsticks. This is handled with a basic onCollisionEnter and onCollisionExit (This script is attached to the character). It's all working fine. The problem arises when the block that it is stuck to is destroyed, sometimes this might happen because of a nearby explosion or something. onCollisionExit isn't called when it's destroyed so the character remains stuck in empty space. Does anyone have an idea how I might solve this?
EDIT: Sorted by constantly checking if it's still colliding with the block by recording the objects name when colliding with it and checking if the object still exists.