B
B
bryzgalovp2017-10-08 22:00:01
Java
bryzgalovp, 2017-10-08 22:00:01

The problem with the background color, I don’t understand where the error is?

packageUdavchik.main;
import java.awt.event.ActionEvent;
import javax.swing.AbstractAction;
import javax.swing.Timer;
import Udavchik.display.Display;
public class Main {
public static void main(String[] args) {
Display.create(800, 700, "U", 0xffff0000);
//background color stays the same
Timer t = new Timer(1000 / 60, new AbstractAction() {
public void actionPerformed(ActionEvent e) {
Display.clear();
Display.render();
Display.swapBuffers();
}
}) ;
setRepeats(true);
t.start();
}
}

Answer the question

In order to leave comments, you need to log in

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question