public class DefaultAnimationObject extends AbstractNamedObject implements AnimationObject
AnimationObject.| Constructor and Description |
|---|
DefaultAnimationObject(@NotNull java.lang.String animName,
@NotNull java.lang.String animList,
@NotNull java.lang.String path)
Creates a new instance.
|
| Modifier and Type | Method and Description |
|---|---|
@NotNull java.lang.String |
getAnimList()
Returns the animation list of this animation.
|
@NotNull java.lang.String |
getAnimName()
Get the animName, which is the name of the animation as usable by the
"animations" attribute.
|
@NotNull java.lang.String |
getDisplayIconName()
Returns the face name of the display icon for this AbstractNamedObject.
|
int |
getFacings()
Get the facings, which is the number of different sub-animations, for
instance for different directions.
|
@NotNull java.lang.String |
getFirstFrame(int facing)
Get the first frame.
|
int |
getFrameCount()
Get the number of frames per facing.
|
@NotNull java.lang.String |
getName()
Get the name of this AbstractNamedObject.
|
java.lang.String |
toString()
The String representation of an AnimationObject is suitable
for writing into the animations file.
|
compareTo, equals, getPath, hashCode, setPathclone, finalize, getClass, notify, notifyAll, wait, wait, waitgetPath, setPathpublic DefaultAnimationObject(@NotNull
@NotNull java.lang.String animName,
@NotNull
@NotNull java.lang.String animList,
@NotNull
@NotNull java.lang.String path)
AnimationObjects.addAnimationObject(String,
String, String) instead. If you invoke this constructor directly, the
created AnimationObject will not be registered.animName - name of the animationanimList - list of animation as found between "anim" and "mina",
separated with "\n", including "facings" but including neither "anim" nor
"mina"path - the path for this animation object@NotNull public @NotNull java.lang.String getName()
NamedObjectgetName in interface NamedObjectgetAnimName()public int getFacings()
AnimationObjectgetFacings in interface AnimationObject@NotNull public @NotNull java.lang.String getAnimName()
AnimationObjectgetAnimName in interface AnimationObjectgetName()@NotNull public @NotNull java.lang.String getAnimList()
AnimationObjectgetAnimList in interface AnimationObjectpublic java.lang.String toString()
toString in interface NamedObjecttoString in class AbstractNamedObject@NotNull public @NotNull java.lang.String getDisplayIconName()
NamedObjectgetDisplayIconName in interface NamedObject@NotNull public @NotNull java.lang.String getFirstFrame(int facing)
AnimationObjectgetFirstFrame in interface AnimationObjectfacing - facing to get frame for, usually a directionpublic int getFrameCount()