pinballthread.old

来自「一些JAVA的小程序」· OLD 代码 · 共 33 行

OLD
33
字号
////	PinBallTread class////	From Chapter 7 of//	Understanging Object-Oriented Programming with Java//	Written by Tim Budd//	Published by Addison-Wesley Longman////	See ftp://ftp.cs.orst.edu/pub/budd/java/ReadMe.html //	for further information//public class PinBallThread extends Thread {	private Ball theBall;	private PinBallGame1 world;	public PinBallThread (Ball aBall, PinBallGame1 w) {		theBall = aBall; 		world = w; 	}	public void run ()	{		while (theBall.y() < world.FrameHeight) {			theBall.move ();			world.ballMoved (theBall);			try {				sleep(10);				} catch (InterruptedException e) { }		}	}}

⌨️ 快捷键说明

复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?