For a one dimensional lattice, the solution with $a_n = n$ is trivial: starting from $0$, we proceed to $1, -1, 2, -2, \ldots$. After $2n$ steps, we have covered $[-n, n]$ without stepping anywhere outside of that region.
I'm not sure exactly what is meant by “traversing an infinite grid”, but I can think of two reasonable things one could ask for algorithmically: cover an $N \times N$ region for an arbitrary $N$ while hitting any number of spaces outside, or cover exactly an $N \times N$ region in $N^2$ steps.
The first method is accomplished by mimicking the one dimensional version. Suppose we want to cover the square with corners $(1,1)$ and $(N, N)$. Assume we start at $(0, 1)$, and move strictly horizontally, alternating east then west, to cover the squares $(-N + 1, 1)$ to $(N, 1)$, ending on the latter with a step of length $2N-1$. We then move east to $(3N, 1)$, then south $(3N, -2N)$, and back north to $(3N, 2)$. Now we proceed horizontally again, but perhaps not the obvious way. If we jumped back west into our desired square immediately, we would miss the spaces $(N-2, 2), (N-1, 2)$ and $(N, 2)$, and we may never see them again. So instead we go east, then jump back and forth until we have covered $(1, 2)$ to $(3N, 2)$, as well as $(5N + 3, 2)$ to $(8N+1, 2)$, ending at $(1,2)$ with a step of length $8N$. From here I suppose you see what to do: travel east, then south, then north, and repeat the sequence EWEW... ending at square $(N, 3)$. During leg $k$, we only hit squares in the horizontal line $y=k$, as well as one square at a negative $y$ value, which will never be reached again (consider the successive lengths of the steps south).
The second method cannot be done with $a_n = n$, since we will go outside the box sometime by step $N+1$. It may be possible instead with the set of $\lfloor \sqrt{n} \rfloor$ steps, though the order will have to be altered. For example, the sequence $(3,3,3,2,3,2,2,3,1,3,2,1,1,2,3)$ taken from the set $(\lfloor \sqrt{1} \rfloor, \ldots \lfloor \sqrt{15} \rfloor$ suffices to cover a $4 \times 4$ square, starting in one corner. From the southwest corner, travel $(N3, E3, S3, W2, N3, S2, E2, W3, N1, E3, W2, E1, S1, N2, S3)$ and you will finish one square west of the southeast corner.