You must assign the return value of String.Replace
to your original string instance:
hence instead of(no need for the Contains check)
if (Gamertag2.Contains("^"))
{
Gamertag2.Replace("^" + 1, "");
}
just this(what's that mystic +1
?):
Gamertag2 = Gamertag2.Replace("^", "");
与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…