feat(Core/Scripts): Optimize PlayerScripts by calling only overridden/implemented functions. (#18672)
* feat(Core/Scripts): Optimize PlayerScripts by calling only overridden/implemented functions. * Fix codestyle. * Fix typo * PLAYERHOOK_END is not a hook * Address code review feedback. Co-authored-by: Winfidonarleyan <dowlandtop@yandex.com> * Codestyle fixes * Fix typo Co-authored-by: PkllonG --------- Co-authored-by: Winfidonarleyan <dowlandtop@yandex.com>
This commit is contained in:
parent
fd029f81aa
commit
f792b0d708
11 changed files with 452 additions and 1054 deletions
|
|
@ -25,7 +25,17 @@
|
|||
class ChatLogScript : public PlayerScript
|
||||
{
|
||||
public:
|
||||
ChatLogScript() : PlayerScript("ChatLogScript") { }
|
||||
ChatLogScript() :
|
||||
PlayerScript("ChatLogScript",
|
||||
{
|
||||
PLAYERHOOK_ON_CHAT,
|
||||
PLAYERHOOK_ON_CHAT_WITH_GROUP,
|
||||
PLAYERHOOK_ON_CHAT_WITH_GUILD,
|
||||
PLAYERHOOK_ON_CHAT_WITH_CHANNEL,
|
||||
PLAYERHOOK_ON_CHAT_WITH_RECEIVER
|
||||
})
|
||||
{
|
||||
}
|
||||
|
||||
void OnChat(Player* player, uint32 type, uint32 lang, std::string& msg) override
|
||||
{
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue