org.haphazard.character.body
Class Head

java.lang.Object
  extended byorg.haphazard.character.body.BodyPart
      extended byorg.haphazard.character.body.Head

public class Head
extends BodyPart

A very important bodypart


Field Summary
 
Fields inherited from class org.haphazard.character.body.BodyPart
mClothes, mSlots
 
Constructor Summary
Head()
          Creates a new instance of Head
Head(java.lang.String name)
          Creates a head with a specific name
 
Method Summary
 int getCritical()
          Gets how critical this area is
 java.lang.String toXML(int indent)
          Transforms this object into an XML-notation
 int wound(int damage)
          Computes the effect of a wound
 
Methods inherited from class org.haphazard.character.body.BodyPart
addWound, canWear, getAllClothes, getArmorValue, getLocation, getName, getPenalty, getTreeNode, getWound, heal, isHit, isPrimary, isWearing, setName, setNaturalArmor, setToHit, status, toString, undress, wear
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

Head

public Head()
Creates a new instance of Head


Head

public Head(java.lang.String name)
Creates a head with a specific name

Parameters:
name - The name of the head
Method Detail

wound

public int wound(int damage)
Computes the effect of a wound

Overrides:
wound in class BodyPart
Parameters:
damage - The amount of damage received
Returns:
The severity of the attack

getCritical

public int getCritical()
Gets how critical this area is

Overrides:
getCritical in class BodyPart
Returns:
Very critical

toXML

public java.lang.String toXML(int indent)
Transforms this object into an XML-notation

Overrides:
toXML in class BodyPart
Parameters:
indent - The indentation level to use
Returns:
The object in an XML notation