• Manual
  • Scripting API
  • Changelog
  • Contact
Search Results for

    Show / Hide Table of Contents
    • BattleBehaviour
      • BattleBehaviour.Fusion
        • FusionManager
        • GameCharacterFusion
      • Battle
      • BossSize
      • CharacterGroup
      • ScriptableBattlePosition
      • ScriptableBattleStage
      • TeamData
      • BattleBehaviour.Backup
        • BackupState
        • BattleBackup
    • GameActors
      • GameActor
      • GameCharacter
      • GameCharacter.AIState
      • GameItem
    • States
      • BattleState
      • ChangeStageState
      • FightState
      • FightState.LoseCondition
      • FightState.WinCondition
      • PreparationState
      • ResetSceneState
    • Battlefield
      • BattleGrid
      • BattleGrid.GridType
      • Bench
      • GridCell
      • GridCellEffect
      • SellZone
    • BattleUI
      • CharacterEnergyUI
      • CharacterHealthUI
      • CharacterStatsUI
      • DamagePopup
      • ItemDescriptionUI
      • ShopExpBarUI
      • StageUI
      • TraitDescriptionUI
      • TraitListUI
      • TraitListUI.OrderBy
      • TraitStatsUI
      • TraitUI
    • EditorScripts
      • BattleGridEditor
      • BattlePositionEditor
      • BenchEditor
      • GameCharacterEditor
      • NetworkObjectsListEditor
      • NFO_GameCharacterEditor
      • NGO_MenuActions
      • ReadOnlyDrawer
    • Formulas
      • BattleFormulas
      • BattleFormulas.DamageType
    • Movement
      • ApproximateAstarMovement
      • ExactAstarMovement
      • IBattleMovement
      • PathFinding2D
    • Multiplayer
      • BattleBehaviour
        • NetworkObjectList
        • StatsStruct
        • GameActors
          • NGO_GameCharacter
          • NGO_GameItem
        • Player
          • GamePlayer
          • IPlayer
        • States
          • MP_ConnectionState
          • MP_FightState
          • MP_PreparationState
      • ClientTransform
        • ClientNetworkTransform
      • EditorScripts
        • NGO_MenuActions
      • GamingServices
        • GamingServices
          • GamingServices.RelayHostData
          • GamingServices.RelayJoinData
      • UI
        • NetworkManagerUI
    • Shop
      • ScriptableShopItem
      • ShopCharacter
      • ShopGameItem
      • ShopItemInfo
      • ShopLevel
      • ShopLevelManager
      • ShopManager
      • ShopGUI
        • CurrencyUI
        • EquippedItemDescriptionUI
        • ShopItemUI
        • ShopUI
        • SpecialAttackDescriptionUI
        • Timer
      • ShopList
        • IShopList
        • ScriptableDeckList
        • ScriptableGroupItemList
        • ScriptableIndividualItemList
        • ShopItemList
    • Skills
      • ApplyBuffOnHitEffect
      • ApplyDebuffOnHitEffect
      • ArrowEffect
      • BuffEffect
      • BuffEffectInfo
      • FixedDamageOverTimeEffect
      • HealthMeteoriteAllEffect
      • HealthStealEffect
      • IAttackEffect
      • MeleeEffect
      • MeteoriteEffect
      • OnHitEffect
      • Projectile
      • RangedEffect
      • SimpleBuffEffect
      • SwordEffect
      • VariableDamageOverTimeEffect
    • Stats
      • CharacterStats
      • CharacterStats.CharacterStat
      • ItemModificator
      • StatModificator
      • StatsModificator
      • StatsModificator.ModificatorType
      • Trait
      • TraitOption
      • TraitOption.TraitTarget
    • Utility
      • AutoBattleSettings
      • ReadOnlyAttribute
      • UIUtility

    Class BattleState

    It represents a state of the battle. It determines how the characters behave within the state and sets the conditions for moving to the next state.
    For example, PreparationState allows to instantiate enemies, as well as move and equip characters, while state FightState allows both teams to battle each other.

    Inheritance
    Object
    BattleState
    ChangeSceneState
    ChangeStageState
    FightState
    PreparationState
    ResetSceneState
    Namespace: AutoBattleFramework.BattleBehaviour.States
    Assembly: cs.temp.dll.dll
    Syntax
    public abstract class BattleState : ScriptableObject

    Fields

    ShowInUI

    If true, show the state in StageUI

    Declaration
    public bool ShowInUI
    Field Value
    Type Description
    Boolean

    stage

    The ScriptableBattleStage to which the state belongs.

    Declaration
    public ScriptableBattleStage stage
    Field Value
    Type Description
    ScriptableBattleStage

    time

    Duration of the stage.

    Declaration
    public float time
    Field Value
    Type Description
    Single

    UIPrefab

    Prefab that represents the image of the stage.

    Declaration
    public GameObject UIPrefab
    Field Value
    Type Description
    GameObject

    Methods

    AllowFieldDrag(GameActor)

    Sets the condition in which a GameActor can be moved.

    Declaration
    public abstract bool AllowFieldDrag(GameActor actor)
    Parameters
    Type Name Description
    GameActor actor

    Actor to be dragged.

    Returns
    Type Description
    Boolean

    If a GameActor can be moved.

    ApplyBackupPlayerTeam(Int32)

    Apply the Backup copy of the status of characters and items. Can be used to return to the previous state of a round, before making changes.

    Declaration
    protected bool ApplyBackupPlayerTeam(int PlayerIndex = 0)
    Parameters
    Type Name Description
    Int32 PlayerIndex
    Returns
    Type Description
    Boolean

    BackupStagePlayerTeam(Int32)

    Backup copy of the status of characters and items at the start of a stage. Can be used to return to the initial state of the stage, before making changes.

    Declaration
    protected void BackupStagePlayerTeam(int PlayerIndex = 0)
    Parameters
    Type Name Description
    Int32 PlayerIndex

    BackupStatePlayerTeam(Int32)

    Backup copy of the status of characters and items. Can be used to return to the previous state of a round, before making changes.

    Declaration
    protected void BackupStatePlayerTeam(int PlayerIndex = 0)
    Parameters
    Type Name Description
    Int32 PlayerIndex

    CharacterAIUpdate(GameCharacter)

    Every GameCharacter delegates the Update() method to this state.

    Declaration
    public abstract void CharacterAIUpdate(GameCharacter character)
    Parameters
    Type Name Description
    GameCharacter character

    Character to be updated.

    OnStageStart()

    Method that is invoked once the state starts.

    Declaration
    public abstract void OnStageStart()

    OnTimerFinish()

    Method that is called once when the Timer marks zero.

    Declaration
    public abstract void OnTimerFinish()

    Update()

    Method that is once every frame.

    Declaration
    public abstract void Update()
    In This Article
    Back to top Auto-Battle Framework documentation