[DiscordArchive] I changed it and it still works, it's much cleaner that way thanks for the hook!
[DiscordArchive] I changed it and it still works, it's much cleaner that way thanks for the hook!
Archived author: William Von Kha • Posted: 2023-01-07T16:29:47.303000+00:00
Original source
I changed it and it still works, it's much cleaner that way thanks for the hook!
Now I have no problem with characterHandler, but my VoiceChatHandler file still has a problem with the enum (probably because I include the commons.h library in it)
Error:
```Error C2011 'LogLevel': 'unsigned enum' type redefinition (compiling source file C:\Trinity\server\scripts\VoiceChatChatHandler.cpp) scripts C:\Trinity\server\scripts\VoiceChat\teamspeak\teamloglogtypes.h 14```
When i compile i have this error:
```
23>C:\Trinity\src\server\scripts\VoiceChat\teamspeak\teamlog/logtypes.h(14,15): error C2011: 'LogLevel': 'unsigned enum' type redefinition (compiling source file C:\Trinity\src\server\scripts\VoiceChat\VoiceChatHandler.cpp)
23>C:\Trinity\src\common\Logging\LogCommon.h(24,6): message : see declaration of 'LogLevel' (compiling source file C:\Trinity\src\server\scripts\VoiceChat\VoiceChatHandler.cpp)
```
include in VoiceChatHandler.h :
```
#include <unordered_map>
#include <set>
#include <vector>
#include "Log.h"
#include "ScriptMgr.h"
#include "Common.h"
```
in VoiceChatHandler.cpp :
```
#include "VoiceChatHandler.h"
#include "Chat.h"
#include "Player.h"
#include "WorldSession.h"
#include "ScriptMgr.h"
#include "TeamSpeak/clientlib.h"
#include "TeamSpeak/public_errors.h"
```
Do you know if there is a way to get around the problem ?