For each cell, track the minimum effort needed to reach it. Effort here means the maximum single step on the path. When you pop cell (r, c) with effort e, you check neighbors. For neighbor (nr, nc), calculate the step effort abs(height[r][c] - height[nr][nc]).
The path effort to reach (nr, nc) via this path is max(e, step_effort). If that's better than the current best for (nr, nc), update it and push (max(e, step_effort), nr, nc) onto the heap.
This runs in time and uses space.