Interface ICombatOperationsApi
Interface for the API of combat operations.
Namespace: Fibula.Mechanics.Contracts.Abstractions
Assembly: Fibula.Mechanics.Contracts.dll
Syntax
public interface ICombatOperationsApi
Methods
| Improve this Doc View SourceCombatantAttackTargetChanged(ICombatant, ICombatant)
Handles an attack target change from a combatant.
Declaration
void CombatantAttackTargetChanged(ICombatant combatant, ICombatant oldTarget)
Parameters
| Type | Name | Description |
|---|---|---|
| ICombatant | combatant | The combatant that died. |
| ICombatant | oldTarget | The previous attack target, which can be null. |
CombatantDeath(ICombatant)
Handles a death from a combatant.
Declaration
void CombatantDeath(ICombatant combatant)
Parameters
| Type | Name | Description |
|---|---|---|
| ICombatant | combatant | The combatant that died. |
CreatureFollowTargetChanged(ICombatant, ICreature)
Handles a follow target change from a combatant.
Declaration
void CreatureFollowTargetChanged(ICombatant combatant, ICreature oldTarget)
Parameters
| Type | Name | Description |
|---|---|---|
| ICombatant | combatant | The creature that changed follow target. |
| ICreature | oldTarget | The old follow target, if any. |
CreatureHasLostCreature(ICreatureThatSensesOthers, ICreature)
Handles the event when a creature has lost another creature.
Declaration
void CreatureHasLostCreature(ICreatureThatSensesOthers creature, ICreature creatureLost)
Parameters
| Type | Name | Description |
|---|---|---|
| ICreatureThatSensesOthers | creature | The monster that sees the other. |
| ICreature | creatureLost | The creature that was lost. |
CreatureHasSeenCreature(ICreatureThatSensesOthers, ICreature)
Handles the event when a creature has seen another creature.
Declaration
void CreatureHasSeenCreature(ICreatureThatSensesOthers creature, ICreature creatureSeen)
Parameters
| Type | Name | Description |
|---|---|---|
| ICreatureThatSensesOthers | creature | The monster that sees the other. |
| ICreature | creatureSeen | The creature that was seen. |
SetCombatantAttackTarget(ICombatant, ICombatant)
Sets the combat target of the attacker and it's (possibly new) target.
Declaration
void SetCombatantAttackTarget(ICombatant attacker, ICombatant target)
Parameters
| Type | Name | Description |
|---|---|---|
| ICombatant | attacker | The attacker. |
| ICombatant | target | The target. |
SetCombatantFollowTarget(ICombatant, ICombatant)
Re-sets the follow target of the combatant and it's (possibly new) target.
Declaration
void SetCombatantFollowTarget(ICombatant combatant, ICombatant target)
Parameters
| Type | Name | Description |
|---|---|---|
| ICombatant | combatant | The attacker. |
| ICombatant | target | The new target. |
SetCombatantModes(ICombatant, FightMode, ChaseMode, Boolean)
Sets the fight, chase and safety modes of a combatant.
Declaration
void SetCombatantModes(ICombatant combatant, FightMode fightMode, ChaseMode chaseMode, bool safeModeOn)
Parameters
| Type | Name | Description |
|---|---|---|
| ICombatant | combatant | The combatant that update modes. |
| FightMode | fightMode | The fight mode to change to. |
| ChaseMode | chaseMode | The chase mode to change to. |
| System.Boolean | safeModeOn | A value indicating whether the attack safety lock is on. |