|
|
@ -29,10 +29,7 @@ public class Program { |
|
|
|
boolean running = true; |
|
|
|
|
|
|
|
while(running) { |
|
|
|
for (char inputChar : input.inputList) { |
|
|
|
gameManager.ProcessInput(inputChar); |
|
|
|
} |
|
|
|
input.inputList.clear(); |
|
|
|
ForwardInputToGameManager(); |
|
|
|
|
|
|
|
gameManager.Update(); |
|
|
|
|
|
|
@ -44,6 +41,13 @@ public class Program { |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
public void ForwardInputToGameManager() { |
|
|
|
for (char inputChar : input.inputList) { |
|
|
|
gameManager.ProcessInput(inputChar); |
|
|
|
} |
|
|
|
input.inputList.clear(); |
|
|
|
} |
|
|
|
|
|
|
|
public void CreateAndShowGUI() { |
|
|
|
frame = new JFrame("PacmaaaAAAYYYHAAAaaam"); |
|
|
|
frame.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE); |
|
|
|