I used to have an Amstrad CPC464 64K (with a green screen!) and I had a game called Balldozer (clever, huh?!), in which the idea was to move your balls (ooh, pardon) around the screan, one square at a time, into the alloted squares. But obviously if you pushed them into any kind of corner, you can't get them out. The levels got progressively harder (as they have a habit of doing). Does this sound like it?
I'm sure there are many versions of this kind of game available. A very modern example is
Acno's Energizer, which is available
here.