#include <battle_windows.h>
Inheritance diagram for hoa_battle::private_battle::ActionWindow:


Public Member Functions | |
| ActionWindow () | |
| void | Draw () |
| Draws the menu window and calls appropriate helper method. | |
| void | Initialize (BattleCharacterActor *character) |
| Initializes the window so that it is ready to prepare and select another action. | |
| void | Reset () |
| Sets class members to initial state This call also hides the window from the screen. You'll need to call the Initialize function once more to show it again. | |
| void | Update () |
| Updates the state of the menu window and calls appropriate helper method. | |
| ~ActionWindow () | |
Member Access Functions | |
| uint32 | GetActionCategory () const |
| hoa_global::GLOBAL_TARGET | GetActionTargetType () const |
| hoa_global::GlobalItem * | GetSelectedItem () const |
| hoa_global::GlobalSkill * | GetSelectedSkill () const |
| ACTION_WINDOW_VIEWS | GetState () const |
| bool | IsActionTargetAlly () const |
Private Member Functions | |
| void | _ConstructActionSelectionList () |
| Reconstructs the _action_selection_list based on the current character and selected action category. | |
| void | _DrawActionCategory () |
| Handles update processing when the _state member is VIEW_ACTION_CATEGORY. | |
| void | _DrawActionInformation () |
| Handles update processing when the _state member is VIEW_ACTION_INFORMATION. | |
| void | _DrawActionSelection () |
| Handles update processing when the _state member is VIEW_ACTION_SELECTION. | |
| void | _DrawTargetSelection () |
| Handles update processing when the _state member is VIEW_TARGET_SELECTION. | |
| void | _UpdateActionCategory () |
| Handles update processing when the _state member is VIEW_ACTION_CATEGORY. | |
| void | _UpdateActionInformation () |
| Handles update processing when the _state member is VIEW_ACTION_INFORMATION. | |
| void | _UpdateActionSelection () |
| Handles update processing when the _state member is VIEW_ACTION_SELECTION. | |
| void | _UpdateTargetSelection () |
| Handles update processing when the _state member is VIEW_TARGET_SELECTION. | |
Private Attributes | |
| std::vector< hoa_video::StillImage > | _action_category_icons |
| A vector containing the icons used for representing each action category. | |
| hoa_video::OptionBox | _action_category_list |
| The option box that lists the types of actions that a character may take in battle Typically this list includes "attack", "defend", "support", and "item". More types may appear under special circumstances and conditions. | |
| hoa_video::OptionBox | _action_selection_list |
| The option box that lists the actions that can be taken after a category is selected. | |
| bool | _action_target_ally |
| If true the action should target an ally, otherwise it should target an enemy. | |
| hoa_global::GLOBAL_TARGET | _action_target_type |
| The type of target for the currently selected action (attack point, actor, or party). | |
| BattleCharacterActor * | _character |
| A pointer to the character whom is currently selected for initiating an action. | |
| std::vector< hoa_global::GlobalItem * > | _item_list |
| Contains the list of items that are available for use in battle Each entry in here will correspond to each entry in the _action_selection_list when the player selects an item to be used. This vector is not necessarily a copy of the GlobalItem vector stored in the global inventory, since only items avaialable for use in battle are stored in here. | |
| uint32 | _selected_action |
| The action that the player selected when he/she was at the action selection menu. | |
| uint32 | _selected_action_category |
| The action category that the player selected when he/she was at that menu The value of this member is often compared with the ACTION_TYPE constants at the top of battle.h. | |
| std::vector< hoa_global::GlobalSkill * > * | _skill_list |
| Contains the list of skills that are available for use in battle This is essentially a pointer to the attack, defend, or support skill set for the selected character. Skills are contained within this vector even if they can not be used because of insuffient SP available, or for any other reason. | |
| ACTION_WINDOW_VIEWS | _state |
| The state that the action window is in, which reflects the contents of the window. | |
Friends | |
| class | BattleMode |
****************************************************************************
This window is located at the bottom right hand corner of the screen. This window has a constant position and size, but its inner contents can change greatly depending on the context of the battle. These content views are described below.
Definition at line 101 of file battle_windows.h.
| hoa_battle::private_battle::ActionWindow::ActionWindow | ( | ) |
Definition at line 46 of file battle_windows.cpp.
References _action_category_icons, _action_category_list, _action_selection_list, hoa_video::GameVideo::LoadImage(), hoa_utils::MakeUnicodeString(), Reset(), hoa_video::private_video::GUIElement::SetAlignment(), hoa_video::OptionBox::SetCellSize(), hoa_video::OptionBox::SetCursorOffset(), hoa_video::OptionBox::SetFont(), hoa_video::OptionBox::SetHorizontalWrapMode(), hoa_video::OptionBox::SetOptionAlignment(), hoa_video::OptionBox::SetOptions(), hoa_video::private_video::GUIControl::SetOwner(), hoa_video::private_video::GUIElement::SetPosition(), hoa_video::OptionBox::SetSelection(), hoa_video::OptionBox::SetSelectMode(), hoa_video::OptionBox::SetSize(), hoa_video::OptionBox::SetVerticalWrapMode(), hoa_video::VIDEO_SELECT_SINGLE, hoa_video::VIDEO_WRAP_MODE_STRAIGHT, hoa_video::VIDEO_X_CENTER, hoa_video::VIDEO_X_LEFT, hoa_video::VIDEO_Y_CENTER, hoa_video::VIDEO_Y_TOP, and hoa_video::VideoManager.
Here is the call graph for this function:

| hoa_battle::private_battle::ActionWindow::~ActionWindow | ( | ) |
Definition at line 110 of file battle_windows.cpp.
References _action_category_icons, hoa_video::GameVideo::DeleteImage(), and hoa_video::VideoManager.
Here is the call graph for this function:

| void hoa_battle::private_battle::ActionWindow::_ConstructActionSelectionList | ( | ) | [private] |
Reconstructs the _action_selection_list based on the current character and selected action category.
Definition at line 431 of file battle_windows.cpp.
References _action_selection_list, _character, _item_list, _selected_action_category, _skill_list, hoa_battle::private_battle::ACTION_TYPE_ATTACK, hoa_battle::private_battle::ACTION_TYPE_DEFEND, hoa_battle::private_battle::ACTION_TYPE_ITEM, hoa_battle::private_battle::ACTION_TYPE_SUPPORT, hoa_battle::BATTLE_DEBUG, hoa_video::OptionBox::EnableOption(), hoa_battle::private_battle::BattleCharacterActor::GetActor(), hoa_global::GlobalCharacter::GetAttackSkills(), hoa_global::GlobalObject::GetCount(), hoa_global::GlobalCharacter::GetDefenseSkills(), hoa_global::GameGlobal::GetInventoryItems(), hoa_global::GlobalObject::GetName(), hoa_battle::private_battle::BattleActor::GetSkillPoints(), hoa_global::GlobalCharacter::GetSupportSkills(), hoa_global::GlobalItem::GetUsage(), hoa_global::GLOBAL_USE_BATTLE, hoa_global::GlobalManager, hoa_utils::MakeUnicodeString(), hoa_utils::NumberToString(), hoa_video::OptionBox::SetOptions(), hoa_video::OptionBox::SetSelection(), and hoa_video::OptionBox::SetSize().
Referenced by _UpdateActionCategory().
Here is the call graph for this function:

| void hoa_battle::private_battle::ActionWindow::_DrawActionCategory | ( | ) | [private] |
Handles update processing when the _state member is VIEW_ACTION_CATEGORY.
Definition at line 317 of file battle_windows.cpp.
References _action_category_list, and hoa_video::OptionBox::Draw().
Referenced by Draw().
Here is the call graph for this function:

| void hoa_battle::private_battle::ActionWindow::_DrawActionInformation | ( | ) | [private] |
Handles update processing when the _state member is VIEW_ACTION_INFORMATION.
Definition at line 387 of file battle_windows.cpp.
References _selected_action_category, hoa_battle::private_battle::ACTION_TYPE_ATTACK, hoa_battle::private_battle::ACTION_TYPE_DEFEND, hoa_battle::private_battle::ACTION_TYPE_ITEM, hoa_battle::private_battle::ACTION_TYPE_SUPPORT, hoa_video::GameVideo::DrawText(), GetSelectedItem(), GetSelectedSkill(), hoa_utils::MakeUnicodeString(), hoa_video::GameVideo::Move(), hoa_video::GameVideo::MoveRelative(), hoa_utils::NumberToString(), hoa_video::GameVideo::SetTextColor(), and hoa_video::VideoManager.
Referenced by Draw().
Here is the call graph for this function:

| void hoa_battle::private_battle::ActionWindow::_DrawActionSelection | ( | ) | [private] |
Handles update processing when the _state member is VIEW_ACTION_SELECTION.
Definition at line 323 of file battle_windows.cpp.
References _action_category_icons, _action_selection_list, _selected_action_category, hoa_battle::private_battle::ACTION_TYPE_ATTACK, hoa_battle::private_battle::ACTION_TYPE_DEFEND, hoa_battle::private_battle::ACTION_TYPE_ITEM, hoa_battle::private_battle::ACTION_TYPE_SUPPORT, hoa_battle::BATTLE_DEBUG, hoa_video::OptionBox::Draw(), hoa_video::GameVideo::DrawImage(), hoa_video::GameVideo::DrawText(), hoa_utils::MakeUnicodeString(), hoa_video::GameVideo::Move(), hoa_video::GameVideo::MoveRelative(), hoa_video::GameVideo::SetDrawFlags(), hoa_video::GameVideo::SetFont(), hoa_video::GameVideo::SetTextColor(), hoa_video::VIDEO_X_LEFT, hoa_video::VIDEO_Y_CENTER, hoa_video::VIDEO_Y_TOP, and hoa_video::VideoManager.
Referenced by Draw().
Here is the call graph for this function:

| void hoa_battle::private_battle::ActionWindow::_DrawTargetSelection | ( | ) | [private] |
Handles update processing when the _state member is VIEW_TARGET_SELECTION.
Definition at line 368 of file battle_windows.cpp.
References _action_target_type, hoa_video::GameVideo::DrawText(), hoa_global::GLOBAL_TARGET_ACTOR, hoa_global::GLOBAL_TARGET_ATTACK_POINT, hoa_global::GLOBAL_TARGET_PARTY, hoa_utils::MakeUnicodeString(), hoa_video::GameVideo::Move(), hoa_video::GameVideo::SetTextColor(), and hoa_video::VideoManager.
Referenced by Draw().
Here is the call graph for this function:

| void hoa_battle::private_battle::ActionWindow::_UpdateActionCategory | ( | ) | [private] |
Handles update processing when the _state member is VIEW_ACTION_CATEGORY.
Definition at line 189 of file battle_windows.cpp.
References _action_category_list, _ConstructActionSelectionList(), _selected_action_category, _state, hoa_input::GameInput::ConfirmPress(), hoa_video::OptionBox::GetSelection(), hoa_video::OptionBox::HandleLeftKey(), hoa_video::OptionBox::HandleRightKey(), hoa_input::InputManager, hoa_input::GameInput::LeftPress(), hoa_input::GameInput::RightPress(), and hoa_battle::private_battle::VIEW_ACTION_SELECTION.
Referenced by Update().
Here is the call graph for this function:

| void hoa_battle::private_battle::ActionWindow::_UpdateActionInformation | ( | ) | [private] |
Handles update processing when the _state member is VIEW_ACTION_INFORMATION.
Definition at line 282 of file battle_windows.cpp.
References _state, hoa_input::GameInput::CancelPress(), hoa_input::InputManager, hoa_input::GameInput::MenuPress(), and hoa_battle::private_battle::VIEW_ACTION_SELECTION.
Referenced by Update().
Here is the call graph for this function:

| void hoa_battle::private_battle::ActionWindow::_UpdateActionSelection | ( | ) | [private] |
Handles update processing when the _state member is VIEW_ACTION_SELECTION.
Definition at line 208 of file battle_windows.cpp.
References _action_selection_list, _action_target_ally, _action_target_type, hoa_battle::BattleMode::_cursor_state, _item_list, _selected_action, _selected_action_category, hoa_battle::BattleMode::_selected_target, hoa_battle::BattleMode::_selected_target_index, _skill_list, _state, hoa_battle::private_battle::ACTION_TYPE_ATTACK, hoa_battle::private_battle::ACTION_TYPE_DEFEND, hoa_battle::private_battle::ACTION_TYPE_ITEM, hoa_battle::private_battle::ACTION_TYPE_SUPPORT, hoa_battle::BATTLE_DEBUG, hoa_input::GameInput::CancelPress(), hoa_input::GameInput::ConfirmPress(), hoa_battle::private_battle::current_battle, hoa_battle::private_battle::CURSOR_SELECT_TARGET, hoa_input::GameInput::DownPress(), hoa_battle::BattleMode::GetEnemyActorAt(), hoa_battle::BattleMode::GetIndexOfFirstAliveEnemy(), hoa_battle::BattleMode::GetPlayerCharacterAt(), hoa_video::OptionBox::GetSelection(), hoa_video::OptionBox::HandleDownKey(), hoa_video::OptionBox::HandleUpKey(), hoa_input::InputManager, hoa_input::GameInput::MenuPress(), hoa_input::GameInput::UpPress(), hoa_battle::private_battle::VIEW_ACTION_CATEGORY, hoa_battle::private_battle::VIEW_ACTION_INFORMATION, and hoa_battle::private_battle::VIEW_TARGET_SELECTION.
Referenced by Update().
Here is the call graph for this function:

| void hoa_battle::private_battle::ActionWindow::_UpdateTargetSelection | ( | ) | [private] |
Handles update processing when the _state member is VIEW_TARGET_SELECTION.
Definition at line 268 of file battle_windows.cpp.
References _state, hoa_input::GameInput::CancelPress(), hoa_input::GameInput::DownPress(), hoa_input::InputManager, hoa_input::GameInput::LeftPress(), hoa_input::GameInput::RightPress(), hoa_input::GameInput::UpPress(), and hoa_battle::private_battle::VIEW_ACTION_SELECTION.
Referenced by Update().
Here is the call graph for this function:

| void hoa_battle::private_battle::ActionWindow::Draw | ( | ) | [virtual] |
Draws the menu window and calls appropriate helper method.
Reimplemented from hoa_video::MenuWindow.
Definition at line 290 of file battle_windows.cpp.
References _DrawActionCategory(), _DrawActionInformation(), _DrawActionSelection(), _DrawTargetSelection(), _state, hoa_battle::BATTLE_DEBUG, hoa_battle::private_battle::VIEW_ACTION_CATEGORY, hoa_battle::private_battle::VIEW_ACTION_INFORMATION, hoa_battle::private_battle::VIEW_ACTION_SELECTION, hoa_battle::private_battle::VIEW_INVALID, hoa_battle::private_battle::VIEW_TARGET_SELECTION, and hoa_battle::private_battle::VIEW_TOTAL.
Referenced by hoa_battle::BattleMode::Draw().
Here is the call graph for this function:

| uint32 hoa_battle::private_battle::ActionWindow::GetActionCategory | ( | ) | const [inline] |
Definition at line 131 of file battle_windows.h.
References _selected_action_category.
Referenced by hoa_battle::BattleMode::_DrawTimeMeter(), hoa_battle::BattleMode::_UpdateAttackPointSelection(), and hoa_battle::BattleMode::_UpdateTargetSelection().
| hoa_global::GLOBAL_TARGET hoa_battle::private_battle::ActionWindow::GetActionTargetType | ( | ) | const [inline] |
Definition at line 134 of file battle_windows.h.
References _action_target_type.
Referenced by hoa_battle::BattleMode::_DrawTimeMeter(), and hoa_battle::BattleMode::_UpdateTargetSelection().
| hoa_global::GlobalItem* hoa_battle::private_battle::ActionWindow::GetSelectedItem | ( | ) | const [inline] |
Definition at line 143 of file battle_windows.h.
References _item_list, and _selected_action.
Referenced by _DrawActionInformation(), hoa_battle::BattleMode::_UpdateAttackPointSelection(), and hoa_battle::BattleMode::_UpdateTargetSelection().
| hoa_global::GlobalSkill* hoa_battle::private_battle::ActionWindow::GetSelectedSkill | ( | ) | const [inline] |
Definition at line 140 of file battle_windows.h.
References _selected_action, and _skill_list.
Referenced by _DrawActionInformation(), hoa_battle::BattleMode::_UpdateAttackPointSelection(), and hoa_battle::BattleMode::_UpdateTargetSelection().
| ACTION_WINDOW_VIEWS hoa_battle::private_battle::ActionWindow::GetState | ( | ) | const [inline] |
Reimplemented from hoa_video::MenuWindow.
Definition at line 128 of file battle_windows.h.
References _state.
Referenced by hoa_battle::BattleMode::Draw(), and hoa_battle::BattleMode::Update().
| void hoa_battle::private_battle::ActionWindow::Initialize | ( | BattleCharacterActor * | character | ) |
Initializes the window so that it is ready to prepare and select another action.
| character | A pointer to the character whom an action is being selected for Calling this function will un-hide the menu window |
Definition at line 120 of file battle_windows.cpp.
References _action_category_list, _character, _state, hoa_battle::BATTLE_DEBUG, hoa_video::OptionBox::EnableOption(), hoa_battle::private_battle::BattleCharacterActor::GetActor(), hoa_global::GlobalCharacter::GetAttackSkills(), hoa_global::GlobalCharacter::GetDefenseSkills(), hoa_global::GameGlobal::GetInventoryItems(), hoa_global::GlobalCharacter::GetSupportSkills(), hoa_global::GlobalManager, hoa_battle::private_battle::VIEW_ACTION_CATEGORY, and hoa_battle::private_battle::VIEW_INVALID.
Referenced by hoa_battle::BattleMode::_UpdateCharacterSelection().
Here is the call graph for this function:

| bool hoa_battle::private_battle::ActionWindow::IsActionTargetAlly | ( | ) | const [inline] |
Definition at line 137 of file battle_windows.h.
References _action_target_ally.
Referenced by hoa_battle::BattleMode::_UpdateTargetSelection().
| void hoa_battle::private_battle::ActionWindow::Reset | ( | ) |
Sets class members to initial state This call also hides the window from the screen. You'll need to call the Initialize function once more to show it again.
Definition at line 148 of file battle_windows.cpp.
References _action_target_ally, _action_target_type, _character, _item_list, _selected_action, _selected_action_category, _skill_list, _state, hoa_global::GLOBAL_TARGET_INVALID, and hoa_battle::private_battle::VIEW_INVALID.
Referenced by hoa_battle::BattleMode::_UpdateAttackPointSelection(), ActionWindow(), and hoa_battle::BattleMode::Update().
| void hoa_battle::private_battle::ActionWindow::Update | ( | ) |
Updates the state of the menu window and calls appropriate helper method.
Definition at line 162 of file battle_windows.cpp.
References _state, _UpdateActionCategory(), _UpdateActionInformation(), _UpdateActionSelection(), _UpdateTargetSelection(), hoa_battle::BATTLE_DEBUG, hoa_system::GameSystem::GetUpdateTime(), hoa_system::SystemManager, hoa_battle::private_battle::VIEW_ACTION_CATEGORY, hoa_battle::private_battle::VIEW_ACTION_INFORMATION, hoa_battle::private_battle::VIEW_ACTION_SELECTION, hoa_battle::private_battle::VIEW_INVALID, hoa_battle::private_battle::VIEW_TARGET_SELECTION, and hoa_battle::private_battle::VIEW_TOTAL.
Referenced by hoa_battle::BattleMode::Update().
Here is the call graph for this function:

friend class BattleMode [friend] |
Definition at line 102 of file battle_windows.h.
std::vector<hoa_video::StillImage> hoa_battle::private_battle::ActionWindow::_action_category_icons [private] |
A vector containing the icons used for representing each action category.
Definition at line 192 of file battle_windows.h.
Referenced by _DrawActionSelection(), ActionWindow(), and ~ActionWindow().
The option box that lists the types of actions that a character may take in battle Typically this list includes "attack", "defend", "support", and "item". More types may appear under special circumstances and conditions.
Definition at line 186 of file battle_windows.h.
Referenced by _DrawActionCategory(), _UpdateActionCategory(), ActionWindow(), and Initialize().
The option box that lists the actions that can be taken after a category is selected.
Definition at line 189 of file battle_windows.h.
Referenced by _ConstructActionSelectionList(), _DrawActionSelection(), _UpdateActionSelection(), and ActionWindow().
If true the action should target an ally, otherwise it should target an enemy.
Definition at line 165 of file battle_windows.h.
Referenced by _UpdateActionSelection(), IsActionTargetAlly(), and Reset().
The type of target for the currently selected action (attack point, actor, or party).
Definition at line 162 of file battle_windows.h.
Referenced by _DrawTargetSelection(), _UpdateActionSelection(), GetActionTargetType(), and Reset().
A pointer to the character whom is currently selected for initiating an action.
Definition at line 151 of file battle_windows.h.
Referenced by _ConstructActionSelectionList(), Initialize(), and Reset().
std::vector<hoa_global::GlobalItem*> hoa_battle::private_battle::ActionWindow::_item_list [private] |
Contains the list of items that are available for use in battle Each entry in here will correspond to each entry in the _action_selection_list when the player selects an item to be used. This vector is not necessarily a copy of the GlobalItem vector stored in the global inventory, since only items avaialable for use in battle are stored in here.
Definition at line 173 of file battle_windows.h.
Referenced by _ConstructActionSelectionList(), _UpdateActionSelection(), GetSelectedItem(), and Reset().
The action that the player selected when he/she was at the action selection menu.
Definition at line 159 of file battle_windows.h.
Referenced by _UpdateActionSelection(), GetSelectedItem(), GetSelectedSkill(), and Reset().
The action category that the player selected when he/she was at that menu The value of this member is often compared with the ACTION_TYPE constants at the top of battle.h.
Definition at line 156 of file battle_windows.h.
Referenced by _ConstructActionSelectionList(), _DrawActionInformation(), _DrawActionSelection(), _UpdateActionCategory(), _UpdateActionSelection(), GetActionCategory(), and Reset().
std::vector<hoa_global::GlobalSkill*>* hoa_battle::private_battle::ActionWindow::_skill_list [private] |
Contains the list of skills that are available for use in battle This is essentially a pointer to the attack, defend, or support skill set for the selected character. Skills are contained within this vector even if they can not be used because of insuffient SP available, or for any other reason.
Definition at line 180 of file battle_windows.h.
Referenced by _ConstructActionSelectionList(), _UpdateActionSelection(), GetSelectedSkill(), and Reset().
The state that the action window is in, which reflects the contents of the window.
Definition at line 148 of file battle_windows.h.
Referenced by _UpdateActionCategory(), _UpdateActionInformation(), _UpdateActionSelection(), _UpdateTargetSelection(), Draw(), GetState(), Initialize(), Reset(), and Update().
1.5.1