python clear parent

I’m making a python pickup script where you use a keyboard button to pickup objects.
I used the obj.setParent() feature to parent the objects to the hand but I can’t figure out how to clear parents in python. Does anyone know how to do this?

Looks like there is a removeParent() method

Good luck


Thank you. I didn’t see that. I tried looking it up in the BGE api but I couldn’t find it.