Fixed UniformCost. Don't know what I was thinking before, but it's actually implemented properly now.