An Actor Class

Java Gaming for the Masses

Implementing a Scene Management System


We're going to put together a few demos in this set of notes. Some of the classes have already been discussed already. For those we will provide links to their source code. Some classes are entirely new, and perhaps they should be included here in their entirety. At the very least, though, we need to be able to distinguish between them.

Here's a Scrollable Scene demo.

Please note that you need j2sev1.4 where you run it.

What you need:

You also need (Use your appletviewer from a host with j2sev1.4).

The location of these files is:

/l/www/classes/a348/t540/spr2002/lectures/code/Three
Web-wise that means:
http://www.cs.indiana.edu/classes/a348/t540/spr2002/lectures/code/Three
The scene is also relying on the following two pictures: For the next example the code is in Four.

Here are the files you need:

frilled.cs.indiana.edu%ls -ld *.java *.html
-rw-------   1 dgerman      8532 Apr 18 01:49 Actor2D.java
-rw-------   1 dgerman      1311 Apr 18 01:49 ActorGroup2D.java
-rw-------   1 dgerman      2653 Apr 18 02:03 AnimationStrip.java
-rw-------   1 dgerman      3222 Apr 18 02:04 Animator.java
-rw-------   1 dgerman      1874 Apr 18 01:49 Asteroid.java
-rw-------   1 dgerman      1331 Apr 18 01:45 AsteroidGroup.java
-rw-------   1 dgerman      1248 Apr 18 02:02 ImageGroup.java
-rw-------   1 dgerman      2733 Apr 18 01:46 ImageLoader.java
-rw-------   1 dgerman       277 Apr 18 01:58 Moveable.java
-rw-------   1 dgerman      4822 Apr 18 02:00 QuadNode.java
-rw-------   1 dgerman      3358 Apr 18 01:58 QuadTree.java
-rw-------   1 dgerman      1361 Apr 18 01:52 Scene.java
-rw-------   1 dgerman       842 Apr 18 01:52 TreeScene.java
-rw-------   1 dgerman       883 Apr 18 02:09 TreeTest.html
-rw-------   1 dgerman      3024 Apr 18 01:41 TreeTest.java
-rw-r--r--   1 dgerman       883 Apr 18 02:01 TreeTestBackup.html
-rw-------   1 dgerman      4041 Apr 18 02:02 Vector2D.java
frilled.cs.indiana.edu%
The HTML file is a bit different.

And you also need

For this next one the code is in Five.

Here are the files that are needed:

frilled.cs.indiana.edu%appletviewer IsoTest.html
frilled.cs.indiana.edu%ls -ld *.java
-rw-r--r--   1 dgerman      8532 Apr 18 10:59 Actor2D.java
-rw-r--r--   1 dgerman      1311 Apr 18 10:59 ActorGroup2D.java
-rw-r--r--   1 dgerman      2653 Apr 18 11:06 AnimationStrip.java
-rw-r--r--   1 dgerman      3222 Apr 18 11:07 Animator.java
-rw-------   1 dgerman      1597 Apr 18 11:12 BufferedGraphics.java
-rw-r--r--   1 dgerman      1248 Apr 18 11:04 ImageGroup.java
-rw-r--r--   1 dgerman      2733 Apr 18 11:04 ImageLoader.java
-rw-r--r--   1 dgerman       734 Apr 18 11:00 IsoMan.java
-rw-r--r--   1 dgerman       934 Apr 18 11:01 IsoManGroup.java
-rw-r--r--   1 dgerman      3244 Apr 18 10:56 IsoScene.java
-rw-r--r--   1 dgerman      2779 Apr 18 10:30 IsoTest.java
-rw-r--r--   1 dgerman       366 Apr 18 11:06 IsoTile.java
-rw-r--r--   1 dgerman       878 Apr 18 10:59 IsoTileGroup.java
-rw-r--r--   1 dgerman       277 Apr 18 11:04 Moveable.java
-rw-r--r--   1 dgerman      1361 Apr 18 11:04 Scene.java
-rw-r--r--   1 dgerman       362 Apr 18 11:06 StaticActor.java
-rw-r--r--   1 dgerman      4041 Apr 18 10:58 Vector2D.java
-rw-------   1 dgerman       672 Apr 18 11:12 VolatileGraphics.java
frilled.cs.indiana.edu%ls -ld *.gif
-rw-r--r--   1 dgerman      5214 Apr 18 02:18 isoman.gif
-rw-r--r--   1 dgerman      2105 Apr 18 02:18 isotiles.gif
frilled.cs.indiana.edu%ls -ld *.html
-rw-r--r--   1 dgerman       200 Apr 18 02:20 IsoTest.html
frilled.cs.indiana.edu%
Can you identify those that we have been using over and over again?

If you do, you might be thinking of putting them into a package (and/or a .jar file).

The last example's called Creating a Wrapped Scene.

The code is in Six.

Here's what's needed:

frilled.cs.indiana.edu%ls -ld *.java
-rw-r--r--   1 dgerman      8532 Apr 18 12:21 Actor2D.java
-rw-------   1 dgerman      1311 Apr 18 12:25 ActorGroup2D.java
-rw-------   1 dgerman      2653 Apr 18 12:24 AnimationStrip.java
-rw-------   1 dgerman      3222 Apr 18 12:26 Animator.java
-rw-r--r--   1 dgerman      1597 Apr 18 12:20 BufferedGraphics.java
-rw-------   1 dgerman      1248 Apr 18 12:26 ImageGroup.java
-rw-------   1 dgerman       277 Apr 18 12:25 Moveable.java
-rw-------   1 dgerman       362 Apr 18 12:25 StaticActor.java
-rw-r--r--   1 dgerman       611 Apr 18 12:21 StaticActorGroup.java
-rw-r--r--   1 dgerman      4041 Apr 18 12:20 Vector2D.java
-rw-------   1 dgerman       672 Apr 18 12:27 VolatileGraphics.java
-rw-r--r--   1 dgerman      5209 Apr 18 12:19 WrapTest.java
frilled.cs.indiana.edu%ls -ld *.html
-rw-r--r--   1 dgerman       204 Apr 18 12:15 WrapTest.html
frilled.cs.indiana.edu%ls -ld *.gif
-rw-r--r--   1 dgerman      3115 Apr 18 12:19 ship.gif
frilled.cs.indiana.edu%
We're having 1.4 installed in the classroom this Friday.

We're trying to install the Java 3D API also.

Here's a recent book entirely on-line.


Last updated: Apr 18, 2002 by Adrian German for T540