Copy some helper methods from EnderGloves

You never know, could be useful.