I'm currently reading Nakahara's Geometry, Topology, and Physics, and he makes a claim that I find confusing in his derivation of the fundamental group for $S^{1}$. Instead of doing a standard proof via covering spaces, he argues that $S^{1}\cong \mathbb{R}/2\pi\mathbb{Z}$ by considering the map

$$p:\mathbb{R}\rightarrow S^{1}, p: x\mapsto e^{ix}$$

OK, that's fine. A natural equivalence class to consider is
$$[x] = \{y | x-y=2\pi m, m\in\mathbb{Z}\}$$

and we say $x\sim y$. Now let
$$\tilde f: \mathbb{R}\rightarrow\mathbb{R}$$

be a map which satisfies $\tilde f(0) = 0$ and $\tilde f(x+2\pi) = \tilde f(x)+2n\pi$, $n\in\mathbb{Z}, x\in\mathbb{R}$. It is easy to check that $x\sim y \Rightarrow \tilde f(x)\sim\tilde f(y)$. Hence $\tilde f$ and $p$ induce natural maps on $S^{1}$:
$$f: S^{1}\rightarrow S^{1}, f([x]) = p(\tilde f(x))$$

Nakahara calls the point $1\in S^{1}$ the base point of $S^{1}$, as it is obtained by mapping $0\in\mathbb{R}$. Here comes the claim I find dubious: Nakahara says, and I quote:

"In summary, there is a one-to-one correspondence between the set of maps from $S^{1}$ to $S^{1}$ with $f(1)=1$ and the set of maps from $\mathbb{R}$ to $\mathbb{R}$ such that $\tilde f(0) = 0$ and $\tilde f(x+2\pi) = \tilde f(x)+2\pi n$."

I don't understand this at all. For example, what happens if I cook up a function which preserves the base point on the circle but winds around the image circle an irrational number of times while the pre-image circle is only wound once? In particular, the function

$$f(e^{i\theta}) = e^{i\pi\theta}$$

preserves the base point, but doesn't seem to be associated with an $\tilde f$ that satisfies the condition $\tilde f(x+2\pi) = f(x)+2\pi n$. Am I missing something, or is this just a glaring error? Many thanks for any assistance you can offer, and I apologize if this is somewhat inelegant - I'm really a physicist.