atavism.agis.objects
Class NonCombatPet
java.lang.Object
atavism.server.objects.NamedPropertyClass
atavism.server.objects.Entity
atavism.agis.objects.Pet
atavism.agis.objects.NonCombatPet
- All Implemented Interfaces:
- MessageCallback, java.io.Serializable
public class NonCombatPet
- extends Pet
- implements java.io.Serializable, MessageCallback
- See Also:
- Serialized Form
Method Summary |
boolean |
activate()
Activates the message subscriptions so this pet object can pick up relevant messages. |
boolean |
deactivate()
Deactivates the message subscriptions so this pet object will no longer pick up any messages. |
boolean |
despawnPet()
|
java.lang.Long |
getDespawnTime()
|
void |
handleCommand(java.lang.String command,
OID targetOid)
Processes commands, which will either update the pets attitude, the current command, or activate
an ability that the pet has. |
void |
handleMessage(Message msg,
int flags)
process network messages |
protected void |
handleOwnerPropertyUpdate(PropertyMessage propMsg)
Deals with the different property updates that have occurred for the owner of the pet. |
protected void |
handlePetPropertyUpdate(PropertyMessage propMsg)
Deals with the different property updates that have occurred for the pet. |
void |
setDespawnTime(java.lang.Long despawnTime)
|
void |
summonPet()
|
Methods inherited from class atavism.server.objects.Entity |
addSubObjectNamespace, equals, equals, getLock, getNamespace, getOid, getPersistenceFlag, getProperty, getSubObjectNamespaces, getSubObjectNamespacesInt, getTransientDataRef, getType, hashCode, hasSubObjectNamespace, isDeleted, registerTransientPropertyKey, removeProperty, removeSubObjectNamespace, setDeleted, setNamespace, setOid, setPersistenceFlag, setProperty, setSubObjectNamespaces, setSubObjectNamespacesInt, setType, toBytes, toString, unregisterTransientPropertyKey |
Methods inherited from class atavism.server.objects.NamedPropertyClass |
getBooleanProperty, getIntProperty, getName, getPropertyMap, getPropertyMapRef, getStringProperty, lock, modifyIntProperty, setName, setPropertyMap, setupTransient, unlock |
Methods inherited from class java.lang.Object |
clone, finalize, getClass, notify, notifyAll, wait, wait, wait |
scheduledExecutioner
protected java.util.concurrent.ScheduledFuture<?> scheduledExecutioner
NonCombatPet
public NonCombatPet()
NonCombatPet
public NonCombatPet(int mobTemplateID,
OID mobObj,
boolean isSpawned,
java.lang.Long duration,
OID ownerOid)
summonPet
public void summonPet()
despawnPet
public boolean despawnPet()
- Overrides:
despawnPet
in class Pet
activate
public boolean activate()
- Activates the message subscriptions so this pet object can pick up relevant messages.
- Returns:
deactivate
public boolean deactivate()
- Deactivates the message subscriptions so this pet object will no longer pick up any messages.
- Returns:
handleMessage
public void handleMessage(Message msg,
int flags)
- process network messages
- Specified by:
handleMessage
in interface MessageCallback
- Parameters:
msg
- Message sent from other agent.flags
- Bitwise OR of MessageCallback.NO_FLAGS
, MessageCallback.RESPONSE_EXPECTED
.
handleCommand
public void handleCommand(java.lang.String command,
OID targetOid)
- Processes commands, which will either update the pets attitude, the current command, or activate
an ability that the pet has.
- Parameters:
command
-
handlePetPropertyUpdate
protected void handlePetPropertyUpdate(PropertyMessage propMsg)
- Deals with the different property updates that have occurred for the pet.
- Parameters:
propMsg
-
handleOwnerPropertyUpdate
protected void handleOwnerPropertyUpdate(PropertyMessage propMsg)
- Deals with the different property updates that have occurred for the owner of the pet.
- Parameters:
propMsg
-
getDespawnTime
public java.lang.Long getDespawnTime()
setDespawnTime
public void setDespawnTime(java.lang.Long despawnTime)