diff --git a/src/java/com/threerings/media/animation/AnimationSprite.java b/src/java/com/threerings/media/animation/AnimationSprite.java
index d8ae3bdc..4f845843 100644
--- a/src/java/com/threerings/media/animation/AnimationSprite.java
+++ b/src/java/com/threerings/media/animation/AnimationSprite.java
@@ -79,7 +79,8 @@ public class AnimationSprite extends Sprite
}
@Override
- public void paint (Graphics2D gfx) {
+ public void paint (Graphics2D gfx)
+ {
// Nothing to paint for ourselves.
_anim.paint(gfx);
diff --git a/src/java/com/threerings/media/image/ColorPository.java b/src/java/com/threerings/media/image/ColorPository.java
index 53482829..0eab85c3 100644
--- a/src/java/com/threerings/media/image/ColorPository.java
+++ b/src/java/com/threerings/media/image/ColorPository.java
@@ -190,8 +190,8 @@ public class ColorPository implements Serializable
}
/**
- * Used to store information on a particular color. These are public
- * to simplify the XML parsing process, so pay them no mind.
+ * Used to store information on a particular color. These are public to simplify the XML
+ * parsing process, so pay them no mind.
*/
public static class ColorRecord implements Serializable
{
@@ -208,15 +208,14 @@ public class ColorPository implements Serializable
* source color to recolor to this color. */
public float[] offsets;
- /** Tags this color as a legal starting color or not. This is a
- * shameful copout, placing application-specific functionality
- * into a general purpose library class. */
+ /** Tags this color as a legal starting color or not. This is a shameful copout, placing
+ * application-specific functionality into a general purpose library class. */
public boolean starter;
/**
- * Returns a value that is the composite of our class id and color
- * id which can be used to identify a colorization record. This
- * value will always be a positive integer that fits into 16 bits.
+ * Returns a value that is the composite of our class id and color id which can be used
+ * to identify a colorization record. This value will always be a positive integer that
+ * fits into 16 bits.
*/
public int getColorPrint ()
{
@@ -224,8 +223,7 @@ public class ColorPository implements Serializable
}
/**
- * Returns the data in this record configured as a colorization
- * instance.
+ * Returns the data in this record configured as a colorization instance.
*/
public Colorization getColorization ()
{
@@ -234,16 +232,14 @@ public class ColorPository implements Serializable
// cclass.range, offsets);
// }
// return _zation;
- return new Colorization(getColorPrint(), cclass.source,
- cclass.range, offsets);
+ return new Colorization(getColorPrint(), cclass.source, cclass.range, offsets);
}
@Override
public String toString ()
{
return "[id=" + colorId + ", name=" + name +
- ", offsets=" + StringUtil.toString(offsets) +
- ", starter=" + starter + "]";
+ ", offsets=" + StringUtil.toString(offsets) + ", starter=" + starter + "]";
}
/** Our data represented as a colorization. */
diff --git a/src/java/com/threerings/media/util/AStarPathUtil.java b/src/java/com/threerings/media/util/AStarPathUtil.java
index 88fd4e3b..045321f0 100644
--- a/src/java/com/threerings/media/util/AStarPathUtil.java
+++ b/src/java/com/threerings/media/util/AStarPathUtil.java
@@ -73,18 +73,15 @@ public class AStarPathUtil
*/
public static class Stepper
{
- public Stepper ()
- {
+ public Stepper () {
this(true);
}
- public Stepper (boolean considerDiagonals)
- {
+ public Stepper (boolean considerDiagonals) {
_considerDiagonals = considerDiagonals;
}
- public void init (Info info, Node n)
- {
+ public void init (Info info, Node n) {
_info = info;
_node = n;
}
@@ -94,8 +91,7 @@ public class AStarPathUtil
* coordinates. No checking must be done as to whether the step is legal, that will be
* handled later. Just enumerate all possible steps.
*/
- public void considerSteps (int x, int y)
- {
+ public void considerSteps (int x, int y) {
considerStep(x, y - 1, ADJACENT_COST);
considerStep(x, y + 1, ADJACENT_COST);
considerStep(x - 1, y, ADJACENT_COST);
@@ -108,8 +104,7 @@ public class AStarPathUtil
}
}
- protected void considerStep (int x, int y, int cost)
- {
+ protected void considerStep (int x, int y, int cost) {
AStarPathUtil.considerStep(_info, _node, x, y, cost);
}
@@ -337,8 +332,7 @@ public class AStarPathUtil
/** The maximum cost of any path that we'll consider. */
public int maxcost;
- public Info (TraversalPred tpred, Object trav, int longest, int destx, int desty)
- {
+ public Info (TraversalPred tpred, Object trav, int longest, int destx, int desty) {
// save off references
this.tpred = tpred;
this.trav = trav;
@@ -357,8 +351,7 @@ public class AStarPathUtil
* Returns whether moving from the given source to destination coordinates is a valid
* move.
*/
- protected boolean isStepValid (int sx, int sy, int dx, int dy)
- {
+ protected boolean isStepValid (int sx, int sy, int dx, int dy) {
// not traversable if the destination itself fails test
if (tpred instanceof ExtendedTraversalPred) {
if (!((ExtendedTraversalPred)tpred).canTraverse(trav, sx, sy, dx, dy)) {
@@ -380,16 +373,14 @@ public class AStarPathUtil
/**
* Returns whether the given coordinate is valid and traversable.
*/
- protected boolean isTraversable (int x, int y)
- {
+ protected boolean isTraversable (int x, int y) {
return tpred.canTraverse(trav, x, y);
}
/**
* Get or create the node for the specified point.
*/
- public Node getNode (int x, int y)
- {
+ public Node getNode (int x, int y) {
// note: this _could_ break for unusual values of x and y.
// perhaps use a IntTuple as a key? Bleah.
int key = (x << 16) | (y & 0xffff);
@@ -429,15 +420,13 @@ public class AStarPathUtil
/** The node's monotonically-increasing unique identifier. */
public int id;
- public Node (int x, int y)
- {
+ public Node (int x, int y) {
this.x = x;
this.y = y;
id = _nextid++;
}
- public int compareTo (Node o)
- {
+ public int compareTo (Node o) {
int bf = o.f;
// since the set contract is fulfilled using the equality results returned here, and
diff --git a/src/java/com/threerings/util/DirectionUtil.java b/src/java/com/threerings/util/DirectionUtil.java
index 84997d2f..b3b0a67b 100644
--- a/src/java/com/threerings/util/DirectionUtil.java
+++ b/src/java/com/threerings/util/DirectionUtil.java
@@ -48,8 +48,7 @@ public class DirectionUtil implements DirectionCodes
}
/**
- * Returns an abbreviated string representation of the supplied
- * direction code.
+ * Returns an abbreviated string representation of the supplied direction code.
*/
public static String toShortString (int direction)
{
@@ -58,9 +57,8 @@ public class DirectionUtil implements DirectionCodes
}
/**
- * Returns the direction code that corresponds to the supplied string
- * or {@link #NONE} if the string does not correspond to a known
- * direction code.
+ * Returns the direction code that corresponds to the supplied string or {@link #NONE} if the
+ * string does not correspond to a known direction code.
*/
public static int fromString (String dirstr)
{
@@ -73,9 +71,8 @@ public class DirectionUtil implements DirectionCodes
}
/**
- * Returns the direction code that corresponds to the supplied short
- * string or {@link #NONE} if the string does not correspond to a
- * known direction code.
+ * Returns the direction code that corresponds to the supplied short string or {@link #NONE}
+ * if the string does not correspond to a known direction code.
*/
public static int fromShortString (String dirstr)
{
@@ -88,8 +85,8 @@ public class DirectionUtil implements DirectionCodes
}
/**
- * Returns a string representation of an array of direction codes. The
- * directions are represented by the abbreviated names.
+ * Returns a string representation of an array of direction codes. The directions are
+ * represented by the abbreviated names.
*/
public static String toString (int[] directions)
{
@@ -104,8 +101,8 @@ public class DirectionUtil implements DirectionCodes
}
/**
- * Rotates the requested fine direction constant clockwise by
- * the requested number of ticks.
+ * Rotates the requested fine direction constant clockwise by the requested number of
+ * ticks.
*/
public static int rotateCW (int direction, int ticks)
{
@@ -116,8 +113,8 @@ public class DirectionUtil implements DirectionCodes
}
/**
- * Rotates the requested fine direction constant
- * counter-clockwise by the requested number of ticks.
+ * Rotates the requested fine direction constant counter-clockwise by the requested
+ * number of ticks.
*/
public static int rotateCCW (int direction, int ticks)
{
@@ -144,8 +141,8 @@ public class DirectionUtil implements DirectionCodes
}
/**
- * Get the direction closest to the specified direction, out of
- * the directions in the possible list (preferring a clockwise match).
+ * Get the direction closest to the specified direction, out of the directions in the possible
+ * list (preferring a clockwise match).
*/
public static int getClosest (int direction, int[] possible)
{
@@ -153,11 +150,10 @@ public class DirectionUtil implements DirectionCodes
}
/**
- * Get the direction closest to the specified direction, out of
- * the directions in the possible list.
+ * Get the direction closest to the specified direction, out of the directions in the possible
+ * list.
*
- * @param preferCW whether to prefer a clockwise match or a
- * counter-clockwise match.
+ * @param preferCW whether to prefer a clockwise match or a counter-clockwise match.
*/
public static int getClosest (int direction, int[] possible,
boolean preferCW)
@@ -182,12 +178,10 @@ public class DirectionUtil implements DirectionCodes
}
/**
- * Returns which of the eight compass directions that point
- * b lies in from point a as one of the
- * {@link DirectionCodes} direction constants. Note: that the
- * coordinates supplied are assumed to be logical (screen) rather than
- * cartesian coordinates and NORTH is considered to point
- * toward the top of the screen.
+ * Returns which of the eight compass directions that point b lies in from point
+ * a as one of the {@link DirectionCodes} direction constants. Note:
+ * that the coordinates supplied are assumed to be logical (screen) rather than cartesian
+ * coordinates and NORTH is considered to point toward the top of the screen.
*/
public static int getDirection (Point a, Point b)
{
@@ -195,12 +189,10 @@ public class DirectionUtil implements DirectionCodes
}
/**
- * Returns which of the eight compass directions that point
- * b lies in from point a as one of the
- * {@link DirectionCodes} direction constants. Note: that the
- * coordinates supplied are assumed to be logical (screen) rather than
- * cartesian coordinates and NORTH is considered to point
- * toward the top of the screen.
+ * Returns which of the eight compass directions that point b lies in from point
+ * a as one of the {@link DirectionCodes} direction constants. Note:
+ * that the coordinates supplied are assumed to be logical (screen) rather than cartesian
+ * coordinates and NORTH is considered to point toward the top of the screen.
*/
public static int getDirection (int ax, int ay, int bx, int by)
{
@@ -208,12 +200,10 @@ public class DirectionUtil implements DirectionCodes
}
/**
- * Returns which of the eight compass directions that point
- * b lies in from point a as one of the
- * {@link DirectionCodes} direction constants. Note: that the
- * coordinates supplied are assumed to be logical (screen) rather than
- * cartesian coordinates and NORTH is considered to point
- * toward the top of the screen.
+ * Returns which of the eight compass directions that point b lies in from point
+ * a as one of the {@link DirectionCodes} direction constants. Note:
+ * that the coordinates supplied are assumed to be logical (screen) rather than cartesian
+ * coordinates and NORTH is considered to point toward the top of the screen.
*/
public static int getDirection (double ax, double ay, double bx, double by)
{
@@ -221,12 +211,10 @@ public class DirectionUtil implements DirectionCodes
}
/**
- * Returns which of the eight compass directions is associated with
- * the specified angle theta. Note: that the angle supplied
- * is assumed to increase clockwise around the origin (which screen
- * angles do) rather than counter-clockwise around the origin (which
- * cartesian angles do) and NORTH is considered to point
- * toward the top of the screen.
+ * Returns which of the eight compass directions is associated with the specified angle theta.
+ * Note: that the angle supplied is assumed to increase clockwise around the origin
+ * (which screen angles do) rather than counter-clockwise around the origin (which cartesian
+ * angles do) and NORTH is considered to point toward the top of the screen.
*/
public static int getDirection (double theta)
{
@@ -235,12 +223,11 @@ public class DirectionUtil implements DirectionCodes
}
/**
- * Returns which of the sixteen compass directions that point
- * b lies in from point a as one of the
- * {@link DirectionCodes} direction constants. Note: that the
- * coordinates supplied are assumed to be logical (screen) rather than
- * cartesian coordinates and NORTH is considered to point
- * toward the top of the screen.
+ * Returns which of the sixteen compass directions that point b lies in from
+ * point a as one of the {@link DirectionCodes} direction constants.
+ * Note: that the coordinates supplied are assumed to be logical (screen) rather than
+ * cartesian coordinates and NORTH is considered to point toward the top of the
+ * screen.
*/
public static int getFineDirection (Point a, Point b)
{
@@ -248,12 +235,11 @@ public class DirectionUtil implements DirectionCodes
}
/**
- * Returns which of the sixteen compass directions that point
- * b lies in from point a as one of the
- * {@link DirectionCodes} direction constants. Note: that the
- * coordinates supplied are assumed to be logical (screen) rather than
- * cartesian coordinates and NORTH is considered to point
- * toward the top of the screen.
+ * Returns which of the sixteen compass directions that point b lies in from
+ * point a as one of the {@link DirectionCodes} direction constants.
+ * Note: that the coordinates supplied are assumed to be logical (screen) rather than
+ * cartesian coordinates and NORTH is considered to point toward the top of the
+ * screen.
*/
public static int getFineDirection (int ax, int ay, int bx, int by)
{
@@ -261,12 +247,11 @@ public class DirectionUtil implements DirectionCodes
}
/**
- * Returns which of the sixteen compass directions is associated with
- * the specified angle theta. Note: that the angle supplied
- * is assumed to increase clockwise around the origin (which screen
- * angles do) rather than counter-clockwise around the origin (which
- * cartesian angles do) and NORTH is considered to point
- * toward the top of the screen.
+ * Returns which of the sixteen compass directions is associated with the specified angle
+ * theta. Note: that the angle supplied is assumed to increase clockwise around the
+ * origin (which screen angles do) rather than counter-clockwise around the origin (which
+ * cartesian angles do) and NORTH is considered to point toward the top of the
+ * screen.
*/
public static int getFineDirection (double theta)
{
@@ -275,15 +260,13 @@ public class DirectionUtil implements DirectionCodes
}
/**
- * Move the specified point in the specified screen direction,
- * adjusting by the specified adjustments. Fine directions are
- * not supported.
+ * Move the specified point in the specified screen direction, adjusting by the specified
+ * adjustments. Fine directions are not supported.
*/
public static void moveDirection (Point p, int direction, int dx, int dy)
{
if (direction >= DIRECTION_COUNT) {
- throw new IllegalArgumentException(
- "Fine coordinates not supported.");
+ throw new IllegalArgumentException("Fine coordinates not supported.");
}
switch (direction) {