org.xistrat.bean
Class FigurData

java.lang.Object
  extended by org.xistrat.bean.FigurData

public class FigurData
extends java.lang.Object

bulk data of a piece

Since:
0.5.42

Field Summary
 boolean alive
           
 boolean isKing
           
 int location
           
 int nameAsInt
           
 int party
           
 int stand
           
 
Constructor Summary
FigurData()
          of course in principle u could define non-constant parameters as well (being periodic) ...
FigurData(int location, int stand, boolean alive, int nameAsInt, int party, boolean isKing)
           
 
Method Summary
 java.lang.Object clone()
          in Object is protected access ...
 java.lang.String getAlive()
           
 int getLocation()
           
 java.lang.String getName()
           
 int getParty()
           
 java.lang.String getRole()
           
 int getStand()
           
 boolean isAlive()
           
 boolean isReachingFor(int pos, FigurData[] _figures, FastFace fastFace, int index)
           
 void kill()
           
 void setAlive(boolean alive)
           
 void setFLocation(int location, FastFace fastFace)
          stand will be in [0, faces - 1]
 void setLocation(int location, FastFace fastFace)
          Deprecated.  
 void updateData(int _stand)
           
 
Methods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

location

public int location

stand

public int stand

alive

public boolean alive

nameAsInt

public int nameAsInt

party

public int party

isKing

public boolean isKing
Constructor Detail

FigurData

public FigurData()
of course in principle u could define non-constant parameters as well (being periodic) ...

for example distInEdges alternating a and (poly-a) would be cool, givig straight lines for odd and even poly


FigurData

public FigurData(int location,
                 int stand,
                 boolean alive,
                 int nameAsInt,
                 int party,
                 boolean isKing)
Method Detail

clone

public java.lang.Object clone()
in Object is protected access ...

Overrides:
clone in class java.lang.Object

isReachingFor

public boolean isReachingFor(int pos,
                             FigurData[] _figures,
                             FastFace fastFace,
                             int index)

getName

public java.lang.String getName()

getStand

public int getStand()

setLocation

public void setLocation(int location,
                        FastFace fastFace)
Deprecated. 

the stand will be in [0, polygons-1]

Parameters:
location - is in [0, polygons - 1] in case it's not D or E

setFLocation

public void setFLocation(int location,
                         FastFace fastFace)
stand will be in [0, faces - 1]

Parameters:
location - is in [0, faces - 1] in case it's not D or E

getLocation

public int getLocation()

isAlive

public boolean isAlive()

getAlive

public java.lang.String getAlive()

getRole

public java.lang.String getRole()

getParty

public int getParty()

kill

public void kill()

setAlive

public void setAlive(boolean alive)

updateData

public void updateData(int _stand)