Making A Game

When my group made a game, the only thing we could do to keep the screen constantly clear is to constantly clear it. Is there anything that we could do to stop the clearing?


Clearing the screen


You need to look at how you have structured your game to see whether this is necessary or whether there is a simple alternative. For example, if your game has a background image then all you need to do is refresh the image and all the foreground stuff will disappear. As an alternative to clear you might think about using BOX AREA to re-color the entire screen.

If you want to clear some things off the screen but leave others where they are, then try constructing an internal array that keeps track of where things are on the screen so that you can selectively erase them (or restore them). This is how the library module TrueCtrl does it.

Big John