[Languages] Cleanup language constants, use repositories (#3838)

* [Languages] Cleanup languages constants

# Notes
- Cleanup formatting and logic where necessary.
- Cleaned up constants to use a namespace with `constexpr` instead.
- Changed `LoadCharacterLanguages` to use a repository instead.

* Lua GroupMessage uint8/language_id

* Lua More uint8/language_id
This commit is contained in:
Alex King
2024-01-06 23:17:10 -05:00
committed by GitHub
parent 43c4b13978
commit 122fe398b4
34 changed files with 393 additions and 393 deletions
+2 -3
View File
@@ -1,5 +1,4 @@
#include "../common/features.h"
#include "../common/languages.h"
#include "client.h"
#ifdef EMBPERL_XS_CLASSES
@@ -21,12 +20,12 @@ void Perl_QuestItem_SetScale(EQ::ItemInstance* self, float scale_multiplier) //
void Perl_QuestItem_ItemSay(EQ::ItemInstance* self, const char* text) // @categories Inventory and Items
{
quest_manager.GetInitiator()->ChannelMessageSend(self->GetItem()->Name, 0, ChatChannel_Say, LANG_COMMON_TONGUE, MAX_LANGUAGE_SKILL, text);
quest_manager.GetInitiator()->ChannelMessageSend(self->GetItem()->Name, 0, ChatChannel_Say, Language::CommonTongue, Language::MaxValue, text);
}
void Perl_QuestItem_ItemSay(EQ::ItemInstance* self, const char* text, uint8 language_id) // @categories Inventory and Items
{
quest_manager.GetInitiator()->ChannelMessageSend(self->GetItem()->Name, 0, ChatChannel_Say, language_id, MAX_LANGUAGE_SKILL, text);
quest_manager.GetInitiator()->ChannelMessageSend(self->GetItem()->Name, 0, ChatChannel_Say, language_id, Language::MaxValue, text);
}
bool Perl_QuestItem_IsType(EQ::ItemInstance* self, int type) // @categories Inventory and Items