Posted: Tue Apr 27, 2010 10:36 pm Post subject: Removing printed cout text
Lets say I'm making a console game that asks for 2 players names. After they've entered their name, and I've stored it in a string, is there a way to remove the printed cout text?
Joined: 17 Feb 2008 Posts: 524 Location: Inside the Intel CET shadow stack
Posted: Wed Apr 28, 2010 3:28 am Post subject:
If it's Windows only, use the system function to clear the screen... something like system("cls");
However, if you really just want to clear one line you can colour the text in black with standard APIs. See this sample on how to do that. _________________
It's not fun unless every exploit mitigation is enabled.
Please do not reply to my posts with LLM-generated slop; I consider it to be an insult to my time.
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum You cannot attach files in this forum You can download files in this forum