ccbc47a7de
follow a path (specifically, I want to allow the media panel to be "scrolled" along a path). git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@1409 542714f4-19e9-0310-aa3c-eee0fc999fb1
52 lines
1.0 KiB
Java
52 lines
1.0 KiB
Java
//
|
|
// $Id: TilePathNode.java,v 1.2 2002/05/31 03:38:03 mdb Exp $
|
|
|
|
package com.threerings.miso.scene;
|
|
|
|
import com.threerings.media.util.PathNode;
|
|
|
|
/**
|
|
* The tile path nodes extends the path node class to allow
|
|
* associating tile coordinates with a node in a path.
|
|
*/
|
|
public class TilePathNode extends PathNode
|
|
{
|
|
/**
|
|
* Constructs a tile path node.
|
|
*/
|
|
public TilePathNode (int tilex, int tiley, int x, int y, int dir)
|
|
{
|
|
super(x, y, dir);
|
|
|
|
_tilex = tilex;
|
|
_tiley = tiley;
|
|
}
|
|
|
|
/**
|
|
* Returns the node's x-axis tile coordinates.
|
|
*/
|
|
public int getTileX ()
|
|
{
|
|
return _tilex;
|
|
}
|
|
|
|
/**
|
|
* Returns the node's y-axis tile coordinates.
|
|
*/
|
|
public int getTileY ()
|
|
{
|
|
return _tiley;
|
|
}
|
|
|
|
// documentation inherited
|
|
public void toString (StringBuffer buf)
|
|
{
|
|
super.toString(buf);
|
|
buf.append(", tilex=").append(_tilex);
|
|
buf.append(", tiley=").append(_tiley);
|
|
}
|
|
|
|
/** The path node tile coordinates. */
|
|
protected int _tilex, _tiley;
|
|
}
|