目的是按下回车暂停游戏,再按恢复。现情况如下:注释掉1,保留2,运行正常。
注释掉2,保留1,运行错误。
我的JDK是1.6.0_32
如有兴趣研究,留邮箱或加Q308862125,在线求解答,谢谢关注!boolean isGameContinue(){
while(GameInf.KeyProcess.isStop())
//1 GameInf.KeyProcess.isStop();
//2 System.out.println(GameInf.KeyProcess.isStop());
if(GameInf.KeyProcess.isExit())
System.exit(0);
if(PM.player.getHP() == 0)
{
if(!(PM.player.getY()>=WindowInf.OPERATE_Y0+WindowInf.OPERATE_HEIGHT))
Sound.dead2.play();
else 
Sound.dead1.play();
PM.player.setImage(null);
return false;
}
else return true;
}