Vegastrike 0.5.1 rc1
1.0
Original sources for Vegastrike Evolved
|
#include <base.h>
Classes | |
class | Room |
Public Member Functions | |
void | Terminate () |
void | GotoLink (int linknum) |
void | InitCallbacks () |
void | CallCommonLinks (const std::string &name, const std::string &value) |
void | Load (const char *filename, const char *time_of_day, const char *faction) |
void | Click (int x, int y, int button, int state) |
void | Key (unsigned int ch, unsigned int mod, bool release, int x, int y) |
void | MouseOver (int x, int y) |
BaseInterface (const char *basefile, Unit *base, Unit *un) | |
~BaseInterface () | |
void | Draw () |
void | setDJEnabled (bool enabled) |
bool | isDJEnabled () const |
Static Public Member Functions | |
static void | ClickWin (int x, int y, int button, int state) |
static void | PassiveMouseOverWin (int x, int y) |
static void | ActiveMouseOverWin (int x, int y) |
static void | ProcessKeyboardBuffer () |
Public Attributes | |
int | curroom |
std::vector< Room * > | rooms |
TextPlane | othtext |
bool | CallComp |
UnitContainer | caller |
UnitContainer | baseun |
std::string | python_kbhandler |
Static Public Attributes | |
static BaseInterface * | CurrentBase = NULL |
Friends | |
class | Room |
class | Room::BaseTalk |
Definition at line 1084 of file base_interface.cpp.
References AUDHighestSoundPlaying(), BASE_EXTENSION, baseun, CallComp, caller, BaseUtil::Comp(), compute_time_of_day(), createdbase, createdmusic, CurrentBase, curroom, ExecuteDirector(), Unit::faction, TextPlane::GetCharSize(), FactionUtil::GetFaction(), UniverseUtil::GetGalaxyFaction(), UnitUtil::getUnitSystemFile(), GotoLink(), i, UnitUtil::isPlayerStarship(), BaseUtil::Launch(), Load(), mission_key, Unit::name, othtext, QVector, Room, rooms, saveStringList(), TextPlane::SetCharSize(), TextPlane::SetSize(), VSFileSystem::vs_fprintf(), x, and y.
BaseInterface::~BaseInterface | ( | ) |
Definition at line 952 of file base_interface.cpp.
References BASE_EXTENSION, CurrentBase, i, restore_main_loop(), rooms, VSFileSystem::vs_close(), and VSFileSystem::vs_open().
Definition at line 892 of file base_interface.cpp.
References CallComp, CurrentBase, ModifyMouseSensitivity(), NavigationSystem::mouseDrag(), MouseOver(), and SetSoftwareMousePosition().
Referenced by InitCallbacks(), and GameCockpit::NavScreen().
void BaseInterface::CallCommonLinks | ( | const std::string & | name, |
const std::string & | value | ||
) |
Definition at line 841 of file base_interface.cpp.
References CalculateRealXAndY(), curroom, rooms, x, and y.
Referenced by ClickWin().
Definition at line 848 of file base_interface.cpp.
References CallComp, Click(), CurrentBase, getMouseButtonMask(), ModifyMouseSensitivity(), NavigationSystem::mouseClick(), WS_MOUSE_DOWN, and WS_MOUSE_UP.
Referenced by InitCallbacks(), and GameCockpit::NavScreen().
void BaseInterface::Draw | ( | ) |
Definition at line 1429 of file base_interface.cpp.
References GFXColor::a, MessageCenter::add(), AnimationDraw(), baseun, TextPlane::bgcol, caller, curroom, UnitImages< BOGUS >::dockedunits, TextPlane::Draw(), EndGUIFrame(), Unit::FreeDockingPort(), g_game, GetElapsedTime(), Singleton< SceneManager >::getSingleton(), TextPlane::GetText(), UnitContainer::GetUnit(), VegaConfig::getVariable(), GFXTRUE, BaseInterface::Room::BaseTalk::hastalked, i, mission, Mission::msgcenter, othtext, XMLSupport::parse_float(), Unit::pImage, rooms, TextPlane::SetPos(), SetupViewport(), game_data_t::sound_enabled, StartGUIFrame(), Terminate(), AnimatedTexture::UpdateAllFrame(), vs_config, VSFileSystem::vs_fprintf(), x, game_data_t::x_resolution, y, and game_data_t::y_resolution.
Referenced by RefreshGUI().
void BaseInterface::GotoLink | ( | int | linknum) |
Definition at line 928 of file base_interface.cpp.
References curroom, BaseInterface::Room::deftext, MOUSE_POINTER_NORMAL, othtext, BaseInterface::Room::Room(), rooms, TextPlane::SetText(), and VSFileSystem::vs_fprintf().
Referenced by BaseInterface(), BaseInterface::Room::Goto::Click(), and BaseUtil::SetCurRoom().
void BaseInterface::InitCallbacks | ( | ) |
Definition at line 993 of file base_interface.cpp.
References _Universe, ActiveMouseOverWin(), base_keyboard_cb(), base_main_loop(), CallComp, ClickWin(), CurrentBase, VegaConfig::getVariable(), GFXLoop(), Universe::numPlayers(), XMLSupport::parse_bool(), PassiveMouseOverWin(), vs_config, winsys_set_keyboard_func(), winsys_set_motion_func(), winsys_set_mouse_func(), and winsys_set_passive_motion_func().
Referenced by InitCallbacks(), and BaseUtil::LoadBaseInterfaceAtDock().
|
inline |
Definition at line 912 of file base_interface.cpp.
References python_kbhandler, RunPython(), and BaseUtil::SetKeyEventData().
Referenced by base_keyboard_cb(), and ProcessKeyboardBuffer().
void BaseInterface::Load | ( | const char * | filename, |
const char * | time_of_day, | ||
const char * | faction | ||
) |
Definition at line 34 of file base_xml.cpp.
References BASE_EXTENSION, baseun, getFullFile(), Unit::isUnit(), PLANETPTR, VSFileSystem::vs_close(), and VSFileSystem::vs_open().
Referenced by BaseInterface().
Definition at line 791 of file base_interface.cpp.
References CalculateRealXAndY(), curroom, BaseInterface::Room::deftext, getMouseButtonMask(), VegaConfig::getVariable(), i, BaseInterface::Room::links, MOUSE_POINTER_HOVER, MOUSE_POINTER_NORMAL, BaseInterface::Room::Link::MouseEnter(), BaseInterface::Room::Link::MouseLeave(), BaseInterface::Room::Link::MouseMove(), XMLSupport::parse_bool(), XMLSupport::parse_float(), BaseInterface::Room::Link::pythonfile, rooms, UniverseUtil::sqrt(), BaseInterface::Room::Link::text, vs_config, x, and y.
Referenced by ActiveMouseOverWin(), and PassiveMouseOverWin().
Definition at line 872 of file base_interface.cpp.
References CallComp, CurrentBase, ModifyMouseSensitivity(), NavigationSystem::mouseMotion(), MouseOver(), and SetSoftwareMousePosition().
Referenced by BaseInterface::Room::Click(), InitCallbacks(), and GameCockpit::NavScreen().
|
static |
Definition at line 1493 of file base_interface.cpp.
References base_keyboard_queue, CallComp, CurrentBase, and Key().
Referenced by base_keyboard_cb().
void BaseInterface::setDJEnabled | ( | bool | enabled) |
Definition at line 1507 of file base_interface.cpp.
Referenced by BaseUtil::SetDJEnabled().
void BaseInterface::Terminate | ( | ) |
Definition at line 1185 of file base_interface.cpp.
References caller, CurrentBase, UnitContainer::GetUnit(), UnitUtil::isPlayerStarship(), mission_key, restore_main_loop(), and saveStringList().
Referenced by BaseInterface::Room::Launch::Click(), BaseInterface::Room::Eject::Click(), Draw(), BaseUtil::LoadBaseInterfaceAtDock(), and TerminateCurrentBase().
|
friend |
Definition at line 320 of file base.h.
Referenced by BaseInterface().
|
friend |
UnitContainer BaseInterface::baseun |
Definition at line 328 of file base.h.
Referenced by BaseInterface(), BaseUtil::BuyShip(), BaseInterface::Room::Comp::Click(), BaseInterface::Room::Launch::Click(), BaseInterface::Room::Eject::Click(), Draw(), Load(), and BaseUtil::SellShip().
bool BaseInterface::CallComp |
Definition at line 326 of file base.h.
Referenced by ActiveMouseOverWin(), base_keyboard_cb(), BaseInterface(), BaseInterface::Room::Comp::Click(), ClickWin(), InitCallbacks(), PassiveMouseOverWin(), ProcessKeyboardBuffer(), and RefreshGUI().
UnitContainer BaseInterface::caller |
Definition at line 327 of file base.h.
Referenced by BaseInterface(), BaseUtil::BuyShip(), BaseInterface::Room::Comp::Click(), BaseInterface::Room::Launch::Click(), BaseInterface::Room::Eject::Click(), CurrentBaseUnitSet(), BaseInterface::Room::BaseShip::Draw(), Draw(), RefreshGUI(), BaseUtil::SellShip(), and Terminate().
|
static |
Definition at line 325 of file base.h.
Referenced by ActiveMouseOverWin(), base_keyboard_cb(), BaseInterface(), BaseUtil::BuyShip(), BaseUtil::CheckRoom(), ClickWin(), CurrentBaseUnitSet(), BaseUtil::EnqueueMessage(), BaseUtil::EnqueueMessageToRoom(), GameUnit< UnitType >::Explode(), BaseUtil::GetCurRoom(), BaseUtil::GetNumRoom(), BaseUtil::GlobalKeyPython(), InitCallbacks(), InitCallbacks(), isInside(), BaseUtil::LoadBaseInterfaceAtDock(), BaseUtil::Message(), BaseUtil::MessageToRoom(), Music::MuzakCycle(), BaseUtil::VideoAudioStreamListener::onEndOfStream(), PassiveMouseOverWin(), ProcessKeyboardBuffer(), RefreshGUI(), BaseUtil::Room(), BaseUtil::SellShip(), BaseUtil::SetCurRoom(), BaseUtil::SetDJEnabled(), Terminate(), TerminateCurrentBase(), and ~BaseInterface().
int BaseInterface::curroom |
Definition at line 322 of file base.h.
Referenced by BaseInterface(), BaseInterface::Room::Talk::Click(), Click(), BaseInterface::Room::BaseTalk::Draw(), Draw(), BaseUtil::GetCurRoom(), GotoLink(), and MouseOver().
TextPlane BaseInterface::othtext |
Definition at line 324 of file base.h.
Referenced by BaseInterface(), BaseInterface::Room::Talk::Click(), BaseInterface::Room::BaseTalk::Draw(), Draw(), and GotoLink().
std::string BaseInterface::python_kbhandler |
Definition at line 330 of file base.h.
Referenced by BaseUtil::GlobalKeyPython(), and Key().
std::vector< Room* > BaseInterface::rooms |
Definition at line 323 of file base.h.
Referenced by BaseInterface(), BaseUtil::CheckRoom(), BaseInterface::Room::Talk::Click(), Click(), BaseInterface::Room::BaseTalk::Draw(), Draw(), BaseUtil::EnqueueMessageToRoom(), BaseUtil::GetNumRoom(), GotoLink(), BaseUtil::MessageToRoom(), MouseOver(), BaseUtil::Room(), and ~BaseInterface().