Each $C^*$-embedded subset $S$ of a first countable Tychonoff space $X$ is closed. 
Proposition. Each $C^*$-embedded subset $S$ of a first countable Tychonoff space $X$ is closed.

Proof. Let $S$ be a non-closed subset of the space $X$. Pick a point $x_0\in \overline{S}\setminus S$ and a countable base $\{U_n\}$ of open neighborhoods of the point $x_0$. For each $n$ take a continuos function $f_n:X\to [0,1]$ such that $f(x_0)=1$ and $f_n(X\setminus U_n)=\{0\}$, and put $f(x)=\sum f_n(x)$ for each $x\in S$. It is easy to check that the function $f$ is correctly defined and continuous on $S$ and the image $f(S)\subset\Bbb R$ is unbounded. So it contains a sequence $Y=\{y_n\}$ of distinct points such that $|y_n|>n$ for each $n$. Define a function $g:Y\to [0,1]$ such that $g(y_n)=0$ for even $n$ and $g(y_n)=0$ for odd $n$. Since $Y$ is a closed discrete subspace of a normal space $\Bbb R$, the function $g$ can be extended to a continuous function $\hat g:\Bbb R\to [0,1]$. The construction implies that the function $\hat gf:S\to [0,1]$ cannot be extended to a continuous function from $S\cup\{x_0\}$ to $[0,1]$, so the set $S$ is not $C^*$-embedded in the space $X$. $\square$
My question are:

1: Why is $f(x)=\sum f_n(x)$ for each $x\in S$ defined  on $S$ and why is   the image $f(S)\subset\Bbb R$ unbounded?
2:Why are   $g(y_n)=0$ for even $n$ and $g(y_n)=0$ for odd $n$  and why is $Y$  a closed discrete subspace of a normal space $\Bbb R$?

 A: Ok, it’s clear that the $f_n$ exist by Tychonoffness, and they are continuous. 
If $x \in S$ then there is some $n_x$ such that  $x \notin \overline{U_{n_x}}$. We can choose the $U_n$ to be decreasing and even obeying $\overline{U_{n+1}} \subseteq U_n$ for all $n$ at the outset to easily achieve this. So for such a situation we have that $x \notin U_m$ for all $m > n_x$ as well and hence $f_m(x) = 0$ for such $m$, and so $f(x) = \sum_{i=1}^{n_x}f_i(x)$ is just a finite sum of continuous functions, and this also holds for all $p \in X\setminus \overline{U_{n_x}}$, so $f$ is locally continuous at $x$, at all $x \in S$, hence continuous.
$f$ is unbounded on $S$: pick $N>0$ some integer. Then for any point $p \in S$ in $\bigcap_{i=1}^{2N} f_i^{-1}[(\frac{1}{2},1]]$ (which is a non-empty neighbourhood of $x_0$ so intersects $S$) we have that $f(p) > \frac{1}{2} \cdot 2N = N$ so $f$ is unbounded on $S$.
Then we have $y_n \in S$ with $|f(y_n)| > n$. Then the set $Y = \{y_n: n =1,2,3,4, \ldots\}$ is discrete and closed by continuity of $f$: suppose $s \in Y’$ then find an open neighbourhood $U$ of such that $f[U] \subseteq (f(s) -1 ,f(s) +1)$ (by continuity). Then find $N$ with $N > f(s)+1$ and then $U$ as a neighbourhood of $s$ must intersect infinitely many members of $Y$ (a limit point in a $T_1$ space..) among which some $y_n$ with $n> N$ so $f(y_n) > N > f(s)+1$ contradicting that it is in $U$.So $Y’ = \emptyset$ which is equivalent to $Y$ being closed and discrete as a subspace. This is a common idea in proofs with pseudocompactness and bounded functions, etc....
edit I saw that you were working in the image actually, in which case it’s even easier. If a set in $Y = \{y_n: n \in \mathbb{N}\} \subseteq \mathbb{R}$ obeys $|y_n| > n$ it’s similarly easy to see that if we assume $x \in Y’$ we get a similar contradiction using $U = (x-1,x+1)$ which cannot intersect infinitely members of $Y$. The previous argument might be useful for you later... (it’s a lemma in a proof that a normal limit point compact space is pseudocompact) 
This means that we can define any function on $Y$ as we like (including $0$ on even indexed and $1$ on odd-indexed $y_n$ and the result will always be a continuous function on $Y$. Hence $g$ is well-defined and the extension of $g$ exists by Tietze-Urysohn applied to the reals. That $\mathbb{R}$ is normal (it’s even metrisable) should be familiar knowledge when you’re studying $C(X)$ theory..
