Game Development Reference
In-Depth Information
Add the following inner class to the
Assets
class:
public class AssetBunny {
public final AtlasRegion head;
public AssetBunny (TextureAtlas atlas) {
head = atlas.findRegion("bunny_head");
}
}
Next is the rock game object that represents the platform in our game world. It
consists of two image files:
rock_edge.png
and
rock_middle.png
. Both these
following images get their own variable in the inner class called
AssetRock
:
Add the following inner class to the
Assets
class:
public class AssetRock {
public final AtlasRegion edge;
public final AtlasRegion middle;
public AssetRock (TextureAtlas atlas) {