java写的贪吃蛇游戏怎么可能不flash?

双缓冲技术public void update(graphics g){ image bgimage = create image(this . getsize()。width,this.getsize()。身高);graphics BG = bgimage . get graphics();g . set color(color . black);//设置背景g.fillRect(0,0,480,480);BG . set color(color . green);//食品颜色bg.fill3drect (foodx,foody,10,10,true);BG . set color(color . pink);for(I = 0;我& lt= length-1;i++) bg.fill3DRect(m[i],n[i],10,10,true);//m[]x坐标n[]y坐标g.drawImage (bgImage,0,0,this);} public void paint(图形g){ update(g);}