You can only have sex with him with certain triggers present like a particular room or a smell, then you can ignore him when he tries mounting without that trigger present, and tell guests to ignore that behavior too. You can have sex with him before guests stop he doesn't want to mount, and that should become a habit. Stay consistent. If he's particularly stubborn, you can say timeout when he inappropriately mounts and put him in a bathroom away from people for a minute or two and then let him out.