Java, it seems, cannot find my constructor, I have no idea what is wrong. Is there a problem with InterruptedException entanglement? Any help would be appreciated, thanks!
package gameloop; import javax.swing.*; public class GameLoop extends JFrame { private boolean isRunning; public int drawx = 0; public int drawy = 0; public void GameLoop() throws InterruptedException{ setSize(700, 700); setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE); setLocationRelativeTo(null); setVisible(true); while(isRunning){ doGameUpdate(); render(); Thread.sleep(1); if (isRunning){ GameLoop(); } } } private void doGameUpdate() { GameUpdate GU = new GameUpdate(); } private void render() { Draw dr = new Draw(); } public static void main(String[] args) { GameLoop GL = new GameLoop(); } }
source share