Skip to content

feat(PlayerMethods): Add new player methods #281

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 8 commits into
base: master
Choose a base branch
from
47 changes: 47 additions & 0 deletions src/LuaEngine/LuaFunctions.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -584,6 +584,21 @@ ElunaRegister<Player> PlayerMethods[] =
{ "RemoveBonusTalent", &LuaPlayer::RemoveBonusTalent },
{ "GetHomebind", &LuaPlayer::GetHomebind },
{ "GetSpells", &LuaPlayer::GetSpells },
{ "GetAverageItemLevel", &LuaPlayer::GetAverageItemLevel },
{ "GetBarberShopCost", &LuaPlayer::GetBarberShopCost },
{ "GetSightRange", &LuaPlayer::GetSightRange },
{ "GetWeaponProficiency", &LuaPlayer::GetWeaponProficiency },
{ "GetArmorProficiency", &LuaPlayer::GetArmorProficiency },
{ "GetAmmoDPS", &LuaPlayer::GetAmmoDPS },
{ "GetShield", &LuaPlayer::GetShield },
{ "GetRunesState", &LuaPlayer::GetRunesState },
{ "GetViewpoint", &LuaPlayer::GetViewpoint },
{ "GetDodgeFromAgility", &LuaPlayer::GetDodgeFromAgility },
{ "GetMeleeCritFromAgility", &LuaPlayer::GetMeleeCritFromAgility },
{ "GetSpellCritFromIntellect", &LuaPlayer::GetSpellCritFromIntellect },
{ "GetInventoryItem", &LuaPlayer::GetInventoryItem },
{ "GetBankItem", &LuaPlayer::GetBankItem },
{ "GetCreationTime", &LuaPlayer::GetCreationTime },

// Boolean
{ "HasTankSpec", &LuaPlayer::HasTankSpec },
Expand Down Expand Up @@ -654,6 +669,23 @@ ElunaRegister<Player> PlayerMethods[] =
{ "CanFly", &LuaPlayer::CanFly },
{ "IsMoving", &LuaPlayer::IsMoving },
{ "IsFlying", &LuaPlayer::IsFlying },
{ "IsMaxLevel", &LuaPlayer::IsMaxLevel },
{ "IsDailyQuestDone", &LuaPlayer::IsDailyQuestDone },
{ "IsPvP", &LuaPlayer::IsPvP },
{ "IsFFAPvP", &LuaPlayer::IsFFAPvP },
{ "IsUsingLfg", &LuaPlayer::IsUsingLfg },
{ "InRandomLfgDungeon", &LuaPlayer::InRandomLfgDungeon },
{ "CanInteractWithQuestGiver", &LuaPlayer::CanInteractWithQuestGiver },
{ "CanSeeStartQuest", &LuaPlayer::CanSeeStartQuest },
{ "CanTakeQuest", &LuaPlayer::CanTakeQuest },
{ "CanAddQuest", &LuaPlayer::CanAddQuest },
{ "CalculateReputationGain", &LuaPlayer::CalculateReputationGain },
{ "HasTitleByIndex", &LuaPlayer::HasTitleByIndex },
{ "IsAtGroupRewardDistance", &LuaPlayer::IsAtGroupRewardDistance },
{ "IsAtLootRewardDistance", &LuaPlayer::IsAtLootRewardDistance },
{ "CanTeleport", &LuaPlayer::CanTeleport },
{ "IsSpectator", &LuaPlayer::IsSpectator },
// { "HasSpellMod", &LuaPlayer::HasSpellMod },

// Gossip
{ "GossipMenuAddItem", &LuaPlayer::GossipMenuAddItem },
Expand Down Expand Up @@ -755,6 +787,21 @@ ElunaRegister<Player> PlayerMethods[] =
{ "SendMovieStart", &LuaPlayer::SendMovieStart },
{ "UpdatePlayerSetting", &LuaPlayer::UpdatePlayerSetting },
{ "TeleportTo", &LuaPlayer::TeleportTo },
{ "SetPlayerFlag", &LuaPlayer::SetPlayerFlag },
{ "RemovePlayerFlag", &LuaPlayer::RemovePlayerFlag },
{ "DoRandomRoll", &LuaPlayer::DoRandomRoll },
{ "EnvironmentalDamage", &LuaPlayer::EnvironmentalDamage },
{ "InitTaxiNodesForLevel", &LuaPlayer::InitTaxiNodesForLevel },
{ "AbandonQuest", &LuaPlayer::AbandonQuest },
{ "AddWeaponProficiency", &LuaPlayer::AddWeaponProficiency },
{ "AddArmorProficiency", &LuaPlayer::AddArmorProficiency },
{ "SetAmmo", &LuaPlayer::SetAmmo },
{ "RemoveAmmo", &LuaPlayer::RemoveAmmo },
{ "SetCanTeleport", &LuaPlayer::SetCanTeleport },
{ "SetIsSpectator", &LuaPlayer::SetIsSpectator },
{ "SetViewpoint", &LuaPlayer::SetViewpoint },
{ "ToggleInstantFlight", &LuaPlayer::ToggleInstantFlight },
{ "SetCreationTime", &LuaPlayer::SetCreationTime },

{ NULL, NULL }
};
Expand Down
Loading