|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectjgame.JGObject
examples.StdScoring
public class StdScoring
A class for displaying an animated piece of text. The text is displayed in the supplied font and can be made to colour-cycle.
Field Summary |
---|
Fields inherited from class jgame.JGObject |
---|
colid, eng, expire_never, expire_off_pf, expire_off_view, expiry, resume_in_view, suspend_off_view, suspend_off_view_expire_off_pf, x, xdir, xspeed, y, ydir, yspeed |
Constructor Summary | |
---|---|
StdScoring(java.lang.String name,
double x,
double y,
double xspeed,
double yspeed,
int expiry,
java.lang.String message,
java.awt.Font font,
java.awt.Color[] colors,
int cyclespeed)
Create animated piece of text. |
Method Summary | |
---|---|
void |
paint()
Paints the message. |
Methods inherited from class jgame.JGObject |
---|
and, checkBGCollision, checkBGCollision, clearAnim, clearBBox, clearTileBBox, dbgPrint, getAnimId, getBBox, getCenterTile, getCenterTiles, getGraphic, getImageBBox, getLastBBox, getLastCenterTiles, getLastTileBBox, getLastTiles, getLastX, getLastY, getName, getTileBBox, getTiles, getTopLeftTile, hit_bg, hit_bg, hit_bg, hit, isAlive, isBottomAligned, isInView, isLeftAligned, isOnPF, isOnScreen, isRightAligned, isSuspended, isTopAligned, isXAligned, isXAligned, isYAligned, isYAligned, move, remove, resetAnim, resetAnim, resume, setAnim, setAnimPingpong, setAnimSpeed, setBBox, setDir, setDirSpeed, setDirSpeed, setGraphic, setImage, setPos, setResumeMode, setSpeed, setSpeed, setSpeedAbs, setTileBBox, snapBBoxToGrid, snapToGrid, snapToGrid, startAnim, stopAnim, suspend |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public StdScoring(java.lang.String name, double x, double y, double xspeed, double yspeed, int expiry, java.lang.String message, java.awt.Font font, java.awt.Color[] colors, int cyclespeed)
name
- name prefix (unique id is always added)x
- center of text (text is centered)y
- top of textexpiry
- the expiry value: # ticks, -1=never, or -2=die offscreencolors
- colors through which to cyclecyclespeed
- number of ticks before next colour in the colour cycleMethod Detail |
---|
public void paint()
paint
in class JGObject
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |