OGS Java API Spec

ogs.feats
Class Alertness

java.lang.Object
  |
  +--ogs.support.Object
        |
        +--ogs.core.Feature
              |
              +--ogs.core.Feat
                    |
                    +--ogs.feats.Alertness
All Implemented Interfaces:
EventListener

public class Alertness
extends Feat

A feat that adds a +2 bonus to all Listen and Spot skill checks.


Field Summary
 
Fields inherited from class ogs.core.Feat
COMBAT, CUMULATIVE, EXCLUSIVE, GENERAL, MAGIC, REPEATABLE, SPECIAL
 
Fields inherited from class ogs.support.Object
listeners
 
Constructor Summary
Alertness()
          Create a new Alertness feat.
 
Method Summary
 boolean attachObject(Object object)
          Attach this feat to an object.
protected  boolean canAttach(Object object)
          Determine if this feat can be attached to an object.
 boolean detachObject()
          Detach this feat from an object.
 int getCompatibility()
          Determine the compatability of this feat.
 int getGroup()
          Determine the group that this feat belongs to.
 
Methods inherited from class ogs.core.Feat
findFeat, getSlots, getSlotsLevel
 
Methods inherited from class ogs.core.Feature
canDetach, getObject
 
Methods inherited from class ogs.support.Object
addListener, handleEvent, notifyListeners, removeListener
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

Alertness

public Alertness()
Create a new Alertness feat.

Method Detail

getCompatibility

public int getCompatibility()
Determine the compatability of this feat. Alertness feats are exclusive feats.

Specified by:
getCompatibility in class Feat
Returns:
Feat.EXCLUSIVE

getGroup

public int getGroup()
Determine the group that this feat belongs to. Alertness feats are general feats.

Specified by:
getGroup in class Feat
Returns:
Feat.GENERAL

canAttach

protected boolean canAttach(Object object)
Determine if this feat can be attached to an object. Since Alertness feats are exclusive feats, they can only be attached to objects that do not already have this feat.

Overrides:
canAttach in class Feat
Parameters:
object - Object to attach this feature to.
Returns:
True if the feature is attached to the object.

attachObject

public boolean attachObject(Object object)
Attach this feat to an object. This function adds a +2 bonus to Listen and Spot skill checks if the creature has either or both of these skills.

Overrides:
attachObject in class Feature
Parameters:
object - Object to attach this feat to.
Returns:
True if feat is attached to object.

detachObject

public boolean detachObject()
Detach this feat from an object.

Overrides:
detachObject in class Feature
Returns:
True if this feat is detached from the object.

OGS Java API Spec