Use Depth instead of int in search