#include <MainFrame.hh>
Definition at line 44 of file MainFrame.hh.
Public Member Functions | |
MainFrame () | |
Constructor for the MainFrame. | |
Private Member Functions | |
void | CreateControls () |
Sets up the controls for this Frame. | |
void | setEquipment (int slot) |
Sets the equipment value for a particular slot. | |
void | setFeluccaOptions (enum City trammel) |
Changes the options for the Felucca moon control depending upon the phase of Trammel. | |
bool | isOpen () |
Checks if an SRAM file is currently open. | |
bool | hasValidEquipment (enum Character character) const |
Checks if a character has valid equipment. | |
bool | isValidParty () const |
Checks if the current party formation is valid. | |
bool | close () |
Closes the current SRAM file. | |
void | load (const wxString &filename) |
Loads an SRAM file. | |
void | loadGame (int game) |
Loads the game values into the frame controls. | |
void | loadStats (enum Character character) |
Loads the stats of a particular character into the character tab. | |
bool | save (const wxString &filename) |
Saves the SRAM to disk. | |
void | onBalloonChange (wxCommandEvent &event) |
Callback when the Balloon's location is changed. | |
void | onCharacterChange (wxCommandEvent &event) |
Callback when one of the characters is selected. | |
void | onEquipmentChange (wxCommandEvent &event) |
Callback when a characters equipment is changed. | |
void | onEquippedChange (wxCommandEvent &event) |
Callback when a character's equipped item is changed. | |
void | onEquippedUpdate (wxUpdateUIEvent &event) |
Callback to update the equipped checkboxes. | |
void | onFileClose (wxCommandEvent &event) |
Callback when close is selected from the file menu. | |
void | onFileExit (wxCommandEvent &event) |
Callback when exit is selected from the file menu. | |
void | onFileOpen (wxCommandEvent &event) |
Callback when open is selected from the file menu. | |
void | onFileSave (wxCommandEvent &event) |
Callback when save is selected from the file menu. | |
void | onFileSaveAs (wxCommandEvent &event) |
Callback when save as is selected from the file menu. | |
void | onGameChange (wxCommandEvent &event) |
Callback when one of the game menu items are selected. | |
void | onGameMenuUpdate (wxUpdateUIEvent &event) |
Callback when the game menu needs updated. | |
void | onGoldChange (wxCommandEvent &event) |
Callback when the gold amount is changed. | |
void | onHelpAbout (wxCommandEvent &event) |
Callback when about is selected from the help menu. | |
void | onHerbChange (wxScrollEvent &event) |
Callback when one of the herbs is changed. | |
void | onHerosNameChange (wxCommandEvent &event) |
Callback when the hero's name is changed. | |
void | onJoinedChange (wxCommandEvent &event) |
Callback when one of the joined members is changed. | |
void | onLocationBalloon (wxCommandEvent &event) |
Callback when balloon is selected from the location menu. | |
void | onLocationPlaceChange (wxCommandEvent &event) |
Callback when the location place is changed. | |
void | onLocationShip (wxCommandEvent &event) |
Callback when a ship is selected from the location menu. | |
void | onMagicChange (wxCommandEvent &event) |
Callback when one of the magics is changed. | |
void | onMemberClassChange (wxCommandEvent &event) |
Callback when one of the member's classes is changed. | |
void | onMemberUpdate (wxUpdateUIEvent &event) |
Callback when the party member choices need updated. | |
void | onPhaseChange (wxCommandEvent &event) |
Callback when one of the moon phases is changed. | |
void | onRuneChange (wxCommandEvent &event) |
Callback when one of the runes is changed. | |
void | onSaveCloseUpdate (wxUpdateUIEvent &event) |
Callback when the save or close file menu items need updating. | |
void | onSaveUpdate (wxUpdateUIEvent &event) |
Callback when the save as file menu item needs updating. | |
void | onShipChange (wxCommandEvent &event) |
Callback when one the pirate ships is changed. | |
void | onShipLocationChange (wxCommandEvent &event) |
Callback when the location of a pirate ship is changed. | |
void | onShipUpdate (wxUpdateUIEvent &event) |
Callback when a ship location item needs updating. | |
void | onStartLocationChange (wxCommandEvent &event) |
Callback when the start location is changed. | |
void | onStatChange (wxCommandEvent &event) |
Callback when one of the character stats is changed. | |
void | onStoneChange (wxCommandEvent &event) |
Callback when one of the stones is changed. | |
void | onToolHaveChange (wxCommandEvent &event) |
Callback when one of the have/have not tools is changed. | |
void | onToolQuantityChange (wxScrollEvent &event) |
Callback when one of the quantity tools is changed. | |
void | onVirtueChange (wxScrollEvent &event) |
Callback when one of the virtue values is changed. | |
void | onWhirlpoolChange (wxCommandEvent &event) |
Callback when the whirlpool's location is changed. | |
void | onWindowClosing (wxCloseEvent &event) |
Callback when the window is closing. | |
Private Attributes | |
wxCheckBox * | itemEquippedCheck [6] |
wxChoice * | itemChoice [6] |
wxChoice * | memberChoice [4] |
wxString | sramFile |
SaveSlot * | saveslot |
SRAMFile * | sram |
enum Location | location |
int | gameMenu |
int | locationMenu |
bool | ignoreEvents |
bool | open |
Static Private Attributes | |
static const wxString | CHARACTER_NAMES [] |
Array of the character class names. | |
static const wxString | CITY_NAMES [] |
Array of the names of the eight cities of virtue. | |
static const std::pair< int, int > | BALLOON_LOCATIONS [] |
Array of locations for the balloon. | |
static const std::pair< int, int > | PIRATESHIP_LOCATIONS [] |
Array of locations for the pirate ships. | |
static const int | INN_INDEX [] |
Array of indicies mapping start locations to choice selection. | |
Friends | |
class | FileDropTarget |
MainFrame::MainFrame | ( | ) |
void MainFrame::CreateControls | ( | ) | [private] |
void MainFrame::setEquipment | ( | int | slot | ) | [private] |
Sets the equipment value for a particular slot.
slot | The slot to set (0-5). |
Definition at line 202 of file MainFrame.cc.
void MainFrame::setFeluccaOptions | ( | enum City | trammel | ) | [private] |
Changes the options for the Felucca moon control depending upon the phase of Trammel.
trammel | The phase of trammel. |
Definition at line 214 of file MainFrame.cc.
bool hack4u::MainFrame::isOpen | ( | ) | [inline, private] |
Checks if an SRAM file is currently open.
Definition at line 430 of file MainFrame.hh.
bool MainFrame::hasValidEquipment | ( | enum Character | character | ) | const [private] |
Checks if a character has valid equipment.
character | The character. |
Definition at line 265 of file MainFrame.cc.
bool MainFrame::isValidParty | ( | ) | const [private] |
Checks if the current party formation is valid.
Definition at line 301 of file MainFrame.cc.
bool MainFrame::close | ( | ) | [private] |
Closes the current SRAM file.
Definition at line 330 of file MainFrame.cc.
void MainFrame::load | ( | const wxString & | filename | ) | [private] |
Loads an SRAM file.
filename | The SRAM file. |
Definition at line 363 of file MainFrame.cc.
void MainFrame::loadGame | ( | int | game | ) | [private] |
Loads the game values into the frame controls.
game | The game number to load (0, 1, or 2). |
Definition at line 405 of file MainFrame.cc.
void MainFrame::loadStats | ( | enum Character | character | ) | [private] |
Loads the stats of a particular character into the character tab.
character | The character. |
Definition at line 676 of file MainFrame.cc.
bool MainFrame::save | ( | const wxString & | filename | ) | [private] |
Saves the SRAM to disk.
filename | The filename to save the SRAM to. |
Definition at line 714 of file MainFrame.cc.
void MainFrame::onBalloonChange | ( | wxCommandEvent & | event | ) | [private] |
Callback when the Balloon's location is changed.
event | The associated command event. |
Definition at line 764 of file MainFrame.cc.
void hack4u::MainFrame::onCharacterChange | ( | wxCommandEvent & | event | ) | [inline, private] |
Callback when one of the characters is selected.
event | The associated command event. |
Definition at line 433 of file MainFrame.hh.
void MainFrame::onEquipmentChange | ( | wxCommandEvent & | event | ) | [private] |
Callback when a characters equipment is changed.
event | The associated command event. |
Definition at line 785 of file MainFrame.cc.
void MainFrame::onEquippedChange | ( | wxCommandEvent & | event | ) | [private] |
Callback when a character's equipped item is changed.
event | The associated command event. |
Definition at line 798 of file MainFrame.cc.
void MainFrame::onEquippedUpdate | ( | wxUpdateUIEvent & | event | ) | [private] |
Callback to update the equipped checkboxes.
event | The associated update UI event. |
Definition at line 811 of file MainFrame.cc.
void hack4u::MainFrame::onFileClose | ( | wxCommandEvent & | event | ) | [inline, private] |
Callback when close is selected from the file menu.
event | The associated command event. |
Definition at line 436 of file MainFrame.hh.
void MainFrame::onFileExit | ( | wxCommandEvent & | event | ) | [private] |
Callback when exit is selected from the file menu.
event | The associated command event. |
Definition at line 854 of file MainFrame.cc.
void MainFrame::onFileOpen | ( | wxCommandEvent & | event | ) | [private] |
Callback when open is selected from the file menu.
event | The associated command event. |
Definition at line 864 of file MainFrame.cc.
void hack4u::MainFrame::onFileSave | ( | wxCommandEvent & | event | ) | [inline, private] |
Callback when save is selected from the file menu.
event | The associated command event. |
Definition at line 439 of file MainFrame.hh.
void MainFrame::onFileSaveAs | ( | wxCommandEvent & | event | ) | [private] |
Callback when save as is selected from the file menu.
event | The associated command event. |
Definition at line 877 of file MainFrame.cc.
void MainFrame::onGameChange | ( | wxCommandEvent & | event | ) | [private] |
Callback when one of the game menu items are selected.
event | The associated command event. |
Definition at line 890 of file MainFrame.cc.
void MainFrame::onGameMenuUpdate | ( | wxUpdateUIEvent & | event | ) | [private] |
Callback when the game menu needs updated.
event | The associated update UI event. |
Definition at line 900 of file MainFrame.cc.
void MainFrame::onGoldChange | ( | wxCommandEvent & | event | ) | [private] |
Callback when the gold amount is changed.
event | The associated command event. |
Definition at line 917 of file MainFrame.cc.
void MainFrame::onHelpAbout | ( | wxCommandEvent & | event | ) | [private] |
Callback when about is selected from the help menu.
event | The associated command event. |
Definition at line 927 of file MainFrame.cc.
void MainFrame::onHerbChange | ( | wxScrollEvent & | event | ) | [private] |
Callback when one of the herbs is changed.
event | The associated scroll event. |
Definition at line 937 of file MainFrame.cc.
void MainFrame::onHerosNameChange | ( | wxCommandEvent & | event | ) | [private] |
Callback when the hero's name is changed.
event | The associated command event. |
Definition at line 959 of file MainFrame.cc.
void MainFrame::onJoinedChange | ( | wxCommandEvent & | event | ) | [private] |
Callback when one of the joined members is changed.
event | The associated command event. |
Definition at line 969 of file MainFrame.cc.
void MainFrame::onLocationBalloon | ( | wxCommandEvent & | event | ) | [private] |
Callback when balloon is selected from the location menu.
event | The associated command event. |
Definition at line 992 of file MainFrame.cc.
void MainFrame::onLocationPlaceChange | ( | wxCommandEvent & | event | ) | [private] |
Callback when the location place is changed.
event | The associated command event. |
Definition at line 1001 of file MainFrame.cc.
void MainFrame::onLocationShip | ( | wxCommandEvent & | event | ) | [private] |
Callback when a ship is selected from the location menu.
event | The associated command event. |
Definition at line 1038 of file MainFrame.cc.
void MainFrame::onMagicChange | ( | wxCommandEvent & | event | ) | [private] |
Callback when one of the magics is changed.
event | The associated command event. |
Definition at line 1085 of file MainFrame.cc.
void MainFrame::onMemberClassChange | ( | wxCommandEvent & | event | ) | [private] |
Callback when one of the member's classes is changed.
event | The associated command event. |
Definition at line 1141 of file MainFrame.cc.
void MainFrame::onMemberUpdate | ( | wxUpdateUIEvent & | event | ) | [private] |
Callback when the party member choices need updated.
event | The associated update UI event. |
Definition at line 1179 of file MainFrame.cc.
void MainFrame::onPhaseChange | ( | wxCommandEvent & | event | ) | [private] |
Callback when one of the moon phases is changed.
event | The associated command event. |
Definition at line 1190 of file MainFrame.cc.
void MainFrame::onRuneChange | ( | wxCommandEvent & | event | ) | [private] |
Callback when one of the runes is changed.
event | The associated command event. |
Definition at line 1209 of file MainFrame.cc.
void hack4u::MainFrame::onSaveCloseUpdate | ( | wxUpdateUIEvent & | event | ) | [inline, private] |
Callback when the save or close file menu items need updating.
event | The associated update UI event. |
Definition at line 442 of file MainFrame.hh.
void MainFrame::onSaveUpdate | ( | wxUpdateUIEvent & | event | ) | [private] |
Callback when the save as file menu item needs updating.
event | The associated update UI event. |
Definition at line 1231 of file MainFrame.cc.
void MainFrame::onShipChange | ( | wxCommandEvent & | event | ) | [private] |
Callback when one the pirate ships is changed.
event | The associated command event. |
Definition at line 1239 of file MainFrame.cc.
void MainFrame::onShipLocationChange | ( | wxCommandEvent & | event | ) | [private] |
Callback when the location of a pirate ship is changed.
event | The associated command event. |
Definition at line 1258 of file MainFrame.cc.
void MainFrame::onShipUpdate | ( | wxUpdateUIEvent & | event | ) | [private] |
Callback when a ship location item needs updating.
event | The associated update UI event. |
Definition at line 1308 of file MainFrame.cc.
void MainFrame::onStartLocationChange | ( | wxCommandEvent & | event | ) | [private] |
Callback when the start location is changed.
event | The associated command event. |
Definition at line 1335 of file MainFrame.cc.
void MainFrame::onStatChange | ( | wxCommandEvent & | event | ) | [private] |
Callback when one of the character stats is changed.
event | The associated command event. |
Definition at line 1346 of file MainFrame.cc.
void MainFrame::onStoneChange | ( | wxCommandEvent & | event | ) | [private] |
Callback when one of the stones is changed.
event | The associated command event. |
Definition at line 1377 of file MainFrame.cc.
void MainFrame::onToolHaveChange | ( | wxCommandEvent & | event | ) | [private] |
Callback when one of the have/have not tools is changed.
event | The associated command event. |
Definition at line 1399 of file MainFrame.cc.
void MainFrame::onToolQuantityChange | ( | wxScrollEvent & | event | ) | [private] |
Callback when one of the quantity tools is changed.
event | The associated scroll event. |
Definition at line 1431 of file MainFrame.cc.
void MainFrame::onVirtueChange | ( | wxScrollEvent & | event | ) | [private] |
Callback when one of the virtue values is changed.
event | The associated scroll event. |
Definition at line 1443 of file MainFrame.cc.
void MainFrame::onWhirlpoolChange | ( | wxCommandEvent & | event | ) | [private] |
Callback when the whirlpool's location is changed.
event | The associated command event. |
Definition at line 1465 of file MainFrame.cc.
void MainFrame::onWindowClosing | ( | wxCloseEvent & | event | ) | [private] |
Callback when the window is closing.
event | The associated close event. |
Definition at line 1487 of file MainFrame.cc.
friend class FileDropTarget [friend] |
Definition at line 48 of file MainFrame.hh.
wxCheckBox* hack4u::MainFrame::itemEquippedCheck[6] [private] |
Definition at line 51 of file MainFrame.hh.
wxChoice* hack4u::MainFrame::itemChoice[6] [private] |
Definition at line 52 of file MainFrame.hh.
wxChoice* hack4u::MainFrame::memberChoice[4] [private] |
Definition at line 53 of file MainFrame.hh.
wxString hack4u::MainFrame::sramFile [private] |
Definition at line 54 of file MainFrame.hh.
SaveSlot* hack4u::MainFrame::saveslot [private] |
Definition at line 55 of file MainFrame.hh.
SRAMFile* hack4u::MainFrame::sram [private] |
Definition at line 56 of file MainFrame.hh.
enum Location hack4u::MainFrame::location [private] |
Definition at line 57 of file MainFrame.hh.
int hack4u::MainFrame::gameMenu [private] |
Definition at line 58 of file MainFrame.hh.
int hack4u::MainFrame::locationMenu [private] |
Definition at line 58 of file MainFrame.hh.
bool hack4u::MainFrame::ignoreEvents [private] |
Definition at line 59 of file MainFrame.hh.
bool hack4u::MainFrame::open [private] |
Definition at line 60 of file MainFrame.hh.
const wxString MainFrame::CHARACTER_NAMES [static, private] |
Initial value:
{ wxT("Mage"), wxT("Bard"), wxT("Fighter"), wxT("Druid"), wxT("Tinker"), wxT("Paladin"), wxT("Ranger"), wxT("Shepherd") }
Definition at line 63 of file MainFrame.hh.
const wxString MainFrame::CITY_NAMES [static, private] |
Initial value:
{ wxT("Moonglow"), wxT("Britain"), wxT("Jhelom"), wxT("Yew"), wxT("Minoc"), wxT("Trinsic"), wxT("Skara Brae"), wxT("Magincia") }
Definition at line 66 of file MainFrame.hh.
const std::pair< int, int > MainFrame::BALLOON_LOCATIONS [static, private] |
Initial value:
{ std::pair<int, int>(131, 224), std::pair<int, int>(108, 84), std::pair<int, int>(218, 38), std::pair<int, int>(45, 57), std::pair<int, int>(22, 159), std::pair<int, int>(186, 104), std::pair<int, int>(130, 22), std::pair<int, int>(171, 188), std::pair<int, int>(106, 216), std::pair<int, int>(50, 26), std::pair<int, int>(244, 147), std::pair<int, int>(148, 96), std::pair<int, int>(59, 199), std::pair<int, int>(159, 136), std::pair<int, int>(92, 137) }
Definition at line 69 of file MainFrame.hh.
const std::pair< int, int > MainFrame::PIRATESHIP_LOCATIONS [static, private] |
Initial value:
{ std::pair<int, int>(134, 230), std::pair<int, int>(109, 84), std::pair<int, int>(222, 40), std::pair<int, int>(18, 57), std::pair<int, int>(19, 168), std::pair<int, int>(184, 108), std::pair<int, int>(127, 19), std::pair<int, int>(169, 190), std::pair<int, int>(108, 216), std::pair<int, int>(47, 26), std::pair<int, int>(242, 148), std::pair<int, int>(145, 96), std::pair<int, int>(59, 196), std::pair<int, int>(158, 134), std::pair<int, int>(92, 135) }
Definition at line 72 of file MainFrame.hh.
const int MainFrame::INN_INDEX [static, private] |
Initial value:
{ 1, 1, 1, 1, 1, 0, 1, 2, 3, 4, 5, 6, 1, 1, 7 }
Definition at line 75 of file MainFrame.hh.