|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object org.haphazard.character.GlobalSkill
A system wide list of all available skills and their descriptions
Method Summary | |
void |
add(GeneralSkill skill)
Adds a skill to the global skill list |
GeneralSkill |
get(java.lang.String skill)
Gets a skill |
static GlobalSkill |
getInstance()
Gets the instance of GlobalSkill |
java.util.Vector |
getList()
Gets the whole slew of skills in a nice list Only the name is listed |
void |
load(java.io.InputStream stream)
Loads a global skill list from a file Clears the global skill list before load. |
void |
remove(java.lang.String skill)
removes a skill from the global skill list |
int |
roll(int value,
int penalty)
Rolls a statistic |
void |
save(java.io.OutputStream stream)
Saves the global skill list in an XML-file |
java.lang.String |
toXML(int indent)
Translates this object into an XML notation |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Method Detail |
public static GlobalSkill getInstance()
public void add(GeneralSkill skill)
skill
- The skill to addpublic void remove(java.lang.String skill)
skill
- The skill to removepublic GeneralSkill get(java.lang.String skill)
skill
- The name of the skill to get
public java.util.Vector getList()
public int roll(int value, int penalty)
value
- The value of the skill to rollpenalty
- Any eventual penalties to the roll
public void save(java.io.OutputStream stream)
stream
- The stream to save topublic void load(java.io.InputStream stream)
stream
- The stream to load frompublic java.lang.String toXML(int indent)
indent
- The level of indentation to use
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |