摘要:
1.屏幕刷新控制public static final int FPS = 20;public void run() { while(isPlay) { long startTime = System.currentTimeMillis(); gameLogic(); repaint(); long endTime = System.currentTimeMillis(); long costTime = endTime - startTime; if(costTime < 1000/FPS) { try { loopThread.sleep(1000/FPS - costTime); 阅读全文
posted @ 2011-02-24 14:30
小西346
阅读(681)
评论(1)
推荐(1)

浙公网安备 33010602011771号