|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object wyvern.kernel.properties.PList wyvern.kernel.commands.EventImpl wyvern.kernel.commands.TargetedEvent wyvern.kernel.combat.DamageEvent
The standard CommandEvent generated when someone (or something) takes damage. Note that it's usually enqueued in the attacker's queue, not the defender's queue, although that isn't always the case.
Field Summary |
Fields inherited from class wyvern.kernel.commands.TargetedEvent |
cloneError_, location_, quantity_, target_, targetName_ |
Fields inherited from class wyvern.kernel.commands.EventImpl |
agent_, appendToFile_, argString_, argStringParsed_, argv_, argvParsed_, delay_, failureMessage_, filterObjects_, filters_, handler_, map_, modified_, originalText_, playerOriginated_, redirectFile_, redirecting_, sendToAgent_, successMessage_, verb_, vetoed_, wizParsed_ |
Fields inherited from class wyvern.kernel.properties.PList |
readOnly_ |
Fields inherited from interface wyvern.lib.PropertyList |
PROPERTY_PACKAGE |
Constructor Summary | |
DamageEvent()
|
Method Summary | |
java.lang.String |
getAttackerMessage()
Returns message to print to attacker |
int[] |
getDamageAmounts()
Returns array of damage amounts done |
DamageType[] |
getDamageTypes()
Returns damage types involved in the event |
java.lang.String |
getDefenderMessage()
Returns message to print to defender |
BodyPart |
getHitLocation()
Returns the body part where the damage is occurring. |
int |
getTotalDamage()
Returns total damage done in the event |
java.lang.Object |
getWeapon()
Returns the weapon or attack used to produce the damage |
boolean |
hasHitLocation()
Returns true if the event has a hit location. |
boolean |
hasWeapon()
Returns true if there was a weapon for this event. |
void |
setAttackerMessage(java.lang.String msg)
Sets message to print to attacker |
void |
setDamageAmounts(int[] damageAmounts)
Sets array of damage amounts done |
void |
setDamageTypes(DamageType[] damageTypes)
Sets damage types involved |
void |
setDefenderMessage(java.lang.String msg)
Sets message to print to defender |
void |
setHitLocation(BodyPart hitloc)
Sets the body part where the damage is taking place. |
void |
setTotalDamage(int totalDamage)
Sets total damage done in the event |
void |
setWeapon(java.lang.Object weapon)
Sets the weapon or attack used to produce the damage |
java.lang.String |
toString()
Returns a string representation of this PropertyList. |
Methods inherited from class wyvern.kernel.commands.TargetedEvent |
getCloneErrorMsg, getLocation, getQuantity, getTarget, getTargetName, hasTarget, isQuantified, isTargetSpecifiedByHashcode, setLocation, setQuantified, setQuantity, setTarget, setTargetName |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Constructor Detail |
public DamageEvent()
Method Detail |
public boolean hasHitLocation()
public void setHitLocation(BodyPart hitloc)
public BodyPart getHitLocation()
public boolean hasWeapon()
public java.lang.Object getWeapon()
public void setWeapon(java.lang.Object weapon)
weapon
- the weapon or attack used to produce the damage
(a wyvern.lib.Attack or wyvern.lib.GameObject)public int[] getDamageAmounts()
public void setDamageAmounts(int[] damageAmounts)
damageAmounts
- array of damage amounts donepublic DamageType[] getDamageTypes()
public void setDamageTypes(DamageType[] damageTypes)
damageTypes
- damage types involvedpublic int getTotalDamage()
public void setTotalDamage(int totalDamage)
totalDamage
- total damage done in the eventpublic java.lang.String getAttackerMessage()
public void setAttackerMessage(java.lang.String msg)
msg
- message to print to attacker, or null if
attacker shouldn't hear anythingpublic java.lang.String getDefenderMessage()
public void setDefenderMessage(java.lang.String msg)
msg
- message to print to defender, or null if
defender shouldn't hear anythingpublic java.lang.String toString()
PList
toString
in class EventImpl
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |