way of making the baby move around the maze
We'd prefer that you didn't use messages and that you continue posting back here to this thread so that everyone might learn.
Ben Grabouski wrote:Any help would be appreciated! If you would prefer to leave your discord name so you can see it properly I will message you.
So, are you going to have buttons or keystrokes for up/down/left/right?
Ben Grabouski wrote:the maze is supposed to be controlled by the user.
So what have you got for this so far?
Carey Brown wrote:Whether the user moves the baby or the baby moves itself you'll need logic to tell if the square it wants to move to is even on the board, and if so, does it have a brick on it.
Because all your coordinates are hand picked I don't think there is a simple way to make a loop to initialize the maze. On the other hand, what you've got is an accident waiting to happen. It's very likely that you'd make a typo error in all those coordinates. Here is "a" way around that by using an array of Strings to "draw" the maze and then initialize your img_array from that. I don't know if you'll find this confusing or not. If so, feel free to ignore it.
Ben Grabouski wrote:For the loop that you mentioned, would you be able to share an example? I'm very new to Java and find it quite confusing.