-1

I want to make a 2D game in java that is run on command prompt. However instead of redrawing the map as a character moves across it I wanted to see if there was a way to edit the the map already written

1 Answers1

1

How to do it can depend on the operating system used. But in general, it is surely possible to do what you want.

Typically you can for example use \b character (backspace) to go a position back on the console. Be aware that it won't work in Eclipse though.

But what you really want is probably a library giving you a "Curses" port (not sure if there is a native Java one), or Lanterna perhaps?

Community
  • 1
  • 1
ChristopheD
  • 112,638
  • 29
  • 165
  • 179