|
Project SkyFire Core
SkyFire 5.4.8 server core API documentation
|
#include "Define.h"#include "Dynamic/UnorderedMap.h"#include <stdio.h>#include <stdlib.h>#include <string.h>#include <time.h>#include <math.h>#include <errno.h>#include <signal.h>#include <assert.h>#include <set>#include <list>#include <string>#include <map>#include <queue>#include <sstream>#include <algorithm>#include "Threading/LockedQueue.h"#include "Threading/Threading.h"#include <sys/types.h>#include <sys/ioctl.h>#include <sys/socket.h>#include <netinet/in.h>#include <unistd.h>#include <netdb.h>#include <float.h>Go to the source code of this file.
Classes | |
| struct | LocalizedString |
Macros | |
| #define | atoll _atoi64 |
| #define | DEFAULT_LOCALE LOCALE_enUS |
| #define | finite(X) |
| #define | I32FMT "%08I32X" |
| #define | I64FMT "%016I64X" |
| #define | llabs _abs64 |
| #define | M_PI 3.14159265358979323846f |
| #define | MAX_ACCOUNT_TUTORIAL_VALUES 8 |
| #define | MAX_LOCALES 11 |
| #define | MAX_QUERY_LEN 32*1024 |
| #define | STRCASECMP strcasecmp |
| #define | STRINGIZE(a) |
| #define | vsnprintf _vsnprintf |
Typedefs | |
| typedef std::vector< std::string > | StringVector |
Enumerations | |
| enum class | AccountTypes { SEC_PLAYER = 0 , SEC_MODERATOR = 1 , SEC_GAMEMASTER = 2 , SEC_ADMINISTRATOR = 3 , SEC_CONSOLE = 4 } |
| enum | LocaleConstant { LOCALE_enUS = 0 , LOCALE_koKR = 1 , LOCALE_frFR = 2 , LOCALE_deDE = 3 , LOCALE_zhCN = 4 , LOCALE_zhTW = 5 , LOCALE_esES = 6 , LOCALE_esMX = 7 , LOCALE_ruRU = 8 , LOCALE_itIT = 9 , LOCALE_ptBR = 10 , LOCALE_ptPT = 11 } |
| enum | TimeConstants { MINUTE = 60 , HOUR = MINUTE * 60 , DAY = HOUR * 24 , WEEK = DAY * 7 , MONTH = DAY * 30 , YEAR = MONTH * 12 , IN_MILLISECONDS = 1000 } |
Functions | |
| float | finiteAlways (float f) |
| LocaleConstant | GetLocaleByName (const std::string &name) |
Variables | |
| char const * | localeNames [TOTAL_LOCALES] |
| const uint8 | TOTAL_LOCALES = 12 |
| #define DEFAULT_LOCALE LOCALE_enUS |
Definition at line 154 of file Common.h.
Referenced by Guild::BroadcastAddonToGuild(), LuaGlobalFunctions::GetItemLink(), LuaItem::GetItemLink(), CreatureTextMgr::GetLocalizedChatString(), Creature::GetNameForLocaleIdx(), GameObject::GetNameForLocaleIdx(), ObjectMgr::GetSkyFireString(), WorldSession::HandleAddonMessagechatOpcode(), Guild::Validate(), and Player::WhisperAddon().
| #define finite | ( | X | ) |
Definition at line 101 of file Common.h.
Referenced by finiteAlways(), Skyfire::IsValidMapCoord(), Skyfire::IsValidMapCoord(), and Skyfire::IsValidMapCoord().
| #define llabs _abs64 |
Definition at line 102 of file Common.h.
Referenced by WorldSocket::HandleAuthSession().
| #define M_PI 3.14159265358979323846f |
Definition at line 192 of file Common.h.
Referenced by FleeingMovementGenerator< T >::_getPoint(), RandomMovementGenerator< T >::_setRandomLocation(), SpellImplicitTargetInfo::CalcDirectionAngle(), WorldObject::CanDetectStealthOf(), ObjectPosSelector::CheckAngle(), Spell::CheckCast(), spell_warr_retaliation::spell_warr_retaliation_AuraScript::CheckProc(), Spell::CheckRange(), boss_viscidus::boss_viscidusAI::DamageTaken(), Unit::DealMeleeDamage(), npc_announcer_toc5::npc_announcer_toc5AI::DoSummonGrandChampion(), boss_malygos::boss_malygosAI::FillCirclePath(), npc_caster_hover_disk::npc_caster_hover_diskAI::FillCirclePath(), npc_ominous_cloud::npc_ominous_cloudAI::FillCirclePath(), Position::GetAngle(), Unit::GetFollowAngle(), Unit::GetRandomContactPoint(), WorldObject::GetRandomNearPosition(), WorldObject::GetRandomPoint(), GetRandPosFromCenterInDist(), LuaGameObject::GetRelativePoint(), Position::GetSinCos(), spell_monk_chi_torpedo::spell_monk_chi_torpedo_SpellScript::HandleAfterCast(), WorldSession::HandleAreaTriggerOpcode(), spell_item_unusual_compass::spell_item_unusual_compass_SpellScript::HandleDummy(), spell_ulduar_squeezed_lifeless::spell_ulduar_squeezed_lifeless_SpellScript::HandleInstaKill(), npc_commandscript::HandleNpcAddFormationCommand(), npc_commandscript::HandleNpcTameCommand(), Position::HasInArc(), Position::HasInLine(), molten_flame::molten_flameAI::InitializeAI(), WorldObject::isInBack(), Unit::isInBackInMap(), Unit::isSpellBlocked(), npc_meteor_strike_initial::npc_meteor_strike_initialAI::IsSummonedBy(), Unit::JumpTo(), npc_transient::npc_transientAI::JustDied(), boss_sara::boss_saraAI::JustSummoned(), spell_alysrazor_turn_monstrosity::spell_alysrazor_turn_monstrosity_SpellScript::KnockBarrage(), CreatureGroup::LeaderMoveTo(), FormationMgr::LoadCreatureFormations(), Unit::MagicSpellHitResult(), Unit::MeleeSpellHitResult(), spell_q12308_escape_from_silverbrook_summon_worgen::spell_q12308_escape_from_silverbrook_summon_worgen_SpellScript::ModDest(), boss_leotheras_the_blind::boss_leotheras_the_blindAI::MoveInLineOfSight(), MotionMaster::MoveKnockbackFrom(), boss_sindragosa::boss_sindragosaAI::MovementInform(), ObjectPosSelector::NextSmallStepAngle(), Position::NormalizeOrientation(), AreaTrigger_at_darkspear_isle::OnTrigger(), LunaticGazeTargetSelector::operator()(), SmartScript::ProcessAction(), SmartScript::ProcessEvent(), Player::ReadMovementInfo(), npc_lake_frog::npc_lake_frogAI::ReceiveEmote(), Position::RelocateOffset(), npc_firework::npc_fireworkAI::Reset(), Unit::RollMeleeOutcomeAgainst(), Spell::SearchChainTargets(), Spell::SelectImplicitCasterDestTargets(), Spell::SelectImplicitConeTargets(), spell_omega_stance_spider_effect::spell_omega_stance_spider_effect_SpellScript::SetDestPosition(), boss_malchezaar::boss_malchezaarAI::SummonInfernal(), go_wind_stone::SummonNPC(), boss_warp_splinter::boss_warp_splinterAI::SummonTreants(), Player::Update(), RotateMovementGenerator::Update(), boss_ancient_stone_keeper::boss_ancient_stone_keeperAI::UpdateAI(), boss_devourer_of_souls::boss_devourer_of_soulsAI::UpdateAI(), boss_eye_of_cthun::eye_of_cthunAI::UpdateAI(), boss_nightbane::boss_nightbaneAI::UpdateAI(), boss_romulo::boss_romuloAI::UpdateAI(), boss_the_lurker_below::boss_the_lurker_belowAI::UpdateAI(), npc_master_shang_xi_wood_of_staves::npc_master_shang_xi_wood_of_stavesAI::UpdateAI(), npc_shield_orb::npc_shield_orbAI::UpdateAI(), npc_shu_pool_of_reflection::npc_shu_pool_of_reflectionAI::UpdateAI(), PetAI::UpdateAI(), and GameObject::Use().
| #define MAX_ACCOUNT_TUTORIAL_VALUES 8 |
Definition at line 157 of file Common.h.
Referenced by WorldSession::HandleTutorialClear(), WorldSession::HandleTutorialFlag(), WorldSession::HandleTutorialReset(), WorldSession::LoadTutorialsData(), WorldSession::SaveTutorialsData(), and WorldSession::SendTutorialsData().
| #define MAX_LOCALES 11 |
Definition at line 156 of file Common.h.
Referenced by LuaGlobalFunctions::GetItemLink(), LuaItem::GetItemLink(), CreatureTextMgr::GetLocalizedChatString(), and ObjectMgr::LoadNpcTextLocales().
| #define MAX_QUERY_LEN 32*1024 |
Definition at line 195 of file Common.h.
Referenced by DatabaseWorkerPool< CharacterDatabaseConnection >::AsyncPQuery(), DatabaseWorkerPool< CharacterDatabaseConnection >::DirectPExecute(), PlayerDumpWriter::GenerateWhereStr(), Log::outCommand(), Transaction::PAppend(), DatabaseWorkerPool< CharacterDatabaseConnection >::PExecute(), DatabaseWorkerPool< CharacterDatabaseConnection >::PQuery(), DatabaseWorkerPool< CharacterDatabaseConnection >::PQuery(), SQLQueryHolder::SetPQuery(), Log::vlog(), and Appender::write().
| #define STRCASECMP strcasecmp |
| #define vsnprintf _vsnprintf |
Definition at line 100 of file Common.h.
Referenced by DatabaseWorkerPool< CharacterDatabaseConnection >::AsyncPQuery(), DatabaseWorkerPool< CharacterDatabaseConnection >::DirectPExecute(), InstanceScript::DoSendNotifyToInstance(), Skyfire::BattlegroundChatBuilder::operator()(), Skyfire::WorldWorldTextBuilder::operator()(), Log::outCommand(), Transaction::PAppend(), DatabaseWorkerPool< CharacterDatabaseConnection >::PExecute(), ChatHandler::PGetParseString(), DatabaseWorkerPool< CharacterDatabaseConnection >::PQuery(), DatabaseWorkerPool< CharacterDatabaseConnection >::PQuery(), ChatHandler::PSendSysMessage(), ChatHandler::PSendSysMessage(), World::RecordTimeDiff(), WorldSession::SendNotification(), WorldSession::SendNotification(), Battleground::SendWarningToAll(), SQLQueryHolder::SetPQuery(), Log::vlog(), and vutf8printf().
| typedef std::vector<std::string> StringVector |
|
strong |
| enum LocaleConstant |
| enum TimeConstants |
|
inline |
| LocaleConstant GetLocaleByName | ( | const std::string & | name | ) |
Definition at line 23 of file Common.cpp.
References LOCALE_enUS, localeNames, and TOTAL_LOCALES.
Referenced by AuthSocket::_HandleLogonChallenge(), AuthSocket::_HandleLogonProof(), and ObjectMgr::LoadGossipMenuItemsLocales().
|
extern |
Definition at line 8 of file Common.cpp.
Referenced by GetLocaleByName(), character_commandscript::HandleCharacterReputationCommand(), character_commandscript::HandleCharacterTitlesCommand(), lookup_commandscript::HandleLookupSpellIdCommand(), World::LoadConfigSettings(), LoadDB2(), and LoadDBC().
| const uint8 TOTAL_LOCALES = 12 |
Definition at line 153 of file Common.h.
Referenced by DB2FileLoader::AutoProduceStringsArrayHolders(), CreatureTextLocalizer< Builder >::CreatureTextLocalizer(), GetLocaleByName(), WorldSocket::HandleAuthSession(), lookup_commandscript::HandleLookupMapCommand(), World::LoadConfigSettings(), ObjectMgr::LoadCreatureLocales(), CreatureTextMgr::LoadCreatureTextLocales(), LoadDB2(), LoadDBC(), ObjectMgr::LoadGameObjectLocales(), ObjectMgr::LoadItemLocales(), ObjectMgr::LoadNpcTextLocales(), ObjectMgr::LoadPageTextLocales(), ObjectMgr::LoadPointOfInterestLocales(), ObjectMgr::LoadQuestLocales(), ObjectMgr::LoadQuestObjectiveLocales(), AchievementGlobalMgr::LoadRewardLocales(), ObjectMgr::LoadSkyFireStrings(), and ItemChatLink::ValidateName().