How to make object stick to other object in game engine??

Everyone on the internet says it’s impossible to do conventionally yet somehow this guy made it so that when his spider walks on terrain it just automatically sticks onto the terrain no matter where the spider is going, how did he do it?

John Hamilton and ThaTimst3r has already made this tutorial

Alright that’s a good video that explains a bit. How do you make it move along the surface of yet another object that isn’t terrain, but something that pokes out of the ground? Like let’s say I have a statue…

Also in this tutorial, the gravity still pulls the object off of the terrain if you go up vertically, but in the blend file it’s always sticking to the surface no matter what.

Also, so, I applied all my constraints to the armature, but the armature isn’t moving with the changes in the surface of the terrain.