From 6bf4676bc1a9fd73c96b3c2f580d7848c99c2af3 Mon Sep 17 00:00:00 2001 From: rogo Date: Sat, 5 Aug 2023 22:01:47 +0200 Subject: [PATCH] updated sdk and fixed build errors --- .clang-format | 42 + .qmake.stash | 22 + .travis.yml | 2 + Makefile | 16 + Makefile.Debug | 593 ++++ Makefile.Release | 593 ++++ README.md | 18 +- include/plugin_definitions.h | 67 +- include/teamlog/logtypes.h | 26 +- include/teamspeak/clientlib.h | 2411 +++++++++++++++++ include/teamspeak/public_definitions.h | 756 ++++-- include/teamspeak/public_errors.h | 356 +-- include/teamspeak/public_errors_rare.h | 165 +- include/teamspeak/public_rare_definitions.h | 559 ++-- .../teamspeak/server_commands_file_transfer.h | 149 + include/teamspeak/serverlib.h | 1291 +++++++++ .../teamspeak/serverlib_publicdefinitions.h | 4 + include/ts3_functions.h | 507 ++-- src/icons/1.png | Bin 0 -> 234 bytes src/icons/2.png | Bin 0 -> 297 bytes src/icons/3.png | Bin 0 -> 303 bytes src/icons/t.png | Bin 0 -> 241 bytes src/ledhandler.cpp | 42 +- src/ledhandler.h | 51 +- src/plugin.cpp | 69 +- src/plugin.h | 86 +- 26 files changed, 6659 insertions(+), 1166 deletions(-) create mode 100644 .clang-format create mode 100644 .qmake.stash create mode 100644 .travis.yml create mode 100644 Makefile create mode 100644 Makefile.Debug create mode 100644 Makefile.Release create mode 100644 include/teamspeak/clientlib.h create mode 100644 include/teamspeak/server_commands_file_transfer.h create mode 100644 include/teamspeak/serverlib.h create mode 100644 include/teamspeak/serverlib_publicdefinitions.h create mode 100644 src/icons/1.png create mode 100644 src/icons/2.png create mode 100644 src/icons/3.png create mode 100644 src/icons/t.png diff --git a/.clang-format b/.clang-format new file mode 100644 index 0000000..786a94d --- /dev/null +++ b/.clang-format @@ -0,0 +1,42 @@ +--- +Language: Cpp +AlignAfterOpenBracket: Align +AlignConsecutiveAssignments: 'true' +AlignConsecutiveDeclarations: 'true' +AlignEscapedNewlinesLeft: 'false' +AlignOperands: 'true' +AlignTrailingComments: 'true' +AllowAllParametersOfDeclarationOnNextLine: 'false' +AllowShortBlocksOnASingleLine: 'true' +AllowShortCaseLabelsOnASingleLine: 'false' +AllowShortFunctionsOnASingleLine: Empty +AllowShortIfStatementsOnASingleLine: 'false' +AllowShortLoopsOnASingleLine: 'false' +BinPackArguments: 'true' +BinPackParameters: 'true' +BreakBeforeBinaryOperators: NonAssignment +BreakBeforeBraces: Linux +BreakBeforeTernaryOperators: 'true' +BreakConstructorInitializersBeforeComma: 'true' +Cpp11BracedListStyle: 'true' +DerivePointerAlignment: 'true' +ExperimentalAutoDetectBinPacking: 'false' +IndentCaseLabels: 'true' +IndentWidth: '4' +ColumnLimit: 256 +ReflowComments: 'false' +NamespaceIndentation: Inner +PointerAlignment: Left +SortIncludes: 'true' +SpaceAfterCStyleCast: 'false' +SpaceBeforeAssignmentOperators: 'true' +SpaceBeforeParens: ControlStatements +SpaceInEmptyParentheses: 'false' +SpacesInAngles: 'false' +SpacesInCStyleCastParentheses: 'false' +SpacesInContainerLiterals: 'false' +SpacesInParentheses: 'false' +SpacesInSquareBrackets: 'false' +Standard: Cpp11 +TabWidth: '4' +UseTab: Never diff --git a/.qmake.stash b/.qmake.stash new file mode 100644 index 0000000..3127c90 --- /dev/null +++ b/.qmake.stash @@ -0,0 +1,22 @@ +QMAKE_CXX.QT_COMPILER_STDCXX = 199711L +QMAKE_CXX.QMAKE_MSC_VER = 1929 +QMAKE_CXX.QMAKE_MSC_FULL_VER = 192930148 +QMAKE_CXX.COMPILER_MACROS = \ + QT_COMPILER_STDCXX \ + QMAKE_MSC_VER \ + QMAKE_MSC_FULL_VER +QMAKE_CXX.INCDIRS = \ + "C:\\Program Files (x86)\\Microsoft Visual Studio\\2019\\Community\\VC\\Tools\\MSVC\\14.29.30133\\ATLMFC\\include" \ + "C:\\Program Files (x86)\\Microsoft Visual Studio\\2019\\Community\\VC\\Tools\\MSVC\\14.29.30133\\include" \ + "C:\\Program Files (x86)\\Windows Kits\\NETFXSDK\\4.8\\include\\um" \ + "C:\\Program Files (x86)\\Windows Kits\\10\\include\\10.0.16299.0\\ucrt" \ + "C:\\Program Files (x86)\\Windows Kits\\10\\include\\10.0.16299.0\\shared" \ + "C:\\Program Files (x86)\\Windows Kits\\10\\include\\10.0.16299.0\\um" \ + "C:\\Program Files (x86)\\Windows Kits\\10\\include\\10.0.16299.0\\winrt" \ + "C:\\Program Files (x86)\\Windows Kits\\10\\include\\10.0.16299.0\\cppwinrt" +QMAKE_CXX.LIBDIRS = \ + "C:\\Program Files (x86)\\Microsoft Visual Studio\\2019\\Community\\VC\\Tools\\MSVC\\14.29.30133\\ATLMFC\\lib\\x64" \ + "C:\\Program Files (x86)\\Microsoft Visual Studio\\2019\\Community\\VC\\Tools\\MSVC\\14.29.30133\\lib\\x64" \ + "C:\\Program Files (x86)\\Windows Kits\\NETFXSDK\\4.8\\lib\\um\\x64" \ + "C:\\Program Files (x86)\\Windows Kits\\10\\lib\\10.0.16299.0\\ucrt\\x64" \ + "C:\\Program Files (x86)\\Windows Kits\\10\\lib\\10.0.16299.0\\um\\x64" diff --git a/.travis.yml b/.travis.yml new file mode 100644 index 0000000..3393b24 --- /dev/null +++ b/.travis.yml @@ -0,0 +1,2 @@ +language: C +script: make diff --git a/Makefile b/Makefile new file mode 100644 index 0000000..9a129ce --- /dev/null +++ b/Makefile @@ -0,0 +1,16 @@ +# +# Makefile to build TeamSpeak 3 Client Test Plugin +# + +CFLAGS = -c -O2 -Wall -fPIC + +all: test_plugin + +test_plugin: plugin.o + gcc -o test_plugin.so -shared plugin.o + +plugin.o: ./src/plugin.c + gcc -Iinclude src/plugin.c $(CFLAGS) + +clean: + rm -rf *.o test_plugin.so diff --git a/Makefile.Debug b/Makefile.Debug new file mode 100644 index 0000000..98bfdae --- /dev/null +++ b/Makefile.Debug @@ -0,0 +1,593 @@ +############################################################################# +# Makefile for building: TS_WIFILED +# Generated by qmake (3.1) (Qt 6.5.1) +# Project: TS_WIFILED.pro +# Template: lib +############################################################################# + +MAKEFILE = Makefile.Debug + +EQ = = + +####### Compiler, tools and options + +CC = cl +CXX = cl +DEFINES = -DUNICODE -D_UNICODE -DWIN32 -D_ENABLE_EXTENDED_ALIGNED_STORAGE -DWIN64 -DQT_GUI_LIB -DQT_NETWORK_LIB -DQT_CORE_LIB -D_WINDLL +CFLAGS = -nologo -Zc:wchar_t -FS -Zc:strictStrings -Zi -MDd -utf-8 -W3 -w44456 -w44457 -w44458 /Fddebug\TS_WIFILED.vc.pdb $(DEFINES) +CXXFLAGS = -nologo -Zc:wchar_t -FS -Zc:rvalueCast -Zc:inline -Zc:strictStrings -Zc:throwingNew -permissive- -Zc:__cplusplus -Zc:externConstexpr -Zi -MDd -std:c++17 -utf-8 -W3 -w34100 -w34189 -w44996 -w44456 -w44457 -w44458 -wd4577 -wd4467 -EHsc /Fddebug\TS_WIFILED.vc.pdb $(DEFINES) +INCPATH = -I. -Iinclude -Iinclude\teamlog -Iinclude\teamspeak -Isrc -IC:\Qt\6.5.1\msvc2019_64\include -IC:\Qt\6.5.1\msvc2019_64\include\QtGui -IC:\Qt\6.5.1\msvc2019_64\include\QtNetwork -IC:\Qt\6.5.1\msvc2019_64\include\QtCore -Idebug -I/include -IC:\Qt\6.5.1\msvc2019_64\mkspecs\win32-msvc +LINKER = link +LFLAGS = /NOLOGO /DYNAMICBASE /NXCOMPAT /DEBUG /DLL /SUBSYSTEM:WINDOWS +LIBS = C:\Qt\6.5.1\msvc2019_64\lib\Qt6Guid.lib C:\Qt\6.5.1\msvc2019_64\lib\Qt6Networkd.lib C:\Qt\6.5.1\msvc2019_64\lib\Qt6Cored.lib +QMAKE = C:\Qt\6.5.1\msvc2019_64\bin\qmake.exe +DEL_FILE = del +CHK_DIR_EXISTS= if not exist +MKDIR = mkdir +COPY = copy /y +COPY_FILE = copy /y +COPY_DIR = xcopy /s /q /y /i +INSTALL_FILE = copy /y +INSTALL_PROGRAM = copy /y +INSTALL_DIR = xcopy /s /q /y /i +QINSTALL = C:\Qt\6.5.1\msvc2019_64\bin\qmake.exe -install qinstall +QINSTALL_PROGRAM = C:\Qt\6.5.1\msvc2019_64\bin\qmake.exe -install qinstall -exe +DEL_FILE = del +SYMLINK = $(QMAKE) -install ln -f -s +DEL_DIR = rmdir +MOVE = move +IDC = idc +IDL = midl +ZIP = zip -r -9 +DEF_FILE = +RES_FILE = +SED = $(QMAKE) -install sed +MOVE = move + +####### Output directory + +OBJECTS_DIR = debug + +####### Files + +SOURCES = src\plugin.cpp \ + src\ledhandler.cpp +OBJECTS = debug\plugin.obj \ + debug\ledhandler.obj + +DIST = include\teamlog\logtypes.h \ + include\teamspeak\clientlib_publicdefinitions.h \ + include\teamspeak\public_definitions.h \ + include\teamspeak\public_errors.h \ + include\teamspeak\public_errors_rare.h \ + include\teamspeak\public_rare_definitions.h \ + include\plugin_definitions.h \ + include\ts3_functions.h \ + src\plugin.h \ + \ \ + src\ledhandler.h src\plugin.cpp \ + src\ledhandler.cpp +QMAKE_TARGET = TS_WIFILED +DESTDIR = debug\ #avoid trailing-slash linebreak +TARGET = TS_WIFILED.dll +DESTDIR_TARGET = debug\TS_WIFILED.dll + +####### Implicit rules + +.SUFFIXES: .c .cpp .cc .cxx + +{src}.cpp{debug\}.obj:: + $(CXX) -c $(CXXFLAGS) $(INCPATH) -Fodebug\ @<< + $< +<< + +{src}.cc{debug\}.obj:: + $(CXX) -c $(CXXFLAGS) $(INCPATH) -Fodebug\ @<< + $< +<< + +{src}.cxx{debug\}.obj:: + $(CXX) -c $(CXXFLAGS) $(INCPATH) -Fodebug\ @<< + $< +<< + +{src}.c{debug\}.obj:: + $(CC) -c $(CFLAGS) $(INCPATH) -Fodebug\ @<< + $< +<< + +{.}.cpp{debug\}.obj:: + $(CXX) -c $(CXXFLAGS) $(INCPATH) -Fodebug\ @<< + $< +<< + +{.}.cc{debug\}.obj:: + $(CXX) -c $(CXXFLAGS) $(INCPATH) -Fodebug\ @<< + $< +<< + +{.}.cxx{debug\}.obj:: + $(CXX) -c $(CXXFLAGS) $(INCPATH) -Fodebug\ @<< + $< +<< + +{.}.c{debug\}.obj:: + $(CC) -c $(CFLAGS) $(INCPATH) -Fodebug\ @<< + $< +<< + +####### Build rules + +first: all +all: Makefile.Debug debug\TS_WIFILED.dll + +debug\TS_WIFILED.dll: C:\Qt\6.5.1\msvc2019_64\lib\Qt6Guid.lib C:\Qt\6.5.1\msvc2019_64\lib\Qt6Networkd.lib C:\Qt\6.5.1\msvc2019_64\lib\Qt6Cored.lib $(OBJECTS) + $(LINKER) $(LFLAGS) /MANIFEST:embed /OUT:$(DESTDIR_TARGET) @<< +debug\plugin.obj debug\ledhandler.obj +$(LIBS) +<< + +qmake: FORCE + @$(QMAKE) -o Makefile.Debug TS_WIFILED.pro -spec win32-msvc + +qmake_all: FORCE + +dist: + $(ZIP) TS_WIFILED.zip $(SOURCES) $(DIST) TS_WIFILED.pro C:\Qt\6.5.1\msvc2019_64\mkspecs\features\spec_pre.prf C:\Qt\6.5.1\msvc2019_64\mkspecs\common\windows-desktop.conf C:\Qt\6.5.1\msvc2019_64\mkspecs\features\win32\windows_vulkan_sdk.prf C:\Qt\6.5.1\msvc2019_64\mkspecs\common\windows-vulkan.conf C:\Qt\6.5.1\msvc2019_64\mkspecs\common\msvc-desktop.conf C:\Qt\6.5.1\msvc2019_64\mkspecs\qconfig.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_ext_freetype.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_ext_libjpeg.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_ext_libpng.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_concurrent.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_concurrent_private.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_core.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_core5compat.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_core5compat_private.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_core_private.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_dbus.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_dbus_private.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_designer.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_designer_private.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_designercomponents_private.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_devicediscovery_support_private.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_entrypoint_private.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_example_icons_private.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_fb_support_private.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_freetype_private.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_gui.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_gui_private.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_harfbuzz_private.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_help.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_help_private.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_jpeg_private.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_labsanimation.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_labsanimation_private.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_labsfolderlistmodel.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_labsfolderlistmodel_private.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_labsqmlmodels.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_labsqmlmodels_private.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_labssettings.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_labssettings_private.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_labssharedimage.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_labssharedimage_private.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_labswavefrontmesh.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_labswavefrontmesh_private.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_linguist.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_linguist_private.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_network.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_network_private.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_opengl.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_opengl_private.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_openglwidgets.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_openglwidgets_private.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_packetprotocol_private.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_png_private.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_positioning.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_positioning_private.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_positioningquick.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_positioningquick_private.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_printsupport.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_printsupport_private.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_qml.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_qml_private.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_qmlcompiler_private.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_qmlcore.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_qmlcore_private.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_qmldebug_private.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_qmldom_private.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_qmlintegration.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_qmlintegration_private.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_qmllocalstorage.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_qmllocalstorage_private.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_qmlmodels.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_qmlmodels_private.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_qmltest.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_qmltest_private.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_qmltyperegistrar_private.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_qmlworkerscript.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_qmlworkerscript_private.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_qmlxmllistmodel.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_qmlxmllistmodel_private.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_quick.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_quick_private.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_quickcontrols2.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_quickcontrols2_private.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_quickcontrols2impl.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_quickcontrols2impl_private.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_quickcontrolstestutilsprivate_private.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_quickdialogs2.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_quickdialogs2_private.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_quickdialogs2quickimpl.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_quickdialogs2quickimpl_private.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_quickdialogs2utils.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_quickdialogs2utils_private.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_quickeffects_private.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_quicklayouts.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_quicklayouts_private.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_quickparticles_private.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_quickshapes_private.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_quicktemplates2.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_quicktemplates2_private.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_quicktestutilsprivate_private.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_quickwidgets.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_quickwidgets_private.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_sql.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_sql_private.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_svg.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_svg_private.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_svgwidgets.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_svgwidgets_private.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_testlib.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_testlib_private.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_tools_private.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_uiplugin.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_uitools.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_uitools_private.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_webchannel.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_webchannel_private.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_webenginecore.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_webenginecore_private.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_webenginequick.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_webenginequick_private.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_webenginequickdelegatesqml.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_webenginequickdelegatesqml_private.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_webenginewidgets.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_webenginewidgets_private.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_webview.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_webview_private.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_webviewquick.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_webviewquick_private.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_widgets.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_widgets_private.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_xml.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_xml_private.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_zlib_private.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\features\qt_functions.prf C:\Qt\6.5.1\msvc2019_64\mkspecs\features\qt_config.prf C:\Qt\6.5.1\msvc2019_64\mkspecs\win32-msvc\qmake.conf C:\Qt\6.5.1\msvc2019_64\mkspecs\features\spec_post.prf .qmake.stash C:\Qt\6.5.1\msvc2019_64\mkspecs\features\exclusive_builds.prf C:\Qt\6.5.1\msvc2019_64\mkspecs\common\msvc-version.conf C:\Qt\6.5.1\msvc2019_64\mkspecs\features\toolchain.prf C:\Qt\6.5.1\msvc2019_64\mkspecs\features\default_pre.prf C:\Qt\6.5.1\msvc2019_64\mkspecs\features\win32\default_pre.prf C:\Qt\6.5.1\msvc2019_64\mkspecs\features\resolve_config.prf C:\Qt\6.5.1\msvc2019_64\mkspecs\features\exclusive_builds_post.prf C:\Qt\6.5.1\msvc2019_64\mkspecs\features\default_post.prf C:\Qt\6.5.1\msvc2019_64\mkspecs\features\build_pass.prf C:\Qt\6.5.1\msvc2019_64\mkspecs\features\entrypoint.prf C:\Qt\6.5.1\msvc2019_64\mkspecs\features\precompile_header.prf C:\Qt\6.5.1\msvc2019_64\mkspecs\features\warn_on.prf C:\Qt\6.5.1\msvc2019_64\mkspecs\features\qt.prf C:\Qt\6.5.1\msvc2019_64\mkspecs\features\resources_functions.prf C:\Qt\6.5.1\msvc2019_64\mkspecs\features\resources.prf C:\Qt\6.5.1\msvc2019_64\mkspecs\features\moc.prf C:\Qt\6.5.1\msvc2019_64\mkspecs\features\win32\opengl.prf C:\Qt\6.5.1\msvc2019_64\mkspecs\features\qmake_use.prf C:\Qt\6.5.1\msvc2019_64\mkspecs\features\file_copies.prf C:\Qt\6.5.1\msvc2019_64\mkspecs\features\win32\windows.prf C:\Qt\6.5.1\msvc2019_64\mkspecs\features\testcase_targets.prf C:\Qt\6.5.1\msvc2019_64\mkspecs\features\exceptions.prf C:\Qt\6.5.1\msvc2019_64\mkspecs\features\yacc.prf C:\Qt\6.5.1\msvc2019_64\mkspecs\features\lex.prf TS_WIFILED.pro C:\Qt\6.5.1\msvc2019_64\lib\Qt6Guid.prl C:\Qt\6.5.1\msvc2019_64\lib\Qt6Networkd.prl C:\Qt\6.5.1\msvc2019_64\lib\Qt6Cored.prl C:\Qt\6.5.1\msvc2019_64\mkspecs\features\data\dummy.cpp include\teamlog\logtypes.h include\teamspeak\clientlib_publicdefinitions.h include\teamspeak\public_definitions.h include\teamspeak\public_errors.h include\teamspeak\public_errors_rare.h include\teamspeak\public_rare_definitions.h include\plugin_definitions.h include\ts3_functions.h src\plugin.h \ src\ledhandler.h src\plugin.cpp src\ledhandler.cpp + +clean: compiler_clean + -$(DEL_FILE) debug\plugin.obj debug\ledhandler.obj + -$(DEL_FILE) debug\TS_WIFILED.exp debug\TS_WIFILED.vc.pdb debug\TS_WIFILED.ilk debug\TS_WIFILED.idb + +distclean: clean + -$(DEL_FILE) .qmake.stash debug\TS_WIFILED.lib debug\TS_WIFILED.pdb + -$(DEL_FILE) $(DESTDIR_TARGET) + -$(DEL_FILE) Makefile.Debug + +mocclean: compiler_moc_header_clean compiler_moc_objc_header_clean compiler_moc_source_clean + +mocables: compiler_moc_header_make_all compiler_moc_objc_header_make_all compiler_moc_source_make_all + +check: first + +benchmark: first + +compiler_no_pch_compiler_make_all: +compiler_no_pch_compiler_clean: +compiler_rcc_make_all: +compiler_rcc_clean: +compiler_moc_predefs_make_all: debug\moc_predefs.h +compiler_moc_predefs_clean: + -$(DEL_FILE) debug\moc_predefs.h +debug\moc_predefs.h: C:\Qt\6.5.1\msvc2019_64\mkspecs\features\data\dummy.cpp + cl -BxC:\Qt\6.5.1\msvc2019_64\bin\qmake.exe -nologo -Zc:wchar_t -FS -Zc:rvalueCast -Zc:inline -Zc:strictStrings -Zc:throwingNew -permissive- -Zc:__cplusplus -Zc:externConstexpr -Zi -MDd -std:c++17 -utf-8 -W3 -w34100 -w34189 -w44996 -w44456 -w44457 -w44458 -wd4577 -wd4467 -E C:\Qt\6.5.1\msvc2019_64\mkspecs\features\data\dummy.cpp 2>NUL >debug\moc_predefs.h + +compiler_moc_header_make_all: +compiler_moc_header_clean: +compiler_moc_objc_header_make_all: +compiler_moc_objc_header_clean: +compiler_moc_source_make_all: +compiler_moc_source_clean: +compiler_yacc_decl_make_all: +compiler_yacc_decl_clean: +compiler_yacc_impl_make_all: +compiler_yacc_impl_clean: +compiler_lex_make_all: +compiler_lex_clean: +compiler_clean: compiler_moc_predefs_clean + + + +####### Compile + +debug\plugin.obj: src\plugin.cpp C:\Qt\6.5.1\msvc2019_64\include\QtCore\QtCore \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\QtCoreDepends \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qglobal.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qtversionchecks.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qconfig.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qtcore-config.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qtconfigmacros.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qtcoreexports.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qtpreprocessorsupport.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qtnoop.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qsystemdetection.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qprocessordetection.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qcompilerdetection.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qassert.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qtypes.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qtclasshelpermacros.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qtversion.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qtypeinfo.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qcontainerfwd.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qsysinfo.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qlogging.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qflags.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qcompare_impl.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qatomic.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qbasicatomic.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qatomic_cxx11.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qgenericatomic.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qconstructormacros.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qdarwinhelpers.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qexceptionhandling.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qforeach.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qtdeprecationmarkers.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qttypetraits.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qfunctionpointer.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qglobalstatic.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qmalloc.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qminmax.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qnumeric.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qoverload.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qswap.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qtenvironmentvariables.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qtresource.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qttranslation.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qversiontagging.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\q20algorithm.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\q20functional.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\q20iterator.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\q20memory.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\q23functional.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qabstractanimation.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qobject.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qobjectdefs.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qnamespace.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qtmetamacros.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qobjectdefs_impl.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qstring.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qchar.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qstringview.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qbytearray.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qrefcount.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qarraydata.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qpair.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qarraydatapointer.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qarraydataops.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qcontainertools_impl.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qxptype_traits.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qbytearrayalgorithms.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qbytearrayview.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qstringfwd.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\q20type_traits.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qstringliteral.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qstringalgorithms.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qanystringview.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qutf8stringview.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qstringtokenizer.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qstringbuilder.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qlist.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qhashfunctions.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qiterator.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qbytearraylist.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qstringlist.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qalgorithms.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qstringmatcher.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qcoreevent.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qscopedpointer.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qmetatype.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qcompare.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qdatastream.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qiodevicebase.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qfloat16.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qmath.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qiterable.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qmetacontainer.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qcontainerinfo.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qtaggedpointer.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qscopeguard.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qobject_impl.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qbindingstorage.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qabstracteventdispatcher.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qeventloop.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qabstractitemmodel.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qhash.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qvariant.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qdebug.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qtextstream.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qstringconverter_base.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qcontiguouscache.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qsharedpointer.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qshareddata.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qsharedpointer_impl.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qmap.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qshareddata_impl.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qset.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qvarlengtharray.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qabstractnativeeventfilter.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qabstractproxymodel.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qanimationgroup.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qapplicationstatic.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\QMutex \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qmutex.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qtsan_impl.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qcoreapplication.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qnativeinterface.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qcoreapplication_platform.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qfuture.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qfutureinterface.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qresultstore.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qfuture_impl.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qthreadpool.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qthread.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qdeadlinetimer.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qelapsedtimer.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qrunnable.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qexception.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qpointer.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qpromise.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qassociativeiterable.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qbasictimer.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qbitarray.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qbuffer.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qiodevice.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qbytearraymatcher.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qcache.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qcalendar.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qlocale.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qcborarray.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qcborvalue.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qdatetime.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qcborcommon.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qregularexpression.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qurl.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\quuid.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qcbormap.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qcborstream.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qcborstreamreader.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qcborstreamwriter.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qcollator.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qcommandlineoption.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qcommandlineparser.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qconcatenatetablesproxymodel.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qcryptographichash.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qdir.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qfile.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qfiledevice.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qfileinfo.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qdiriterator.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qeasingcurve.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qendian.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qfactoryinterface.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qfileselector.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\QObject \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\QStringList \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qfilesystemwatcher.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qfuturesynchronizer.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qfuturewatcher.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qidentityproxymodel.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qitemselectionmodel.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qjsonarray.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qjsonvalue.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qjsondocument.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qjsonobject.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qlatin1stringmatcher.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qlibrary.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qlibraryinfo.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qversionnumber.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qline.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qpoint.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qlockfile.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qloggingcategory.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qmargins.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qmessageauthenticationcode.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qmetaobject.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qmimedata.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qmimedatabase.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qmimetype.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qobjectcleanuphandler.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qoperatingsystemversion.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qparallelanimationgroup.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qpauseanimation.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qplugin.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qpluginloader.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qprocess.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qproperty.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qpropertyprivate.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qpropertyanimation.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qvariantanimation.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qqueue.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qrandom.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qreadwritelock.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qrect.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qsize.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qresource.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qsavefile.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qscopedvaluerollback.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qsemaphore.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qsequentialanimationgroup.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qsequentialiterable.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qsettings.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qsharedmemory.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qsignalmapper.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qsimd.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qsocketnotifier.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qsortfilterproxymodel.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qstack.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qstandardpaths.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qstorageinfo.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qstringconverter.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qstringlistmodel.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qsystemsemaphore.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qtcoreversion.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qtemporarydir.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qtemporaryfile.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qtextboundaryfinder.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qthreadstorage.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qtimeline.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qtimer.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qtimezone.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qtranslator.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qtransposeproxymodel.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qurlquery.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qvarianthash.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\QHash \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\QVariant \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\QString \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qvariantlist.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\QList \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qvariantmap.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\QMap \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qvector.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qwaitcondition.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\QDeadlineTimer \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qwineventnotifier.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qxmlstream.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qxpfunctional.h \ + src\plugin.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtNetwork\QUdpSocket \ + C:\Qt\6.5.1\msvc2019_64\include\QtNetwork\qudpsocket.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtNetwork\qtnetworkglobal.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtNetwork\qtnetwork-config.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtNetwork\qtnetworkexports.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtNetwork\qabstractsocket.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtNetwork\qhostaddress.h \ + src\ledhandler.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\QSettings \ + include\ts3_functions.h \ + include\teamspeak\clientlib_publicdefinitions.h \ + include\teamspeak\public_definitions.h \ + include\teamlog\logtypes.h \ + include\plugin_definitions.h \ + include\teamspeak\public_errors.h \ + include\teamspeak\public_errors_rare.h \ + include\teamspeak\public_rare_definitions.h + +debug\ledhandler.obj: src\ledhandler.cpp src\ledhandler.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\QSettings \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qsettings.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qobject.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qobjectdefs.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qnamespace.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qglobal.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qtversionchecks.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qconfig.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qtcore-config.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qtconfigmacros.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qtcoreexports.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qtpreprocessorsupport.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qtnoop.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qsystemdetection.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qprocessordetection.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qcompilerdetection.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qassert.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qtypes.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qtclasshelpermacros.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qtversion.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qtypeinfo.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qcontainerfwd.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qsysinfo.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qlogging.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qflags.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qcompare_impl.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qatomic.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qbasicatomic.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qatomic_cxx11.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qgenericatomic.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qconstructormacros.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qdarwinhelpers.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qexceptionhandling.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qforeach.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qtdeprecationmarkers.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qttypetraits.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qfunctionpointer.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qglobalstatic.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qmalloc.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qminmax.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qnumeric.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qoverload.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qswap.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qtenvironmentvariables.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qtresource.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qttranslation.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qversiontagging.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qtmetamacros.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qobjectdefs_impl.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qstring.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qchar.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qstringview.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qbytearray.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qrefcount.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qarraydata.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qpair.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qarraydatapointer.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qarraydataops.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qcontainertools_impl.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qxptype_traits.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qbytearrayalgorithms.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qbytearrayview.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qstringfwd.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\q20type_traits.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qstringliteral.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qstringalgorithms.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qanystringview.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qutf8stringview.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qstringtokenizer.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qstringbuilder.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qlist.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qhashfunctions.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qiterator.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qbytearraylist.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qstringlist.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qalgorithms.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qstringmatcher.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qcoreevent.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qscopedpointer.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qmetatype.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qcompare.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qdatastream.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qiodevicebase.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qfloat16.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qmath.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qiterable.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qmetacontainer.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qcontainerinfo.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qtaggedpointer.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qscopeguard.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qobject_impl.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qbindingstorage.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qvariant.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qdebug.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qtextstream.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qstringconverter_base.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qcontiguouscache.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qsharedpointer.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qshareddata.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qsharedpointer_impl.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qmap.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qshareddata_impl.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qset.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qhash.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qvarlengtharray.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\q20memory.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtNetwork\QUdpSocket \ + C:\Qt\6.5.1\msvc2019_64\include\QtNetwork\qudpsocket.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtNetwork\qtnetworkglobal.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtNetwork\qtnetwork-config.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtNetwork\qtnetworkexports.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtNetwork\qabstractsocket.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtNetwork\qhostaddress.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qiodevice.h \ + include\ts3_functions.h \ + include\teamspeak\clientlib_publicdefinitions.h \ + include\teamspeak\public_definitions.h \ + include\teamlog\logtypes.h \ + include\plugin_definitions.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtGui\QColor \ + C:\Qt\6.5.1\msvc2019_64\include\QtGui\qcolor.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtGui\qtguiglobal.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtGui\qtgui-config.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtGui\qtguiexports.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtGui\qrgb.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtGui\qrgba64.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtNetwork\QNetworkDatagram \ + C:\Qt\6.5.1\msvc2019_64\include\QtNetwork\qnetworkdatagram.h + +####### Install + +install: FORCE + +uninstall: FORCE + +FORCE: + diff --git a/Makefile.Release b/Makefile.Release new file mode 100644 index 0000000..b67da15 --- /dev/null +++ b/Makefile.Release @@ -0,0 +1,593 @@ +############################################################################# +# Makefile for building: TS_WIFILED +# Generated by qmake (3.1) (Qt 6.5.1) +# Project: TS_WIFILED.pro +# Template: lib +############################################################################# + +MAKEFILE = Makefile.Release + +EQ = = + +####### Compiler, tools and options + +CC = cl +CXX = cl +DEFINES = -DUNICODE -D_UNICODE -DWIN32 -D_ENABLE_EXTENDED_ALIGNED_STORAGE -DWIN64 -DNDEBUG -DQT_NO_DEBUG -DQT_GUI_LIB -DQT_NETWORK_LIB -DQT_CORE_LIB -D_WINDLL +CFLAGS = -nologo -Zc:wchar_t -FS -Zc:strictStrings -O2 -MD -utf-8 -W3 -w44456 -w44457 -w44458 $(DEFINES) +CXXFLAGS = -nologo -Zc:wchar_t -FS -Zc:rvalueCast -Zc:inline -Zc:strictStrings -Zc:throwingNew -permissive- -Zc:__cplusplus -Zc:externConstexpr -O2 -MD -std:c++17 -utf-8 -W3 -w34100 -w34189 -w44996 -w44456 -w44457 -w44458 -wd4577 -wd4467 -EHsc $(DEFINES) +INCPATH = -I. -Iinclude -Iinclude\teamlog -Iinclude\teamspeak -Isrc -IC:\Qt\6.5.1\msvc2019_64\include -IC:\Qt\6.5.1\msvc2019_64\include\QtGui -IC:\Qt\6.5.1\msvc2019_64\include\QtNetwork -IC:\Qt\6.5.1\msvc2019_64\include\QtCore -Irelease -I/include -IC:\Qt\6.5.1\msvc2019_64\mkspecs\win32-msvc +LINKER = link +LFLAGS = /NOLOGO /DYNAMICBASE /NXCOMPAT /OPT:REF /OPT:ICF /INCREMENTAL:NO /DLL /SUBSYSTEM:WINDOWS +LIBS = C:\Qt\6.5.1\msvc2019_64\lib\Qt6Gui.lib C:\Qt\6.5.1\msvc2019_64\lib\Qt6Network.lib C:\Qt\6.5.1\msvc2019_64\lib\Qt6Core.lib +QMAKE = C:\Qt\6.5.1\msvc2019_64\bin\qmake.exe +DEL_FILE = del +CHK_DIR_EXISTS= if not exist +MKDIR = mkdir +COPY = copy /y +COPY_FILE = copy /y +COPY_DIR = xcopy /s /q /y /i +INSTALL_FILE = copy /y +INSTALL_PROGRAM = copy /y +INSTALL_DIR = xcopy /s /q /y /i +QINSTALL = C:\Qt\6.5.1\msvc2019_64\bin\qmake.exe -install qinstall +QINSTALL_PROGRAM = C:\Qt\6.5.1\msvc2019_64\bin\qmake.exe -install qinstall -exe +DEL_FILE = del +SYMLINK = $(QMAKE) -install ln -f -s +DEL_DIR = rmdir +MOVE = move +IDC = idc +IDL = midl +ZIP = zip -r -9 +DEF_FILE = +RES_FILE = +SED = $(QMAKE) -install sed +MOVE = move + +####### Output directory + +OBJECTS_DIR = release + +####### Files + +SOURCES = src\plugin.cpp \ + src\ledhandler.cpp +OBJECTS = release\plugin.obj \ + release\ledhandler.obj + +DIST = include\teamlog\logtypes.h \ + include\teamspeak\clientlib_publicdefinitions.h \ + include\teamspeak\public_definitions.h \ + include\teamspeak\public_errors.h \ + include\teamspeak\public_errors_rare.h \ + include\teamspeak\public_rare_definitions.h \ + include\plugin_definitions.h \ + include\ts3_functions.h \ + src\plugin.h \ + \ \ + src\ledhandler.h src\plugin.cpp \ + src\ledhandler.cpp +QMAKE_TARGET = TS_WIFILED +DESTDIR = release\ #avoid trailing-slash linebreak +TARGET = TS_WIFILED.dll +DESTDIR_TARGET = release\TS_WIFILED.dll + +####### Implicit rules + +.SUFFIXES: .c .cpp .cc .cxx + +{src}.cpp{release\}.obj:: + $(CXX) -c $(CXXFLAGS) $(INCPATH) -Forelease\ @<< + $< +<< + +{src}.cc{release\}.obj:: + $(CXX) -c $(CXXFLAGS) $(INCPATH) -Forelease\ @<< + $< +<< + +{src}.cxx{release\}.obj:: + $(CXX) -c $(CXXFLAGS) $(INCPATH) -Forelease\ @<< + $< +<< + +{src}.c{release\}.obj:: + $(CC) -c $(CFLAGS) $(INCPATH) -Forelease\ @<< + $< +<< + +{.}.cpp{release\}.obj:: + $(CXX) -c $(CXXFLAGS) $(INCPATH) -Forelease\ @<< + $< +<< + +{.}.cc{release\}.obj:: + $(CXX) -c $(CXXFLAGS) $(INCPATH) -Forelease\ @<< + $< +<< + +{.}.cxx{release\}.obj:: + $(CXX) -c $(CXXFLAGS) $(INCPATH) -Forelease\ @<< + $< +<< + +{.}.c{release\}.obj:: + $(CC) -c $(CFLAGS) $(INCPATH) -Forelease\ @<< + $< +<< + +####### Build rules + +first: all +all: Makefile.Release release\TS_WIFILED.dll + +release\TS_WIFILED.dll: C:\Qt\6.5.1\msvc2019_64\lib\Qt6Gui.lib C:\Qt\6.5.1\msvc2019_64\lib\Qt6Network.lib C:\Qt\6.5.1\msvc2019_64\lib\Qt6Core.lib $(OBJECTS) + $(LINKER) $(LFLAGS) /MANIFEST:embed /OUT:$(DESTDIR_TARGET) @<< +release\plugin.obj release\ledhandler.obj +$(LIBS) +<< + +qmake: FORCE + @$(QMAKE) -o Makefile.Release TS_WIFILED.pro -spec win32-msvc + +qmake_all: FORCE + +dist: + $(ZIP) TS_WIFILED.zip $(SOURCES) $(DIST) TS_WIFILED.pro C:\Qt\6.5.1\msvc2019_64\mkspecs\features\spec_pre.prf C:\Qt\6.5.1\msvc2019_64\mkspecs\common\windows-desktop.conf C:\Qt\6.5.1\msvc2019_64\mkspecs\features\win32\windows_vulkan_sdk.prf C:\Qt\6.5.1\msvc2019_64\mkspecs\common\windows-vulkan.conf C:\Qt\6.5.1\msvc2019_64\mkspecs\common\msvc-desktop.conf C:\Qt\6.5.1\msvc2019_64\mkspecs\qconfig.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_ext_freetype.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_ext_libjpeg.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_ext_libpng.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_concurrent.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_concurrent_private.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_core.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_core5compat.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_core5compat_private.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_core_private.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_dbus.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_dbus_private.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_designer.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_designer_private.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_designercomponents_private.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_devicediscovery_support_private.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_entrypoint_private.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_example_icons_private.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_fb_support_private.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_freetype_private.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_gui.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_gui_private.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_harfbuzz_private.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_help.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_help_private.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_jpeg_private.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_labsanimation.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_labsanimation_private.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_labsfolderlistmodel.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_labsfolderlistmodel_private.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_labsqmlmodels.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_labsqmlmodels_private.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_labssettings.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_labssettings_private.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_labssharedimage.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_labssharedimage_private.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_labswavefrontmesh.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_labswavefrontmesh_private.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_linguist.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_linguist_private.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_network.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_network_private.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_opengl.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_opengl_private.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_openglwidgets.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_openglwidgets_private.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_packetprotocol_private.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_png_private.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_positioning.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_positioning_private.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_positioningquick.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_positioningquick_private.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_printsupport.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_printsupport_private.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_qml.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_qml_private.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_qmlcompiler_private.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_qmlcore.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_qmlcore_private.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_qmldebug_private.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_qmldom_private.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_qmlintegration.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_qmlintegration_private.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_qmllocalstorage.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_qmllocalstorage_private.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_qmlmodels.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_qmlmodels_private.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_qmltest.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_qmltest_private.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_qmltyperegistrar_private.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_qmlworkerscript.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_qmlworkerscript_private.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_qmlxmllistmodel.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_qmlxmllistmodel_private.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_quick.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_quick_private.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_quickcontrols2.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_quickcontrols2_private.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_quickcontrols2impl.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_quickcontrols2impl_private.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_quickcontrolstestutilsprivate_private.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_quickdialogs2.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_quickdialogs2_private.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_quickdialogs2quickimpl.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_quickdialogs2quickimpl_private.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_quickdialogs2utils.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_quickdialogs2utils_private.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_quickeffects_private.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_quicklayouts.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_quicklayouts_private.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_quickparticles_private.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_quickshapes_private.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_quicktemplates2.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_quicktemplates2_private.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_quicktestutilsprivate_private.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_quickwidgets.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_quickwidgets_private.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_sql.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_sql_private.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_svg.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_svg_private.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_svgwidgets.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_svgwidgets_private.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_testlib.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_testlib_private.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_tools_private.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_uiplugin.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_uitools.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_uitools_private.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_webchannel.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_webchannel_private.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_webenginecore.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_webenginecore_private.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_webenginequick.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_webenginequick_private.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_webenginequickdelegatesqml.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_webenginequickdelegatesqml_private.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_webenginewidgets.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_webenginewidgets_private.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_webview.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_webview_private.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_webviewquick.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_webviewquick_private.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_widgets.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_widgets_private.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_xml.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_xml_private.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\modules\qt_lib_zlib_private.pri C:\Qt\6.5.1\msvc2019_64\mkspecs\features\qt_functions.prf C:\Qt\6.5.1\msvc2019_64\mkspecs\features\qt_config.prf C:\Qt\6.5.1\msvc2019_64\mkspecs\win32-msvc\qmake.conf C:\Qt\6.5.1\msvc2019_64\mkspecs\features\spec_post.prf .qmake.stash C:\Qt\6.5.1\msvc2019_64\mkspecs\features\exclusive_builds.prf C:\Qt\6.5.1\msvc2019_64\mkspecs\common\msvc-version.conf C:\Qt\6.5.1\msvc2019_64\mkspecs\features\toolchain.prf C:\Qt\6.5.1\msvc2019_64\mkspecs\features\default_pre.prf C:\Qt\6.5.1\msvc2019_64\mkspecs\features\win32\default_pre.prf C:\Qt\6.5.1\msvc2019_64\mkspecs\features\resolve_config.prf C:\Qt\6.5.1\msvc2019_64\mkspecs\features\exclusive_builds_post.prf C:\Qt\6.5.1\msvc2019_64\mkspecs\features\default_post.prf C:\Qt\6.5.1\msvc2019_64\mkspecs\features\build_pass.prf C:\Qt\6.5.1\msvc2019_64\mkspecs\features\entrypoint.prf C:\Qt\6.5.1\msvc2019_64\mkspecs\features\precompile_header.prf C:\Qt\6.5.1\msvc2019_64\mkspecs\features\warn_on.prf C:\Qt\6.5.1\msvc2019_64\mkspecs\features\qt.prf C:\Qt\6.5.1\msvc2019_64\mkspecs\features\resources_functions.prf C:\Qt\6.5.1\msvc2019_64\mkspecs\features\resources.prf C:\Qt\6.5.1\msvc2019_64\mkspecs\features\moc.prf C:\Qt\6.5.1\msvc2019_64\mkspecs\features\win32\opengl.prf C:\Qt\6.5.1\msvc2019_64\mkspecs\features\qmake_use.prf C:\Qt\6.5.1\msvc2019_64\mkspecs\features\file_copies.prf C:\Qt\6.5.1\msvc2019_64\mkspecs\features\win32\windows.prf C:\Qt\6.5.1\msvc2019_64\mkspecs\features\testcase_targets.prf C:\Qt\6.5.1\msvc2019_64\mkspecs\features\exceptions.prf C:\Qt\6.5.1\msvc2019_64\mkspecs\features\yacc.prf C:\Qt\6.5.1\msvc2019_64\mkspecs\features\lex.prf TS_WIFILED.pro C:\Qt\6.5.1\msvc2019_64\lib\Qt6Gui.prl C:\Qt\6.5.1\msvc2019_64\lib\Qt6Network.prl C:\Qt\6.5.1\msvc2019_64\lib\Qt6Core.prl C:\Qt\6.5.1\msvc2019_64\mkspecs\features\data\dummy.cpp include\teamlog\logtypes.h include\teamspeak\clientlib_publicdefinitions.h include\teamspeak\public_definitions.h include\teamspeak\public_errors.h include\teamspeak\public_errors_rare.h include\teamspeak\public_rare_definitions.h include\plugin_definitions.h include\ts3_functions.h src\plugin.h \ src\ledhandler.h src\plugin.cpp src\ledhandler.cpp + +clean: compiler_clean + -$(DEL_FILE) release\plugin.obj release\ledhandler.obj + -$(DEL_FILE) release\TS_WIFILED.exp + +distclean: clean + -$(DEL_FILE) .qmake.stash release\TS_WIFILED.lib + -$(DEL_FILE) $(DESTDIR_TARGET) + -$(DEL_FILE) Makefile.Release + +mocclean: compiler_moc_header_clean compiler_moc_objc_header_clean compiler_moc_source_clean + +mocables: compiler_moc_header_make_all compiler_moc_objc_header_make_all compiler_moc_source_make_all + +check: first + +benchmark: first + +compiler_no_pch_compiler_make_all: +compiler_no_pch_compiler_clean: +compiler_rcc_make_all: +compiler_rcc_clean: +compiler_moc_predefs_make_all: release\moc_predefs.h +compiler_moc_predefs_clean: + -$(DEL_FILE) release\moc_predefs.h +release\moc_predefs.h: C:\Qt\6.5.1\msvc2019_64\mkspecs\features\data\dummy.cpp + cl -BxC:\Qt\6.5.1\msvc2019_64\bin\qmake.exe -nologo -Zc:wchar_t -FS -Zc:rvalueCast -Zc:inline -Zc:strictStrings -Zc:throwingNew -permissive- -Zc:__cplusplus -Zc:externConstexpr -O2 -MD -std:c++17 -utf-8 -W3 -w34100 -w34189 -w44996 -w44456 -w44457 -w44458 -wd4577 -wd4467 -E C:\Qt\6.5.1\msvc2019_64\mkspecs\features\data\dummy.cpp 2>NUL >release\moc_predefs.h + +compiler_moc_header_make_all: +compiler_moc_header_clean: +compiler_moc_objc_header_make_all: +compiler_moc_objc_header_clean: +compiler_moc_source_make_all: +compiler_moc_source_clean: +compiler_yacc_decl_make_all: +compiler_yacc_decl_clean: +compiler_yacc_impl_make_all: +compiler_yacc_impl_clean: +compiler_lex_make_all: +compiler_lex_clean: +compiler_clean: compiler_moc_predefs_clean + + + +####### Compile + +release\plugin.obj: src\plugin.cpp C:\Qt\6.5.1\msvc2019_64\include\QtCore\QtCore \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\QtCoreDepends \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qglobal.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qtversionchecks.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qconfig.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qtcore-config.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qtconfigmacros.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qtcoreexports.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qtpreprocessorsupport.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qtnoop.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qsystemdetection.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qprocessordetection.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qcompilerdetection.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qassert.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qtypes.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qtclasshelpermacros.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qtversion.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qtypeinfo.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qcontainerfwd.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qsysinfo.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qlogging.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qflags.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qcompare_impl.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qatomic.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qbasicatomic.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qatomic_cxx11.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qgenericatomic.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qconstructormacros.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qdarwinhelpers.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qexceptionhandling.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qforeach.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qtdeprecationmarkers.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qttypetraits.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qfunctionpointer.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qglobalstatic.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qmalloc.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qminmax.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qnumeric.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qoverload.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qswap.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qtenvironmentvariables.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qtresource.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qttranslation.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qversiontagging.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\q20algorithm.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\q20functional.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\q20iterator.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\q20memory.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\q23functional.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qabstractanimation.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qobject.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qobjectdefs.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qnamespace.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qtmetamacros.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qobjectdefs_impl.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qstring.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qchar.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qstringview.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qbytearray.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qrefcount.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qarraydata.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qpair.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qarraydatapointer.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qarraydataops.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qcontainertools_impl.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qxptype_traits.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qbytearrayalgorithms.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qbytearrayview.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qstringfwd.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\q20type_traits.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qstringliteral.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qstringalgorithms.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qanystringview.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qutf8stringview.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qstringtokenizer.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qstringbuilder.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qlist.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qhashfunctions.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qiterator.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qbytearraylist.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qstringlist.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qalgorithms.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qstringmatcher.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qcoreevent.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qscopedpointer.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qmetatype.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qcompare.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qdatastream.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qiodevicebase.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qfloat16.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qmath.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qiterable.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qmetacontainer.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qcontainerinfo.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qtaggedpointer.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qscopeguard.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qobject_impl.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qbindingstorage.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qabstracteventdispatcher.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qeventloop.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qabstractitemmodel.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qhash.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qvariant.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qdebug.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qtextstream.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qstringconverter_base.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qcontiguouscache.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qsharedpointer.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qshareddata.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qsharedpointer_impl.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qmap.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qshareddata_impl.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qset.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qvarlengtharray.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qabstractnativeeventfilter.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qabstractproxymodel.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qanimationgroup.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qapplicationstatic.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\QMutex \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qmutex.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qtsan_impl.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qcoreapplication.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qnativeinterface.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qcoreapplication_platform.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qfuture.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qfutureinterface.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qresultstore.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qfuture_impl.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qthreadpool.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qthread.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qdeadlinetimer.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qelapsedtimer.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qrunnable.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qexception.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qpointer.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qpromise.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qassociativeiterable.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qbasictimer.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qbitarray.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qbuffer.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qiodevice.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qbytearraymatcher.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qcache.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qcalendar.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qlocale.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qcborarray.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qcborvalue.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qdatetime.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qcborcommon.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qregularexpression.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qurl.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\quuid.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qcbormap.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qcborstream.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qcborstreamreader.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qcborstreamwriter.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qcollator.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qcommandlineoption.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qcommandlineparser.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qconcatenatetablesproxymodel.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qcryptographichash.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qdir.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qfile.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qfiledevice.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qfileinfo.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qdiriterator.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qeasingcurve.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qendian.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qfactoryinterface.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qfileselector.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\QObject \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\QStringList \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qfilesystemwatcher.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qfuturesynchronizer.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qfuturewatcher.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qidentityproxymodel.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qitemselectionmodel.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qjsonarray.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qjsonvalue.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qjsondocument.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qjsonobject.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qlatin1stringmatcher.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qlibrary.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qlibraryinfo.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qversionnumber.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qline.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qpoint.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qlockfile.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qloggingcategory.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qmargins.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qmessageauthenticationcode.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qmetaobject.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qmimedata.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qmimedatabase.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qmimetype.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qobjectcleanuphandler.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qoperatingsystemversion.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qparallelanimationgroup.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qpauseanimation.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qplugin.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qpluginloader.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qprocess.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qproperty.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qpropertyprivate.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qpropertyanimation.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qvariantanimation.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qqueue.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qrandom.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qreadwritelock.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qrect.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qsize.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qresource.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qsavefile.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qscopedvaluerollback.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qsemaphore.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qsequentialanimationgroup.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qsequentialiterable.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qsettings.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qsharedmemory.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qsignalmapper.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qsimd.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qsocketnotifier.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qsortfilterproxymodel.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qstack.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qstandardpaths.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qstorageinfo.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qstringconverter.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qstringlistmodel.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qsystemsemaphore.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qtcoreversion.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qtemporarydir.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qtemporaryfile.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qtextboundaryfinder.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qthreadstorage.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qtimeline.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qtimer.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qtimezone.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qtranslator.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qtransposeproxymodel.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qurlquery.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qvarianthash.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\QHash \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\QVariant \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\QString \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qvariantlist.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\QList \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qvariantmap.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\QMap \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qvector.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qwaitcondition.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\QDeadlineTimer \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qwineventnotifier.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qxmlstream.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qxpfunctional.h \ + src\plugin.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtNetwork\QUdpSocket \ + C:\Qt\6.5.1\msvc2019_64\include\QtNetwork\qudpsocket.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtNetwork\qtnetworkglobal.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtNetwork\qtnetwork-config.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtNetwork\qtnetworkexports.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtNetwork\qabstractsocket.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtNetwork\qhostaddress.h \ + src\ledhandler.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\QSettings \ + include\ts3_functions.h \ + include\teamspeak\clientlib_publicdefinitions.h \ + include\teamspeak\public_definitions.h \ + include\teamlog\logtypes.h \ + include\plugin_definitions.h \ + include\teamspeak\public_errors.h \ + include\teamspeak\public_errors_rare.h \ + include\teamspeak\public_rare_definitions.h + +release\ledhandler.obj: src\ledhandler.cpp src\ledhandler.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\QSettings \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qsettings.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qobject.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qobjectdefs.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qnamespace.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qglobal.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qtversionchecks.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qconfig.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qtcore-config.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qtconfigmacros.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qtcoreexports.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qtpreprocessorsupport.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qtnoop.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qsystemdetection.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qprocessordetection.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qcompilerdetection.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qassert.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qtypes.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qtclasshelpermacros.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qtversion.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qtypeinfo.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qcontainerfwd.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qsysinfo.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qlogging.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qflags.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qcompare_impl.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qatomic.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qbasicatomic.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qatomic_cxx11.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qgenericatomic.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qconstructormacros.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qdarwinhelpers.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qexceptionhandling.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qforeach.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qtdeprecationmarkers.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qttypetraits.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qfunctionpointer.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qglobalstatic.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qmalloc.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qminmax.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qnumeric.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qoverload.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qswap.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qtenvironmentvariables.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qtresource.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qttranslation.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qversiontagging.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qtmetamacros.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qobjectdefs_impl.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qstring.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qchar.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qstringview.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qbytearray.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qrefcount.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qarraydata.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qpair.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qarraydatapointer.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qarraydataops.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qcontainertools_impl.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qxptype_traits.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qbytearrayalgorithms.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qbytearrayview.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qstringfwd.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\q20type_traits.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qstringliteral.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qstringalgorithms.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qanystringview.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qutf8stringview.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qstringtokenizer.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qstringbuilder.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qlist.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qhashfunctions.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qiterator.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qbytearraylist.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qstringlist.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qalgorithms.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qstringmatcher.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qcoreevent.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qscopedpointer.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qmetatype.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qcompare.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qdatastream.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qiodevicebase.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qfloat16.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qmath.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qiterable.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qmetacontainer.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qcontainerinfo.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qtaggedpointer.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qscopeguard.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qobject_impl.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qbindingstorage.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qvariant.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qdebug.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qtextstream.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qstringconverter_base.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qcontiguouscache.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qsharedpointer.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qshareddata.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qsharedpointer_impl.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qmap.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qshareddata_impl.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qset.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qhash.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qvarlengtharray.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\q20memory.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtNetwork\QUdpSocket \ + C:\Qt\6.5.1\msvc2019_64\include\QtNetwork\qudpsocket.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtNetwork\qtnetworkglobal.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtNetwork\qtnetwork-config.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtNetwork\qtnetworkexports.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtNetwork\qabstractsocket.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtNetwork\qhostaddress.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtCore\qiodevice.h \ + include\ts3_functions.h \ + include\teamspeak\clientlib_publicdefinitions.h \ + include\teamspeak\public_definitions.h \ + include\teamlog\logtypes.h \ + include\plugin_definitions.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtGui\QColor \ + C:\Qt\6.5.1\msvc2019_64\include\QtGui\qcolor.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtGui\qtguiglobal.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtGui\qtgui-config.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtGui\qtguiexports.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtGui\qrgb.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtGui\qrgba64.h \ + C:\Qt\6.5.1\msvc2019_64\include\QtNetwork\QNetworkDatagram \ + C:\Qt\6.5.1\msvc2019_64\include\QtNetwork\qnetworkdatagram.h + +####### Install + +install: FORCE + +uninstall: FORCE + +FORCE: + diff --git a/README.md b/README.md index 95bf820..b08bbc7 100644 --- a/README.md +++ b/README.md @@ -1,2 +1,18 @@ -# TS_WIFILED +# TeamSpeak 3 Client Plugin SDK: Helper Repository +Welcome to the official helper repository for creating native plugins for the TeamSpeak 3 Client. This repository includes example code and SDK header files to assist in the development of your plugin. + +## Quick Start Guide + +To get started, it's highly recommended that you base your plugin on the provided test plugin. This test plugin includes the necessary special functions that your plugin must export. If certain optional functions are not needed for your project, feel free to remove them. For more details, please refer to the code comments. + +## Additional Resources + +To expand your knowledge and get support, we recommend visiting the following resources: + +- [TeamSpeak Community Forums](https://community.teamspeak.com): Connect with other developers and TeamSpeak users. +- [TeamSpeak SDK Downloads](https://www.teamspeak.com/downloads#sdk): Access the latest version of our SDK and other development resources. + +## Copyright Information + +This repository is protected under copyright law. Copyright © TeamSpeak Systems GmbH. All rights reserved. diff --git a/include/plugin_definitions.h b/include/plugin_definitions.h index 428e4c2..6523236 100644 --- a/include/plugin_definitions.h +++ b/include/plugin_definitions.h @@ -3,70 +3,51 @@ /* Return values for ts3plugin_offersConfigure */ enum PluginConfigureOffer { - PLUGIN_OFFERS_NO_CONFIGURE = 0, /* Plugin does not implement ts3plugin_configure */ - PLUGIN_OFFERS_CONFIGURE_NEW_THREAD, /* Plugin does implement ts3plugin_configure and requests to run this function in an own thread */ - PLUGIN_OFFERS_CONFIGURE_QT_THREAD /* Plugin does implement ts3plugin_configure and requests to run this function in the Qt GUI thread */ + PLUGIN_OFFERS_NO_CONFIGURE = 0, /* Plugin does not implement ts3plugin_configure */ + PLUGIN_OFFERS_CONFIGURE_NEW_THREAD, /* Plugin does implement ts3plugin_configure and requests to run this function in an own thread */ + PLUGIN_OFFERS_CONFIGURE_QT_THREAD /* Plugin does implement ts3plugin_configure and requests to run this function in the Qt GUI thread */ }; -enum PluginMessageTarget { - PLUGIN_MESSAGE_TARGET_SERVER = 0, - PLUGIN_MESSAGE_TARGET_CHANNEL -}; +enum PluginMessageTarget { PLUGIN_MESSAGE_TARGET_SERVER = 0, PLUGIN_MESSAGE_TARGET_CHANNEL }; -enum PluginItemType { - PLUGIN_SERVER = 0, - PLUGIN_CHANNEL, - PLUGIN_CLIENT -}; +enum PluginItemType { PLUGIN_SERVER = 0, PLUGIN_CHANNEL, PLUGIN_CLIENT }; -enum PluginMenuType { - PLUGIN_MENU_TYPE_GLOBAL = 0 -}; +enum PluginMenuType { PLUGIN_MENU_TYPE_GLOBAL = 0, PLUGIN_MENU_TYPE_CHANNEL, PLUGIN_MENU_TYPE_CLIENT }; #define PLUGIN_MENU_BUFSZ 128 struct PluginMenuItem { - enum PluginMenuType type; - int id; - char text[PLUGIN_MENU_BUFSZ]; - char icon[PLUGIN_MENU_BUFSZ]; + enum PluginMenuType type; + int id; + char text[PLUGIN_MENU_BUFSZ]; + char icon[PLUGIN_MENU_BUFSZ]; }; #define PLUGIN_HOTKEY_BUFSZ 128 struct PluginHotkey { - char keyword[PLUGIN_HOTKEY_BUFSZ]; - char description[PLUGIN_HOTKEY_BUFSZ]; + char keyword[PLUGIN_HOTKEY_BUFSZ]; + char description[PLUGIN_HOTKEY_BUFSZ]; }; struct PluginBookmarkList; struct PluginBookmarkItem { - char* name; - unsigned char isFolder; - unsigned char reserved[3]; - union{ - char* uuid; - struct PluginBookmarkList* folder; - }; + char* name; + unsigned char isFolder; + unsigned char reserved[3]; + union { + char* uuid; + struct PluginBookmarkList* folder; + }; }; -struct PluginBookmarkList{ - int itemcount; - struct PluginBookmarkItem items[1]; //should be 0 but compiler complains +struct PluginBookmarkList { + int itemcount; + struct PluginBookmarkItem items[1]; //should be 0 but compiler complains }; -enum PluginGuiProfile{ - PLUGIN_GUI_SOUND_CAPTURE = 0, - PLUGIN_GUI_SOUND_PLAYBACK, - PLUGIN_GUI_HOTKEY, - PLUGIN_GUI_SOUNDPACK, - PLUGIN_GUI_IDENTITY -}; +enum PluginGuiProfile { PLUGIN_GUI_SOUND_CAPTURE = 0, PLUGIN_GUI_SOUND_PLAYBACK, PLUGIN_GUI_HOTKEY, PLUGIN_GUI_SOUNDPACK, PLUGIN_GUI_IDENTITY }; -enum PluginConnectTab{ - PLUGIN_CONNECT_TAB_NEW = 0, - PLUGIN_CONNECT_TAB_CURRENT, - PLUGIN_CONNECT_TAB_NEW_IF_CURRENT_CONNECTED -}; +enum PluginConnectTab { PLUGIN_CONNECT_TAB_NEW = 0, PLUGIN_CONNECT_TAB_CURRENT, PLUGIN_CONNECT_TAB_NEW_IF_CURRENT_CONNECTED }; #endif diff --git a/include/teamlog/logtypes.h b/include/teamlog/logtypes.h index fc53910..1a57888 100644 --- a/include/teamlog/logtypes.h +++ b/include/teamlog/logtypes.h @@ -2,22 +2,22 @@ #define TEAMLOG_LOGTYPES_H enum LogTypes { - LogType_NONE = 0x0000, - LogType_FILE = 0x0001, - LogType_CONSOLE = 0x0002, - LogType_USERLOGGING = 0x0004, - LogType_NO_NETLOGGING = 0x0008, - LogType_DATABASE = 0x0010, - LogType_SYSLOG = 0x0020, + LogType_NONE = 0x0000, ///< Logging is disabled + LogType_FILE = 0x0001, ///< Log to regular log file + LogType_CONSOLE = 0x0002, ///< Log to standard output / error + LogType_USERLOGGING = 0x0004, ///< User defined logging. Will call the \ref ServerLibFunctions.onUserLoggingMessageEvent callback for every message to be logged + LogType_NO_NETLOGGING = 0x0008, ///< Not used + LogType_DATABASE = 0x0010, ///< Log to database (deprecated, server only, no effect in SDK) + LogType_SYSLOG = 0x0020, ///< Log to syslog (only available on Linux) }; enum LogLevel { - LogLevel_CRITICAL = 0, //these messages stop the program - LogLevel_ERROR, //everything that is really bad, but not so bad we need to shut down - LogLevel_WARNING, //everything that *might* be bad - LogLevel_DEBUG, //output that might help find a problem - LogLevel_INFO, //informational output, like "starting database version x.y.z" - LogLevel_DEVEL //developer only output (will not be displayed in release mode) + LogLevel_CRITICAL = 0, ///< these messages stop the program + LogLevel_ERROR, ///< everything that is really bad, but not so bad we need to shut down + LogLevel_WARNING, ///< everything that *might* be bad + LogLevel_DEBUG, ///< output that might help find a problem + LogLevel_INFO, ///< informational output, like "starting database version x.y.z" + LogLevel_DEVEL ///< developer only output (will not be displayed in release mode) }; #endif //TEAMLOG_LOGTYPES_H diff --git a/include/teamspeak/clientlib.h b/include/teamspeak/clientlib.h new file mode 100644 index 0000000..09a89c9 --- /dev/null +++ b/include/teamspeak/clientlib.h @@ -0,0 +1,2411 @@ +/* + * This is the main header for the TeamSpeak 3 Client SDK. All the functions that are used + * to communicate with the Teamspeak 3 Client are here. Please view the documentation for + * details. Note that some of these functions REQUIRE you to call ts3sclient_freeMemory() + * after finishing with the result. This holds true for all the functions returning strings + * (so the parameter is "char** result"). Again, the details are all in the documentation. + */ + +#ifndef CLIENTLIB_H +#define CLIENTLIB_H + +//system +#include + +//own +#include "teamspeak/public_definitions.h" + +#ifdef __cplusplus +extern "C" { +#endif + +struct ClientUIFunctionsRare; + +/** + * @brief Defines available callbacks that you can receive. + * + * Set the members of this struct to a function to call when the specific event happens. + */ +struct ClientUIFunctions { + /** + * @brief called when the status of a connection changes + * + * @param serverConnectionHandlerID specifies on which connection the status has changed + * @param newStatus the current status of the connection. One of the values from the ConnectStatus enum + * @param errorNumber if the state change was caused by an error this is set to one of the values from the @ref Ts3ErrorType enum + */ + void (*onConnectStatusChangeEvent) (uint64 serverConnectionHandlerID, int newStatus, unsigned int errorNumber); + + /** + * @brief + * + * @param serverConnectionHandlerID specifies on which connection the callback was called + */ + void (*onServerProtocolVersionEvent) (uint64 serverConnectionHandlerID, int protocolVersion); + + /** + * @brief called when a channel was received. + * + * Will be called once for every channel during connection initialization. Tells you which channels exist. + * + * @param serverConnectionHandlerID specifies on which connection the callback was called + * @param channelID the id of the channel + * @param channelParentID the id of the parent channel. 0 if the channel is a root channel. + */ + void (*onNewChannelEvent) (uint64 serverConnectionHandlerID, uint64 channelID, uint64 channelParentID); + + /** + * @brief called when a new channel was created + * + * @param serverConnectionHandlerID specifies on which connection the callback was called + * @param channelID the id of the new channel + * @param channelParentID the id of the parent channel for the newly created channel. 0 if the channel is a root channel. + */ + void (*onNewChannelCreatedEvent) (uint64 serverConnectionHandlerID, uint64 channelID, uint64 channelParentID, anyID invokerID, const char* invokerName, const char* invokerUniqueIdentifier); + + /** + * @brief called when a channel is deleted + * + * @param serverConnectionHandlerID specifies on which connection the callback was called + * @param channelID the id of the channel that is deleted. This channel is gone already when this is called. It's not possible to get any information about this channel anymore. + * @param invokerID client id of the client that deleted the channel. 0 if deleted by the server. + * @param invokerName utf8 encoded c string containing the display name of the client that caused deletion + * @param invokerUnqiueIdentifier utf8 encoded c string containing the unique identifier of the client that caused deletion + */ + void (*onDelChannelEvent) (uint64 serverConnectionHandlerID, uint64 channelID, anyID invokerID, const char* invokerName, const char* invokerUniqueIdentifier); + + /** + * @brief called when a channel is moved to a different location on the server + * + * @param serverConnectionHandlerID specifies on which connection the callback was called + * @param channelID the id of the channel being moved + * @param newChannelParentID the id of the new parent channel + * @param invokerID client if of the client that moved the channel. 0 if caused by server. + * @param invokerName utf8 encoded c string containing the display name of the client that moved the channel + * @param invokerUniqueIdentifier utf8 encoded c string containing the unique identifier of the client that moved the channel + */ + void (*onChannelMoveEvent) (uint64 serverConnectionHandlerID, uint64 channelID, uint64 newChannelParentID, anyID invokerID, const char* invokerName, const char* invokerUniqueIdentifier); + + /** + * @brief called when new data for a channel was received from the server + * + * @param serverConnectionHandlerID specifies on which connection the callback was called + * @param channelID id of the channel that new information was received for + */ + void (*onUpdateChannelEvent) (uint64 serverConnectionHandlerID, uint64 channelID); + + /** + * @brief called when a channel was edited on the server + * + * @param serverConnectionHandlerID specifies on which connection the callback was called + * @param channelID the id of the channel that was edited + * @param invokerID client id that edited the channel. 0 if done by the server + * @param invokerName utf8 encoded c string containing the display name of the client editing the channel + * @param invokerUniqueIdentifier utf8 encoded c string containing the uid of the client that edited the channel + */ + void (*onUpdateChannelEditedEvent) (uint64 serverConnectionHandlerID, uint64 channelID, anyID invokerID, const char* invokerName, const char* invokerUniqueIdentifier); + + /** + * @brief called whenever a change for a client is received from the server. + * + * @param serverConnectionHandlerID specifies on which connection the callback was called + * @param clientID specifies the client for which variables have changed or are now available + * @param invokerID the source client that caused the update + * @param invokerName utf8 encoded c string containing the display name of the client causing the update + * @param invokerUniqueIdentifier utf8 encoded c string containing the public identity of the client causing the update + */ + void (*onUpdateClientEvent) (uint64 serverConnectionHandlerID, anyID clientID, anyID invokerID, const char* invokerName, const char* invokerUniqueIdentifier); + + /** + * @brief called when a client moves to a different channel, disconnects, connects, gets kicked or banned. + * + * @param serverConnectionHandlerID specifies on which connection the callback was called + * @param clientID id of the client changing channels + * @param oldChannelID id of the previous channel of the client. + * @param newChannelID id of the current channel of the client. Can be 0, if the client disconnected / got kicked / banned. + */ + void (*onClientMoveEvent) (uint64 serverConnectionHandlerID, anyID clientID, uint64 oldChannelID, uint64 newChannelID, int visibility, const char* moveMessage); + + /** + * @brief called after subscribing to or unsubscribing from a channel. Called once for every client that is in the (un)subscribed channel at this time. + * + * Informs you about newly visible clients after subribing to a channel. + * Informs about clients that we will no longer receive information about. + * + * @param serverConnectionHandlerID specifies on which connection the callback was called + * @param clientID id of the client + * @param oldChannelID id of the channel that the client was in last time we saw the client. + * @param newChannelID id of the channel the client is currently in. + * @param visibility whether we can see the client or not. One of the values from the Visibility enum. + * Allows to distinguish whether this callback was called after a subscribe or unsubscribe. + */ + void (*onClientMoveSubscriptionEvent) (uint64 serverConnectionHandlerID, anyID clientID, uint64 oldChannelID, uint64 newChannelID, int visibility); + + /** + * @brief called when a client loses connection and times out. + * + * @param serverConnectionHandlerID specifies on which connection the callback was called + * @param clientID id of the client that lost connection + * @param oldChannelID channel the client used to be in + * @param newChannelID always 0 + * @param visibility whether we can see the client. One of the values from the Visibility enum. + * @param timeoutMessage uft8 encoded c string containing the reason message. + */ + void (*onClientMoveTimeoutEvent) (uint64 serverConnectionHandlerID, anyID clientID, uint64 oldChannelID, uint64 newChannelID, int visibility, const char* timeoutMessage); + + /** + * @brief called when a client was moved by the server or another client + * + * @param serverConnectionHandlerID specifies on which connection the callback was called + * @param clientID the client that was moved + * @param oldChannelID id of the previous channel the client used to be in + * @param newChannelID id of the current channel the client was moved to + * @param visibility whether we can see the client. One of the values from the Visibility enum. + * @param moverID id of the client that moved the client + * @param moverName utf8 encoded c string containing the display name of the client that caused the move + * @param moverUniqueIdentifier utf8 encoded c string containing the identifier of the client that caused the move + * @param moveMessage utf8 encoded c string containing the reason message + */ + void (*onClientMoveMovedEvent) (uint64 serverConnectionHandlerID, anyID clientID, uint64 oldChannelID, uint64 newChannelID, int visibility, anyID moverID, const char* moverName, const char* moverUniqueIdentifier, const char* moveMessage); + + /** + * @brief called when a client is kicked from their channel + * + * @param serverConnectionHandlerID specifies on which connection the callback was called + * @param clientID id of the client that was kicked + * @param oldChannelID id of the previous channel the client used to be in + * @param newChannelID id of the current channel the client was kicked to. This is the id of the server default channel. + * @param visibility whether we can see the client. One of the values from the Visibility enum. + * @param kickerID id of the client that kicked the client. 0 if the server kicked the client. + * @param kickerName utf8 encoded c string containing the display name of the client initiating the kick + * @param kickerUniqueIdentifier utf8 encoded c string containing the identifier of the client initiating the kick + * @param kickMessage utf8 encoded c string containing the provided reason for the kick + */ + void (*onClientKickFromChannelEvent) (uint64 serverConnectionHandlerID, anyID clientID, uint64 oldChannelID, uint64 newChannelID, int visibility, anyID kickerID, const char* kickerName, const char* kickerUniqueIdentifier, const char* kickMessage); + + /** + * @brief called when a client was kicked from the server + * + * @param serverConnectionHandlerID specifies on which connection the callback was called + * @param clientID id of the client that was kicked + * @param oldChannelID id of the previous channel the client used to be in + * @param newChannelID always 0 + * @param visibility whether we can see the client. One of the values from the Visibility enum. + * @param kickerID id of the client that kicked the client. 0 if the server kicked the client. + * @param kickerName utf8 encoded c string containing the display name of the client initiating the kick + * @param kickerUniqueIdentifier utf8 encoded c string containing the identifier of the client initiating the kick + * @param kickMessage utf8 encoded c string containing the provided reason for the kick + */ + void (*onClientKickFromServerEvent) (uint64 serverConnectionHandlerID, anyID clientID, uint64 oldChannelID, uint64 newChannelID, int visibility, anyID kickerID, const char* kickerName, const char* kickerUniqueIdentifier, const char* kickMessage); + + /** + * @brief called for every connection using the identity after a call to ts3client_requestClientIDs. + * + * This is called multiple times for each identity queried. Once + * @param serverConnectionHandlerID specifies on which connection the callback was called + * @param uniqueClientIdentifier the public identity queried and used by the client + * @param clientID the id assigned to this client + * @param clientName the display name of this client + */ + void (*onClientIDsEvent) (uint64 serverConnectionHandlerID, const char* uniqueClientIdentifier, anyID clientID, const char* clientName); + + /** + * @brief called after onClientIDsEvent was called for every client using the queried identity. + * + * Once this callback is called, you know of all clients on the server that use the identity. + * + * @param serverConnectionHandlerID specifies on which connection the callback was called + */ + void (*onClientIDsFinishedEvent) (uint64 serverConnectionHandlerID); + + /** + * @brief called when the server was edited + * + * @param serverConnectionHandlerID specifies on which connection the callback was called + * @param editerID id of the client that edited the server + * @param editerName utf8 encoded c string containing the display name of the client editing the server + * @param editerUniqueIdentifier utf8 encoded c string containing the public identity of the client + */ + void (*onServerEditedEvent) (uint64 serverConnectionHandlerID, anyID editerID, const char* editerName, const char* editerUniqueIdentifier); + + /** + * @brief called whenever updates about changed server properties are received from the server. + * + * Happens after a call to ts3client_requestServerVariables but can also be called sporadically. + * + * @param serverConnectionHandlerID specifies on which connection the updated variables are available + */ + void (*onServerUpdatedEvent) (uint64 serverConnectionHandlerID); + + /** + * @brief called after an action was performed by us. Tells whether the action was successful or which error occurred. + * + * @param serverConnectionHandlerID specifies on which connection the callback was called + * @param errorMessage utf8 encoded c string describing the error + * @param error the error code the action finished with. One of the values from the @ref Ts3ErrorType enum. + * @param returnCode a c string identifying the action that caused this error. This is the same string given as returnCode to function calls that request an action on the server + * @param extraMessage utf8 encoded c string containing additional information if available. + */ + void (*onServerErrorEvent) (uint64 serverConnectionHandlerID, const char* errorMessage, unsigned int error, const char* returnCode, const char* extraMessage); + + /** + * @brief called when the server was stopped + * + * @param serverConnectionHandlerID specifies on which connection the callback was called + * @param shutdownMessage utf8 encoded c string containing the provided reason for the shutdown + */ + void (*onServerStopEvent) (uint64 serverConnectionHandlerID, const char* shutdownMessage); + + /** + * @brief called when a text message was received + * + * @param serverConnectionHandlerID specifies on which connection the callback was called + * @param targetMode identifies the type of the message. One of the values from the TextMessageTargetMode enum. + * @param toID the id of the recipient. Depends on the value of targetMode. a channel id for channel chat, own client id for private messages, 0 for server messages + * @param fromID id of the client that sent the message + * @param fromName utf8 encoded c string containing the display name of the client sending the message + * @param fromUniqueIdentifier utf8 encoded c string containing the public identity of the sending client + * @param message utf8 encoded c string containing the actual message + */ + void (*onTextMessageEvent) (uint64 serverConnectionHandlerID, anyID targetMode, anyID toID, anyID fromID, const char* fromName, const char* fromUniqueIdentifier, const char* message); + + /** + * @brief called when a client starts or stops talking. + * + * This event is only received for clients in our own channel and clients that whisper us + * + * @param serverConnectionHandlerID specifies on which connection the callback was called + * @param status Whether the client is talking or not. One of the values from the TalkStatus enum. + * @param clientID the client the event was called for + */ + void (*onTalkStatusChangeEvent) (uint64 serverConnectionHandlerID, int status, int isReceivedWhisper, anyID clientID); + + /** + * @brief called when someone whispers us that is not on the list of clients we accept whispers from. + * + * @param serverConnectionHandlerID specifies on which connection the callback was called + * @param clientID id of the client that tried to whisper us + * @sa ts3client_allowWhispersFrom + * @sa ts3client_setWhisperReceiveWhitelist + */ + void (*onIgnoredWhisperEvent) (uint64 serverConnectionHandlerID, anyID clientID); + + /** + * @brief called when updated connection properties for a client are available. + * + * This happens after a call to ts3client_requestConnectionInfo + * + * @param serverConnectionHandlerID specifies on which connection the callback was called + * @param clientID id of the client that updated properties are available for + */ + void (*onConnectionInfoEvent) (uint64 serverConnectionHandlerID, anyID clientID); + + /** + * @brief called after a call ts3client_requestServerConnectionInfo when the connection information for the server are available. + * + * Information can now be queried using ts3client_getServerConnectionVariableAsFloat and ts3client_getServerConnectionVariableAsUInt64 + * + * @param serverConnectionHandlerID specifies on which connection the callback was called + */ + void (*onServerConnectionInfoEvent) (uint64 serverConnectionHandlerID); + + /** + * @brief called when a channel was successfully subscribed by us + * + * @param serverConnectionHandlerID specifies on which connection the callback was called + * @param channelID id of the channel we subscribed to + */ + void (*onChannelSubscribeEvent) (uint64 serverConnectionHandlerID, uint64 channelID); + + /** + * @brief called after all channels we attempted to subscribe to are subscribed. + * + * @param serverConnectionHandlerID specifies on which connection the callback was called + */ + void (*onChannelSubscribeFinishedEvent) (uint64 serverConnectionHandlerID); + + /** + * @brief called after we unsubscribed from a channel + * + * @param serverConnectionHandlerID specifies on which connection the callback was called + * @param channelID id of the channel we unsubscribed from. Will no longer receive updates about clients in this channel. + */ + void (*onChannelUnsubscribeEvent) (uint64 serverConnectionHandlerID, uint64 channelID); + + /** + * @brief called after all channels we attempted to unsubscribe from are unsubscribed + * + * @param serverConnectionHandlerID specifies on which connection the callback was called + */ + void (*onChannelUnsubscribeFinishedEvent) (uint64 serverConnectionHandlerID); + + /** + * @brief called when the channel description of a channel has changed. + * + * @param serverConnectionHandlerID specifies on which connection the callback was called + * @param channelID the channel for which the description has changed + */ + void (*onChannelDescriptionUpdateEvent) (uint64 serverConnectionHandlerID, uint64 channelID); + + /** + * @brief called when a channel password was changed. Can be used to invalidate cached passwords + * previously stored for the channel. + * + * @param serverConnectionHandlerID specifies on which connection the callback was called + * @param channelID id of the channel the password was changed on + */ + void (*onChannelPasswordChangedEvent) (uint64 serverConnectionHandlerID, uint64 channelID); + + /** + * @brief called once the playback device was closed on a connection + * + * @param serverConnectionHandlerID specifies on which connection the callback was called + * @sa ts3client_initiateGracefulPlaybackShutdown + * @sa ts3client_closePlaybackDevice + */ + void (*onPlaybackShutdownCompleteEvent) (uint64 serverConnectionHandlerID); + + /** + * @brief called when the available devices changed + * + * @param modeID utf8 encoded c string describing the mode of the device + * @param playOrCap indicates whether the device is a capture or playback device + */ + void (*onSoundDeviceListChangedEvent) (const char* modeID, int playOrCap); + + /** + * @brief called before any effects are applied, allows access to individual client raw audio data + * + * @param serverConnectionHandlerID specifies on which connection the callback was called + * @param clientID id of the source client for the audio + * @param samples buffer of audio data for the client as 16 bit signed at 48kHz + * @param sampleCount how many audio frames are available in the buffer + * @param channels number of audio channels in the audio data + */ + void (*onEditPlaybackVoiceDataEvent) (uint64 serverConnectionHandlerID, anyID clientID, short* samples, int sampleCount, int channels); + + /** + * @brief called before audio data is mixed together into a single audio stream for playback, but after effects (3D positioning for example) have been applied. + * + * @param serverConnectionHandlerID specifies on which connection the callback was called + * @param clientID id of the source client for the audio + * @param samples buffer of audio data for the client as 16 bit signed at 48kHz + * @param sampleCount how many audio frames are available in the buffer + * @param channels number of audio channels in the audio data + * @param channelSpeakerArray Array with an entry for each channel in the buffer, defining the speaker each channel represents. see SPEAKER_* defines in public_definitions.h + * @param channelFillMask a bit mask of SPEAKER_* that defines which of the channels in the buffer have audio data. Be sure to set the corresponding flag when adding audio to previously empty channels in the buffer. + */ + void (*onEditPostProcessVoiceDataEvent) (uint64 serverConnectionHandlerID, anyID clientID, short* samples, int sampleCount, int channels, const unsigned int* channelSpeakerArray, unsigned int* channelFillMask); + + /** + * @brief called after mixing individual client audio together but before sending it to playback device. + * + * Last chance to access/modify audio data before it gets sent to the playback device. + * + * @param serverConnectionHandlerID specifies on which connection the callback was called + * @param samples buffer of audio data as 16 bit signed at 48kHz + * @param sampleCount how many audio frames are available in the buffer + * @param channels how many audio channels are available in the buffer + * @param channelSpeakerArray Array with an entry for each channel in the buffer, defining the speaker each channel represents. See SPEAKER_* defines in public_definitions.h + * @param channelFillMask a bit mask of SPEAKER_* that defines which of the channels in the buffer have audio data. + */ + void (*onEditMixedPlaybackVoiceDataEvent) (uint64 serverConnectionHandlerID, short* samples, int sampleCount, int channels, const unsigned int* channelSpeakerArray, unsigned int* channelFillMask); + + /** + * @brief called after audio data was aquired from the capture device, without any pre processing applied. Allows access to raw audio data. + * + * @param serverConnectionHandlerID specifies on which connection the callback was called + * @param samples buffer of audio data + * @param sampleCount how many audio frames are available in the buffer + * @param channels how many audio channels are available in the buffer + * @param flags allows to mute the audio stream, set LSB to 1 to mute the audio. + */ + void (*onEditCapturedVoiceDataPreprocessEvent) (uint64 serverConnectionHandlerID, short* samples, int sampleCount, int channels, int* flags); + + /** + * @brief called after pre processing has been applied to recorded voice data, before it is sent to the server. + * + * This allows access to or modification of captured data from the recording device. + * + * @param serverConnectionHandlerID specifies on which connection the callback was called + * @param samples buffer of audio data as 16 bit signed at 48kHz + * @param sampleCount how many audio frames are available in the buffer + * @param channels how many audio channels are available in the buffer + * @param edited bitMask indicating whether you modified the buffer. Set LSB to 1 if you modified the buffer. Bit 2 indicates whether or not this buffer will be sent to the server. + */ + void (*onEditCapturedVoiceDataEvent) (uint64 serverConnectionHandlerID, short* samples, int sampleCount, int channels, int* edited); + + /** + * @brief called to calculate the volume attenuation for the distance in 3D positioning of clients + * + * @param serverConnectionHandlerID specifies on which connection the callback was called + * @param clientID id of the client for which the position is calculated + * @param distance the distance from own client to the client + * @param volume the volume calculated by the client lib. Can be modified in the callback. + */ + void (*onCustom3dRolloffCalculationClientEvent) (uint64 serverConnectionHandlerID, anyID clientID, float distance, float* volume); + + /** + * @brief called to calculate the volume attenuation for the distance in 3D positioning of wave files + * + * @param serverConnectionHandlerID specifies on which connection the callback was called + * @param waveHandle identifies the wave file to calculate the volume for. A handle previously created with @ref ts3client_playWaveFileHandle + * @param distance the distance from own client to the source of the wave file + * @param volume the volume of the wave file calculated by the client lib. Can be modified in the callback. + * @sa ts3client_playWaveFileHandle + */ + void (*onCustom3dRolloffCalculationWaveEvent) (uint64 serverConnectionHandlerID, uint64 waveHandle, float distance, float* volume); + + /** + * @brief called for every log message if the client lib was initialized with user logging + * + * @param logmessage utf8 encoded c string containing the text to log + * @param logLevel indicates severity of the message. One of the values from the LogLevel enum + * @param logChannel utf8 encoded c string containing the category this message is logged under + * @param logID the connection handler this message was logged on + * @param completeLogString utf8 encoded c string containing the complete log message containing all other parameters for convenience + */ + void (*onUserLoggingMessageEvent) (const char* logmessage, int logLevel, const char* logChannel, uint64 logID, const char* logTime, const char* completeLogString); + + /** + * @brief called for every packet to be sent to the server. Used to implement custom cryptography. + * + * Only implement if you need custom encryption of network traffic. Replaces default encryption. + * If implemented Encryption and Decryption must be implemented the same way on both server and client. + * + * @param dataToSend pointer to a byte array of data to be encrypted. Must not be freed. Write encrypted data to array. + * Replace array pointer with pointer to own buffer if you need more space. Need to take care of freeing your own memory yourself. + * @param sizeOfData pointer to the size of the data array. + */ + void (*onCustomPacketEncryptEvent) (char** dataToSend, unsigned int* sizeOfData); + + /** + * @brief called for every packet received from the server. Used to implement custom cryptography. + * + * Only implement if you need custom encryption of network traffic. Replaces default encryption. + * If implemented Encryption and Decryption must be implemented the same way on both server and client. + * + * @param dataReceived pointer to byte array of data to decrypt. Must not be freed. Write decrypted data to the array if large enough. + * Replace array pointer with pointer to own buffer if decrypted data exceeds the array size. Must take care to free own memory. + * @param sizeOfData pointer to the size of the data array. + */ + void (*onCustomPacketDecryptEvent) (char** dataReceived, unsigned int* dataReceivedSize); + + void (*onProvisioningSlotRequestResultEvent) (unsigned int error, uint64 requestHandle, const char* connectionKey); + + /** + * @brief called during the connection initialization, allows to check whether the server identifier is the one you expect. + * + * @param serverConnectionHandlerID specifies on which connection the callback was called + * @param ServerUniqueIdentifier utf8 encoded c string containing the server identifier of the server connecting to + * @param cancelConnect allows to cancel the connection. Set variable pointed to to 1 to abort the connection. + */ + void (*onCheckServerUniqueIdentifierEvent) (uint64 serverConnectionHandlerID, const char* ServerUniqueIdentifier, int* cancelConnect); + + /** + * @brief called when a channel password is set. + * + * Can be used to implement custom password checks against external sources (e.g. LDAP). + * + * @param serverConnectionHandlerID specifies on which connection the callback was called + * @param plaintext utf8 encoded c string containing the plaintext password as entered by the user + * @param encryptedText output parameter. Fill with the encrypted password / password hash. Must be an utf8 encoded c string (zero terminated). + * Must not be larger than the size specified by the encryptedTextByteSize parameter. + * @param encryptedTextByteSize the maximum amount of bytes (including trailing zero byte) that may be written to encryptedText parameter + */ + void (*onClientPasswordEncrypt) (uint64 serverConnectionHandlerID, const char* plaintext, char* encryptedText, int encryptedTextByteSize); + + /** + * @brief called when file transfers finish or terminate with an error + * + * @param transferID identifies the file transfer the callback was called for. As created by @ref ts3client_requestFile or @ref ts3client_sendFile + * @param status indicates success status or error reason. One of the values from the @ref Ts3ErrorType enum. + * @param statusMessage utf8 encoded c string containing a human readable description of the status message + * @param remotefileSize size of the file in bytes at the source of the transfer. + * @param serverConnectionHandlerID specifies the connection the transfer was started on + * @sa ts3client_sendFile + * @sa ts3client_requestFile + */ + void (*onFileTransferStatusEvent) (anyID transferID, unsigned int status, const char* statusMessage, uint64 remotefileSize, uint64 serverConnectionHandlerID); + + /** + * @brief called as an answer to ts3client_requestFileList. Called once for every file in the requested path, providing file information. + * + * Followed by a onFileList_FinishedEvent callback after this callback was called for the last file in the requested path. + * + * @param serverConnectionHandlerID specifies on which connection the callback was called + * @param channelID the channel in which the file is located + * @param path the folder in which this file or directory is located + * @param name the name of the file or directory this event is called for + * @param size file size in bytes. 0 if this event describes a directory + * @param datetime unix timestamp of when this file was last modified + * @param type whether the entry described is a directory or a file. One of the values from the FileTransferType enum. + * @param incompleteSize number of bytes that have already been transmitted. If not equal to size then this file is still being transmitted or the transfer was aborted. + * @param returnCode allows to identify which call to ts3client_requestFileList caused this event to be fired. Same as given to the ts3client_requestFileList call. Can be NULL + */ + void (*onFileListEvent) (uint64 serverConnectionHandlerID, uint64 channelID, const char* path, const char* name, uint64 size, uint64 datetime, int type, uint64 incompletesize, const char* returnCode); + + /** + * @brief called after onFileListEvent was called for all directories / files in a given path. + * + * This signifies that you now know of all files and directories in the path requested. + * + * @param serverConnectionHandlerID specifies on which connection the callback was called + * @param channelID the channel for which the file list is now complete + * @param path the path within the channel that files and directories were requested for. + */ + void (*onFileListFinishedEvent) (uint64 serverConnectionHandlerID, uint64 channelID, const char* path); + + /** + * @brief called after a call to ts3client_requestFileInfo providing the requested information about a file. + * + * @param serverConnectionHandlerID specifies on which connection the callback was called + * @param channelID the channel in which the file resides + * @param name utf8 encoded c string containing the absolute path within the channel, including the file / directory name. + * @param size the size of the file in bytes + * @param datetime unix timestamp for the last time the file was modified + */ + void (*onFileInfoEvent) (uint64 serverConnectionHandlerID, uint64 channelID, const char* name, uint64 size, uint64 datetime); + + /** + * @brief called after a call to ts3client_getChatLoginToken providing the requested login token for the chat server associated with this teamspeak server + * + * @param serverConnectionHandlerID specifies on which connection the callback was called + * @param token THe requested chat login token + */ + void (*onChatLoginTokenEvent) (uint64 serverConnectionHandlerID, const char* token); + + /** + * @brief called after a call to ts3client_getAuthenticationToken providing the requested authentication token for the virtual server + * + * @param serverConnectionHandlerID specifies on which connection the callback was called + * @param token THe requested authentication token + */ + void (*onAuthenticationTokenEvent) (uint64 serverConnectionHandlerID, const char* token); +}; //END OF ClientUIFunctions + +/*Memory management*/ + +/** + * @brief Releases memory allocated by the client library + * + * For every function that has output parameters which take pointers to memory (e.g. char**) + * the client library will allocate sufficient memory for you, however you need to take care + * of releasing the memory by passing the variable to this function. + * + * @param pointer pointer to memory allocated by the client library +*/ +EXPORTDLL unsigned int ts3client_freeMemory(void* pointer); + +/*Construction and Destruction*/ + +/** + * @brief initializes the client library and defines callback functions + * + * This is the first function you need to call, before this all calls to the client library will fail. In this call you will also set the functions you would like to have called when + * certain changes happen on the client side as well as on connected servers. + * + * @param functionPointers defines which functions in your code are to be called on specific events. Zero initialize it and assign the desired function to call to the respective members of the struct + * @param functionRarePointers similar to the functionPointers parameter. These are not available in the SDK, so SDK users should pass a nullptr here. + * @param usedLogTypes a combination of values from the @ref LogTypes enum. Specifies which type(s) of logging you would like to use. + * @param logFileFolder path in which to create log files + * @param resourcesFolder path to the directory in which the soundbackends folder is located. Required to be able to load the sound backends and process audio. + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason +*/ +EXPORTDLL unsigned int ts3client_initClientLib(const struct ClientUIFunctions* functionPointers, const struct ClientUIFunctionsRare* functionRarePointers, int usedLogTypes, const char* logFileFolder, const char* resourcesFolder); + +/** + * @brief destroys the client library. Must not be called from within a callback. + * + * This is the last function to call, after calling this function you will no longer be able to use client library functions. + * + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason +*/ +EXPORTDLL unsigned int ts3client_destroyClientLib(); + +/** + * @brief Get the version string of the client library + * + * @param result Pointer to a char* variable that the client library will allocate memory for. + * If the return value is ERROR_ok the memory was allocated and the variable pointed to will contain the client library version. + * You need to free the variable pointed to by using @ref ts3client_freeMemory + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason +*/ +EXPORTDLL unsigned int ts3client_getClientLibVersion(char** result); + +/** + * @brief Get the version number of the client library + * + * @param result Pointer to a variable to store the client library version number into + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason +*/ +EXPORTDLL unsigned int ts3client_getClientLibVersionNumber(uint64* result); + +/** + * @brief Creates a new server connection handler to connect to servers + * + * A connection handler is what handles and identifies server connections to the client library. There can be many of these at the same time + * and every single one of them can be connected to any server. The client library identifies them by the id placed in the result param. + * When you receive callbacks, or need to change things, on a specific server you will also specify which server you would like to use by + * providing the corresponding serverConnectionHandlerId to the client library function. + * + * @param port the local port to use. Specify 0 to use an ephemeral port. + * @param result Address of a variable to store the id of the connection handler in. Use this to reference the connection handler in future calls to client lib functions. + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason +*/ +EXPORTDLL unsigned int ts3client_spawnNewServerConnectionHandler(int port, uint64* result); + +/** + * @brief Destroys a connection handler + * + * After destruction the connection handler is invalid and cannot be used any longer. Must not be called from within a callback! + * + * @param serverConnectionHandlerID which connection handler to destroy + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason +*/ +EXPORTDLL unsigned int ts3client_destroyServerConnectionHandler(uint64 serverConnectionHandlerID); + +/*Identity management*/ + +/** + * @brief Create a new identity to use for connecting to a server + * + * Identities identify a client to the server. The identity should be stored and reused for sessions by the same user. + * + * @param result Address of a variable to store the identity in. + * Memory is allocated by the client lib and caller must free it using @ref ts3client_freeMemory + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason +*/ +EXPORTDLL unsigned int ts3client_createIdentity(char** result); + +/** + * @brief Get the unique client identifier from an identity + * + * @param identityString The identity to produce the unique identifier for, as created by ts3client_createIdentity + * @param result Pointer to a variable to store the unique client identifier in. + * Memory is allocated by the client lib and caller must free it using @ref ts3client_freeMemory + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason +*/ +EXPORTDLL unsigned int ts3client_identityStringToUniqueIdentifier(const char* identityString, char** result); + +/*sound*/ + +/** + * @brief Retrieve available playback devices as reported by the operating system + * + * @param modeID a string indicating a valid playback mode as retrieved by ts3client_getPlaybackModeList or + * ts3client_getDefaultPlaybackMode + * @param result address of a variable that receives a NULL terminated array like `{{char* deviceName, char* deviceId, + * char* interfaceName char* description, char* fromFactor} ..., NULL}` on windows, `{{char* deviceName, char* + * deviceId}, ..., NULL}` on other platforms. Memory is allocated by the client lib and caller must free individual strings, array members + * and the array itself using @ref ts3client_freeMemory + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason + */ +EXPORTDLL unsigned int ts3client_getPlaybackDeviceList(const char* modeID, char**** result); + +/** + * @brief Retrieve available recording devices as reported by the operating system + * + * @param modeID a string indicating a valid capture mode as retrieved by ts3client_getCaptureModeList or + * ts3client_getDefaultCaptureMode + * @param result address of a variable that receives a NULL terminated array like `{{char* deviceName, char* deviceId, + * char* interfaceName char* description, char* fromFactor} + * ..., NULL}` on windows, `{{char* deviceName, char* deviceId}, ..., NULL}` on other platforms. + * Memory is allocated by the client lib and caller must free individual strings and the array itself using @ref + * ts3client_freeMemory + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason + */ +EXPORTDLL unsigned int ts3client_getCaptureDeviceList(const char* modeID, char**** result); + +/** + * @brief Retrieve available playback modes + * + * @param result address of a variable that receives a NULL terminated array of utf8 encoded c strings of available playback modes. + * Memory is allocated by the client lib and caller must free individual strings and the array itself using @ref ts3client_freeMemory + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason +*/ +EXPORTDLL unsigned int ts3client_getPlaybackModeList(char*** result); + +/** + * @brief Retrieve available capture modes + * + * @param result address of a variable that receives a NULL terminated array of utf8 encoded c strings of available capture modes. + * Memory is allocated by the client lib and caller must free individual strings and the array itself using @ref ts3client_freeMemory + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason +*/ +EXPORTDLL unsigned int ts3client_getCaptureModeList(char*** result); + +/** + * @brief Get the current operating system defined default playback device for the indicated mode + * + * The operating system may define different devices for different modes. + * + * @param modeID a string indicating a valid playback mode as retrieved by @ref ts3client_getPlaybackModeList or @ref ts3client_getDefaultPlayBackMode + * @param result Address of a variable that receives a NULL terminated array of two c strings like `{char* deviceName, char* deviceID, NULL}` + * Memory is allocated by the client lib and caller must free individual strings and the array itself using @ref ts3client_freeMemory + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason +*/ +EXPORTDLL unsigned int ts3client_getDefaultPlaybackDevice(const char* modeID, char*** result); + +/** + * @brief Get the current operating system defined default capture device for the indicated mode + * + * The operating system may define different devices for different modes. + * + * @param modeID a string indicating a valid capture mode as retrieved by @ref ts3client_getCaptureModeList or @ref ts3client_getDefaultCaptureMode + * @param result Address of a variable that receives a NULL terminated array of two c strings like `{char* deviceName, char* deviceID, NULL}` + * Memory is allocated by the client lib and both the array and its individual members must be freed by caller using @ref ts3client_freeMemory + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason +*/ +EXPORTDLL unsigned int ts3client_getDefaultCaptureDevice(const char* modeID, char*** result); + +/** + * @brief Retrieve the current default playback mode + * + * @param result Address of a char array to receive the c string indicating the default mode. + * Memory is allocated by the client lib and must be freed by caller using @ref ts3client_freeMemory + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason +*/ +EXPORTDLL unsigned int ts3client_getDefaultPlayBackMode(char** result); + +/** + * @brief Retrieve the current default capture mode + * + * @param result Address of a char array to receive a c string indicating the default mode. + * Memory is allocated by the client lib and must be freed by caller using @ref ts3client_freeMemory + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason +*/ +EXPORTDLL unsigned int ts3client_getDefaultCaptureMode(char** result); + +/** + * @brief initializes a playback device for a connection handler + * + * Call this function to start audio playback of TeamSpeak audio on a connection + * + * @param serverConnectionHandlerID the connection handler on which to initialize the specified device + * @param modeID utf8 encoded c-string containing the mode to open the device in. Pass an empty string to use the default mode. See @ref ts3client_getPlaybackModeList and @ref ts3client_getDefaultPlayBackMode for a list of valid modes. + * @param playbackDevice utf8 encoded c-string containing the device name of the device to open. Pass an empty string to use the default device. See @ref ts3client_getPlaybackDeviceList and @ref ts3client_getDefaultPlaybackDevice for valid devices. + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason +*/ +EXPORTDLL unsigned int ts3client_openPlaybackDevice(uint64 serverConnectionHandlerID, const char* modeID, const char* playbackDevice); + +/** + * @brief initializes a capture device for a connection handler + * + * Call this function to start consuming audio from the specified device and send it to the server + * + * @param serverConnectionHandlerID the connection handler on which to open the capture device + * @param modeID utf8 encoded c-string containing the mode in which to open the device. Pass an empty string to use the default mode. See @ref ts3client_getCaptureModeList and @ref ts3client_getDefaultCaptureMode for a list of valid modes. + * @param captureDevice utf8 encoded c-string containing the device name of the device to open. Pass an empty string to use the default device. See @ref ts3client_getCaptureDeviceList and @ref ts3client_getDefaultCaptureDevice for a list or valid devices. + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason +*/ +EXPORTDLL unsigned int ts3client_openCaptureDevice(uint64 serverConnectionHandlerID, const char* modeID, const char* captureDevice); + +/** + * @brief retrieve the device name that is currently used to play audio on a server + * + * @param serverConnectionHandlerID the connection handler to retrieve the active playback device on + * @param result address of a variable receiving a c string of the device name currently in use. + * Memory is allocated by the client lib and must be freed by caller using @ref ts3client_freeMemory + * @param isDefault address of a variable receiving whether the device in use is the default device. Pass NULL if you don't need the information + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason +*/ +EXPORTDLL unsigned int ts3client_getCurrentPlaybackDeviceName(uint64 serverConnectionHandlerID, char** result, int* isDefault); + +/** + * @brief retrieve the mode the current playback device on a server is using + * + * @param serverConnectionHandlerID the connection handler to retrieve the playback mode on + * @param result address of a variable receiving a c string of the playback mode currently in use. + * Memory is allocated by the client lib and must be freed by caller using @ref ts3client_freeMemory + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason +*/ +EXPORTDLL unsigned int ts3client_getCurrentPlayBackMode(uint64 serverConnectionHandlerID, char** result); + +/** + * @brief retrieve the device name that is currently used to capture audio on a server + * + * @param serverConnectionHandlerID the connection handler to retrieve the active capture device on + * @param result address of a variable receiving a c string of the device name currently in use. + * Memory is allocated by the client lib and must be freed by caller using @ref ts3client_freeMemory + * @param isDefault address of a variable receiving whether the device in use is the default device. Pass NULL if you don't need the information + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason +*/ +EXPORTDLL unsigned int ts3client_getCurrentCaptureDeviceName(uint64 serverConnectionHandlerID, char** result, int* isDefault); + +/** + * @brief retrieve the mode the current capture device on a server is using + * + * @param serverConnectionHandlerID the connection handler to retrieve the capture mode on + * @param result address of a variable receiving a c string of the capture mode currently in use. + * Memory is allocated by the client lib and must be freed by caller using @ref ts3client_freeMemory + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason +*/ +EXPORTDLL unsigned int ts3client_getCurrentCaptureMode(uint64 serverConnectionHandlerID, char** result); + +/** + * @brief Close the playback device after all currently playing sounds are done playing + * + * A more user friendly way of closing a playback device. The client lib will monitor and ensure + * that any sounds that have already started playing have completely played before closing the device. + * New sounds are not allowed to be played after calling this function. + * This function will return right away, regardless of whether the device has been closed already or not. + * + * @param serverConnectionHandlerID the connection handler on which to shut down the playback device + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason +*/ +EXPORTDLL unsigned int ts3client_initiateGracefulPlaybackShutdown(uint64 serverConnectionHandlerID); + +/** + * @brief Immediately close the current playback device on a connection handler. + * + * This will instantly shut down the device. Any sounds currently playing will be interrupted. + * + * @param serverConnectionHandlerID the connection handler on which to shut down the playback device + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason +*/ +EXPORTDLL unsigned int ts3client_closePlaybackDevice(uint64 serverConnectionHandlerID); + +/** + * @brief Immediately close the current capture device on a connection handler. + * + * This will instantly shut down the device. + * + * @param serverConnectionHandlerID the connection handler on which to shut down the capture device + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason +*/ +EXPORTDLL unsigned int ts3client_closeCaptureDevice(uint64 serverConnectionHandlerID); + +/** + * @brief Activate a previously opened capture device on a server connection. + * + * Only one server connection can receive audio from its capture device at any given time. This + * function will set the server connection handler that is going to receive the audio from the + * capture device opened on that connection. + * + * @param serverConnectionHandlerID the connection handler on which to shut down the playback device + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason +*/ +EXPORTDLL unsigned int ts3client_activateCaptureDevice(uint64 serverConnectionHandlerID); + +/** + * @brief Play a local wave file on the playback device of the connection handler + * + * @param serverConnectionHandlerID the connection handler on which to play the file. Effectively sets the playback device. + * @param path the full path of the wave file on the local file system + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason +*/ +EXPORTDLL unsigned int ts3client_playWaveFile(uint64 serverConnectionHandlerID, const char* path); + +/** + * @brief Play a local wave file on the playback device of the connection handler. + * + * This is a more advanced version of ts3client_playWaveFile as it gives you a handle which can be + * used to stop, pause, resume or even loop the wave file. + * + * @param serverConnectionHandlerID the connection handler on which to play the file. Effectively sets the playback device. + * @param path the full path of the wave file on the local file system + * @param loop Boolean value defining whether or not to loop the wave file until the handle is paused or stopped + * @param waveHandle address of a variable to receive the handle. Use the handle to stop, pause or resume the wave playback. + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason +*/ +EXPORTDLL unsigned int ts3client_playWaveFileHandle(uint64 serverConnectionHandlerID, const char* path, int loop, uint64* waveHandle); + +/** + * @brief Pauses or resumes playback of a wave file handle retrieved by ts3client_playWaveFileHandle. + * + * Audio will be stopped at whatever location it is currently at and resumed from its paused location. + * + * @param serverConnectionHandlerID the connection handler on which the file is playing. + * @param waveHandle a wave handle on the specified connection handler as retrieved by ts3client_playWaveFileHandle + * @param pause Boolean value defining whether to pause or resume the waveHandle + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason +*/ +EXPORTDLL unsigned int ts3client_pauseWaveFileHandle(uint64 serverConnectionHandlerID, uint64 waveHandle, int pause); + +/** + * @brief Stops playback of, closes the wave file and invalidates the handle retrieved by ts3client_playWaveFileHandle + * + * @param serverConnectionHandlerID the connection handler on which the file is playing. + * @param waveHandle a wave handle on the specified connection handler as retrieved by ts3client_playWaveFileHandle + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason + * @sa ts3client_playWaveFileHandle + */ +EXPORTDLL unsigned int ts3client_closeWaveFileHandle(uint64 serverConnectionHandlerID, uint64 waveHandle); + +/** + * @brief create a new software device to be used for playback and/or capture. + * + * This allows you to create custom devices for implementing your own audio capture or playback. + * For capture devices you will need to regularly provide audio data via the @ref ts3client_processCustomCaptureData function. + * For playback devices you will need to regularly aquire audio data via the @ref ts3client_acquireCustomPlaybackData function. + * + * @param deviceID a unique string by which you will refer to this audio device when opening devices ore removing it. + * @param deviceDisplayName custom display string for your device. Not required to be unique, you can freely choose this. + * @param capFrequency The frequency of the capture device. Determines the frequency the audio you're passing in to @ref ts3client_processCustomCaptureData is expected to be in when using this device. + * @param capChannels The amount of channels the audio source on this device has. Determines the number of audio channels the data you're passing to @ref ts3client_processCustomCaptureData is expected to have when using this device. + * @param playFrequency Determines which frequency the audio you're getting out of @ref ts3client_acquireCustomPlaybackData has when using this device. + * @param playChannels Determines the number of audio channels of the audio you're getting out of @ref ts3client_acquireCustomPlaybackData has when using this device. + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason +*/ +EXPORTDLL unsigned int ts3client_registerCustomDevice(const char* deviceID, const char* deviceDisplayName, int capFrequency, int capChannels, int playFrequency, int playChannels); + +/** + * @brief Removes a custom audio device previously registered. + * + * @param deviceID the deviceID of the custom device to remove. Must be a deviceID previously passed to a @ref ts3client_registerCustomDevice call. + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason +*/ +EXPORTDLL unsigned int ts3client_unregisterCustomDevice(const char* deviceID); + +/** + * @brief Provide audio data for a registered custom device. + * + * When using custom devices, you're expected to call this function regularly to provide your audio data to the client lib for processing and sending it to the server. + * The audio will be sent to the connection handler that currently has the specified custom device active (if any). + * The client lib will read captureChannels * samples * sizeof(short) bytes of data from the buffer. + * + * @param deviceName the deviceID for which you're providing audio data. Must be a deviceID previously passed to a @ref ts3client_registerCustomDevice call. + * @param buffer pointer to the beginning of the raw audio data for the device. Caller must ensure that enough data is present in the buffer (samples * channel count of the audio device). + * @param samples the number of audio frames in the buffer + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason +*/ +EXPORTDLL unsigned int ts3client_processCustomCaptureData(const char* deviceName, const short* buffer, int samples); + +/** + * @brief Retrieve playback data for the specified device from the client lib + * + * When using custom playback devices you're expected to call this function regularly. + * + * @param deviceName the deviceID from which to retrieve audio data. Must be a deviceID previously passed to a @ref ts3client_registerCustomDevice call. + * @param buffer address in which to write the sound data that is pending playback. Caller must allocate sufficient memory (samples * channels of the audio device). + * @param samples how many audio frames to retrieve. + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason. + * May return ERROR_sound_no_data meaning no sound is currently played on the device. No data has been written to the buffer. +*/ +EXPORTDLL unsigned int ts3client_acquireCustomPlaybackData(const char* deviceName, short* buffer, int samples); + +/** + * @brief Route captured audio directly to the playback device rather than through the network. + * + * Enable or disable local test mode. Enabling will no longer send audio data to the server, instead it will + * be routed directly to the playback device. This allows a user to receive direct feedback from their own + * audio transmission, allowing easier adjustments to audio settings. + * + * @param serverConnectionHandlerID the connection handler on which to enable or disable test mode. Determines the audio devices used. + * @param status Boolean value either enabling test mode or disabling it. + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason +*/ +EXPORTDLL unsigned int ts3client_setLocalTestMode(uint64 serverConnectionHandlerID, int status); + +/** + * @brief Flags the client as recording received audio transmissions. + * + * This does NOT cause any recording to take place, it merely informs other clients that this client is + * actually recording the conversation. + * + * @param serverConnectionHandlerID the connection handler on which to flag this client for recording. + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason +*/ +EXPORTDLL unsigned int ts3client_startVoiceRecording(uint64 serverConnectionHandlerID); + +/** + * @brief Flags the client as no longer recording audio transmissions. + * + * Unsets the flag set by ts3client_startVoiceRecording causing other clients to no longer mark this + * client as recording the conversation. + * + * @param serverConnectionHandlerID the connection handler on which to unset the recording flag for this client. + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason +*/ +EXPORTDLL unsigned int ts3client_stopVoiceRecording(uint64 serverConnectionHandlerID); + +/** + * @brief Allow another client to whisper us. + * + * Adds the specified other client on the server to whisper us. Prior to this call whispers from other clients + * are ignored and no audio data will be made available from whispers. Can be undone using @ref ts3client_removeFromAllowedWhispersFrom + * + * @param serverConnectionHandlerID the connection handler for the server on which the client specified by clID is located. + * @param clID the client id of another client which we want to receive whispers from. + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason + * @sa ts3client_setWhisperReceiveWhitelist + * @sa ts3client_removeFromAllowedWhispersFrom +*/ +EXPORTDLL unsigned int ts3client_allowWhispersFrom(uint64 serverConnectionHandlerID, anyID clID); + +/** + * @brief Removes a client from the allowed whisper list. + * + * Removes the specified other client on the server from the allowed whisperer list. After this call no more audio + * is made available when receiving whispers from the specified client. The opposite of @ref ts3client_allowWhispersFrom + * + * @param serverConnectionHandlerID the connection handler for the server on which the client specified by clID is located. + * @param clID the client id of another client which we do not want to receive whispers from anymore. + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason + * @sa ts3client_setWhisperReceiveWhitelist + * @sa ts3client_allowWhispersFrom +*/ +EXPORTDLL unsigned int ts3client_removeFromAllowedWhispersFrom(uint64 serverConnectionHandlerID, anyID clID); + +/** + * @brief Retrieve the list of clients we allow to whisper us + * + * @since 3.0.9.0 + * @param serverConnectionHandlerID the connection handler for which to retrieve the list of clients. + * @param result Address of an array of anyID which receives the list of clients we are allowing whispers from. + * Memory is allocated by the client lib and caller must free the array using @ref ts3client_freeMemory + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason + * @sa ts3client_setWhisperReceiveWhitelist +*/ +EXPORTDLL unsigned int ts3client_getWhisperReceiveWhitelist(uint64 serverConnectionHandlerID, anyID** result); + +/** + * @brief Check if we allow receiving whispers from a client + * + * @since 3.0.9.0 + * @param serverConnectionHandlerID the connection handler for the server on which the client specified by clID is located. + * @param clientID the client id of the client to check. + * @param result address of a variable to receive the boolean status on whether or not we allow whisper from the specified client. + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason +*/ +EXPORTDLL unsigned int ts3client_isWhisperReceiveWhitelisted(uint64 serverConnectionHandlerID, anyID clientID, int* result); + +/** + * @brief Set the list of clients we allow to whisper us + * + * @since 3.0.9.0 + * @param serverConnectionHandlerID the connection handler on which to set the list of clients. + * @param clientIDs NULL terminated array of client ids that we want to allow receiving whispers from. + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason + * @sa ts3client_getWhisperReceiveWhitelist + * @sa ts3client_allowWhispersFrom +*/ +EXPORTDLL unsigned int ts3client_setWhisperReceiveWhitelist(uint64 serverConnectionHandlerID, anyID* clientIDs); + +/* 3d sound positioning */ +/** + * @brief Set position, orientation and velocity of own client in 3D space + * + * @param serverConnectionHandlerID the connection handler for which to set the specified 3D settings. + * @param position 3D position of own client, pass NULL to ignore. + * @param forward Forward orientation. Vector must be of unit length and perpendicular to the up vector. Pass NULL to ignore. + * @param up Upward orientation. Vector must be of unit length and perpendicular to the forward vector. Pass NULL to ignore. + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason +*/ +EXPORTDLL unsigned int ts3client_systemset3DListenerAttributes(uint64 serverConnectionHandlerID, const TS3_VECTOR* position, const TS3_VECTOR* forward, const TS3_VECTOR* up); + +/** + * @brief Set the 3D position of a wave handle as retrieved by ts3client_playWaveFileHandle + * + * @param serverConnectionHandlerID the connection handler of the wave handle + * @param waveHandle a valid wave Handle as retrieved by ts3client_openWaveFileHandle. Specifies the sound file for which to adjust the position + * @param position the position the wave file should be played from + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason + * @sa ts3client_playWaveFileHandle +*/ +EXPORTDLL unsigned int ts3client_set3DWaveAttributes(uint64 serverConnectionHandlerID, uint64 waveHandle, const TS3_VECTOR* position); + +/** + * @brief Change 3D sound attenuation and distance settings + * + * @param serverConnectionHandlerID the connection handler for which to adjust the settings. + * @param distanceFactor relative distance factor in meters. Default is 1.0. Use to adjust the distance between two @ref TS3_VECTOR. Distance on x axis in meters = (a.x - b.x) * distanceFactor + * @param rolloffScale Defines how fast sound volume will attenuate with distance. A higher value will cause sound to be toned down faster with increasing distance. + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason +*/ +EXPORTDLL unsigned int ts3client_systemset3DSettings(uint64 serverConnectionHandlerID, float distanceFactor, float rolloffScale); + +/** + * @brief Adjusts other clients position in 3D space + * + * @param serverConnectionHandlerID the connection handler for the server on which the client specified by clID is located. + * @param clientID the client id of the other client we want to adjust the position of. + * @param position the desired position in 3D space of the other client + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason +*/ +EXPORTDLL unsigned int ts3client_channelset3DAttributes(uint64 serverConnectionHandlerID, anyID clientID, const TS3_VECTOR* position); + +/*preprocessor*/ +/** + * @brief Retrieve floating point preprocessor configuration values + * + * @param serverConnectionHandlerID the connection handler for which to retrieve the value + * @param ident the name of the preprocessor value to retrieve + * @param result address of a variable to receive the specified configuration value + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason +*/ +EXPORTDLL unsigned int ts3client_getPreProcessorInfoValueFloat(uint64 serverConnectionHandlerID, const char* ident, float* result); + +/** + * @brief Retrieve preprocessor configuration values + * + * Preprocessor settings are bound to a capture device. You must open a capture device on the specified connection handler before + * calling this function. + * + * @param serverConnectionHandlerID the connection handler for which to retrieve the configuration value + * @param ident the name of the preprocessor configuration to retrieve + * @param result address of a variable to receive a c string with the value of the specified preprocessor configuration. + * Memory is allocated by the client lib and must be freed by caller using @ref ts3client_freeMemory + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason +*/ +EXPORTDLL unsigned int ts3client_getPreProcessorConfigValue(uint64 serverConnectionHandlerID, const char* ident, char** result); + +/** + * @brief Set preprocessor configuration values + * + * Preprocessor settings are bound to a capture device. You must open a capture device on the specified connection handler before + * calling this function. + * + * @param serverConnectionHandlerID the connection handler for which to retrieve the configuration value + * @param ident the name of the preprocessor configuration to retrieve + * @param value the new value to set + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason +*/ +EXPORTDLL unsigned int ts3client_setPreProcessorConfigValue(uint64 serverConnectionHandlerID, const char* ident, const char* value); + +/** + * @brief Indicates to the client that a key press has occurred and that it should run the typing attenuation algoritm. + * + * This will hint to the client lib that the typing attenuation code should be applied to the currently processed chunk + * of audio data. + * Effectively sets a flag in the client lib to run the code for the currently processed chunk of audio data. The client + * will reset this flag after the current audio chunk has been completed. + * + * @since 3.0.9.0 + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason +*/ +EXPORTDLL unsigned int ts3client_setKeyPressedDuringChunk(); + +/** + * @brief Gets global client configuration values. + * + * ident can have the following values: + * input_deactivation_delay_ms: Number of milliseconds to continue transmitting after PTT key was released. + * input_deactivation_delay_active: Whether the above described delay is active or not. + * + * @since 3.0.9.0 + * @param ident the name of the global configuration option to retrieve + * @param result address of a variable to receive the configuration value + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason +*/ +EXPORTDLL unsigned int ts3client_getGlobalConfigValueAsInt(const char* ident, int* result); + +/** + * @brief Allows changing global client configuration values. + * + * ident can have the following values: + * input_deactivation_delay_ms: Number of milliseconds to continue transmitting after PTT key was released. + * input_deactivation_delay_active: Whether the above described delay is active or not. + * + * @since 3.0.9.0 + * @param ident the name of the global configuration option to set + * @param value the new value for the configuration option + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason +*/ +EXPORTDLL unsigned int ts3client_setGlobalConfigValue(const char* ident, const char* value); + +/*encoder*/ + +/** + * @brief Retrieve voice encoder information. + * + * Encoder options are bound to a capture device. You must open a capture device on the specified + * connection handler prior to calling this function. + * bitrate will return the estimated bitrate of audio without any overhead. + * name will return the used codec name. + * quality will return the codec quality setting, a value between 0 and 10 inclusive. + * + * @param serverConnectionHandlerID the connection handler to query the encoder information for. + * @param ident the configuration value to query. Valid values are name, quality and bitrate + * @param result address of a variable to receive an utf8 encoded c string with the value of the option queried. + * Memory is allocated by the client lib and must be freed by caller using @ref ts3client_freeMemory + * @return An error code from the @ref Ts3ErrorType enum indicating either success or the failure reason +*/ +EXPORTDLL unsigned int ts3client_getEncodeConfigValue(uint64 serverConnectionHandlerID, const char* ident, char** result); + +/*playback*/ + +/** + * @brief Retrieve floating point playback configuration settings + * + * @param serverConnectionHandlerID the connection handler to query the playback setting for. + * @param ident the name of the configuration setting to retrieve. Valid values are volume_modifier and volume_factor_wave + * @param result address of a variable to receive the current value of the queried setting + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason +*/ +EXPORTDLL unsigned int ts3client_getPlaybackConfigValueAsFloat(uint64 serverConnectionHandlerID, const char* ident, float* result); + +/** + * @brief Set playback configuration settings + * + * @param serverConnectionHandlerID the connection handler to set the playback setting on. + * @param ident the name of the configuration setting to set. Valid values are volume_modifier and volume_factor_wave + * @param value the new value to set as an utf8 encoded c string. Appropriate conversion takes place within the client lib. + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason +*/ +EXPORTDLL unsigned int ts3client_setPlaybackConfigValue(uint64 serverConnectionHandlerID, const char* ident, const char* value); + +/** + * @brief Adjust playback volume of an individual client + * + * Allows adjustment of single clients in addition to the global playback volume_modifier configuration option. + * Individual client volume adjustments are temporary and only valid as long as the client is visible. Once the + * target client leaves to an unsubscribed channel or disconnects from the server, this setting is discarded. + * If desired, the adjustment needs to be made again after the client reconnects or becomes visible again. + * + * @param serverConnectionHandlerID the connection handler for the server on which the client is located + * @param clientID the id of the client to adjust the volume for. + * @param value the volume modifier to apply to the client. + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason +*/ +EXPORTDLL unsigned int ts3client_setClientVolumeModifier(uint64 serverConnectionHandlerID, anyID clientID, float value); + +/*logging*/ + +/** + * @brief Log a message to the client log + * + * @param logMessage utf8 encoded c string of the message to log + * @param severity the seriousness of the message logged + * @param channel arbitrary utf8 encoded c string used to group messages. Pass empty string if unused. + * @param logID a connection handler on which to log the message. Pass 0 if unused. + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason +*/ +EXPORTDLL unsigned int ts3client_logMessage(const char* logMessage, enum LogLevel severity, const char* channel, uint64 logID); + +/** + * @brief When using custom logging define the severity of log messages above which to call the onUserLoggingMessageEvent for + * + * @param logVerbosity the verbosity above which to call the logging callback for. + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason +*/ +EXPORTDLL unsigned int ts3client_setLogVerbosity(enum LogLevel logVerbosity); + +/*error handling*/ + +/** + * @brief Retrieve human readable description for an error code + * + * @param errorCode the error code from the @ref Ts3ErrorType enum to retrieve the description for + * @param error address of a variable to receive a c string with the error description. + * Memory is allocated by the client lib and must be freed by caller using @ref ts3client_freeMemory + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason +*/ +EXPORTDLL unsigned int ts3client_getErrorMessage(unsigned int errorCode, char** error); + +/*Interacting with the server*/ + +/** + * @brief initiates a connection to a TeamSpeak server. + * + * When using a hostname instead of an IP address, this function will block until the client lib resolved the host name. + * + * @param serverConnectionHandlerID the connection handler to connect on, as created by ts3client_spawnNewServerConnectionHandler + * @param identity an identity string, as created by ts3client_createIdentity + * @param ip the server address to connect to. Can be a hostname or an IPv4 or IPv6 address + * @param port UDP port on which the TeamSpeak server is listening + * @param nickname a utf8 encoded c string used to display this client to other clients on the server. Not guaranteed to be the final name. + * @param defaultChannelArray An array describing the path to a channel to join after connect. Pass NULL when not used + * @param defaultChannelPassword The password for the channel in defaultChannelArray. Pass empty string if unused + * @param serverPassword server password. Pass empty string if the server does not have a password set + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason + * @sa ts3client_startConnectionWithChannelID +*/ +EXPORTDLL unsigned int ts3client_startConnection(uint64 serverConnectionHandlerID, const char* identity, const char* ip, unsigned int port, const char* nickname, + const char** defaultChannelArray, const char* defaultChannelPassword, const char* serverPassword); + +/** + * @brief initiates a connection to a TeamSpeak server. + * + * When using a hostname instead of an IP address, this function will block until the client lib resolved the host name. + * + * @param serverConnectionHandlerID the connection handler to connect on, as created by ts3client_spawnNewServerConnectionHandler + * @param identity an identity string, as created by ts3client_createIdentity + * @param ip the server address to connect to. Can be a hostname or an IPv4 or IPv6 address + * @param port UDP port on which the TeamSpeak server is listening + * @param nickname a utf8 encoded c string used to display this client to other clients on the server. Not guaranteed to be the final name. + * @param defaultChannelId The channel id of the channel to join on connect. Pass 0 to join server default channel + * @param defaultChannelPassword The password for the channel in defaultChannelId. Pass empty string if unused + * @param serverPassword server password. Pass empty string if the server does not have a password set + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason + * @sa ts3client_startConnection +*/ +EXPORTDLL unsigned int ts3client_startConnectionWithChannelID(uint64 serverConnectionHandlerID, const char* identity, const char* ip, unsigned int port, const char* nickname, + uint64 defaultChannelId, const char* defaultChannelPassword, const char* serverPassword); +/** + * @brief Disconnect from a TeamSpeak server + * + * @param serverConnectionHandlerID the connection handler to disconnect on + * @param quitMessage an optional utf8 encoded message to display to other clients. Pass empty string if unused. + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason +*/ +EXPORTDLL unsigned int ts3client_stopConnection(uint64 serverConnectionHandlerID, const char* quitMessage); + +/** + * @brief Attempt to move one or more clients to a different channel + * + * The move is requested from the server. See the onServerErrorEvent callback to know whether the move was successful or not. + * + * @param serverConnectionHandlerID the connection handler of which the channel and client are located + * @param clientIDArray NULL terminated array of client ids to move + * @param newChannelID the target channel id to move the clients to + * @param password the password for the channel. Pass an empty string if the channel has no password. + * @param returnCode a c string to identify this request in callbacks. Pass an empty string if unused. + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason +*/ +EXPORTDLL unsigned int ts3client_requestClientMove(uint64 serverConnectionHandlerID, const anyID* clientIDArray, uint64 newChannelID, const char* password, const char* returnCode); + +/** + * @brief Ask the server to provide additional request only variables for a client. + * + * You will receive an onUpdateClientEvent callback when the data is available to you. + * + * @param serverConnectionHandlerID the connection handler on which the client is located + * @param clientID the client for which to receive the client variables + * @param returnCode a c string to identify this request in callbacks. Pass an empty string if unused. + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason +*/ +EXPORTDLL unsigned int ts3client_requestClientVariables(uint64 serverConnectionHandlerID, anyID clientID, const char* returnCode); + +/** + * @brief Request client(s) to be kicked from their current channel. + * + * Kicking a client is essentially a glorified move to the server default channel with a message displayed to everyone. + * You will receive an onServerErrorEvent with the passed returnCode indicating whether or not the operation was successful. + * + * @param serverConnectionHandlerID the connection handler on which the client is located + * @param clientIDArray a NULL terminated array of client Ids to kick from their current channel. + * @param kickReason an explanatory message to display as the reason for everyone. + * @param returnCode a c string to identify this request in callbacks. Pass an empty string if unused. + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason +*/ +EXPORTDLL unsigned int ts3client_requestClientKickFromChannel(uint64 serverConnectionHandlerID, const anyID* clientIDArray, const char* kickReason, const char* returnCode); + +/** + * @brief Request client(s) to be kicked from the server. + * + * The clients will be disconnected and shown the reason. Reason is also displayed to everyone else on the server. + * You will receive an onServerErrorEvent with the passed returnCode indicating whether or not the operation was successful. + * + * @param serverConnectionHandlerID the connection handler on which the client is located + * @param clientIDArray a NULL terminated array of client Ids to kick from their current channel. + * @param kickReason an explanatory message to display as the reason for everyone. + * @param returnCode a c string to identify this request in callbacks. Pass an empty string if unused. + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason +*/ +EXPORTDLL unsigned int ts3client_requestClientKickFromServer(uint64 serverConnectionHandlerID, const anyID* clientIDArray, const char* kickReason, const char* returnCode); + +/** + * @brief Request a channel to be deleted. + * + * Whether or not this was successful can be determined through the associated onServerErrorEvent callback. + * + * @param serverConnectionHandlerID the connection handler on which the channel is located + * @param channelID the channel id to delete + * @param force boolean value on whether to kick clients out and delete any sub channels before deleting the channel. 1 = kick everyone, then delete sub channels and finally the requested channel; 0 = fail if there are clients in the channel or the channel has sub channels. + * @param returnCode a c string to identify this request in callbacks. Pass an empty string if unused. + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason +*/ +EXPORTDLL unsigned int ts3client_requestChannelDelete(uint64 serverConnectionHandlerID, uint64 channelID, int force, const char* returnCode); + +/** + * @brief Move a channel in a tree or to a different parent channel. + * + * You will receive an onServerErrorEvent with the passed returnCode indicating whether or not the operation was successful. + * + * @param serverConnectionHandlerID the connection handler on which the channel is located + * @param channelID the channel id to move or change the parent of + * @param newChannelParentID the channel id of the channel to be the new parent channel + * @param newChannelOrder the channel id of the channel below which the channel is to be sorted + * @param returnCode a c string to identify this request in callbacks. Pass an empty string if unused. + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason +*/ +EXPORTDLL unsigned int ts3client_requestChannelMove(uint64 serverConnectionHandlerID, uint64 channelID, uint64 newChannelParentID, uint64 newChannelOrder, const char* returnCode); + +/** + * @brief Send a private chat message to a client. + * + * You will receive an onServerErrorEvent with the passed returnCode indicating whether or not the operation was successful. + * + * @param serverConnectionHandlerID the connection handler on which to send the message + * @param message a utf8 encoded c string with the text to send + * @param targetClientID the client id of the client to send the message to + * @param returnCode a c string to identify this request in callbacks. Pass an empty string if unused. + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason +*/ +EXPORTDLL unsigned int ts3client_requestSendPrivateTextMsg(uint64 serverConnectionHandlerID, const char* message, anyID targetClientID, const char* returnCode); + +/** + * @brief Send a text message to your current channel. + * + * You will receive an onServerErrorEvent with the passed returnCode indicating whether or not the operation was successful. + * + * @param serverConnectionHandlerID the connection handler on which to send the message + * @param message a utf8 encoded c string with the text to send + * @param targetChannelID the channel to send the message to. IGNORED. + * @param returnCode a c string to identify this request in callbacks. Pass an empty string if unused. + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason +*/ +EXPORTDLL unsigned int ts3client_requestSendChannelTextMsg(uint64 serverConnectionHandlerID, const char* message, uint64 targetChannelID, const char* returnCode); + +/** + * @brief Send a text message to the server chat. + * + * You will receive an onServerErrorEvent with the passed returnCode indicating whether or not the operation was successful. + * + * @param serverConnectionHandlerID the connection handler on which to send the message + * @param message a utf8 encoded c string with the text to send + * @param returnCode a c string to identify this request in callbacks. Pass an empty string if unused. + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason +*/ +EXPORTDLL unsigned int ts3client_requestSendServerTextMsg(uint64 serverConnectionHandlerID, const char* message, const char* returnCode); + +/** + * @brief Request opening a new new-style chat room to the target user + * + * @param serverConnectionHandlerID the connection handler on which to open the chat + * @param type Chat type, currently supported values. "private" + * @param returnCode a c string to identify this request in callbacks. Pass an empty string if unused. + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason + */ +EXPORTDLL unsigned int ts3client_requestChat(uint64 serverConnectionHandlerID, const char* type, anyID targetClientID, const char* returnCode); + +/** + * @brief Request connection variables for a client (e.g. bandwidth usage, ping). + * + * You will receive a onConnectionInfoEvent callback once the information is available. + * + * @param serverConnectionHandlerID the connection handler on which the client resides + * @param clientID which client to request the connection information for + * @param returnCode a c string to identify this request in callbacks. Pass an empty string if unused. + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason +*/ +EXPORTDLL unsigned int ts3client_requestConnectionInfo(uint64 serverConnectionHandlerID, anyID clientID, const char* returnCode); + +/** + * @brief Sets the client to which to transmit voice. Stops standard channel voice transmission. + * + * The client will still receive voice from their current channel, however their voice will not be transmitted to their current channel anymore. + * If this call is successful (check onServerErrorEvent) then voice of the specified client will be transmitted to all specified channels and + * all the specified clients. + * Pass 0 to both target parameter arrays to restore default behavior of transmitting voice to current channel. + * You will receive an onServerErrorEvent with the passed returnCode indicating whether or not the operation was successful. + * + * @param serverConnectionHandlerID the connection handler on which to set the whisper list + * @param clientID the client to set the whisper list for. Set to 0 or your own client ID to set your own whisper list. + * @param targetChannelIDArray a zero terminated array of channel ids to transmit voice to. + * @param targetClientIDArray a zero terminated array of client ids to transmit voice to. + * @param returnCode a c string to identify this request in callbacks. Pass an empty string if unused. + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason +*/ +EXPORTDLL unsigned int ts3client_requestClientSetWhisperList(uint64 serverConnectionHandlerID, anyID clientID, const uint64* targetChannelIDArray, const anyID* targetClientIDArray, const char* returnCode); + +/** + * @brief Request live updates to specific channels, being able to see clients in the channel. + * + * If you intend to subscribe to all channels on the server, use ts3client_requestChannelSubscribeAll function instead. + * You will receive an onServerErrorEvent with the passed returnCode indicating whether or not the operation was successful. + * + * @param serverConnectionHandlerID the connection handler on which to subscribe to the specified channels + * @param channelIDArray a zero terminated array of channel ids to subscribe to + * @param returnCode a c string to identify this request in callbacks. Pass an empty string if unused. + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason +*/ +EXPORTDLL unsigned int ts3client_requestChannelSubscribe(uint64 serverConnectionHandlerID, const uint64* channelIDArray, const char* returnCode); + +/** + * @brief Request live updates from all channels, being able to see clients in the channels. + * + * If you only want to subscribe to a specific subset of channels, use ts3client_requestChannelSubscribe funtion instead. + * You will receive an onServerErrorEvent with the passed returnCode indicating whether or not the operation was successful. + * + * @param serverConnectionHandlerID the connection handler on which to subscribe to all channels + * @param returnCode a c string to identify this request in callbacks. Pass an empty string if unused. + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason +*/ +EXPORTDLL unsigned int ts3client_requestChannelSubscribeAll(uint64 serverConnectionHandlerID, const char* returnCode); + +/** + * @brief Remove subscription from channels. No longer receiving updates to clients in the channels. + * + * You will receive an onServerErrorEvent with the passed returnCode indicating whether or not the operation was successful. + * + * @param serverConnectionHandlerID the connection handler on which to unsubscribe from the specified channels + * @param channelIDArray a zero terminated array of channel ids to unsubscribe from + * @param returnCode a c string to identify this request in callbacks. Pass an empty string if unused. + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason +*/ +EXPORTDLL unsigned int ts3client_requestChannelUnsubscribe(uint64 serverConnectionHandlerID, const uint64* channelIDArray, const char* returnCode); + +/** + * @brief Remove subscription from all channels. No longer receiving updates to clients outside of own channel. + * + * The current channel will always be subscribed and you will always receive updates about clients in the current channel. + * You will receive an onServerErrorEvent with the passed returnCode indicating whether or not the operation was successful. + * + * @param serverConnectionHandlerID the connection handler on which to unsubscribe from all channels + * @param returnCode a c string to identify this request in callbacks. Pass an empty string if unused. + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason +*/ +EXPORTDLL unsigned int ts3client_requestChannelUnsubscribeAll(uint64 serverConnectionHandlerID, const char* returnCode); + +/** + * @brief retrieve the channel description of the specified channel. + * + * After calling this function you will receive an onUpdateChannelEvent callback at which point the description is available to + * be queried using ts3client_getChannelVariableAsString. + * You will receive an onServerErrorEvent with the passed returnCode indicating whether or not the operation was successful. + * + * @param serverConnectionHandlerID the connection handler on which the channel is located + * @param channelID the id of the channel to retrieve the description for + * @param returnCode a c string to identify this request in callbacks. Pass an empty string if unused. + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason +*/ +EXPORTDLL unsigned int ts3client_requestChannelDescription(uint64 serverConnectionHandlerID, uint64 channelID, const char* returnCode); + +/** + * @brief Mute clients locally, the server will not be sending audio data for the specified clients anymore. + * + * You will receive an onServerErrorEvent with the passed returnCode indicating whether or not the operation was successful. + * + * @param serverConnectionHandlerID the connection handler on which to mute the clients + * @param clientIDArray a zero terminated array of client ids to mute + * @param returnCode a c string to identify this request in callbacks. Pass an empty string if unused. + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason + * @sa ts3client_requestUnmuteClients +*/ +EXPORTDLL unsigned int ts3client_requestMuteClients(uint64 serverConnectionHandlerID, const anyID* clientIDArray, const char* returnCode); + +/** + * @brief Unmute clients locally. Server will start sending audio packets for the specified clients again. + * + * You will receive an onServerErrorEvent with the passed returnCode indicating whether or not the operation was successful. + * + * @param serverConnectionHandlerID the connection handler on which to unmute the clients + * @param clientIDArray a zero terminated array of client ids to unmute + * @param returnCode a c string to identify this request in callbacks. Pass an empty string if unused. + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason + * @sa ts3client_requestMuteClients +*/ +EXPORTDLL unsigned int ts3client_requestUnmuteClients(uint64 serverConnectionHandlerID, const anyID* clientIDArray, const char* returnCode); + +/** + * @brief retrieve the current client ids of all clients connected using the specified unique identifier + * + * You will receive a onClientIDsEvent callback for every client connected with the identity specified by the clientUniqueIdentifier. + * Once all client ids for the specified identity have been indicated, you will receive a onClientIDsFinishedEvent callback. + * You will receive an onServerErrorEvent with the passed returnCode indicating whether or not the operation was successful. + * + * @param serverConnectionHandlerID the connection handler on which to retrieve the client ids for + * @param clientUniqueIdentifier a c string with a unique identifier to retreive the client ids for. This is the public part of the identity + * @param returnCode a c string to identify this request in callbacks. Pass an empty string if unused. + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason +*/ +EXPORTDLL unsigned int ts3client_requestClientIDs(uint64 serverConnectionHandlerID, const char* clientUniqueIdentifier, const char* returnCode); + +/*provisioning server calls*/ +EXPORTDLL unsigned int ts3client_requestSlotsFromProvisioningServer(const char* ip, unsigned short port, const char* serverPassword, unsigned short slots, const char* identity, const char* region, uint64* requestHandle); +EXPORTDLL unsigned int ts3client_cancelRequestSlotsFromProvisioningServer(uint64 requestHandle); +EXPORTDLL unsigned int ts3client_startConnectionWithProvisioningKey(uint64 serverConnectionHandlerID, const char* identity, const char* nickname, const char* connectionKey, const char* clientMetaData); + +/*retrieve information ClientLib has stored*/ + +/*general info*/ + +/** + * @brief get your own client id on a server + * + * @param serverConnectionHandlerID the connection handler on which to retrieve your own client id + * @param result address of a variable to receive your client id on success + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason +*/ +EXPORTDLL unsigned int ts3client_getClientID(uint64 serverConnectionHandlerID, anyID* result); + +/*client connection info*/ + +/** + * @brief check the current status of the connection + * + * @param serverConnectionHandlerID the connection handler for which to receive the connection status + * @param result address of a variable to receive the current connect status. One of the values from the ConnectStatus enum + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason +*/ +EXPORTDLL unsigned int ts3client_getConnectionStatus(uint64 serverConnectionHandlerID, int* result); + +/** + * @brief Get value for connection based variable of a client as unsigned 64 bit integer + * + * Not all variables are available as unsigned 64 bit integer. Some are only available as string or double. + * + * @param serverConnectionHandlerID the connection handler on which to get the value + * @param clientID the client for which to retrieve the value + * @param flag specifies which value to receive. One of the values from the ConnectionProperties enum + * @param result address of a variable to receive the variable on success. + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason +*/ +EXPORTDLL unsigned int ts3client_getConnectionVariableAsUInt64(uint64 serverConnectionHandlerID, anyID clientID, size_t flag, uint64* result); + +/** + * @brief Get value for connection based variable of a client as double + * + * Not all variables are available as double. Some are only available as string or unsigned 64 bit integers. + * + * @param serverConnectionHandlerID the connection handler on which to get the value + * @param clientID the client for which to retrieve the value + * @param flag specifies which value to receive. One of the values from the ConnectionProperties enum + * @param result address of a variable to receive the variable on success. + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason +*/ +EXPORTDLL unsigned int ts3client_getConnectionVariableAsDouble(uint64 serverConnectionHandlerID, anyID clientID, size_t flag, double* result); + +/** + * @brief Get value for connection based variable of a client as string + * + * Not all variables are available as string. Some are only available as unsigned 64 bit integer or double. + * + * @param serverConnectionHandlerID the connection handler on which to get the value + * @param clientID the client for which to retrieve the value + * @param flag specifies which value to receive. One of the values from the ConnectionProperties enum + * @param result address of a variable to receive the variable on success. + * Memory is allocated by the client lib and must be freed by caller using @ref ts3client_freeMemory + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason +*/ +EXPORTDLL unsigned int ts3client_getConnectionVariableAsString(uint64 serverConnectionHandlerID, anyID clientID, size_t flag, char** result); + +/** + * @brief TODO + * + * @param serverConnectionHandlerID connection handler to clean up on + * @param clientID the client to clean up + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason +*/ +EXPORTDLL unsigned int ts3client_cleanUpConnectionInfo(uint64 serverConnectionHandlerID, anyID clientID); + +/*server connection info*/ + +/** + * @brief Make server connection variables available for retrieval + * + * @param serverConnectionHandlerID the connection handler for which to make connection variables available + * @param returnCode a c string to identify this request in callbacks. Pass an empty string if unused. + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason +*/ +EXPORTDLL unsigned int ts3client_requestServerConnectionInfo(uint64 serverConnectionHandlerID, const char* returnCode); + +/** + * @brief Retrieve value of a server connection variable as unsigned 64 bit integer + * + * Not all variables are available as unsigned 64 bit integer. Some are only available float. + * + * @param serverConnectionHandlerID the connection handler on which to retrieve the value + * @param flag specifies which variable to receive. One of the values from the ConnectionProperties enum + * @param result address of a variable to receive the value on success. + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason +*/ +EXPORTDLL unsigned int ts3client_getServerConnectionVariableAsUInt64(uint64 serverConnectionHandlerID, size_t flag, uint64* result); + +/** + * @brief Retrieve value of a server connection variable as float + * + * Not all variables are available as float. Some are only available as unsigned 64 bit integer. + * + * @param serverConnectionHandlerID the connection handler on which to retrieve the value + * @param flag specifies which variable to receive. One of the values from the ConnectionProperties enum + * @param result address of a variable to receive the value on success. + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason +*/ +EXPORTDLL unsigned int ts3client_getServerConnectionVariableAsFloat(uint64 serverConnectionHandlerID, size_t flag, float* result); + +/*client info*/ + +/** + * @brief Retrieve value of a variable of your own client as an integer + * + * Not all variables are available as integer. Some are only available as string. + * NOTE: Not all variables are available using this function, some are only available using ts3client_getClientVariableAsInt + * + * @param serverConnectionHandlerID connection handler on which to retrieve information + * @param flag specifies which variable to receive. One of the values from the ClientProperties enum + * @param result address of a variable to receive the value on success + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason +*/ +EXPORTDLL unsigned int ts3client_getClientSelfVariableAsInt(uint64 serverConnectionHandlerID, size_t flag, int* result); + +/** + * @brief Retrieve value of a variable of your own client as string + * + * Not all variables are available as integer. Some are only available as integer. + * NOTE: Not all variables are available using this function, some are only available using ts3client_getClientVariableAsString + * + * @param serverConnectionHandlerID connection handler on which to retrieve information + * @param flag specifies which variable to receive. One of the values from the ClientProperties or ClientPropertiesRare enums + * @param result address of a variable to receive the value on success. + * Memory is allocated by the client lib and must be freed by caller using @ref ts3client_freeMemory + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason +*/ +EXPORTDLL unsigned int ts3client_getClientSelfVariableAsString(uint64 serverConnectionHandlerID, size_t flag, char** result); + +/** + * @brief Change the value of an integer variable on your own client + * + * After having changed all variables desired, call ts3client_flushClientSelfUpdates to publish the changes to the server + * Not all variables can be changed, many are read only. + * + * @param serverConnectionHandlerID the connection handler on which to set the value + * @param flag specifies which variable to change. One of the values from the ClientProperties or ClientPropertiesRare enums + * @param value the new value to set + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason +*/ +EXPORTDLL unsigned int ts3client_setClientSelfVariableAsInt(uint64 serverConnectionHandlerID, size_t flag, int value); + +/** + * @brief Change the value of a string variable on your own client + * + * After having changed all variables desired, call ts3client_flushClientSelfUpdates to publish the changes to the server + * Not all variables can be changed, many are read only. + * + * @param serverConnectionHandlerID the connection handler on which to set the value + * @param flag specifies which variable to change. One of the values from the ClientProperties or ClientPropertiesRare enums + * @param value the new value to set + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason +*/ +EXPORTDLL unsigned int ts3client_setClientSelfVariableAsString(uint64 serverConnectionHandlerID, size_t flag, const char* value); + +/** + * @brief Send changes to the local client to the server + * + * Publish changes previously set using @ref ts3client_setClientSelfVariableAsInt and @ref ts3client_setClientSelfVariableAsString on the + * connection handler. + * + * @param serverConnectionHandlerID connection handler on which to publish changes + * @param returnCode a c string to identify this request in callbacks. Pass an empty string if unused. + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason +*/ +EXPORTDLL unsigned int ts3client_flushClientSelfUpdates(uint64 serverConnectionHandlerID, const char* returnCode); + +/** + * @brief Retrieve the value of a variable from a client as integer + * + * Not all variables are available as integer. Some are only available as string or unsigned 64bit integer. + * + * @param serverConnectionHandlerID connection handler on which the client is located + * @param clientID for which client to retrieve the value + * @param flag specifies which variable to receive. One of the values from the ClientProperties or ClientPropertiesRare enums + * @param result address of a variable to receive the value on success + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason +*/ +EXPORTDLL unsigned int ts3client_getClientVariableAsInt(uint64 serverConnectionHandlerID, anyID clientID, size_t flag, int* result); + +/** + * @brief Retrieve the value of a variable from a client as unsigned 64bit integer + * + * Not all variables are available as integer. Some are only available as string or integer. + * + * @param serverConnectionHandlerID connection handler on which the client is located + * @param clientID for which client to retrieve the value + * @param flag specifies which variable to receive. One of the values from the ClientProperties or ClientPropertiesRare enums + * @param result address of a variable to receive the value on success + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason +*/ +EXPORTDLL unsigned int ts3client_getClientVariableAsUInt64(uint64 serverConnectionHandlerID, anyID clientID, size_t flag, uint64* result); + +/** + * @brief Retrieve the value of a variable from a client as string + * + * Not all variables are available as integer. Some are only available as integer or unsigned 64bit integer. + * + * @param serverConnectionHandlerID connection handler on which the client is located + * @param clientID for which client to retrieve the value + * @param flag specifies which variable to receive. One of the values from the ClientProperties or ClientPropertiesRare enums + * @param result address of a variable to receive the value on success. + * Memory is allocated by the client lib and must be freed by caller using @ref ts3client_freeMemory + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason +*/ +EXPORTDLL unsigned int ts3client_getClientVariableAsString(uint64 serverConnectionHandlerID, anyID clientID, size_t flag, char** result); + +/** + * @brief Get a list of all clients in subscribed channels on the server + * + * @param serverConnectionHandlerID connection handler on which to retrieve the client list + * @param result address of a variable to receive a null terminated array of client ids like {10, 30, ..., 0} + * Memory is allocated by the client lib and caller must free the array using @ref ts3client_freeMemory + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason +*/ +EXPORTDLL unsigned int ts3client_getClientList(uint64 serverConnectionHandlerID, anyID** result); + +/** + * @brief Get id of the current channel the specified client is in + * + * @param serverConnectionHandlerID connection handler on which the client is located + * @param clientID the client to receive the current channel for + * @param result address of a variable to receive the channel id of the specified client + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason +*/ +EXPORTDLL unsigned int ts3client_getChannelOfClient(uint64 serverConnectionHandlerID, anyID clientID, uint64* result); + +/*channel info*/ + +/** + * @brief Retrieve the value of a channel property as integer + * + * Not all properties are available as integer. Some are only available as string or unsigned 64 bit integer. + * + * @param serverConnectionHandlerID connection handler on which the channel is located + * @param channelID the channel of which to retrieve the property + * @param flag specifies which property to retrieve. One of the values from the ChannelProperties or ChannelPropertiesRare enum + * @param result address of a variable to receive the result on success + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason +*/ +EXPORTDLL unsigned int ts3client_getChannelVariableAsInt(uint64 serverConnectionHandlerID, uint64 channelID, size_t flag, int* result); + +/** + * @brief Retrieve the value of a channel property as unsigned 64 bit integer + * + * Not all properties are available as string. Some are only available as integer or string. + * + * @param serverConnectionHandlerID connection handler on which the channel is located + * @param channelID the channel of which to retrieve the property + * @param flag specifies which property to retrieve. One of the values from the ChannelProperties or ChannelPropertiesRare enum + * @param result address of a variable to receive the result on success + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason +*/ +EXPORTDLL unsigned int ts3client_getChannelVariableAsUInt64(uint64 serverConnectionHandlerID, uint64 channelID, size_t flag, uint64* result); + +/** + * @brief Retrieve the value of a channel property as string + * + * Not all properties are available as string. Some are only available as integer or unsigned 64 bit integer. + * + * @param serverConnectionHandlerID connection handler on which the channel is located + * @param channelID the channel of which to retrieve the property + * @param flag specifies which property to retrieve. One of the values from the ChannelProperties or ChannelPropertiesRare enum + * @param result address of a variable to receive the result on success. + * Memory is allocated by the client lib and must be freed by caller using @ref ts3client_freeMemory + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason +*/ +EXPORTDLL unsigned int ts3client_getChannelVariableAsString(uint64 serverConnectionHandlerID, uint64 channelID, size_t flag, char** result); + +/** + * @brief Get the channel id for the given channel path + * + * @param serverConnectionHandlerID connection handler on which to find the channel + * @param channelNameArray zero terminated array of c strings describing the channel path. Like {"Main channel", "sub channel", null} + * @param result address of a variable to receive the channel id on success + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason +*/ +EXPORTDLL unsigned int ts3client_getChannelIDFromChannelNames(uint64 serverConnectionHandlerID, char** channelNameArray, uint64* result); + +/** + * @brief set a new value for an integer channel property + * + * @param serverConnectionHandlerID connection handler on which the channel is located + * @param channelID id of the channel to set the property for + * @param flag specifies which property to set. One of the values from the ChannelProperties or ChannelPropertiesRare enums + * @param value the new value to set + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason +*/ +EXPORTDLL unsigned int ts3client_setChannelVariableAsInt(uint64 serverConnectionHandlerID, uint64 channelID, size_t flag, int value); + +/** + * @brief set a new value for an unsigned 64 bit channel property + * + * @param serverConnectionHandlerID connection handler on which the channel is located + * @param channelID id of the channel to set the property for + * @param flag specifies which property to set. One of the values from the ChannelProperties or ChannelPropertiesRare enums + * @param value the new value to set + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason +*/ +EXPORTDLL unsigned int ts3client_setChannelVariableAsUInt64(uint64 serverConnectionHandlerID, uint64 channelID, size_t flag, uint64 value); + +/** + * @brief set a new value for a string channel property + * + * @param serverConnectionHandlerID connection handler on which the channel is located + * @param channelID id of the channel to set the property for + * @param flag specifies which property to set. One of the values from the ChannelProperties or ChannelPropertiesRare enums + * @param value the new value to set + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason +*/ +EXPORTDLL unsigned int ts3client_setChannelVariableAsString(uint64 serverConnectionHandlerID, uint64 channelID, size_t flag, const char* value); + +/** + * @brief Inform server of changes to channel properties + * + * After all desired changes have been done using @ref ts3client_setChannelVariableAsInt, @ref ts3client_setChannelVariableAsUInt64 + * or @ref ts3client_setChannelVariableAsString call this function to send the changes to the server and publish them to other clients. + * Prior to calling this function the channel property changes will not have any effect. + * + * @param serverConnectionHandlerID connection handler on which the channel is located + * @param channelID id of the channel to publish updates for + * @param returnCode a c string to identify this request in callbacks. Pass an empty string if unused. + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason +*/ +EXPORTDLL unsigned int ts3client_flushChannelUpdates(uint64 serverConnectionHandlerID, uint64 channelID, const char* returnCode); + +/** + * @brief Create the channel on the server + * + * After setting all the desired properties on the channel, call this function to actually create the channel on the server + * + * @param serverConnectionHandlerID connection handler on which to create the channel + * @param channelParentID id of the channel this channel should be a sub channel of. Pass 0 to create a root channel. + * @param returnCode a c string to identify this request in callbacks. Pass an empty string if unused. + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason +*/ +EXPORTDLL unsigned int ts3client_flushChannelCreation(uint64 serverConnectionHandlerID, uint64 channelParentID, const char* returnCode); + +/** + * @brief Get a list of all channels currently on the server + * + * @param serverConnectionHandlerID connection handler on which to retrieve the channels + * @param result address of a variable to receive a zero terminated array of channel ids, like {1, 4023, 49, 8534, ..., 0} + * Memory is allocated by the client lib and must be freed by caller using @ref ts3client_freeMemory + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason +*/ +EXPORTDLL unsigned int ts3client_getChannelList(uint64 serverConnectionHandlerID, uint64** result); + +/** + * @brief Get a list of all clients in the specified channel + * + * @param serverConnectionHandlerID connection handler on which the channel is located + * @param channelID the channel of which to retrieve the current clients + * @param result address of a variable to receive a zero terminated array of client ids, like {2, 50, 4, ..., 0} + * Memory is allocated by the client lib and must be freed by caller using @ref ts3client_freeMemory + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason +*/ +EXPORTDLL unsigned int ts3client_getChannelClientList(uint64 serverConnectionHandlerID, uint64 channelID, anyID** result); + +/** + * @brief get the id of the parent channel of the specified channel. + * + * If the channel specified by channelID is a root channel, the result will be 0. + * + * @param serverConnectionHandlerID connection handler on which the channel is located + * @param channelID id of the channel to retrieve the parent of + * @param result address of a variable to receive the parent channel id. + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason +*/ +EXPORTDLL unsigned int ts3client_getParentChannelOfChannel(uint64 serverConnectionHandlerID, uint64 channelID, uint64* result); + +/** + * @brief get time in seconds since last client left the specified channel + * + * @param serverConnectionHandlerID connection handler on which the channel is located + * @param channelID id of the channel to get the + * @param result address of a variable to receive the result on success + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason +*/ +EXPORTDLL unsigned int ts3client_getChannelEmptySecs(uint64 serverConnectionHandlerID, uint64 channelID, int* result); + +/*server info*/ + +/** + * @brief get a list of all connection handlers + * + * @param result address of a variable to receive a zero terminated array of connection handlers, like {1, 5, ..., 0} + * Memory is allocated by the client lib and must be freed by caller using @ref ts3client_freeMemory + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason +*/ +EXPORTDLL unsigned int ts3client_getServerConnectionHandlerList(uint64** result); + +/** + * @brief get the value of an integer server property. + * + * Not all properties are available as integer. Some are only available as string or unsigned 64 bit integer. + * + * @param serverConnectionHandlerID specifies the server on which to retrieve the property + * @param flag specifies which property to retrieve. One of the values from the VirtualServerProperties or VirtualServerPropertiesRare enums + * @param result address of a variable to receive the property value on success. + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason +*/ +EXPORTDLL unsigned int ts3client_getServerVariableAsInt(uint64 serverConnectionHandlerID, size_t flag, int* result); + +/** + * @brief get the value of an unsigned 64 bit integer server property. + * + * Not all properties are available as unsigned 64 bit integer. Some are only available as string or integer. + * + * @param serverConnectionHandlerID specifies the server on which to retrieve the property + * @param flag specifies which property to retrieve. One of the values from the VirtualServerProperties or VirtualServerPropertiesRare enums + * @param result address of a variable to receive the property value on success. + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason +*/ +EXPORTDLL unsigned int ts3client_getServerVariableAsUInt64(uint64 serverConnectionHandlerID, size_t flag, uint64* result); + +/** + * @brief get the value of a string server property. + * + * Not all properties are available as string. Some are only available as integer or unsigned 64 bit integer + * + * @param serverConnectionHandlerID specifies the server on which to retrieve the property + * @param flag specifies which property to retrieve. One of the values from the VirtualServerProperties or VirtualServerPropertiesRare enums + * @param result address of a variable to receive the property value on success. + * Memory is allocated by the client lib and must be freed by caller using @ref ts3client_freeMemory + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason +*/ +EXPORTDLL unsigned int ts3client_getServerVariableAsString(uint64 serverConnectionHandlerID, size_t flag, char** result); + +/** + * @brief Make request only server variables available locally. + * + * You will receive an onServerUpdateEvent once the request only properties are available. + * Prior to the callback being called the variables are not available, and querying them will yield undefined results. + * + * @param serverConnectionHandlerID connection handler on which to request the variables + * @param returnCode a c string to identify this request in callbacks. Pass an empty string if unused. + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason +*/ +EXPORTDLL unsigned int ts3client_requestServerVariables(uint64 serverConnectionHandlerID, const char* returnCode); + +/*filetransfer management*/ + +/** + * @brief get the local file name for a file transfer + * + * @param transferID identifies the file transfer to query + * @param result address of a variable to receive an utf8 encoded c string on success. + * Memory is allocated by the client lib and must be freed by caller using @ref ts3client_freeMemory + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason +*/ +EXPORTDLL unsigned int ts3client_getTransferFileName(anyID transferID, char** result); + +/** + * @brief get the local path of a file transfer + * + * @param transferID identifies the file transfer to query + * @param result address of a variable to receive an utf8 encoded c string on success. + * Memory is allocated by the client lib and must be freed by caller using @ref ts3client_freeMemory + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason +*/ +EXPORTDLL unsigned int ts3client_getTransferFilePath(anyID transferID, char** result); + +/** + * @brief get the server path of the file transfer + * + * @param transferID identifies which file transfer to query + * @param result address of a variable to receive an utf8 encoded c string on success. + * Memory is allocated by the client lib and must be freed by caller using @ref ts3client_freeMemory + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason +*/ +EXPORTDLL unsigned int ts3client_getTransferFileRemotePath(anyID transferID, char** result); + +/** + * @brief get the total size in bytes of a file transfer. + * + * @param transferID specifies which file transfer to query + * @param result address of a variable to receive the file size + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason +*/ +EXPORTDLL unsigned int ts3client_getTransferFileSize(anyID transferID, uint64* result); + +/** + * @brief get the amount of bytes already transferred. + * + * 0 <= result <= ts3client_getTransferFileSize for the same transferID. + * + * @param transferID specifies the file transfer to query + * @param result address of a variable to receive the result on success + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason +*/ +EXPORTDLL unsigned int ts3client_getTransferFileSizeDone(anyID transferID, uint64* result); + +/** + * @brief determine if the file transfer is an upload or download + * + * @param transferID specifies the file transfer to query + * @param result address of a variable to receive the result on success. 1 = upload, 0 = download + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason +*/ +EXPORTDLL unsigned int ts3client_isTransferSender(anyID transferID, int* result); + +/** + * @brief determine the current status of the transfer in question + * + * @param transferID specifies the file transfer to query + * @param result address of a variable to receive the status on success. One of the values from the FileTransferState enum. + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason +*/ +EXPORTDLL unsigned int ts3client_getTransferStatus(anyID transferID, int* result); + +/** + * @brief get the current approximate speed (in bytes/sec) of a file transfer + * + * @param transferID specifies the file transfer to query + * @param result address of a variable to receive the transfer speed in bytes per second, averaged across the past 5 seconds. + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason +*/ +EXPORTDLL unsigned int ts3client_getCurrentTransferSpeed(anyID transferID, float* result); + +/** + * @brief get the average transfer speed (in bytes/sec) of a file transfer since it started + * + * @param transferID specifies the file transfer to query + * @param result address of a variable to receive the approximate speed in bytes per second, averaged across its lifetime. + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason +*/ +EXPORTDLL unsigned int ts3client_getAverageTransferSpeed(anyID transferID, float* result); + +/** + * @brief get the time (in seconds) a file transfer has been active + * + * @param transferID specifies the file transfer to query + * @param result address of a variable to receive the time in seconds the transfer was active. + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason +*/ +EXPORTDLL unsigned int ts3client_getTransferRunTime(anyID transferID, uint64* result); + +/*Interacting with the server - file transfers*/ + +/** + * @brief Initiate a file upload to the server. + * + * @param serverConnectionHandlerID connection handler to which to upload a file + * @param channelID channel to which to upload the file + * @param channelPW password of the channel specified in channelID. Pass an empty string if the channel does not have a password. + * @param file the name of file to upload on the local file system. + * @param overwrite boolean flag, whether to overwrite the file on the server. If 0 the transfer will fail if the file already exists on the server. + * @param resume boolean flag, set to 1 to resume a previously aborted or halted transfer. If 1 will append to the file on the server. + * @param sourceDirectory the absolute path in which the file resides on the local file system. + * @param result address of a variable in which to store the transferID on success. + * @param returnCode a c string to identify this request in callbacks. Pass an empty string if unused. + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason +*/ +EXPORTDLL unsigned int ts3client_sendFile(uint64 serverConnectionHandlerID, uint64 channelID, const char* channelPW, const char* file, int overwrite, int resume, const char* sourceDirectory, anyID* result, const char* returnCode); + +/** + * @brief Initiate a file download from the server. + * + * @param serverConnectionHandlerID connection handler from which to download the file + * @param channelID channel in which the file to download is located + * @param channelPW password of the channel specified in channelID. Pass an empty string if the channel does not have a password. + * @param file the name of the file on the server file system. See ts3client_getFileList to receive a list of files. + * @param overwrite boolean flag, whether to overwrite the local file if it already exists. If set to 0 transfer will fail if local file already exists unless resume is 1. + * Mutually exclusive to resume. + * @param resume boolean flag, whether to append to the local file. If set to 1 the contents of the download will be appended to the local file. Mutually exclusive with overwrite. + * @param destinationDirectory absolute path to the directory in which to store the file. + * @param result address of a variable to receive the transfer id, used to identity this request in callbacks and other calls regarding the status of this transfer + * @param returnCode a c string to identify this request in callbacks. Pass an empty string if unused. + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason +*/ +EXPORTDLL unsigned int ts3client_requestFile(uint64 serverConnectionHandlerID, uint64 channelID, const char* channelPW, const char* file, int overwrite, int resume, const char* destinationDirectory, anyID* result, const char* returnCode); + +/** + * @brief Cancel a file transfer + * + * @param serverConnectionHandlerID connection handler on which the file transfer is happening + * @param transferID specifies the file transfer to cancel + * @param deleteUnfinishedFile boolean flag, whether to delete the partially transmitted file from the file system. + * @param returnCode a c string to identify this request in callbacks. Pass an empty string if unused. + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason +*/ +EXPORTDLL unsigned int ts3client_haltTransfer(uint64 serverConnectionHandlerID, anyID transferID, int deleteUnfinishedFile, const char* returnCode); + +/** + * @brief retrieve a list of files in a directory. + * + * This function is NOT recursive. Only directories and files in the directory specified by path will be listed. + * You will receive a onFileListEvent callback for every file or directory after this function was successful. + * Once all files and directories were sent you will receive a onFileListFinishedEvent callback. + * + * @param serverConnectionHandlerID the connection handler on which to request files + * @param channelID the channel from which to list the files + * @param channelPW the password of the specified channel. Pass an empty string if the channel has no password. + * @param path the path in the specified channel from which to list the files. Pass "/" to list the files in the root channel. + * @param returnCode a c string to identify this request in callbacks. Pass an empty string if unused. + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason +*/ +EXPORTDLL unsigned int ts3client_requestFileList(uint64 serverConnectionHandlerID, uint64 channelID, const char* channelPW, const char* path, const char* returnCode); + +/** + * @brief retrieve information about a specific file. + * + * You will receive an onFileInfoEvent callback after this function was successful. + * + * @param serverConnectionHandlerID connection handler on which to request the file information. + * @param channelID the channel in which the file is located + * @param channelPW the password of the specified channel. Pass an empty string if the channel has no password. + * @param file absolute path to the file to query information of. Must begin with "/". + * @param returnCode a c string to identify this request in callbacks. Pass an empty string if unused. + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason +*/ +EXPORTDLL unsigned int ts3client_requestFileInfo(uint64 serverConnectionHandlerID, uint64 channelID, const char* channelPW, const char* file, const char* returnCode); + +/** + * @brief delete one or more files from a channel. + * + * You will receive an onServerErrorEvent with the passed returnCode indicating whether or not the operation was successful. + * + * @param serverConnectionHandlerID connection handler on which to delete the file + * @param channelID the channel in which the file is located + * @param channelPW the password of the specified channel. Pass an empty string if the channel has no password. + * @param file a zero terminated array of absolute paths to the files to delete. Each path must begin with "/". Like {"/file.txt", "/dir/subdir/test.txt", ..., 0} + * @param returnCode a c string to identify this request in callbacks. Pass an empty string if unused. + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason +*/ +EXPORTDLL unsigned int ts3client_requestDeleteFile(uint64 serverConnectionHandlerID, uint64 channelID, const char* channelPW, const char** file, const char* returnCode); + +/** + * @brief create a directory in a channel for file organization + * + * Note: This will NOT recursively create directories. If you need recursive creation call this function again after the intended parent directory has been created. + * You will receive an onServerErrorEvent with the passed returnCode indicating whether or not the operation was successful. + * + * @param serverConnectionHandlerID connection handler on which the channel is located. + * @param channelID the channel in which the file is located + * @param channelPW the password of the specified channel. Pass an empty string if the channel has no password. + * @param directoryPath absolute path of the directory to create. Must start with "/" e.g. "/existing/newDirName" + * @param returnCode a c string to identify this request in callbacks. Pass an empty string if unused. + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason +*/ +EXPORTDLL unsigned int ts3client_requestCreateDirectory(uint64 serverConnectionHandlerID, uint64 channelID, const char* channelPW, const char* directoryPath, const char* returnCode); + +/** + * @brief move or rename a file on the server. + * + * You will receive an onServerErrorEvent with the passed returnCode indicating whether or not the operation was successful. + * + * @param serverConnectionHandlerID connection handler on which to move/rename the file + * @param fromChannelID channel the file is currently located in + * @param fromChannelPW password of the specified channel. Pass an empty string if the channel has no password. + * @param toChannelID channel id to which to move the file to. Pass the same value as fromChannelID to keep the file in the same channel. + * @param toChannelPW password of the target channel. Pass an empty string if the channel has no password. + * @param oldFile current absolute path of the file in the channel. Must start with "/". + * @param newFile new absolute path of the file in the target channel. Must start with "/". e.g. "/subdirectory/filename.txt" + * @param returnCode a c string to identify this request in callbacks. Pass an empty string if unused. + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason +*/ +EXPORTDLL unsigned int ts3client_requestRenameFile(uint64 serverConnectionHandlerID, uint64 fromChannelID, const char* fromChannelPW, uint64 toChannelID, const char* toChannelPW, const char* oldFile, const char* newFile, const char* returnCode); + +/** + * @brief get the configured maximum upload speed of the server instance. + * + * The limit is temporary and valid only until ts3client_destroyClientLib is called. + * + * @param limit address of a variable to receive the limit in bytes per second. + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason +*/ +EXPORTDLL unsigned int ts3client_getInstanceSpeedLimitUp(uint64 *limit); + +/** + * @brief get the configured maximum download speed of the server instance. + * + * The limit is temporary and valid only until ts3client_destroyClientLib is called. + * + * @param limit address of a variable to receive the limit in bytes per second. + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason +*/ +EXPORTDLL unsigned int ts3client_getInstanceSpeedLimitDown(uint64 *limit); + +/** + * @brief get the configured maximum upload speed for the virtual server. + * + * Upload speeds on this server will not exceed min(instance limit, virtual server limit) bytes per second. + * The limit is temporary and valid only for the lifetime of the connection handler. + * + * @param serverConnectionHandlerID connection handler to query the value on. + * @param limit address of a variable to receive the limit in bytes per second. + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason +*/ +EXPORTDLL unsigned int ts3client_getServerConnectionHandlerSpeedLimitUp(uint64 serverConnectionHandlerID, uint64* limit); + +/** + * @brief get the configured maximum download speed for the virtual server. + * + * Download speeds on this server will not exceed min(instance limit, virtual server limit) bytes per second. + * The limit is temporary and valid only for the lifetime of the connection handler. + * + * @param serverConnectionHandlerID connection handler to query the value on. + * @param limit address of a variable to receive the limit in bytes per second. + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason +*/ +EXPORTDLL unsigned int ts3client_getServerConnectionHandlerSpeedLimitDown(uint64 serverConnectionHandlerID, uint64* limit); + +/** + * @brief get the speed limit for a specific file transfer. + * + * @param transferID specifies which transfer to query. + * @param limit address of a variable to receive the transfer limit in bytes per second. + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason +*/ +EXPORTDLL unsigned int ts3client_getTransferSpeedLimit(anyID transferID, uint64* limit); + +/** + * @brief set the instance wide upload speed limit for file transfer. + * + * All concurrent file transfers combined will not exceed min(instance limit, virtual server limit) bytes per second. + * The limit is temporary and valid only for the lifetime of the connection handler. + * + * @param newLimit maximum upload speed in bytes per second. Must be >= 5120. + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason +*/ +EXPORTDLL unsigned int ts3client_setInstanceSpeedLimitUp(uint64 newLimit); + +/** + * @brief set the instance wide download speed limit for file transfer. + * + * All concurrent file transfers combined will not exceed min(instance limit, virtual server limit) bytes per second. + * The limit is temporary and valid only for the lifetime of the connection handler. + * + * @param newLimit maximum download speed in bytes per second. Must be >= 5120. + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason +*/ +EXPORTDLL unsigned int ts3client_setInstanceSpeedLimitDown(uint64 newLimit); + +/** + * @brief set the virtual server upload speed limit for file transfer. + * + * All concurrent file transfers combined will not exceed min(instance limit, virtual server limit) bytes per second. + * The limit is temporary and valid only for the lifetime of the connection handler. + * + * @param serverConnectionHandlerID connection handler on which to set the limit. + * @param newLimit maximum upload speed in bytes per second. Must be >= 5120. + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason +*/ +EXPORTDLL unsigned int ts3client_setServerConnectionHandlerSpeedLimitUp(uint64 serverConnectionHandlerID, uint64 newLimit); + +/** + * @brief set the virtual server download speed limit for file transfer. + * + * All concurrent file transfers combined will not exceed min(instance limit, virtual server limit) bytes per second. + * The limit is temporary and valid only for the lifetime of the connection handler. + * + * @param serverConnectionHandlerID connection handler on which to set the limit. + * @param newLimit maximum download speed in bytes per second. Must be >= 5120. + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason +*/ +EXPORTDLL unsigned int ts3client_setServerConnectionHandlerSpeedLimitDown(uint64 serverConnectionHandlerID, uint64 newLimit); + +/** + * @brief set the transfer limit for an individual file transfer. + * + * The maximum transfer speed will be min(instance limit, virtual server limit, transfer limit). + * Whether the limit is upload or download depends on what kind of transfer the specified transfer is. + * + * @param transferID the transfer to set the limit for + * @param newLimit the new maximum speed in bytes per second. Must be >= 5120. + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason +*/ +EXPORTDLL unsigned int ts3client_setTransferSpeedLimit(anyID transferID, uint64 newLimit); + +/** + * @brief Request a login token for the chat server associated with the specified virtual server + * + * @param serverConnectionHandlerID connection handler on which to request the chat login token + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason + */ +EXPORTDLL unsigned int ts3client_getChatLoginToken(uint64 serverConnectionHandlerID); + +/** + * @brief Request an authentication token from the specified virtual server + * + * @param serverConnectionHandlerID connection handler on which to request the authentication token + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason + */ +EXPORTDLL unsigned int ts3client_getAuthenticationToken(uint64 serverConnectionHandlerID); + +#ifdef __cplusplus +} +#endif + +#endif diff --git a/include/teamspeak/public_definitions.h b/include/teamspeak/public_definitions.h index 471dc71..048c336 100644 --- a/include/teamspeak/public_definitions.h +++ b/include/teamspeak/public_definitions.h @@ -3,389 +3,577 @@ #include "teamlog/logtypes.h" -//limited length, measured in characters -#define TS3_MAX_SIZE_CHANNEL_NAME 40 -#define TS3_MAX_SIZE_VIRTUALSERVER_NAME 64 -#define TS3_MAX_SIZE_CLIENT_NICKNAME 64 -#define TS3_MIN_SIZE_CLIENT_NICKNAME 3 -#define TS3_MAX_SIZE_REASON_MESSAGE 80 +#define TS3_MAX_SIZE_CHANNEL_NAME 40 // channel name maximum length in characters +#define TS3_MAX_SIZE_VIRTUALSERVER_NAME 64 // virtual server name maximum length in characters +#define TS3_MAX_SIZE_CLIENT_NICKNAME 64 // client display name length limit in characters +#define TS3_MIN_SIZE_CLIENT_NICKNAME 3 // client display name minimum length in characters +#define TS3_MAX_SIZE_REASON_MESSAGE 80 // length limit in characters for kick, move, etc reasons -//limited length, measured in bytes (utf8 encoded) -#define TS3_MAX_SIZE_TEXTMESSAGE 8192 -#define TS3_MAX_SIZE_CHANNEL_TOPIC 255 -#define TS3_MAX_SIZE_CHANNEL_DESCRIPTION 8192 +#define TS3_MAX_SIZE_TEXTMESSAGE 8192 // text message length limit, measured in bytes (utf8 encoded) +#define TS3_MAX_SIZE_CHANNEL_TOPIC 255 // channel topic lengt limith, measured in bytes (utf8 encoded) +#define TS3_MAX_SIZE_CHANNEL_DESCRIPTION 8192 // channel description length limit, measured in bytes (utf8 encoded) +// server welcome message length limit measured in bytes (utf8 encoded) #define TS3_MAX_SIZE_VIRTUALSERVER_WELCOMEMESSAGE 1024 #define TS3_SIZE_MYTSID 44 - -//minimum amount of seconds before a clientID that was in use can be assigned to a new client +// minimum amount of seconds before a clientID that was in use can be assigned to a new client #define TS3_MIN_SECONDS_CLIENTID_REUSE 300 #if defined(WIN32) || defined(__WIN32__) || defined(_WIN32) - typedef unsigned __int16 anyID; - typedef unsigned __int64 uint64; - #ifdef BUILDING_DLL - #define EXPORTDLL __declspec(dllexport) - #else - #define EXPORTDLL - #endif +typedef unsigned __int16 anyID; +typedef unsigned __int64 uint64; +#ifndef EXPORTDLL +#ifdef BUILDING_DLL +#define EXPORTDLL __declspec(dllexport) #else - #include - typedef uint16_t anyID; - typedef uint64_t uint64; - #ifdef BUILDING_DLL - #define EXPORTDLL __attribute__ ((visibility("default"))) - #else - #define EXPORTDLL - #endif +#define EXPORTDLL +#endif +#endif +#else +#include +typedef uint16_t anyID; +typedef uint64_t uint64; +#ifndef EXPORTDLL +#ifdef BUILDING_DLL +#define EXPORTDLL __attribute__((visibility("default"))) +#else +#define EXPORTDLL +#endif +#endif #endif +enum Visibility { + ENTER_VISIBILITY = 0, ///< Client joined from an unsubscribed channel, or joined the server. + RETAIN_VISIBILITY, ///< Client switched from one subscribed channel to a different subscribed channel. + LEAVE_VISIBILITY ///< Client switches to an unsubscribed channel, or disconnected from server. +}; + +enum ConnectStatus { + STATUS_DISCONNECTED = 0, ///< There is no activity to the server, this is the default value + STATUS_CONNECTING, ///< We are trying to connect, we haven't got a client id yet, we haven't been accepted by the server + STATUS_CONNECTED, ///< The server has accepted us, we can talk and hear and we have a client id, but we don't + ///< have the channels and clients yet, we can get server infos (welcome msg etc.) + STATUS_CONNECTION_ESTABLISHING, ///< we are connected and we are visible + STATUS_CONNECTION_ESTABLISHED, ///< we are connected and we have the client and channels available +}; + +enum LocalTestMode { TEST_MODE_OFF = 0, TEST_MODE_VOICE_LOCAL_ONLY, TEST_MODE_VOICE_LOCAL_AND_REMOTE, TEST_MODE_TALK_STATUS_CHANGES_ONLY }; + enum TalkStatus { - STATUS_NOT_TALKING = 0, - STATUS_TALKING = 1, - STATUS_TALKING_WHILE_DISABLED = 2, + STATUS_NOT_TALKING = 0, ///< client is not talking + STATUS_TALKING = 1, ///< client is talking + STATUS_TALKING_WHILE_DISABLED = 2, ///< client is talking while the microphone is muted (only valid for own client) }; enum CodecType { - CODEC_SPEEX_NARROWBAND = 0, //mono, 16bit, 8kHz, bitrate dependent on the quality setting - CODEC_SPEEX_WIDEBAND, //mono, 16bit, 16kHz, bitrate dependent on the quality setting - CODEC_SPEEX_ULTRAWIDEBAND, //mono, 16bit, 32kHz, bitrate dependent on the quality setting - CODEC_CELT_MONO, //mono, 16bit, 48kHz, bitrate dependent on the quality setting - CODEC_OPUS_VOICE, //mono, 16bit, 48khz, bitrate dependent on the quality setting, optimized for voice - CODEC_OPUS_MUSIC, //stereo, 16bit, 48khz, bitrate dependent on the quality setting, optimized for music + CODEC_SPEEX_NARROWBAND = 0, ///< (deprecated) mono, 16bit, 8kHz, bitrate dependent on the quality setting + CODEC_SPEEX_WIDEBAND, ///< (deprecated) mono, 16bit, 16kHz, bitrate dependent on the quality setting + CODEC_SPEEX_ULTRAWIDEBAND, ///< (deprecated) mono, 16bit, 32kHz, bitrate dependent on the quality setting + CODEC_CELT_MONO, ///< (deprecated) mono, 16bit, 48kHz, bitrate dependent on the quality setting + CODEC_OPUS_VOICE, ///< mono, 16bit, 48khz, bitrate dependent on the quality setting, optimized for voice + CODEC_OPUS_MUSIC, ///< stereo, 16bit, 48khz, bitrate dependent on the quality setting, optimized for music }; enum CodecEncryptionMode { - CODEC_ENCRYPTION_PER_CHANNEL = 0, - CODEC_ENCRYPTION_FORCED_OFF, - CODEC_ENCRYPTION_FORCED_ON, + CODEC_ENCRYPTION_PER_CHANNEL = 0, ///< voice data encryption decided per channel + CODEC_ENCRYPTION_FORCED_OFF, ///< voice data encryption disabled + CODEC_ENCRYPTION_FORCED_ON, ///< voice data encryption enabled }; enum TextMessageTargetMode { - TextMessageTarget_CLIENT=1, - TextMessageTarget_CHANNEL, - TextMessageTarget_SERVER, - TextMessageTarget_MAX + TextMessageTarget_CLIENT = 1, ///< Message is a private message to another client + TextMessageTarget_CHANNEL, ///< Message is sent to a channel, received by all clients in that channel at the time + TextMessageTarget_SERVER, ///< Message is sent to every client on the server + TextMessageTarget_MAX }; enum MuteInputStatus { - MUTEINPUT_NONE = 0, - MUTEINPUT_MUTED, + MUTEINPUT_NONE = 0, ///< Microphone is not muted, audio is sent to the server + MUTEINPUT_MUTED, ///< Microphone is muted, no audio is transmitted to the server }; enum MuteOutputStatus { - MUTEOUTPUT_NONE = 0, - MUTEOUTPUT_MUTED, + MUTEOUTPUT_NONE = 0, ///< Speaker is active, server is sending us audio + MUTEOUTPUT_MUTED, ///< Speaker is muted, server is not sending audio to us }; enum HardwareInputStatus { - HARDWAREINPUT_DISABLED = 0, - HARDWAREINPUT_ENABLED, + HARDWAREINPUT_DISABLED = 0, ///< no capture device opened + HARDWAREINPUT_ENABLED, ///< capture device open }; enum HardwareOutputStatus { - HARDWAREOUTPUT_DISABLED = 0, - HARDWAREOUTPUT_ENABLED, + HARDWAREOUTPUT_DISABLED = 0, ///< no playback device opened + HARDWAREOUTPUT_ENABLED, ///< playback device open }; enum InputDeactivationStatus { - INPUT_ACTIVE = 0, - INPUT_DEACTIVATED = 1, + INPUT_ACTIVE = 0, ///< Audio is captured from the capture device. + INPUT_DEACTIVATED = 1, ///< No audio is captured from the capture device. }; enum ReasonIdentifier { - REASON_NONE = 0, //no reason data - REASON_MOVED = 1, //{SectionInvoker} - REASON_SUBSCRIPTION = 2, //no reason data - REASON_LOST_CONNECTION = 3, //reasonmsg=reason - REASON_KICK_CHANNEL = 4, //{SectionInvoker} reasonmsg=reason //{SectionInvoker} is only added server->client - REASON_KICK_SERVER = 5, //{SectionInvoker} reasonmsg=reason //{SectionInvoker} is only added server->client - REASON_KICK_SERVER_BAN = 6, //{SectionInvoker} reasonmsg=reason bantime=time //{SectionInvoker} is only added server->client - REASON_SERVERSTOP = 7, //reasonmsg=reason - REASON_CLIENTDISCONNECT = 8, //reasonmsg=reason - REASON_CHANNELUPDATE = 9, //no reason data - REASON_CHANNELEDIT = 10, //{SectionInvoker} - REASON_CLIENTDISCONNECT_SERVER_SHUTDOWN = 11, //reasonmsg=reason + REASON_NONE = 0, ///< no reason data + REASON_MOVED = 1, ///< client was moved + REASON_SUBSCRIPTION = 2, // no reason data + REASON_LOST_CONNECTION = 3, // reasonmsg=reason + REASON_KICK_CHANNEL = 4, //{SectionInvoker} reasonmsg=reason //{SectionInvoker} is only added server->client + REASON_KICK_SERVER = 5, //{SectionInvoker} reasonmsg=reason //{SectionInvoker} is only added server->client + REASON_KICK_SERVER_BAN = 6, //{SectionInvoker} reasonmsg=reason bantime=time //{SectionInvoker} is only added server->client + REASON_SERVERSTOP = 7, // reasonmsg=reason + REASON_CLIENTDISCONNECT = 8, // reasonmsg=reason + REASON_CHANNELUPDATE = 9, // no reason data + REASON_CHANNELEDIT = 10, //{SectionInvoker} + REASON_CLIENTDISCONNECT_SERVER_SHUTDOWN = 11, // reasonmsg=reason }; +enum Protocol_Encryption_Cipher { AES_128 = 0, AES_256, PROTOCOL_ENCRYPTION_CIPHER_END_MARKER }; + enum ChannelProperties { - CHANNEL_NAME = 0, //Available for all channels that are "in view", always up-to-date - CHANNEL_TOPIC, //Available for all channels that are "in view", always up-to-date - CHANNEL_DESCRIPTION, //Must be requested (=> requestChannelDescription) - CHANNEL_PASSWORD, //not available client side - CHANNEL_CODEC, //Available for all channels that are "in view", always up-to-date - CHANNEL_CODEC_QUALITY, //Available for all channels that are "in view", always up-to-date - CHANNEL_MAXCLIENTS, //Available for all channels that are "in view", always up-to-date - CHANNEL_MAXFAMILYCLIENTS, //Available for all channels that are "in view", always up-to-date - CHANNEL_ORDER, //Available for all channels that are "in view", always up-to-date - CHANNEL_FLAG_PERMANENT, //Available for all channels that are "in view", always up-to-date - CHANNEL_FLAG_SEMI_PERMANENT, //Available for all channels that are "in view", always up-to-date - CHANNEL_FLAG_DEFAULT, //Available for all channels that are "in view", always up-to-date - CHANNEL_FLAG_PASSWORD, //Available for all channels that are "in view", always up-to-date - CHANNEL_CODEC_LATENCY_FACTOR, //Available for all channels that are "in view", always up-to-date - CHANNEL_CODEC_IS_UNENCRYPTED, //Available for all channels that are "in view", always up-to-date - CHANNEL_SECURITY_SALT, //Not available client side, not used in teamspeak, only SDK. Sets the options+salt for security hash. - CHANNEL_DELETE_DELAY, //How many seconds to wait before deleting this channel - CHANNEL_ENDMARKER, + CHANNEL_NAME = 0, ///< String. Read/Write. Name of the channel. Always available. + CHANNEL_TOPIC, ///< String. Read/Write. Short single line text describing what the channel is about. Always available. + CHANNEL_DESCRIPTION, ///< String. Read/Write. Arbitrary text (up to 8k bytes) with information about the channel. + ///< Must be requested (\ref ts3client_requestChannelDescription) + CHANNEL_PASSWORD, ///< String. Read/Write. Password of the channel. Read access is limited to the server. Clients + ///< will only ever see the last password they attempted to use when joining the channel. Always available. + CHANNEL_CODEC, ///< Integer. Read/Write. The codec this channel is using. One of the values from the \ref CodecType + ///< enum. Always available. + CHANNEL_CODEC_QUALITY, ///< Integer. Read/Write. The quality setting of the channel. Valid values are 0 to 10 inclusive. + ///< Higher value means better voice quality but also more bandwidth usage. Always available. + CHANNEL_MAXCLIENTS, ///< Integer. Read/Write. The number of clients that can be in the channel simultaneously. + ///< Always available. + CHANNEL_MAXFAMILYCLIENTS, ///< Integer. Read/Write. The total number of clients that can be in this channel and all + ///< sub channels of this channel. Always available. + CHANNEL_ORDER, ///< UInt64. Read/Write. The ID of the channel below which this channel should be displayed. If 0 + ///< the channel is sorted at the top of the current level. Always available. + CHANNEL_FLAG_PERMANENT, ///< Integer. Read/Write. Boolean (1/0) indicating whether the channel remains when empty. + ///< Permanent channels are stored to the database and available after server restart. SDK + ///< users will need to take care of restoring channel at server start on their own. + ///< Mutually exclusive with \ref CHANNEL_FLAG_SEMI_PERMANENT. Always available. + CHANNEL_FLAG_SEMI_PERMANENT, ///< Integer. Read/Write. Boolean (1/0) indicating whether the channel remains when + ///< empty. Semi permanent channels are not stored to disk and gone after server + ///< restart but remain while empty. Mutually exclusive with \ref + ///< CHANNEL_FLAG_PERMANENT. Always available. + CHANNEL_FLAG_DEFAULT, ///< Integer. Read/Write. Boolean (1/0). The default channel is the channel that all clients + ///< are located in when they join the server, unless the client explicitly specified a + ///< different channel when connecting and is allowed to join their preferred channel. Only + ///< one channel on the server can have this flag set. The default channel must have \ref + ///< CHANNEL_FLAG_PERMANENT set. Always available. + CHANNEL_FLAG_PASSWORD, ///< Integer. Read/Write. Boolean (1/0) indicating whether this channel is password protected. + ///< When removing or setting \ref CHANNEL_PASSWORD you also need to adjust this flag. + CHANNEL_CODEC_LATENCY_FACTOR, ///< (deprecated) Integer. Read/Write. Allows to increase packet size, reducing + ///< bandwith at the cost of higher latency of voice transmission. Valid values are + ///< 1-10 inclusive. 1 is the default and offers the lowest latency. Always available. + CHANNEL_CODEC_IS_UNENCRYPTED, ///< Integer. Read/Write. Boolean (1/0). If 0 voice data is encrypted, if 1 the voice + ///< data is not encrypted. Only used if the server \ref + ///< VIRTUALSERVER_CODEC_ENCRYPTION_MODE is set to \ref CODEC_ENCRYPTION_PER_CHANNEL. + ///< Always available. + CHANNEL_SECURITY_SALT, ///< String. Read/Write. SDK Only, not used by TeamSpeak. This channels security hash. When + ///< a client joins their \ref CLIENT_SECURITY_HASH is compared to this value, to allow or + ///< deny the client access to the channel. Used to enforce clients joining the server with + ///< specific identity and \ref CLIENT_META_DATA. See SDK Documentation about this feature + ///< for further details. Always available. + CHANNEL_DELETE_DELAY, ///< UInt64. Read/Write. Number of seconds deletion of temporary channels is delayed after + ///< the last client leaves the channel. Channel is only deleted if empty when the delete + ///< delay expired. Always available. + CHANNEL_UNIQUE_IDENTIFIER, ///< String. Read only. An identifier that uniquely identifies a channel. Available in + ///< Server >= 3.10.0 + CHANNEL_ENDMARKER, }; enum ClientProperties { - CLIENT_UNIQUE_IDENTIFIER = 0, //automatically up-to-date for any client "in view", can be used to identify this particular client installation - CLIENT_NICKNAME, //automatically up-to-date for any client "in view" - CLIENT_VERSION, //for other clients than ourself, this needs to be requested (=> requestClientVariables) - CLIENT_PLATFORM, //for other clients than ourself, this needs to be requested (=> requestClientVariables) - CLIENT_FLAG_TALKING, //automatically up-to-date for any client that can be heard (in room / whisper) - CLIENT_INPUT_MUTED, //automatically up-to-date for any client "in view", this clients microphone mute status - CLIENT_OUTPUT_MUTED, //automatically up-to-date for any client "in view", this clients headphones/speakers/mic combined mute status - CLIENT_OUTPUTONLY_MUTED, //automatically up-to-date for any client "in view", this clients headphones/speakers only mute status - CLIENT_INPUT_HARDWARE, //automatically up-to-date for any client "in view", this clients microphone hardware status (is the capture device opened?) - CLIENT_OUTPUT_HARDWARE, //automatically up-to-date for any client "in view", this clients headphone/speakers hardware status (is the playback device opened?) - CLIENT_INPUT_DEACTIVATED, //only usable for ourself, not propagated to the network - CLIENT_IDLE_TIME, //internal use - CLIENT_DEFAULT_CHANNEL, //only usable for ourself, the default channel we used to connect on our last connection attempt - CLIENT_DEFAULT_CHANNEL_PASSWORD, //internal use - CLIENT_SERVER_PASSWORD, //internal use - CLIENT_META_DATA, //automatically up-to-date for any client "in view", not used by TeamSpeak, free storage for sdk users - CLIENT_IS_MUTED, //only make sense on the client side locally, "1" if this client is currently muted by us, "0" if he is not - CLIENT_IS_RECORDING, //automatically up-to-date for any client "in view" - CLIENT_VOLUME_MODIFICATOR, //internal use - CLIENT_VERSION_SIGN, //sign - CLIENT_SECURITY_HASH, //SDK use, not used by teamspeak. Hash is provided by an outside source. A channel will use the security salt + other client data to calculate a hash, which must be the same as the one provided here. - CLIENT_ENCRYPTION_CIPHERS, //internal use - CLIENT_ENDMARKER, + CLIENT_UNIQUE_IDENTIFIER = 0, ///< String. Read only. Public Identity, can be used to identify a client + ///< installation. Remains identical as long as the client keeps using the same + ///< identity. Available for visible clients. + CLIENT_NICKNAME, ///< String. Read/Write. Display name of the client. Available for visible clients. + CLIENT_VERSION, ///< String. Read only. Version String of the client used. For clients other than ourself this + ///< needs to be requested (\ref ts3client_requestClientVariables). + CLIENT_PLATFORM, ///< String. Read only. Operating system used by the client. For other clients other than ourself + ///< this needs to be requested (\ref ts3client_requestClientVariables). + CLIENT_FLAG_TALKING, ///< Integer. Read only. Whether the client is talking. Available on clients that are either + ///< whispering to us, or in our channel. + CLIENT_INPUT_MUTED, ///< Integer. Read/Write. Microphone mute status. Available for visible clients. One of the + ///< values from the \ref MuteInputStatus enum. + CLIENT_OUTPUT_MUTED, ///< Integer. Read only. Speaker mute status. Speaker mute implies microphone mute. Available + ///< for visible clients. One of the values from the \ref MuteOutputStatus enum. + CLIENT_OUTPUTONLY_MUTED, ///< Integer. Read only. Speaker mute status. Microphone may be active. Available for + ///< visible clients. One of the values from the \ref MuteOutputStatus enum. + CLIENT_INPUT_HARDWARE, ///< Integer. Read only. Indicates whether a capture device is open. Available for visible + ///< clients. One of the values from the \ref HardwareInputStatus enum. + CLIENT_OUTPUT_HARDWARE, ///< Integer. Read only. Indicates whether a playback device is open. Available for visible + ///< clients. One of the values from the \ref HardwareOutputStatus enum. + CLIENT_INPUT_DEACTIVATED, ///< Integer. Read/Write. Not available server side. Local microphone mute status. + ///< Available only for own client. Used to implement Push To Talk. One of the values from + ///< the \ref InputDeactivationStatus enum. + CLIENT_IDLE_TIME, ///< UInt64. Read only. Seconds since last activity. Available only for own client. + CLIENT_DEFAULT_CHANNEL, ///< String. Read only. User specified channel they joined when connecting to the server. + ///< Available only for own client. + CLIENT_DEFAULT_CHANNEL_PASSWORD, ///< String. Read only. User specified channel password for the channel they + ///< attempted to join when connecting to the server. Available only for own + ///< client. + CLIENT_SERVER_PASSWORD, ///< String. Read only. User specified server password. Available only for own client. + CLIENT_META_DATA, ///< String. Read/Write. Can be used to store up to 4096 bytes of information on clients. Not + ///< used by TeamSpeak. Available for visible clients. + CLIENT_IS_MUTED, ///< Integer. Read only. Not available server side. Indicates whether we have muted the client + ///< using \ref ts3client_requestMuteClients. Available for visible clients other than ourselves. + CLIENT_IS_RECORDING, ///< Integer. Read only. Indicates whether the client is recording incoming audio. Available + ///< for visible clients. + CLIENT_VOLUME_MODIFICATOR, ///< Integer. Read only. Volume adjustment for this client as set by \ref + ///< ts3client_setClientVolumeModifier. Available for visible clients. + CLIENT_VERSION_SIGN, ///< String. Read only. TeamSpeak internal signature. + CLIENT_SECURITY_HASH, ///< String. Read/Write. This clients security hash. Not used by TeamSpeak, SDK only. Hash is + ///< provided by an outside source. A channel will use the security salt + other client data + ///< to calculate a hash, which must be the same as the one provided here. See SDK + ///< documentation about Client / Channel Security Hashes for more details. + CLIENT_ENCRYPTION_CIPHERS, ///< String. Read only. SDK only. List of available ciphers this client can use. + CLIENT_ENDMARKER, }; enum VirtualServerProperties { - VIRTUALSERVER_UNIQUE_IDENTIFIER = 0, //available when connected, can be used to identify this particular server installation - VIRTUALSERVER_NAME, //available and always up-to-date when connected - VIRTUALSERVER_WELCOMEMESSAGE, //available when connected, (=> requestServerVariables) - VIRTUALSERVER_PLATFORM, //available when connected - VIRTUALSERVER_VERSION, //available when connected - VIRTUALSERVER_MAXCLIENTS, //only available on request (=> requestServerVariables), stores the maximum number of clients that may currently join the server - VIRTUALSERVER_PASSWORD, //not available to clients, the server password - VIRTUALSERVER_CLIENTS_ONLINE, //only available on request (=> requestServerVariables), - VIRTUALSERVER_CHANNELS_ONLINE, //only available on request (=> requestServerVariables), - VIRTUALSERVER_CREATED, //available when connected, stores the time when the server was created - VIRTUALSERVER_UPTIME, //only available on request (=> requestServerVariables), the time since the server was started - VIRTUALSERVER_CODEC_ENCRYPTION_MODE, //available and always up-to-date when connected - VIRTUALSERVER_ENCRYPTION_CIPHERS, //internal use - VIRTUALSERVER_ENDMARKER, + VIRTUALSERVER_UNIQUE_IDENTIFIER = 0, ///< String. Read only. Unique identifier for a virtual server, does not + ///< change on server restart. Available if \ref ts3client_getConnectionStatus + ///< is >= \ref STATUS_CONNECTED. + VIRTUALSERVER_NAME, ///< String. Read/Write. The virtual server display name. Available if \ref + ///< ts3client_getConnectionStatus is >= \ref STATUS_CONNECTED. + VIRTUALSERVER_WELCOMEMESSAGE, ///< String. Read/Write. The welcome message displayed to clients on connect. + ///< Available if \ref ts3client_getConnectionStatus is >= \ref STATUS_CONNECTED. Not + ///< updated automatically when changed, updates need to be requested (\ref + ///< ts3client_requestServerVariables). + VIRTUALSERVER_PLATFORM, ///< String. Read only. The operating system the server is running on. Available if \ref + ///< ts3client_getConnectionStatus is >= \ref STATUS_CONNECTED. + VIRTUALSERVER_VERSION, ///< String. Read only. The server software version string. Available if \ref + ///< ts3client_getConnectionStatus is >= \ref STATUS_CONNECTED. + VIRTUALSERVER_MAXCLIENTS, ///< UInt64. Read/Write. The maximum number of clients that can be connected + ///< simultaneously. Only available on request (\ref ts3client_requestServerVariables). + VIRTUALSERVER_PASSWORD, ///< String. Read/Write. The server password. Read access is limited to the server. Clients + ///< will only get the password they supplied when connecting. Available if \ref + ///< ts3client_getConnectionStatus is >= \ref STATUS_CONNECTED. + VIRTUALSERVER_CLIENTS_ONLINE, ///< UInt64. Read only. The current number of clients connected to the server, + ///< including query connections. Only available on request (\ref + ///< ts3client_requestServerVariables). + VIRTUALSERVER_CHANNELS_ONLINE, ///< UInt64. Read only. The current number of channels on the server. Only + ///< available on request (\ref ts3client_requestServerVariables). + VIRTUALSERVER_CREATED, ///< Integer. Read only. The time this virtual server was created as unix timestamp. + ///< Available if \ref ts3client_getConnectionStatus is >= \ref STATUS_CONNECTED. + VIRTUALSERVER_UPTIME, ///< UInt64. Read only. Number of seconds that have passed since the virtual server was + ///< started. Only available on request (\ref ts3client_requestServerVariables). + VIRTUALSERVER_CODEC_ENCRYPTION_MODE, ///< Integer. Read/Write. Boolean (1/0) that specifies if voice data is encrypted + ///< during transfer. One of the values from the \ref CodecEncryptionMode enum. + ///< Available if \ref ts3client_getConnectionStatus is >= \ref STATUS_CONNECTED. + VIRTUALSERVER_ENCRYPTION_CIPHERS, ///< String. Read/Write. Comma separated list of available ciphers to encrypt the + ///< connection. The server will use the first cipher in the list that is also + ///< listed in the \ref CLIENT_ENCRYPTION_CIPHERS of the connecting client. + ///< Clients will fail to connect if no match is found. Always available. + VIRTUALSERVER_ENDMARKER, + VIRTUALSERVER_FILEBASE = 24, ///< String. Read only. The path to the base directory used to store files + ///< transferred using file transfer. Available only on the server. Is set by \ref + ///< ts3server_enableFileManager + VIRTUALSERVER_MAX_DOWNLOAD_TOTAL_BANDWIDTH = 29, ///< UInt64. Read/Write. Maximum traffic in bytes the server can + ///< use for file transfer downloads. Only available on request + ///< (\ref ts3client_requestServerVariables). + VIRTUALSERVER_MAX_UPLOAD_TOTAL_BANDWIDTH = 30, ///< UInt64. Read/Write. Maximum traffic in bytes the server can use + ///< for file transfer uploads. Only available on request (=> + ///< requestServerVariables) + VIRTUALSERVER_LOG_FILETRANSFER = 64 ///< Integer. Read/Write. Boolean (1/0) indicating whether to include file + ///< transfer activities (uploading or downloading of files) in the server log. + ///< Always available. }; +/** + * Various connection properties. + * These are all read only, and except for your own client must be requested using \ref ts3client_requestConnectionInfo + */ enum ConnectionProperties { - CONNECTION_PING = 0, //average latency for a round trip through and back this connection - CONNECTION_PING_DEVIATION, //standard deviation of the above average latency - CONNECTION_CONNECTED_TIME, //how long the connection exists already - CONNECTION_IDLE_TIME, //how long since the last action of this client - CONNECTION_CLIENT_IP, //IP of this client (as seen from the server side) - CONNECTION_CLIENT_PORT, //Port of this client (as seen from the server side) - CONNECTION_SERVER_IP, //IP of the server (seen from the client side) - only available on yourself, not for remote clients, not available server side - CONNECTION_SERVER_PORT, //Port of the server (seen from the client side) - only available on yourself, not for remote clients, not available server side - CONNECTION_PACKETS_SENT_SPEECH, //how many Speech packets were sent through this connection - CONNECTION_PACKETS_SENT_KEEPALIVE, - CONNECTION_PACKETS_SENT_CONTROL, - CONNECTION_PACKETS_SENT_TOTAL, //how many packets were sent totally (this is PACKETS_SENT_SPEECH + PACKETS_SENT_KEEPALIVE + PACKETS_SENT_CONTROL) - CONNECTION_BYTES_SENT_SPEECH, - CONNECTION_BYTES_SENT_KEEPALIVE, - CONNECTION_BYTES_SENT_CONTROL, - CONNECTION_BYTES_SENT_TOTAL, - CONNECTION_PACKETS_RECEIVED_SPEECH, - CONNECTION_PACKETS_RECEIVED_KEEPALIVE, - CONNECTION_PACKETS_RECEIVED_CONTROL, - CONNECTION_PACKETS_RECEIVED_TOTAL, - CONNECTION_BYTES_RECEIVED_SPEECH, - CONNECTION_BYTES_RECEIVED_KEEPALIVE, - CONNECTION_BYTES_RECEIVED_CONTROL, - CONNECTION_BYTES_RECEIVED_TOTAL, - CONNECTION_PACKETLOSS_SPEECH, - CONNECTION_PACKETLOSS_KEEPALIVE, - CONNECTION_PACKETLOSS_CONTROL, - CONNECTION_PACKETLOSS_TOTAL, //the probability with which a packet round trip failed because a packet was lost - CONNECTION_SERVER2CLIENT_PACKETLOSS_SPEECH, //the probability with which a speech packet failed from the server to the client - CONNECTION_SERVER2CLIENT_PACKETLOSS_KEEPALIVE, - CONNECTION_SERVER2CLIENT_PACKETLOSS_CONTROL, - CONNECTION_SERVER2CLIENT_PACKETLOSS_TOTAL, - CONNECTION_CLIENT2SERVER_PACKETLOSS_SPEECH, - CONNECTION_CLIENT2SERVER_PACKETLOSS_KEEPALIVE, - CONNECTION_CLIENT2SERVER_PACKETLOSS_CONTROL, - CONNECTION_CLIENT2SERVER_PACKETLOSS_TOTAL, - CONNECTION_BANDWIDTH_SENT_LAST_SECOND_SPEECH, //howmany bytes of speech packets we sent during the last second - CONNECTION_BANDWIDTH_SENT_LAST_SECOND_KEEPALIVE, - CONNECTION_BANDWIDTH_SENT_LAST_SECOND_CONTROL, - CONNECTION_BANDWIDTH_SENT_LAST_SECOND_TOTAL, - CONNECTION_BANDWIDTH_SENT_LAST_MINUTE_SPEECH, //howmany bytes/s of speech packets we sent in average during the last minute - CONNECTION_BANDWIDTH_SENT_LAST_MINUTE_KEEPALIVE, - CONNECTION_BANDWIDTH_SENT_LAST_MINUTE_CONTROL, - CONNECTION_BANDWIDTH_SENT_LAST_MINUTE_TOTAL, - CONNECTION_BANDWIDTH_RECEIVED_LAST_SECOND_SPEECH, - CONNECTION_BANDWIDTH_RECEIVED_LAST_SECOND_KEEPALIVE, - CONNECTION_BANDWIDTH_RECEIVED_LAST_SECOND_CONTROL, - CONNECTION_BANDWIDTH_RECEIVED_LAST_SECOND_TOTAL, - CONNECTION_BANDWIDTH_RECEIVED_LAST_MINUTE_SPEECH, - CONNECTION_BANDWIDTH_RECEIVED_LAST_MINUTE_KEEPALIVE, - CONNECTION_BANDWIDTH_RECEIVED_LAST_MINUTE_CONTROL, - CONNECTION_BANDWIDTH_RECEIVED_LAST_MINUTE_TOTAL, - CONNECTION_ENDMARKER, + CONNECTION_PING = 0, ///< UInt64. Round trip latency for the connection based on the last 5 seconds. On the server + ///< this is the average across all connected clients for the last 5 seconds. + CONNECTION_PING_DEVIATION, ///< Double. Standard deviation for the round trip latency in \ref CONNECTION_PING + CONNECTION_CONNECTED_TIME, ///< UInt64. Seconds the client has been connected. + CONNECTION_IDLE_TIME, ///< UInt64. Time in seconds since the last activity (voice transmission, switching channels, + ///< changing mic / speaker mute status) of the client. + CONNECTION_CLIENT_IP, ///< String. IP of this client (as seen from the server side) + CONNECTION_CLIENT_PORT, ///< UInt64. Client side port of this client (as seen from the server side) + CONNECTION_SERVER_IP, ///< String. The IP or hostname used to connect to the server. Only available on yourself. + CONNECTION_SERVER_PORT, ///< UInt64. The server port connected to. Only available on yourself. + CONNECTION_PACKETS_SENT_SPEECH, ///< UInt64. The number of voice packets transmitted by the client. + CONNECTION_PACKETS_SENT_KEEPALIVE, ///< UInt64. The number of keep alive packets transmitted by the client. + CONNECTION_PACKETS_SENT_CONTROL, ///< UInt64. The number of command & control packets transmitted by the client. + CONNECTION_PACKETS_SENT_TOTAL, ///< UInt64. Total number of packets transmitted by the client. Equal to the sum of + ///< \ref CONNECTION_PACKETS_SENT_SPEECH, \ref CONNECTION_PACKETS_SENT_KEEPALIVE and + ///< \ref CONNECTION_PACKETS_SENT_CONTROL + CONNECTION_BYTES_SENT_SPEECH, ///< UInt64. Outgoing traffic used for voice data by the client. + CONNECTION_BYTES_SENT_KEEPALIVE, ///< UInt64. Outgoing traffic used for keeping the connection alive by the client. + CONNECTION_BYTES_SENT_CONTROL, ///< UInt64. Outgoing traffic used for command & control data by the client. + CONNECTION_BYTES_SENT_TOTAL, ///< UInt64. Total outgoing traffic to the server by this client. Equal to the sum of + ///< \ref CONNECTION_BYTES_SENT_SPEECH, \ref CONNECTION_BYTES_SENT_KEEPALIVE and \ref + ///< CONNECTION_BYTES_SENT_CONTROL + CONNECTION_PACKETS_RECEIVED_SPEECH, ///< UInt64. Number of voice packets received by the client. + CONNECTION_PACKETS_RECEIVED_KEEPALIVE, ///< UInt64. Number of keep alive packets received by the client. + CONNECTION_PACKETS_RECEIVED_CONTROL, ///< UInt64. Number of command & control packets received by the client. + CONNECTION_PACKETS_RECEIVED_TOTAL, ///< UInt64. Total number of packets received by the client. Equal to the sum of + ///< \ref CONNECTION_PACKETS_RECEIVED_SPEECH, \ref + ///< CONNECTION_PACKETS_RECEIVED_KEEPALIVE and \ref + ///< CONNECTION_PACKETS_RECEIVED_CONTROL + CONNECTION_BYTES_RECEIVED_SPEECH, ///< UInt64. Incoming traffic used by the client for voice data. + CONNECTION_BYTES_RECEIVED_KEEPALIVE, ///< UInt64. Incoming traffic used by the client to keep the connection alive. + CONNECTION_BYTES_RECEIVED_CONTROL, ///< UInt64. Incoming traffic used by the client for command & control data. + CONNECTION_BYTES_RECEIVED_TOTAL, ///< UInt64. Total incoming traffic used by the client. Equal to the sum of \ref + ///< CONNECTION_BYTES_RECEIVED_SPEECH, \ref CONNECTION_BYTES_RECEIVED_KEEPALIVE and + ///< \ref CONNECTION_BYTES_RECEIVED_CONTROL + CONNECTION_PACKETLOSS_SPEECH, ///< Double. Percentage points of voice packets for the client that did not arrive at + ///< the client or server averaged across the last 5 seconds. + CONNECTION_PACKETLOSS_KEEPALIVE, ///< Double. Percentage points of keep alive packets for the client that did not + ///< arrive at the client or server averaged across the last 5 seconds. + CONNECTION_PACKETLOSS_CONTROL, ///< Double. Percentage points of command & control packets for the client that did + ///< not arrive at the client or server averaged across the last 5 seconds. + CONNECTION_PACKETLOSS_TOTAL, ///< Double. Cumulative chance in percentage points with which a packet round trip + ///< failed because a packet was lost + CONNECTION_SERVER2CLIENT_PACKETLOSS_SPEECH, ///< Double. Probability with which a voice packet sent by the server + ///< was not received by the client. + CONNECTION_SERVER2CLIENT_PACKETLOSS_KEEPALIVE, ///< Double. Probability with which a keepalive packet sent by the + ///< server was not received by the client. + CONNECTION_SERVER2CLIENT_PACKETLOSS_CONTROL, ///< Double. Probability with which a control packet sent by the server + ///< was not received by the client. + CONNECTION_SERVER2CLIENT_PACKETLOSS_TOTAL, ///< Double. Probability with which a packet sent by the server was not + ///< received by the client. + CONNECTION_CLIENT2SERVER_PACKETLOSS_SPEECH, ///< Double. Probability with which a speech packet sent by the client + ///< was not received by the server. + CONNECTION_CLIENT2SERVER_PACKETLOSS_KEEPALIVE, ///< Double. Probability with which a keepalive packet sent by the + ///< client was not received by the server. + CONNECTION_CLIENT2SERVER_PACKETLOSS_CONTROL, ///< Double. Probability with which a control packet sent by the client + ///< was not received by the server. + CONNECTION_CLIENT2SERVER_PACKETLOSS_TOTAL, ///< Double. Probability with which a packet sent by the client was not + ///< received by the server. + CONNECTION_BANDWIDTH_SENT_LAST_SECOND_SPEECH, ///< UInt64. Number of bytes sent for speech data in the last second. + CONNECTION_BANDWIDTH_SENT_LAST_SECOND_KEEPALIVE, ///< UInt64. Number of bytes sent for keepalive data in the last second. + CONNECTION_BANDWIDTH_SENT_LAST_SECOND_CONTROL, ///< UInt64. Number of bytes sent for control data in the last second. + CONNECTION_BANDWIDTH_SENT_LAST_SECOND_TOTAL, ///< UInt64. Number of bytes sent in the last second. + CONNECTION_BANDWIDTH_SENT_LAST_MINUTE_SPEECH, ///< UInt64. Bytes per second sent for speech data, averaged over the + ///< last minute. + CONNECTION_BANDWIDTH_SENT_LAST_MINUTE_KEEPALIVE, ///< UInt64. Bytes per second sent for keepalive data, averaged + ///< over the last minute. + CONNECTION_BANDWIDTH_SENT_LAST_MINUTE_CONTROL, ///< UInt64. Bytes per second sent for control data, averaged over + ///< the last minute. + CONNECTION_BANDWIDTH_SENT_LAST_MINUTE_TOTAL, ///< UInt64. Bytes per second sent, averaged over the last minute. + CONNECTION_BANDWIDTH_RECEIVED_LAST_SECOND_SPEECH, ///< UInt64. Number of bytes received for speech data in the last second. + CONNECTION_BANDWIDTH_RECEIVED_LAST_SECOND_KEEPALIVE, ///< UInt64. Number of bytes received for keepalive data in the + ///< last second. + CONNECTION_BANDWIDTH_RECEIVED_LAST_SECOND_CONTROL, ///< UInt64. Number of bytes received for control data in the + ///< last second. + CONNECTION_BANDWIDTH_RECEIVED_LAST_SECOND_TOTAL, ///< UInt64. Number of bytes received in the last second. + CONNECTION_BANDWIDTH_RECEIVED_LAST_MINUTE_SPEECH, ///< UInt64. Bytes per second received for speech data, averaged + ///< over the last minute. + CONNECTION_BANDWIDTH_RECEIVED_LAST_MINUTE_KEEPALIVE, ///< UInt64. Bytes per second received for keepalive data, + ///< averaged over the last minute. + CONNECTION_BANDWIDTH_RECEIVED_LAST_MINUTE_CONTROL, ///< UInt64. Bytes per second received for control data, averaged + ///< over the last minute. + CONNECTION_BANDWIDTH_RECEIVED_LAST_MINUTE_TOTAL, ///< UInt64. Bytes per second received, averaged over the last minute. + CONNECTION_DUMMY_0, + CONNECTION_DUMMY_1, + CONNECTION_DUMMY_2, + CONNECTION_DUMMY_3, + CONNECTION_DUMMY_4, + CONNECTION_DUMMY_5, + CONNECTION_DUMMY_6, + CONNECTION_DUMMY_7, + CONNECTION_DUMMY_8, + CONNECTION_DUMMY_9, + CONNECTION_FILETRANSFER_BANDWIDTH_SENT, ///< UInt64. Current file transfer upstream activity in bytes per second. + ///< Only available on request (\ref ts3client_requestServerConnectionInfo). + CONNECTION_FILETRANSFER_BANDWIDTH_RECEIVED, ///< UInt64. Current file transfer downstream activity in bytes per + ///< second. Only available on request (\ref + ///< ts3client_requestServerConnectionInfo). + CONNECTION_FILETRANSFER_BYTES_RECEIVED_TOTAL, ///< UInt64. Total downstream traffic, in bytes, used for file + ///< transfer since the server was started. Only available on request + ///< (\ref ts3client_requestServerConnectionInfo). + CONNECTION_FILETRANSFER_BYTES_SENT_TOTAL, ///< UInt64. Total upstream traffic, in bytes, used for file transfer + ///< since the server was started. Only available on request (\ref + ///< ts3client_requestServerConnectionInfo). + CONNECTION_ENDMARKER }; +/** + * Describes a client position in 3 dimensional space, used for 3D Sound. + */ typedef struct { - float x; /* X co-ordinate in 3D space. */ - float y; /* Y co-ordinate in 3D space. */ - float z; /* Z co-ordinate in 3D space. */ + float x; ///< X co-ordinate in 3D space. + float y; ///< Y co-ordinate in 3D space. + float z; ///< Z co-ordinate in 3D space. } TS3_VECTOR; enum GroupWhisperType { - GROUPWHISPERTYPE_SERVERGROUP = 0, - GROUPWHISPERTYPE_CHANNELGROUP = 1, - GROUPWHISPERTYPE_CHANNELCOMMANDER = 2, - GROUPWHISPERTYPE_ALLCLIENTS = 3, - GROUPWHISPERTYPE_ENDMARKER, + GROUPWHISPERTYPE_SERVERGROUP = 0, ///< Whisper list consists of server groups + GROUPWHISPERTYPE_CHANNELGROUP = 1, ///< Whisper list consists of channel groups + GROUPWHISPERTYPE_CHANNELCOMMANDER = 2, ///< whisper to channel commanders + GROUPWHISPERTYPE_ALLCLIENTS = 3, ///< whisper to all clients + GROUPWHISPERTYPE_ENDMARKER, }; enum GroupWhisperTargetMode { - GROUPWHISPERTARGETMODE_ALL = 0, - GROUPWHISPERTARGETMODE_CURRENTCHANNEL = 1, - GROUPWHISPERTARGETMODE_PARENTCHANNEL = 2, - GROUPWHISPERTARGETMODE_ALLPARENTCHANNELS = 3, - GROUPWHISPERTARGETMODE_CHANNELFAMILY = 4, - GROUPWHISPERTARGETMODE_ANCESTORCHANNELFAMILY = 5, - GROUPWHISPERTARGETMODE_SUBCHANNELS = 6, - GROUPWHISPERTARGETMODE_ENDMARKER, + GROUPWHISPERTARGETMODE_ALL = 0, + GROUPWHISPERTARGETMODE_CURRENTCHANNEL = 1, ///< Whisper the current channel of the client + GROUPWHISPERTARGETMODE_PARENTCHANNEL = 2, ///< Whisper the parent channel of whatever channel the client is currently in + GROUPWHISPERTARGETMODE_ALLPARENTCHANNELS = 3, ///< Whipser to the parent channel and all their parent channels as well + GROUPWHISPERTARGETMODE_CHANNELFAMILY = 4, ///< Whisper to the current channel and all its sub channels + GROUPWHISPERTARGETMODE_ANCESTORCHANNELFAMILY = 5, ///< Whisper to the current channel, all its parent and sub channels. + GROUPWHISPERTARGETMODE_SUBCHANNELS = 6, ///< Whisper to all sub channels of the current channel of the client + GROUPWHISPERTARGETMODE_ENDMARKER, }; -enum MonoSoundDestination{ - MONO_SOUND_DESTINATION_ALL =0, /* Send mono sound to all available speakers */ - MONO_SOUND_DESTINATION_FRONT_CENTER =1, /* Send mono sound to front center speaker if available */ - MONO_SOUND_DESTINATION_FRONT_LEFT_AND_RIGHT =2 /* Send mono sound to front left/right speakers if available */ +enum MonoSoundDestination { + MONO_SOUND_DESTINATION_ALL = 0, ///< Send mono sound to all available speakers + MONO_SOUND_DESTINATION_FRONT_CENTER = 1, ///< Send mono sound to front center speaker if available + MONO_SOUND_DESTINATION_FRONT_LEFT_AND_RIGHT = 2 ///< Send mono sound to front left/right speakers if available }; enum SecuritySaltOptions { - SECURITY_SALT_CHECK_NICKNAME = 1, /* put nickname into security hash */ - SECURITY_SALT_CHECK_META_DATA = 2 /* put (game)meta data into security hash */ + SECURITY_SALT_CHECK_NICKNAME = 1, ///< put nickname into security hash + SECURITY_SALT_CHECK_META_DATA = 2 ///< put meta data into security hash }; /*this enum is used to disable client commands on the server*/ -enum ClientCommand{ - CLIENT_COMMAND_requestConnectionInfo = 0, - CLIENT_COMMAND_requestClientMove = 1, - CLIENT_COMMAND_requestXXMuteClients = 2, - CLIENT_COMMAND_requestClientKickFromXXX = 3, - CLIENT_COMMAND_flushChannelCreation = 4, - CLIENT_COMMAND_flushChannelUpdates = 5, - CLIENT_COMMAND_requestChannelMove = 6, - CLIENT_COMMAND_requestChannelDelete = 7, - CLIENT_COMMAND_requestChannelDescription = 8, - CLIENT_COMMAND_requestChannelXXSubscribeXXX = 9, - CLIENT_COMMAND_requestServerConnectionInfo = 10, - CLIENT_COMMAND_requestSendXXXTextMsg = 11, - CLIENT_COMMAND_filetransfers = 12, - CLIENT_COMMAND_ENDMARKER +enum ClientCommand { + CLIENT_COMMAND_requestConnectionInfo = 0, ///< disable client connection info request (client bandwidth usage, ip, + ///< port, ping) + CLIENT_COMMAND_requestClientMove = 1, ///< disable moving clients + CLIENT_COMMAND_requestXXMuteClients = 2, ///< disable muting other clients + CLIENT_COMMAND_requestClientKickFromXXX = 3, ///< disable kicking clients + CLIENT_COMMAND_flushChannelCreation = 4, ///< disable creating channels + CLIENT_COMMAND_flushChannelUpdates = 5, ///< disable editing channels + CLIENT_COMMAND_requestChannelMove = 6, ///< disable moving channels + CLIENT_COMMAND_requestChannelDelete = 7, ///< disable deleting channels + CLIENT_COMMAND_requestChannelDescription = 8, ///< disable channel descriptions + CLIENT_COMMAND_requestChannelXXSubscribeXXX = 9, ///< disable being able to see clients in channels other than the + ///< current channel the client is in + CLIENT_COMMAND_requestServerConnectionInfo = 10, ///< disable server connection info request (server bandwidth + ///< usage, ip, port, ping) + CLIENT_COMMAND_requestSendXXXTextMsg = 11, ///< disable text messaging + CLIENT_COMMAND_filetransfers = 12, ///< disable file transfer + CLIENT_COMMAND_ENDMARKER }; /* Access Control List*/ -enum ACLType{ - ACL_NONE = 0, - ACL_WHITE_LIST = 1, - ACL_BLACK_LIST = 2 -}; +enum ACLType { ACL_NONE = 0, ACL_WHITE_LIST = 1, ACL_BLACK_LIST = 2 }; /* file transfer actions*/ -enum FTAction{ - FT_INIT_SERVER = 0, - FT_INIT_CHANNEL = 1, - FT_UPLOAD = 2, - FT_DOWNLOAD = 3, - FT_DELETE = 4, - FT_CREATEDIR = 5, - FT_RENAME = 6, - FT_FILELIST = 7, - FT_FILEINFO = 8 +enum FTAction { + FT_INIT_SERVER = 0, ///< The virtual server is created. result->channelPath can be changed to create a different + ///< directory than the default 'virtualserver_x' where x is the virtual server. + FT_INIT_CHANNEL = 1, ///< A channel is created. result->channelPath can be changed to create a different directory + ///< then the default 'channel_x' where x is the channel id. + FT_UPLOAD = 2, ///< A file is being uploaded. All values in the result struct can be modified. + FT_DOWNLOAD = 3, ///< A file is being downloaded. All values in the result struct can be modified. + FT_DELETE = 4, ///< A file is being deleted. All values in the result struct can be modified. + FT_CREATEDIR = 5, ///< A directory is being created in a channel. All values in the result struct can be modified. + FT_RENAME = 6, ///< A file or folder is being renamed. The callback will be called twice! Once for the old and then + ///< for the new name. All values in the result struct can be modified. + FT_FILELIST = 7, ///< A directory listing is requested. All values in the result struct can be modified. + FT_FILEINFO = 8 ///< Information of a file is requested. All values in the result struct can be modified. }; /* file transfer status */ enum FileTransferState { - FILETRANSFER_INITIALISING = 0, - FILETRANSFER_ACTIVE, - FILETRANSFER_FINISHED, + FILETRANSFER_INITIALISING = 0, ///< File transfer is establishing connection. + FILETRANSFER_ACTIVE, ///< File transfer is in progress + FILETRANSFER_FINISHED, ///< File transfer has finished }; /* file transfer types */ -enum { - FileListType_Directory = 0, - FileListType_File, +enum FileTransferType { + FileListType_Directory = 0, ///< The file entry is a directory + FileListType_File, ///< The file entry is a regular file }; /* some structs to handle variables in callbacks */ #define MAX_VARIABLES_EXPORT_COUNT 64 -struct VariablesExportItem{ - unsigned char itemIsValid; /* This item has valid values. ignore this item if 0 */ - unsigned char proposedIsSet; /* The value in proposed is set. if 0 ignore proposed */ - const char* current; /* current value (stored in memory) */ - const char* proposed; /* New value to change to (const, so no updates please) */ +struct VariablesExportItem { + unsigned char itemIsValid; ///< Whether or not there is any data in this item. Ignore this item if this is 0. + unsigned char proposedIsSet; ///< The value in proposed is set. If 0 ignore proposed + const char* current; ///< current value (stored in memory) + const char* proposed; ///< New value to change to (const, so no updates please) }; -struct VariablesExport{ - struct VariablesExportItem items[MAX_VARIABLES_EXPORT_COUNT]; +struct VariablesExport { + struct VariablesExportItem items[MAX_VARIABLES_EXPORT_COUNT]; }; -struct ClientMiniExport{ - anyID ID; - uint64 channel; - const char* ident; - const char* nickname; +struct ClientMiniExport { + anyID ID; ///< id of the client + uint64 channel; ///< the channel the client is in + const char* ident; ///< client public identity + const char* nickname; ///< client display name }; -struct TransformFilePathExport{ - uint64 channel; - const char* filename; - int action; - int transformedFileNameMaxSize; - int channelPathMaxSize; +/** + * Structure used to describe a file transfer in the \ref ServerLibFunctions.onTransformFilePath callback. + * This describes the original values, and also contains hints for length limitations of the result parameter + * of the callback. + * \verbatim embed:rst + .. important:: + Which values of the struct can be modified is defined by the action value of the original parameter. + \endverbatim + */ +struct TransformFilePathExport { + uint64 channel; ///< The channel id of the file. 0 if action is \ref FT_INIT_SERVER + const char* filename; ///< utf8 encoded c string containing the original file name as intended by the client. + int action; ///< The action to be performed. One of the values from the \ref FTAction enum. Defines which values of + ///< the result struct can be modified. + int transformedFileNameMaxSize; ///< The maximum length the file name can be rewritten to. + int channelPathMaxSize; ///< The maximum length the path can be rewritten to. }; -struct TransformFilePathExportReturns{ - char* transformedFileName; - char* channelPath; - int logFileAction; +/** + * Structure to rewrite the file transfer file name and path in the \ref ServerLibFunctions.onTransformFilePath callback. + * The lengths are limited as described in the original parameter. + * \verbatim embed:rst + .. important:: + Which values of the struct can be modified is defined by the action value of the original parameter. + \endverbatim + */ +struct TransformFilePathExportReturns { + char* transformedFileName; ///< pointer to target file name. Fill the memory pointed to with an utf8 encoded c string + ///< containing the new file name. Limited to original->transformedFileNameMaxSize bytes. + char* channelPath; ///< pointer to memory for new path. Fill the memory pointed to with an utf8 encoded c string + ///< containing the new path. Limited to original->channelPathMaxSize bytes. + int logFileAction; ///< boolean (1/0). Whether to log this file transfer to the log. Action is not logged regardless + ///< of this value if the servers \ref VIRTUALSERVER_LOG_FILETRANSFER property is 0. }; -struct FileTransferCallbackExport{ - anyID clientID; - anyID transferID; - anyID remoteTransferID; - unsigned int status; - const char* statusMessage; - uint64 remotefileSize; - uint64 bytes; - int isSender; +struct FileTransferCallbackExport { + anyID clientID; ///< the client who started the file transfer + anyID transferID; ///< local identifier of the transfer that has completed + anyID remoteTransferID; ///< remote identifier of the transfer that has completed + unsigned int status; ///< status of the transfer. One of the values from the \ref FileTransferState enum + const char* statusMessage; ///< utf8 encoded c string containing a human readable description of the status + uint64 remotefileSize; ///< size in bytes of the complete file to be transferred + uint64 bytes; ///< number of bytes transferred. Same as remotefileSize when the transfer completed entirely. + int isSender; ///< boolean. 1 if the server is sending the file. 0 if the server is receiving the file. }; /*define for file transfer bandwith limits*/ #define BANDWIDTH_LIMIT_UNLIMITED 0xFFFFFFFFFFFFFFFFll - /*defines for speaker locations used by some sound callbacks*/ #ifndef SPEAKER_FRONT_LEFT -#define SPEAKER_FRONT_LEFT 0x1 -#define SPEAKER_FRONT_RIGHT 0x2 -#define SPEAKER_FRONT_CENTER 0x4 -#define SPEAKER_LOW_FREQUENCY 0x8 -#define SPEAKER_BACK_LEFT 0x10 -#define SPEAKER_BACK_RIGHT 0x20 -#define SPEAKER_FRONT_LEFT_OF_CENTER 0x40 -#define SPEAKER_FRONT_RIGHT_OF_CENTER 0x80 -#define SPEAKER_BACK_CENTER 0x100 -#define SPEAKER_SIDE_LEFT 0x200 -#define SPEAKER_SIDE_RIGHT 0x400 -#define SPEAKER_TOP_CENTER 0x800 -#define SPEAKER_TOP_FRONT_LEFT 0x1000 -#define SPEAKER_TOP_FRONT_CENTER 0x2000 -#define SPEAKER_TOP_FRONT_RIGHT 0x4000 -#define SPEAKER_TOP_BACK_LEFT 0x8000 -#define SPEAKER_TOP_BACK_CENTER 0x10000 -#define SPEAKER_TOP_BACK_RIGHT 0x20000 +#define SPEAKER_FRONT_LEFT 0x1 +#define SPEAKER_FRONT_RIGHT 0x2 +#define SPEAKER_FRONT_CENTER 0x4 +#define SPEAKER_LOW_FREQUENCY 0x8 +#define SPEAKER_BACK_LEFT 0x10 +#define SPEAKER_BACK_RIGHT 0x20 +#define SPEAKER_FRONT_LEFT_OF_CENTER 0x40 +#define SPEAKER_FRONT_RIGHT_OF_CENTER 0x80 +#define SPEAKER_BACK_CENTER 0x100 +#define SPEAKER_SIDE_LEFT 0x200 +#define SPEAKER_SIDE_RIGHT 0x400 +#define SPEAKER_TOP_CENTER 0x800 +#define SPEAKER_TOP_FRONT_LEFT 0x1000 +#define SPEAKER_TOP_FRONT_CENTER 0x2000 +#define SPEAKER_TOP_FRONT_RIGHT 0x4000 +#define SPEAKER_TOP_BACK_LEFT 0x8000 +#define SPEAKER_TOP_BACK_CENTER 0x10000 +#define SPEAKER_TOP_BACK_RIGHT 0x20000 #endif -#define SPEAKER_HEADPHONES_LEFT 0x10000000 -#define SPEAKER_HEADPHONES_RIGHT 0x20000000 -#define SPEAKER_MONO 0x40000000 +#define SPEAKER_HEADPHONES_LEFT 0x10000000 +#define SPEAKER_HEADPHONES_RIGHT 0x20000000 +#define SPEAKER_MONO 0x40000000 #endif /*PUBLIC_DEFINITIONS_H*/ diff --git a/include/teamspeak/public_errors.h b/include/teamspeak/public_errors.h index 0659d3d..7025c2f 100644 --- a/include/teamspeak/public_errors.h +++ b/include/teamspeak/public_errors.h @@ -4,191 +4,197 @@ //The idea here is: the values are 2 bytes wide, the first byte identifies the group, the second the count within that group enum Ts3ErrorType { - //general - ERROR_ok = 0x0000, - ERROR_undefined = 0x0001, - ERROR_not_implemented = 0x0002, - ERROR_ok_no_update = 0x0003, - ERROR_dont_notify = 0x0004, - ERROR_lib_time_limit_reached = 0x0005, - ERROR_out_of_memory = 0x0006, - ERROR_canceled = 0x0007, + //general + ERROR_ok = 0x0000, ///< Indicates success. + ERROR_undefined = 0x0001, + ERROR_not_implemented = 0x0002, ///< The attempted operation is not available in this context + ERROR_ok_no_update = 0x0003, ///< Indicates success, but no change occurred. Returned for example upon flushing (e.g. using \ref ts3client_flushChannelUpdates) when all indicated changes already matched the current state. + ERROR_dont_notify = 0x0004, + ERROR_lib_time_limit_reached = 0x0005, + ERROR_out_of_memory = 0x0006, ///< Not enough system memory to perform operation + ERROR_canceled = 0x0007, - //dunno - ERROR_command_not_found = 0x0100, - ERROR_unable_to_bind_network_port = 0x0101, - ERROR_no_network_port_available = 0x0102, - ERROR_port_already_in_use = 0x0103, + //dunno + ERROR_command_not_found = 0x0100, + ERROR_unable_to_bind_network_port = 0x0101, ///< Unspecified failure to create a listening port + ERROR_no_network_port_available = 0x0102, ///< Failure to initialize a listening port for FileTransfer + ERROR_port_already_in_use = 0x0103, ///< Specified port is already in use by a different application - //client - ERROR_client_invalid_id = 0x0200, - ERROR_client_nickname_inuse = 0x0201, - ERROR_client_protocol_limit_reached = 0x0203, - ERROR_client_invalid_type = 0x0204, - ERROR_client_already_subscribed = 0x0205, - ERROR_client_not_logged_in = 0x0206, - ERROR_client_could_not_validate_identity = 0x0207, - ERROR_client_version_outdated = 0x020a, - ERROR_client_is_flooding = 0x020c, - ERROR_client_hacked = 0x020d, - ERROR_client_cannot_verify_now = 0x020e, - ERROR_client_login_not_permitted = 0x020f, - ERROR_client_not_subscribed = 0x0210, + //client + ERROR_client_invalid_id = 0x0200, ///< Client no longer connected + ERROR_client_nickname_inuse = 0x0201, ///< Client name is already in use. Client names must be unique + ERROR_client_protocol_limit_reached = 0x0203, ///< Too many clients on the server + ERROR_client_invalid_type = 0x0204, ///< Function called for normal clients that is only available for query clients or vice versa + ERROR_client_already_subscribed = 0x0205, ///< Attempting to subscribe to a channel already subscribed to + ERROR_client_not_logged_in = 0x0206, + ERROR_client_could_not_validate_identity = 0x0207, ///< Identity not valid or insufficient security level + ERROR_client_invalid_password = 0x0208, + ERROR_client_version_outdated = 0x020a, ///< Server requires newer client version as determined by the min_client_version properties + ERROR_client_is_flooding = 0x020c, ///< Triggered flood protection. Further information is supplied in the extra message if applicable. + ERROR_client_hacked = 0x020d, + ERROR_client_cannot_verify_now = 0x020e, + ERROR_client_login_not_permitted = 0x020f, + ERROR_client_not_subscribed = 0x0210, ///< Action is only available on subscribed channels - //channel - ERROR_channel_invalid_id = 0x0300, - ERROR_channel_protocol_limit_reached = 0x0301, - ERROR_channel_already_in = 0x0302, - ERROR_channel_name_inuse = 0x0303, - ERROR_channel_not_empty = 0x0304, - ERROR_channel_can_not_delete_default = 0x0305, - ERROR_channel_default_require_permanent = 0x0306, - ERROR_channel_invalid_flags = 0x0307, - ERROR_channel_parent_not_permanent = 0x0308, - ERROR_channel_maxclients_reached = 0x0309, - ERROR_channel_maxfamily_reached = 0x030a, - ERROR_channel_invalid_order = 0x030b, - ERROR_channel_no_filetransfer_supported = 0x030c, - ERROR_channel_invalid_password = 0x030d, - ERROR_channel_invalid_security_hash = 0x030f, //note 0x030e is defined in public_rare_errors; + //channel + ERROR_channel_invalid_id = 0x0300, ///< Channel does not exist on the server (any longer) + ERROR_channel_protocol_limit_reached = 0x0301, ///< Too many channels on the server + ERROR_channel_already_in = 0x0302, ///< Attempting to move a client or channel to its current channel + ERROR_channel_name_inuse = 0x0303, ///< Channel name is already taken by another channel. Channel names must be unique + ERROR_channel_not_empty = 0x0304, ///< Attempting to delete a channel with clients or sub channels in it + ERROR_channel_can_not_delete_default = 0x0305, ///< Default channel cannot be deleted. Set a new default channel first (see \ref ts3client_setChannelVariableAsInt or \ref ts3server_setChannelVariableAsInt ) + ERROR_channel_default_require_permanent = 0x0306, ///< Attempt to set a non permanent channel as default channel. Set channel to permanent first (see \ref ts3client_setChannelVariableAsInt or \ref ts3server_setChannelVariableAsInt ) + ERROR_channel_invalid_flags = 0x0307, ///< Invalid combination of \ref ChannelProperties, trying to remove \ref CHANNEL_FLAG_DEFAULT or set a password on the default channel + ERROR_channel_parent_not_permanent = 0x0308, ///< Attempt to move a permanent channel into a non-permanent one, or set a channel to be permanent that is a sub channel of a non-permanent one + ERROR_channel_maxclients_reached = 0x0309, ///< Channel is full as determined by its \ref CHANNEL_MAXCLIENTS setting + ERROR_channel_maxfamily_reached = 0x030a, ///< Channel tree is full as determined by its \ref CHANNEL_MAXFAMILYCLIENTS setting + ERROR_channel_invalid_order = 0x030b, ///< Invalid value for the \ref CHANNEL_ORDER property. The specified channel must exist on the server and be on the same level. + ERROR_channel_no_filetransfer_supported = 0x030c, ///< Invalid \ref CHANNEL_FILEPATH set for the channel + ERROR_channel_invalid_password = 0x030d, ///< Channel has a password not matching the password supplied in the call + // used in public_rare_errors = 0x030e, + ERROR_channel_invalid_security_hash = 0x030f, - //server - ERROR_server_invalid_id = 0x0400, - ERROR_server_running = 0x0401, - ERROR_server_is_shutting_down = 0x0402, - ERROR_server_maxclients_reached = 0x0403, - ERROR_server_invalid_password = 0x0404, - ERROR_server_is_virtual = 0x0407, - ERROR_server_is_not_running = 0x0409, - ERROR_server_is_booting = 0x040a, - ERROR_server_status_invalid = 0x040b, - ERROR_server_version_outdated = 0x040d, - ERROR_server_duplicate_running = 0x040e, + //server + ERROR_server_invalid_id = 0x0400, ///< Chosen virtual server does not exist or is offline + ERROR_server_running = 0x0401, ///< attempting to delete a server that is running. Stop the server before deleting it. + ERROR_server_is_shutting_down = 0x0402, ///< Client disconnected because the server is going offline + ERROR_server_maxclients_reached = 0x0403, ///< Given in the onConnectStatusChange event when the server has reached its maximum number of clients as defined by the \ref VIRTUALSERVER_MAXCLIENTS property + ERROR_server_invalid_password = 0x0404, ///< Specified server password is wrong. Provide the correct password in the \ref ts3client_startConnection / \ref ts3client_startConnectionWithChannelID call. + ERROR_server_is_virtual = 0x0407, ///< Server is in virtual status. The attempted action is not possible in this state. Start the virtual server first. + ERROR_server_is_not_running = 0x0409, ///< Attempting to stop a server that is not online. + ERROR_server_is_booting = 0x040a, // Not used + ERROR_server_status_invalid = 0x040b, + ERROR_server_version_outdated = 0x040d, ///< Attempt to connect to an outdated server version. The server needs to be updated. + ERROR_server_duplicate_running = 0x040e, ///< This server is already running within the instance. Each virtual server may only exist once. - //parameter - ERROR_parameter_quote = 0x0600, - ERROR_parameter_invalid_count = 0x0601, - ERROR_parameter_invalid = 0x0602, - ERROR_parameter_not_found = 0x0603, - ERROR_parameter_convert = 0x0604, - ERROR_parameter_invalid_size = 0x0605, - ERROR_parameter_missing = 0x0606, - ERROR_parameter_checksum = 0x0607, + //parameter + ERROR_parameter_quote = 0x0600, // Not used + ERROR_parameter_invalid_count = 0x0601, ///< Attempt to flush changes without previously calling set*VariableAs* since the last flush + ERROR_parameter_invalid = 0x0602, ///< At least one of the supplied parameters did not meet the criteria for that parameter + ERROR_parameter_not_found = 0x0603, ///< Failure to supply all the necessary parameters + ERROR_parameter_convert = 0x0604, ///< Invalid type supplied for a parameter, such as passing a string (ie. "five") that expects a number. + ERROR_parameter_invalid_size = 0x0605, ///< Value out of allowed range. Such as strings are too long/short or numeric values outside allowed range + ERROR_parameter_missing = 0x0606, ///< Neglecting to specify a required parameter + ERROR_parameter_checksum = 0x0607, ///< Attempting to deploy a modified snapshot - //unsorted, need further investigation - ERROR_vs_critical = 0x0700, - ERROR_connection_lost = 0x0701, - ERROR_not_connected = 0x0702, - ERROR_no_cached_connection_info = 0x0703, - ERROR_currently_not_possible = 0x0704, - ERROR_failed_connection_initialisation = 0x0705, - ERROR_could_not_resolve_hostname = 0x0706, - ERROR_invalid_server_connection_handler_id = 0x0707, - ERROR_could_not_initialise_input_manager = 0x0708, - ERROR_clientlibrary_not_initialised = 0x0709, - ERROR_serverlibrary_not_initialised = 0x070a, - ERROR_whisper_too_many_targets = 0x070b, - ERROR_whisper_no_targets = 0x070c, - ERROR_connection_ip_protocol_missing = 0x070d, - //reserved = 0x070e, - ERROR_illegal_server_license = 0x070f, + //unsorted, need further investigation + ERROR_vs_critical = 0x0700, ///< Failure to create default channel + ERROR_connection_lost = 0x0701, ///< Generic error with the connection. + ERROR_not_connected = 0x0702, ///< Attempting to call functions with a serverConnectionHandler that is not connected. You can use \ref ts3client_getConnectionStatus to check whether the connection handler is connected to a server + ERROR_no_cached_connection_info = 0x0703, ///< Attempting to query connection information (bandwidth usage, ping, etc) without requesting them first using \ref ts3client_requestConnectionInfo + ERROR_currently_not_possible = 0x0704, ///< Requested information is not currently available. You may have to call \ref ts3client_requestClientVariables or \ref ts3client_requestServerVariables + ERROR_failed_connection_initialisation = 0x0705, ///< No TeamSpeak server running on the specified IP address and port + ERROR_could_not_resolve_hostname = 0x0706, ///< Failure to resolve the specified hostname to an IP address + ERROR_invalid_server_connection_handler_id = 0x0707, ///< Attempting to perform actions on a non-existent server connection handler + ERROR_could_not_initialise_input_manager = 0x0708, // Not used + ERROR_clientlibrary_not_initialised = 0x0709, ///< Calling client library functions without successfully calling \ref ts3client_initClientLib before + ERROR_serverlibrary_not_initialised = 0x070a, ///< Calling server library functions without successfully calling \ref ts3server_initServerLib before + ERROR_whisper_too_many_targets = 0x070b, ///< Using a whisper list that contain more clients than the servers \ref VIRTUALSERVER_MIN_CLIENTS_IN_CHANNEL_BEFORE_FORCED_SILENCE property + ERROR_whisper_no_targets = 0x070c, ///< The active whisper list is empty or no clients matched the whisper list (e.g. all channels in the list are empty) + ERROR_connection_ip_protocol_missing = 0x070d, ///< Invalid or unsupported protocol (e.g. attempting an IPv6 connection on an IPv4 only machine) + ERROR_handshake_failed = 0x070e, + ERROR_illegal_server_license = 0x070f, - //file transfer - ERROR_file_invalid_name = 0x0800, - ERROR_file_invalid_permissions = 0x0801, - ERROR_file_already_exists = 0x0802, - ERROR_file_not_found = 0x0803, - ERROR_file_io_error = 0x0804, - ERROR_file_invalid_transfer_id = 0x0805, - ERROR_file_invalid_path = 0x0806, - ERROR_file_no_files_available = 0x0807, - ERROR_file_overwrite_excludes_resume = 0x0808, - ERROR_file_invalid_size = 0x0809, - ERROR_file_already_in_use = 0x080a, - ERROR_file_could_not_open_connection = 0x080b, - ERROR_file_no_space_left_on_device = 0x080c, - ERROR_file_exceeds_file_system_maximum_size = 0x080d, - ERROR_file_transfer_connection_timeout = 0x080e, - ERROR_file_connection_lost = 0x080f, - ERROR_file_exceeds_supplied_size = 0x0810, - ERROR_file_transfer_complete = 0x0811, - ERROR_file_transfer_canceled = 0x0812, - ERROR_file_transfer_interrupted = 0x0813, - ERROR_file_transfer_server_quota_exceeded = 0x0814, - ERROR_file_transfer_client_quota_exceeded = 0x0815, - ERROR_file_transfer_reset = 0x0816, - ERROR_file_transfer_limit_reached = 0x0817, - - //sound - ERROR_sound_preprocessor_disabled = 0x0900, - ERROR_sound_internal_preprocessor = 0x0901, - ERROR_sound_internal_encoder = 0x0902, - ERROR_sound_internal_playback = 0x0903, - ERROR_sound_no_capture_device_available = 0x0904, - ERROR_sound_no_playback_device_available = 0x0905, - ERROR_sound_could_not_open_capture_device = 0x0906, - ERROR_sound_could_not_open_playback_device = 0x0907, - ERROR_sound_handler_has_device = 0x0908, - ERROR_sound_invalid_capture_device = 0x0909, - ERROR_sound_invalid_playback_device = 0x090a, - ERROR_sound_invalid_wave = 0x090b, - ERROR_sound_unsupported_wave = 0x090c, - ERROR_sound_open_wave = 0x090d, - ERROR_sound_internal_capture = 0x090e, - ERROR_sound_device_in_use = 0x090f, - ERROR_sound_device_already_registerred = 0x0910, - ERROR_sound_unknown_device = 0x0911, - ERROR_sound_unsupported_frequency = 0x0912, - ERROR_sound_invalid_channel_count = 0x0913, - ERROR_sound_read_wave = 0x0914, - ERROR_sound_need_more_data = 0x0915, //for internal purposes only - ERROR_sound_device_busy = 0x0916, //for internal purposes only - ERROR_sound_no_data = 0x0917, - ERROR_sound_channel_mask_mismatch = 0x0918, + //file transfer + ERROR_file_invalid_name = 0x0800, ///< Invalid UTF8 string or not a valid file + ERROR_file_invalid_permissions = 0x0801, ///< Permissions prevent opening the file + ERROR_file_already_exists = 0x0802, ///< Target path already exists as a directory + ERROR_file_not_found = 0x0803, ///< Attempt to access or move non existing file + ERROR_file_io_error = 0x0804, ///< Generic file input / output error + ERROR_file_invalid_transfer_id = 0x0805, ///< Attempt to get information about a file transfer after it has already been cleaned up. File transfer information is not available indefinitely after the transfer completed + ERROR_file_invalid_path = 0x0806, ///< specified path contains invalid characters or does not start with "/" + ERROR_file_no_files_available = 0x0807, // Not used + ERROR_file_overwrite_excludes_resume = 0x0808, ///< File overwrite and resume are mutually exclusive. Only one or neither can be 1. + ERROR_file_invalid_size = 0x0809, ///< Attempt to write more bytes than claimed file size. + ERROR_file_already_in_use = 0x080a, ///< File is currently not available, try again later. + ERROR_file_could_not_open_connection = 0x080b, ///< Generic failure in file transfer connection / other party did not conform to file transfer protocol + ERROR_file_no_space_left_on_device = 0x080c, ///< Operating system reports hard disk is full. May be caused by quota limitations. + ERROR_file_exceeds_file_system_maximum_size = 0x080d, ///< File is too large for the file system of the target device. + ERROR_file_transfer_connection_timeout = 0x080e, // Not used + ERROR_file_connection_lost = 0x080f, ///< File input / output timeout or connection failure + ERROR_file_exceeds_supplied_size = 0x0810, // Not used + ERROR_file_transfer_complete = 0x0811, ///< Indicates successful completion + ERROR_file_transfer_canceled = 0x0812, ///< Transfer was cancelled through @ref ts3client_haltTransfer + ERROR_file_transfer_interrupted = 0x0813, ///< Transfer failed because the server is shutting down, or network connection issues + ERROR_file_transfer_server_quota_exceeded = 0x0814, ///< Transfer terminated due to server bandwidth quota being exceeded. No client can transfer files. + ERROR_file_transfer_client_quota_exceeded = 0x0815, ///< Attempt to transfer more data than allowed by this clients' bandwidth quota. Other clients may continue to transfer files. + ERROR_file_transfer_reset = 0x0816, // Not used + ERROR_file_transfer_limit_reached = 0x0817, ///< Too many file transfers are in progress. Try again later + ERROR_file_invalid_storage_class = 0x0818, // TODO: Invalid storage class for HTTP FileTransfer (what is a storage class?) + ERROR_file_invalid_dimension = 0x0819, ///< Avatar image exceeds maximum width or height accepted by the server. + ERROR_file_transfer_channel_quota_exceeded = 0x081a, ///< Transfer failed because the channel quota was exceeded. Uploading to this channel is not possible, but other channels may be fine. + //sound + ERROR_sound_preprocessor_disabled = 0x0900, ///< Cannot set or query pre processor variables with preprocessing disabled + ERROR_sound_internal_preprocessor = 0x0901, + ERROR_sound_internal_encoder = 0x0902, + ERROR_sound_internal_playback = 0x0903, + ERROR_sound_no_capture_device_available = 0x0904, ///< No audio capture devices are available + ERROR_sound_no_playback_device_available = 0x0905, ///< No audio playback devices are available + ERROR_sound_could_not_open_capture_device = 0x0906, ///< Error accessing audio device, or audio device does not support the requested mode + ERROR_sound_could_not_open_playback_device = 0x0907, ///< Error accessing audio device, or audio device does not support the requested mode + ERROR_sound_handler_has_device = 0x0908, ///< Attempt to open a sound device on a connection handler which already has an open device. Close the already open device first using \ref ts3client_closeCaptureDevice or \ref ts3client_closePlaybackDevice + ERROR_sound_invalid_capture_device = 0x0909, ///< Attempt to use a device for capture that does not support capturing audio + ERROR_sound_invalid_playback_device = 0x090a, ///< Attempt to use a device for playback that does not support playback of audio + ERROR_sound_invalid_wave = 0x090b, ///< Attempt to use a non WAV file in \ref ts3client_playWaveFile or \ref ts3client_playWaveFileHandle + ERROR_sound_unsupported_wave = 0x090c, ///< Unsupported wave file used in \ref ts3client_playWaveFile or \ref ts3client_playWaveFileHandle. + ERROR_sound_open_wave = 0x090d, ///< Failure to open the specified sound file + ERROR_sound_internal_capture = 0x090e, + ERROR_sound_device_in_use = 0x090f, ///< Attempt to unregister a custom device that is being used. Close the device first using \ref ts3client_closeCaptureDevice or \ref ts3client_closePlaybackDevice + ERROR_sound_device_already_registerred = 0x0910, ///< Attempt to register a custom device with a device id that has already been used in a previous call. Device ids must be unique. + ERROR_sound_unknown_device = 0x0911, ///< Attempt to open, close, unregister or use a device which is not known. Custom devices must be registered before being used (see \ref ts3client_registerCustomDevice) + ERROR_sound_unsupported_frequency = 0x0912, + ERROR_sound_invalid_channel_count = 0x0913, ///< Invalid device audio channel count, must be > 0 + ERROR_sound_read_wave = 0x0914, ///< Failure to read sound samples from an opened wave file. Is this a valid wave file? + ERROR_sound_need_more_data = 0x0915, // for internal purposes only + ERROR_sound_device_busy = 0x0916, // for internal purposes only + ERROR_sound_no_data = 0x0917, ///< Indicates there is currently no data for playback, e.g. nobody is speaking right now. + ERROR_sound_channel_mask_mismatch = 0x0918, ///< Opening a device with an unsupported channel count - //permissions - ERROR_permissions_client_insufficient = 0x0a08, - ERROR_permissions = 0x0a0c, + //permissions + ERROR_permissions_client_insufficient = 0x0a08, ///< Not enough permissions to perform the requested activity + ERROR_permissions = 0x0a0c, ///< Permissions to use sound device not granted by operating system, e.g. Windows denied microphone access. - //accounting - ERROR_accounting_virtualserver_limit_reached = 0x0b00, - ERROR_accounting_slot_limit_reached = 0x0b01, - ERROR_accounting_license_file_not_found = 0x0b02, - ERROR_accounting_license_date_not_ok = 0x0b03, - ERROR_accounting_unable_to_connect_to_server = 0x0b04, - ERROR_accounting_unknown_error = 0x0b05, - ERROR_accounting_server_error = 0x0b06, - ERROR_accounting_instance_limit_reached = 0x0b07, - ERROR_accounting_instance_check_error = 0x0b08, - ERROR_accounting_license_file_invalid = 0x0b09, - ERROR_accounting_running_elsewhere = 0x0b0a, - ERROR_accounting_instance_duplicated = 0x0b0b, - ERROR_accounting_already_started = 0x0b0c, - ERROR_accounting_not_started = 0x0b0d, - ERROR_accounting_to_many_starts = 0x0b0e, + //accounting + ERROR_accounting_virtualserver_limit_reached = 0x0b00, ///< Attempt to use more virtual servers than allowed by the license + ERROR_accounting_slot_limit_reached = 0x0b01, ///< Attempt to set more slots than allowed by the license + ERROR_accounting_license_file_not_found = 0x0b02, // Not used + ERROR_accounting_license_date_not_ok = 0x0b03, ///< License expired or not valid yet + ERROR_accounting_unable_to_connect_to_server = 0x0b04, ///< Failure to communicate with accounting backend + ERROR_accounting_unknown_error = 0x0b05, ///< Failure to write update license file + ERROR_accounting_server_error = 0x0b06, // Not used + ERROR_accounting_instance_limit_reached = 0x0b07, ///< More than one process of the server is running + ERROR_accounting_instance_check_error = 0x0b08, ///< Shared memory access failure. + ERROR_accounting_license_file_invalid = 0x0b09, ///< License is not a TeamSpeak license + ERROR_accounting_running_elsewhere = 0x0b0a, ///< A copy of this server is already running in another instance. Each server may only exist once. + ERROR_accounting_instance_duplicated = 0x0b0b, ///< A copy of this server is running already in this process. Each server may only exist once. + ERROR_accounting_already_started = 0x0b0c, ///< Attempt to start a server that is already running + ERROR_accounting_not_started = 0x0b0d, + ERROR_accounting_to_many_starts = 0x0b0e, ///< Starting instance / virtual servers too often in too short a time period - //provisioning server - ERROR_provisioning_invalid_password = 0x1100, - ERROR_provisioning_invalid_request = 0x1101, - ERROR_provisioning_no_slots_available = 0x1102, - ERROR_provisioning_pool_missing = 0x1103, - ERROR_provisioning_pool_unknown = 0x1104, - ERROR_provisioning_unknown_ip_location = 0x1105, - ERROR_provisioning_internal_tries_exceeded = 0x1106, - ERROR_provisioning_too_many_slots_requested = 0x1107, - ERROR_provisioning_too_many_reserved = 0x1108, - ERROR_provisioning_could_not_connect = 0x1109, - ERROR_provisioning_auth_server_not_connected = 0x1110, - ERROR_provisioning_auth_data_too_large = 0x1111, - ERROR_provisioning_already_initialized = 0x1112, - ERROR_provisioning_not_initialized = 0x1113, - ERROR_provisioning_connecting = 0x1114, - ERROR_provisioning_already_connected = 0x1115, - ERROR_provisioning_not_connected = 0x1116, - ERROR_provisioning_io_error = 0x1117, - ERROR_provisioning_invalid_timeout = 0x1118, - ERROR_provisioning_ts3server_not_found = 0x1119, - ERROR_provisioning_no_permission = 0x111A, + //provisioning server + /// @cond HAS_PROVISIONING + ERROR_provisioning_invalid_password = 0x1100, + ERROR_provisioning_invalid_request = 0x1101, + ERROR_provisioning_no_slots_available = 0x1102, + ERROR_provisioning_pool_missing = 0x1103, + ERROR_provisioning_pool_unknown = 0x1104, + ERROR_provisioning_unknown_ip_location = 0x1105, + ERROR_provisioning_internal_tries_exceeded = 0x1106, + ERROR_provisioning_too_many_slots_requested = 0x1107, + ERROR_provisioning_too_many_reserved = 0x1108, + ERROR_provisioning_could_not_connect = 0x1109, + ERROR_provisioning_auth_server_not_connected = 0x1110, + ERROR_provisioning_auth_data_too_large = 0x1111, + ERROR_provisioning_already_initialized = 0x1112, + ERROR_provisioning_not_initialized = 0x1113, + ERROR_provisioning_connecting = 0x1114, + ERROR_provisioning_already_connected = 0x1115, + ERROR_provisioning_not_connected = 0x1116, + ERROR_provisioning_io_error = 0x1117, + ERROR_provisioning_invalid_timeout = 0x1118, + ERROR_provisioning_ts3server_not_found = 0x1119, + ERROR_provisioning_no_permission = 0x111A, + /// @endcond }; #endif diff --git a/include/teamspeak/public_errors_rare.h b/include/teamspeak/public_errors_rare.h index 82eb5d5..47b77e8 100644 --- a/include/teamspeak/public_errors_rare.h +++ b/include/teamspeak/public_errors_rare.h @@ -4,94 +4,105 @@ //The idea here is: the values are 2 bytes wide, the first byte identifies the group, the second the count within that group enum Ts3RareErrorType { - //client - ERROR_client_invalid_password = 0x0208, - ERROR_client_too_many_clones_connected = 0x0209, - ERROR_client_is_online = 0x020b, + //client + ERROR_client_too_many_clones_connected = 0x0209, + ERROR_client_is_online = 0x020b, - //channel - ERROR_channel_is_private_channel = 0x030e, - //note 0x030f is defined in public_errors; + //channel + ERROR_channel_is_private_channel = 0x030e, + //note 0x030f is defined in public_errors; - //database - ERROR_database = 0x0500, - ERROR_database_empty_result = 0x0501, - ERROR_database_duplicate_entry = 0x0502, - ERROR_database_no_modifications = 0x0503, - ERROR_database_constraint = 0x0504, - ERROR_database_reinvoke = 0x0505, + //database + ERROR_database = 0x0500, + ERROR_database_empty_result = 0x0501, + ERROR_database_duplicate_entry = 0x0502, + ERROR_database_no_modifications = 0x0503, + ERROR_database_constraint = 0x0504, + ERROR_database_reinvoke = 0x0505, - //permissions - ERROR_permission_invalid_group_id = 0x0a00, - ERROR_permission_duplicate_entry = 0x0a01, - ERROR_permission_invalid_perm_id = 0x0a02, - ERROR_permission_empty_result = 0x0a03, - ERROR_permission_default_group_forbidden = 0x0a04, - ERROR_permission_invalid_size = 0x0a05, - ERROR_permission_invalid_value = 0x0a06, - ERROR_permissions_group_not_empty = 0x0a07, - ERROR_permissions_insufficient_group_power = 0x0a09, - ERROR_permissions_insufficient_permission_power = 0x0a0a, - ERROR_permission_template_group_is_used = 0x0a0b, - //0x0a0c is in public_errors.h - ERROR_permission_used_by_integration = 0x0a0d, + //permissions + ERROR_permission_invalid_group_id = 0x0a00, + ERROR_permission_duplicate_entry = 0x0a01, + ERROR_permission_invalid_perm_id = 0x0a02, + ERROR_permission_empty_result = 0x0a03, + ERROR_permission_default_group_forbidden = 0x0a04, + ERROR_permission_invalid_size = 0x0a05, + ERROR_permission_invalid_value = 0x0a06, + ERROR_permissions_group_not_empty = 0x0a07, + ERROR_permissions_insufficient_group_power = 0x0a09, + ERROR_permissions_insufficient_permission_power = 0x0a0a, + ERROR_permission_template_group_is_used = 0x0a0b, + //0x0a0c is in public_errors.h + ERROR_permission_used_by_integration = 0x0a0d, - //server - ERROR_server_deployment_active = 0x0405, - ERROR_server_unable_to_stop_own_server = 0x0406, - ERROR_server_wrong_machineid = 0x0408, - ERROR_server_modal_quit = 0x040c, - ERROR_server_time_difference_too_large = 0x040f, - ERROR_server_blacklisted = 0x0410, + //server + ERROR_server_deployment_active = 0x0405, + ERROR_server_unable_to_stop_own_server = 0x0406, + ERROR_server_wrong_machineid = 0x0408, + ERROR_server_modal_quit = 0x040c, + ERROR_server_time_difference_too_large = 0x040f, + ERROR_server_blacklisted = 0x0410, + ERROR_server_shutdown = 0x0411, - //messages - ERROR_message_invalid_id = 0x0c00, + //messages + ERROR_message_invalid_id = 0x0c00, - //ban - ERROR_ban_invalid_id = 0x0d00, - ERROR_connect_failed_banned = 0x0d01, - ERROR_rename_failed_banned = 0x0d02, - ERROR_ban_flooding = 0x0d03, + //ban + ERROR_ban_invalid_id = 0x0d00, + ERROR_connect_failed_banned = 0x0d01, + ERROR_rename_failed_banned = 0x0d02, + ERROR_ban_flooding = 0x0d03, - //tts - ERROR_tts_unable_to_initialize = 0x0e00, + //tts + ERROR_tts_unable_to_initialize = 0x0e00, - //privilege key - ERROR_privilege_key_invalid = 0x0f00, + //privilege key + ERROR_privilege_key_invalid = 0x0f00, - //voip - ERROR_voip_pjsua = 0x1000, - ERROR_voip_already_initialized = 0x1001, - ERROR_voip_too_many_accounts = 0x1002, - ERROR_voip_invalid_account = 0x1003, - ERROR_voip_internal_error = 0x1004, - ERROR_voip_invalid_connectionId = 0x1005, - ERROR_voip_cannot_answer_initiated_call = 0x1006, - ERROR_voip_not_initialized = 0x1007, - - //ed25519 - ERROR_ed25519_rng_fail = 0x1300, - ERROR_ed25519_signature_invalid = 0x1301, - ERROR_ed25519_invalid_key = 0x1302, - ERROR_ed25519_unable_to_create_valid_key = 0x1303, - ERROR_ed25519_out_of_memory = 0x1304, - ERROR_ed25519_exists = 0x1305, - ERROR_ed25519_read_beyond_eof = 0x1306, - ERROR_ed25519_write_beyond_eof = 0x1307, - ERROR_ed25519_version = 0x1308, - ERROR_ed25519_invalid = 0x1309, - ERROR_ed25519_invalid_date = 0x130A, - ERROR_ed25519_unauthorized = 0x130B, - ERROR_ed25519_invalid_type = 0x130C, - ERROR_ed25519_address_nomatch = 0x130D, - ERROR_ed25519_not_valid_yet = 0x130E, - ERROR_ed25519_expired = 0x130F, - ERROR_ed25519_index_out_of_range = 0x1310, - ERROR_ed25519_invalid_size = 0x1311, + //voip + ERROR_voip_pjsua = 0x1000, + ERROR_voip_already_initialized = 0x1001, + ERROR_voip_too_many_accounts = 0x1002, + ERROR_voip_invalid_account = 0x1003, + ERROR_voip_internal_error = 0x1004, + ERROR_voip_invalid_connectionId = 0x1005, + ERROR_voip_cannot_answer_initiated_call = 0x1006, + ERROR_voip_not_initialized = 0x1007, //mytsid - client - ERROR_invalid_mytsid_data = 0x1200, - ERROR_invalid_integration = 0x1201, + ERROR_invalid_mytsid_data = 0x1200, + ERROR_invalid_integration = 0x1201, + ERROR_mytsid_needed = 0x1202, + + //ed25519 + ERROR_ed25519_rng_fail = 0x1300, + ERROR_ed25519_signature_invalid = 0x1301, + ERROR_ed25519_invalid_key = 0x1302, + ERROR_ed25519_unable_to_create_valid_key = 0x1303, + ERROR_ed25519_out_of_memory = 0x1304, + ERROR_ed25519_exists = 0x1305, + ERROR_ed25519_read_beyond_eof = 0x1306, + ERROR_ed25519_write_beyond_eof = 0x1307, + ERROR_ed25519_version = 0x1308, + ERROR_ed25519_invalid = 0x1309, + ERROR_ed25519_invalid_date = 0x130A, + ERROR_ed25519_unauthorized = 0x130B, + ERROR_ed25519_invalid_type = 0x130C, + ERROR_ed25519_address_nomatch = 0x130D, + ERROR_ed25519_not_valid_yet = 0x130E, + ERROR_ed25519_expired = 0x130F, + ERROR_ed25519_index_out_of_range = 0x1310, + ERROR_ed25519_invalid_size = 0x1311, + + //api key + ERROR_apikey_outofscope = 0x1400, + ERROR_apikey_crypto_error = 0x1401, + ERROR_apikey_invalid = 0x1402, + ERROR_apikey_invalid_id = 0x1403, + ERROR_apikey_missing = 0x1404, + + //homebase + ERROR_homebase_no_slots_available = 0x1500, }; #endif diff --git a/include/teamspeak/public_rare_definitions.h b/include/teamspeak/public_rare_definitions.h index 86c09a9..3977e37 100644 --- a/include/teamspeak/public_rare_definitions.h +++ b/include/teamspeak/public_rare_definitions.h @@ -16,334 +16,343 @@ #define TS3_MAX_SIZE_POKE_MESSAGE 100 #define TS3_MAX_SIZE_OFFLINE_MESSAGE 4096 #define TS3_MAX_SIZE_OFFLINE_MESSAGE_SUBJECT 200 +#define TS3_MAX_SIZE_USER_TAG 100 //limited length, measured in bytes (utf8 encoded) -#define TS3_MAX_SIZE_PLUGIN_COMMAND 1024*8 +#define TS3_MAX_SIZE_PLUGIN_COMMAND 1024 * 8 #define TS3_MAX_SIZE_VIRTUALSERVER_HOSTBANNER_GFX_URL 2000 - enum GroupShowNameTreeMode { - GroupShowNameTreeMode_NONE= 0, //dont group show name - GroupShowNameTreeMode_BEFORE, //show group name before client name - GroupShowNameTreeMode_BEHIND //show group name behind client name + GroupShowNameTreeMode_NONE = 0, //dont group show name + GroupShowNameTreeMode_BEFORE, //show group name before client name + GroupShowNameTreeMode_BEHIND //show group name behind client name }; enum PluginTargetMode { - PluginCommandTarget_CURRENT_CHANNEL=0, //send plugincmd to all clients in current channel - PluginCommandTarget_SERVER, //send plugincmd to all clients on server - PluginCommandTarget_CLIENT, //send plugincmd to all given client ids - PluginCommandTarget_CURRENT_CHANNEL_SUBSCRIBED_CLIENTS, //send plugincmd to all subscribed clients in current channel - PluginCommandTarget_MAX + PluginCommandTarget_CURRENT_CHANNEL = 0, //send plugincmd to all clients in current channel + PluginCommandTarget_SERVER, //send plugincmd to all clients on server + PluginCommandTarget_CLIENT, //send plugincmd to all given client ids + PluginCommandTarget_CURRENT_CHANNEL_SUBSCRIBED_CLIENTS, //send plugincmd to all subscribed clients in current channel + PluginCommandTarget_MAX }; enum { - SERVER_BINDING_VIRTUALSERVER=0, - SERVER_BINDING_SERVERQUERY =1, - SERVER_BINDING_FILETRANSFER =2, + SERVER_BINDING_VIRTUALSERVER = 0, + SERVER_BINDING_SERVERQUERY = 1, + SERVER_BINDING_FILETRANSFER = 2, }; enum HostMessageMode { - HostMessageMode_NONE=0, //dont display anything - HostMessageMode_LOG, //display message inside log - HostMessageMode_MODAL, //display message inside a modal dialog - HostMessageMode_MODALQUIT //display message inside a modal dialog and quit/close server/connection + HostMessageMode_NONE = 0, //dont display anything + HostMessageMode_LOG, //display message inside log + HostMessageMode_MODAL, //display message inside a modal dialog + HostMessageMode_MODALQUIT //display message inside a modal dialog and quit/close server/connection }; enum HostBannerMode { - HostBannerMode_NO_ADJUST=0, //Do not adjust - HostBannerMode_ADJUST_IGNORE_ASPECT, //Adjust but ignore aspect ratio - HostBannerMode_ADJUST_KEEP_ASPECT, //Adjust and keep aspect ratio + HostBannerMode_NO_ADJUST = 0, //Do not adjust + HostBannerMode_ADJUST_IGNORE_ASPECT, //Adjust but ignore aspect ratio + HostBannerMode_ADJUST_KEEP_ASPECT, //Adjust and keep aspect ratio }; enum ClientType { - ClientType_NORMAL = 0, - ClientType_SERVERQUERY, + ClientType_NORMAL = 0, + ClientType_SERVERQUERY, }; enum AwayStatus { - AWAY_NONE = 0, - AWAY_ZZZ, + AWAY_NONE = 0, + AWAY_ZZZ, }; enum CommandLinePropertiesRare { #ifdef SERVER - COMMANDLINE_CREATE_DEFAULT_VIRTUALSERVER= 0, //create default virtualserver - COMMANDLINE_MACHINE_ID, //machine id (starts only virtualserver with given machineID - COMMANDLINE_DEFAULT_VOICE_PORT, - COMMANDLINE_VOICE_IP, - COMMANDLINE_THREADS_VOICE_UDP, - COMMANDLINE_LICENSEPATH, -#ifndef SDK - COMMANDLINE_FILETRANSFER_PORT, - COMMANDLINE_FILETRANSFER_IP, - COMMANDLINE_QUERY_PORT, - COMMANDLINE_QUERY_IP, - COMMANDLINE_QUERY_IP_WHITELIST, - COMMANDLINE_QUERY_IP_BLACKLIST, - COMMANDLINE_CLEAR_DATABASE, - COMMANDLINE_SERVERADMIN_PASSWORD, - COMMANDLINE_DBPLUGIN, - COMMANDLINE_DBPLUGINPARAMETER, - COMMANDLINE_DBSQLPATH, - COMMANDLINE_DBSQLCREATEPATH, - COMMANDLINE_DBCONNECTIONS, - COMMANDLINE_LOGPATH, - COMMANDLINE_CREATEINIFILE, - COMMANDLINE_INIFILE, - COMMANDLINE_LOGQUERYCOMMANDS, - COMMANDLINE_DBCLIENTKEEPDAYS, - COMMANDLINE_NO_PERMISSION_UPDATE, - COMMANDLINE_OPEN_WIN_CONSOLE, - COMMANDLINE_NO_PASSWORD_DIALOG, - COMMANDLINE_LOGAPPEND, - COMMANDLINE_QUERY_SKIPBRUTEFORCECHECK, - COMMANDLINE_QUERY_BUFFER_MB, - COMMANDLINE_HTTP_PROXY, - COMMANDLINE_LICENSE_ACCEPTED, - COMMANDLINE_SERVERQUERYDOCS_PATH, - COMMANDLINE_QUERY_SSH_IP, - COMMANDLINE_QUERY_SSH_PORT, - COMMANDLINE_QUERY_PROTOCOLS, - COMMANDLINE_QUERY_SSH_RSA_HOST_KEY, - COMMANDLINE_QUERY_TIMEOUT, - COMMANDLINE_VERSION, - COMMANDLINE_CRASHDUMPSPATH, - COMMANDLINE_DAEMON, - COMMANDLINE_PID_FILE, + COMMANDLINE_CREATE_DEFAULT_VIRTUALSERVER = 0, //create default virtualserver + COMMANDLINE_MACHINE_ID, //machine id (starts only virtualserver with given machineID + COMMANDLINE_DEFAULT_VOICE_PORT, + COMMANDLINE_VOICE_IP, + COMMANDLINE_THREADS_VOICE_UDP, + COMMANDLINE_LICENSEPATH, + COMMANDLINE_YAMLFILE, +#ifndef TEAMSPEAK_SDK + COMMANDLINE_FILETRANSFER_PORT, + COMMANDLINE_FILETRANSFER_IP, + COMMANDLINE_QUERY_PORT, + COMMANDLINE_QUERY_IP, + COMMANDLINE_QUERY_IP_ALLOWLIST, + COMMANDLINE_QUERY_IP_DENYLIST, + COMMANDLINE_CLEAR_DATABASE, + COMMANDLINE_SERVERADMIN_PASSWORD, + COMMANDLINE_DBPLUGIN, + COMMANDLINE_DBPLUGINPARAMETER, + COMMANDLINE_DBSQLPATH, + COMMANDLINE_DBSQLCREATEPATH, + COMMANDLINE_DBCONNECTIONS, + COMMANDLINE_LOGPATH, + COMMANDLINE_CREATEINIFILE, + COMMANDLINE_INIFILE, + COMMANDLINE_LOGQUERYCOMMANDS, + COMMANDLINE_DBCLIENTKEEPDAYS, + COMMANDLINE_NO_PERMISSION_UPDATE, + COMMANDLINE_OPEN_WIN_CONSOLE, + COMMANDLINE_NO_PASSWORD_DIALOG, + COMMANDLINE_LOGAPPEND, + COMMANDLINE_QUERY_SKIPBRUTEFORCECHECK, + COMMANDLINE_QUERY_BUFFER_MB, #endif + COMMANDLINE_HTTP_PROXY, +#ifndef TEAMSPEAK_SDK + COMMANDLINE_LICENSE_ACCEPTED, + COMMANDLINE_SERVERQUERYDOCS_PATH, + COMMANDLINE_QUERY_SSH_IP, + COMMANDLINE_QUERY_SSH_PORT, + COMMANDLINE_QUERY_PROTOCOLS, + COMMANDLINE_QUERY_SSH_RSA_HOST_KEY, + COMMANDLINE_QUERY_TIMEOUT, + COMMANDLINE_VERSION, + COMMANDLINE_CRASHDUMPSPATH, + COMMANDLINE_DAEMON, + COMMANDLINE_PID_FILE, + COMMANDLINE_HINTS_ENABLED, + COMMANDLINE_QUERY_HTTP_IP, + COMMANDLINE_QUERY_HTTP_PORT, + COMMANDLINE_QUERY_HTTPS_IP, + COMMANDLINE_QUERY_HTTPS_PORT, + COMMANDLINE_QUERY_HTTPS_CERTIFICATE_FILE, + COMMANDLINE_QUERY_HTTPS_PRIVATE_KEY_FILE, + COMMANDLINE_QUERY_POOL_SIZE, + COMMANDLINE_MMDBPATH, + COMMANDLINE_LOGQUERYTIMINGINTERVAL, + COMMANDLINE_EVENT_TO_DB_LOGGING, + COMMANDLINE_ADMINISTRATIVE_DOMAIN, +#endif + COMMANDLINE_WEBRTC_SERVER_ENABLED, #else - COMMANDLINE_NOTHING=0, + COMMANDLINE_NOTHING = 0, #endif - COMMANDLINE_ENDMARKER_RARE, + COMMANDLINE_ENDMARKER_RARE, }; enum ServerInstancePropertiesRare { - SERVERINSTANCE_DATABASE_VERSION= 0, - SERVERINSTANCE_FILETRANSFER_PORT, - SERVERINSTANCE_SERVER_ENTROPY, - SERVERINSTANCE_MONTHLY_TIMESTAMP, - SERVERINSTANCE_MAX_DOWNLOAD_TOTAL_BANDWIDTH, - SERVERINSTANCE_MAX_UPLOAD_TOTAL_BANDWIDTH, - SERVERINSTANCE_GUEST_SERVERQUERY_GROUP, - SERVERINSTANCE_SERVERQUERY_FLOOD_COMMANDS, //how many commands we can issue while in the SERVERINSTANCE_SERVERQUERY_FLOOD_TIME window - SERVERINSTANCE_SERVERQUERY_FLOOD_TIME, //time window in seconds for max command execution check - SERVERINSTANCE_SERVERQUERY_BAN_TIME, //how many seconds someone get banned if he floods - SERVERINSTANCE_TEMPLATE_SERVERADMIN_GROUP, - SERVERINSTANCE_TEMPLATE_SERVERDEFAULT_GROUP, - SERVERINSTANCE_TEMPLATE_CHANNELADMIN_GROUP, - SERVERINSTANCE_TEMPLATE_CHANNELDEFAULT_GROUP, - SERVERINSTANCE_PERMISSIONS_VERSION, - SERVERINSTANCE_PENDING_CONNECTIONS_PER_IP, - SERVERINSTANCE_SERVERQUERY_MAX_CONNECTIONS_PER_IP, - SERVERINSTANCE_ENDMARKER_RARE, + SERVERINSTANCE_DATABASE_VERSION = 0, + SERVERINSTANCE_FILETRANSFER_PORT, + SERVERINSTANCE_SERVER_ENTROPY, + SERVERINSTANCE_MONTHLY_TIMESTAMP, + SERVERINSTANCE_MAX_DOWNLOAD_TOTAL_BANDWIDTH, + SERVERINSTANCE_MAX_UPLOAD_TOTAL_BANDWIDTH, + SERVERINSTANCE_GUEST_SERVERQUERY_GROUP, + SERVERINSTANCE_SERVERQUERY_FLOOD_COMMANDS, //how many commands we can issue while in the SERVERINSTANCE_SERVERQUERY_FLOOD_TIME window + SERVERINSTANCE_SERVERQUERY_FLOOD_TIME, //time window in seconds for max command execution check + SERVERINSTANCE_SERVERQUERY_BAN_TIME, //how many seconds someone get banned if he floods + SERVERINSTANCE_TEMPLATE_SERVERADMIN_GROUP, + SERVERINSTANCE_TEMPLATE_SERVERDEFAULT_GROUP, + SERVERINSTANCE_TEMPLATE_CHANNELADMIN_GROUP, + SERVERINSTANCE_TEMPLATE_CHANNELDEFAULT_GROUP, + SERVERINSTANCE_PERMISSIONS_VERSION, + SERVERINSTANCE_PENDING_CONNECTIONS_PER_IP, + SERVERINSTANCE_SERVERQUERY_MAX_CONNECTIONS_PER_IP, + SERVERINSTANCE_MAX_HOMEBASES, //How many matrix homebase users this instance can have. -1 for no limit + SERVERINSTANCE_ENDMARKER_RARE, }; enum VirtualServerPropertiesRare { - VIRTUALSERVER_DUMMY_1 = VIRTUALSERVER_ENDMARKER, - VIRTUALSERVER_DUMMY_2, - VIRTUALSERVER_DUMMY_3, - VIRTUALSERVER_DUMMY_4, - VIRTUALSERVER_DUMMY_5, - VIRTUALSERVER_DUMMY_6, - VIRTUALSERVER_DUMMY_7, - VIRTUALSERVER_DUMMY_8, - VIRTUALSERVER_KEYPAIR, //internal use - VIRTUALSERVER_HOSTMESSAGE, //available when connected, not updated while connected - VIRTUALSERVER_HOSTMESSAGE_MODE, //available when connected, not updated while connected - VIRTUALSERVER_FILEBASE, //not available to clients, stores the folder used for file transfers - VIRTUALSERVER_DEFAULT_SERVER_GROUP, //the client permissions server group that a new client gets assigned - VIRTUALSERVER_DEFAULT_CHANNEL_GROUP, //the channel permissions group that a new client gets assigned when joining a channel - VIRTUALSERVER_FLAG_PASSWORD, //only available on request (=> requestServerVariables) - VIRTUALSERVER_DEFAULT_CHANNEL_ADMIN_GROUP, //the channel permissions group that a client gets assigned when creating a channel - VIRTUALSERVER_MAX_DOWNLOAD_TOTAL_BANDWIDTH, //only available on request (=> requestServerVariables) - VIRTUALSERVER_MAX_UPLOAD_TOTAL_BANDWIDTH, //only available on request (=> requestServerVariables) - VIRTUALSERVER_HOSTBANNER_URL, //available when connected, always up-to-date - VIRTUALSERVER_HOSTBANNER_GFX_URL, //available when connected, always up-to-date - VIRTUALSERVER_HOSTBANNER_GFX_INTERVAL, //available when connected, always up-to-date - VIRTUALSERVER_COMPLAIN_AUTOBAN_COUNT, //only available on request (=> requestServerVariables) - VIRTUALSERVER_COMPLAIN_AUTOBAN_TIME, //only available on request (=> requestServerVariables) - VIRTUALSERVER_COMPLAIN_REMOVE_TIME, //only available on request (=> requestServerVariables) - VIRTUALSERVER_MIN_CLIENTS_IN_CHANNEL_BEFORE_FORCED_SILENCE,//only available on request (=> requestServerVariables) - VIRTUALSERVER_PRIORITY_SPEAKER_DIMM_MODIFICATOR, //available when connected, always up-to-date - VIRTUALSERVER_ID, //available when connected - VIRTUALSERVER_ANTIFLOOD_POINTS_TICK_REDUCE, //only available on request (=> requestServerVariables) - VIRTUALSERVER_ANTIFLOOD_POINTS_NEEDED_COMMAND_BLOCK, //only available on request (=> requestServerVariables) - VIRTUALSERVER_ANTIFLOOD_POINTS_NEEDED_IP_BLOCK, //only available on request (=> requestServerVariables) - VIRTUALSERVER_CLIENT_CONNECTIONS, //only available on request (=> requestServerVariables) - VIRTUALSERVER_QUERY_CLIENT_CONNECTIONS, //only available on request (=> requestServerVariables) - VIRTUALSERVER_HOSTBUTTON_TOOLTIP, //available when connected, always up-to-date - VIRTUALSERVER_HOSTBUTTON_URL, //available when connected, always up-to-date - VIRTUALSERVER_HOSTBUTTON_GFX_URL, //available when connected, always up-to-date - VIRTUALSERVER_QUERYCLIENTS_ONLINE, //only available on request (=> requestServerVariables) - VIRTUALSERVER_DOWNLOAD_QUOTA, //only available on request (=> requestServerVariables) - VIRTUALSERVER_UPLOAD_QUOTA, //only available on request (=> requestServerVariables) - VIRTUALSERVER_MONTH_BYTES_DOWNLOADED, //only available on request (=> requestServerVariables) - VIRTUALSERVER_MONTH_BYTES_UPLOADED, //only available on request (=> requestServerVariables) - VIRTUALSERVER_TOTAL_BYTES_DOWNLOADED, //only available on request (=> requestServerVariables) - VIRTUALSERVER_TOTAL_BYTES_UPLOADED, //only available on request (=> requestServerVariables) - VIRTUALSERVER_PORT, //only available on request (=> requestServerVariables) - VIRTUALSERVER_AUTOSTART, //only available on request (=> requestServerVariables) - VIRTUALSERVER_MACHINE_ID, //only available on request (=> requestServerVariables) - VIRTUALSERVER_NEEDED_IDENTITY_SECURITY_LEVEL, //only available on request (=> requestServerVariables) - VIRTUALSERVER_LOG_CLIENT, //only available on request (=> requestServerVariables) - VIRTUALSERVER_LOG_QUERY, //only available on request (=> requestServerVariables) - VIRTUALSERVER_LOG_CHANNEL, //only available on request (=> requestServerVariables) - VIRTUALSERVER_LOG_PERMISSIONS, //only available on request (=> requestServerVariables) - VIRTUALSERVER_LOG_SERVER, //only available on request (=> requestServerVariables) - VIRTUALSERVER_LOG_FILETRANSFER, //only available on request (=> requestServerVariables) - VIRTUALSERVER_MIN_CLIENT_VERSION, //only available on request (=> requestServerVariables) - VIRTUALSERVER_NAME_PHONETIC, //available when connected, always up-to-date - VIRTUALSERVER_ICON_ID, //available when connected, always up-to-date - VIRTUALSERVER_RESERVED_SLOTS, //available when connected, always up-to-date - VIRTUALSERVER_TOTAL_PACKETLOSS_SPEECH, //only available on request (=> requestServerVariables) - VIRTUALSERVER_TOTAL_PACKETLOSS_KEEPALIVE, //only available on request (=> requestServerVariables) - VIRTUALSERVER_TOTAL_PACKETLOSS_CONTROL, //only available on request (=> requestServerVariables) - VIRTUALSERVER_TOTAL_PACKETLOSS_TOTAL, //only available on request (=> requestServerVariables) - VIRTUALSERVER_TOTAL_PING, //only available on request (=> requestServerVariables) - VIRTUALSERVER_IP, //internal use | contains comma separated ip list - VIRTUALSERVER_WEBLIST_ENABLED, //only available on request (=> requestServerVariables) - VIRTUALSERVER_AUTOGENERATED_PRIVILEGEKEY, //internal use - VIRTUALSERVER_ASK_FOR_PRIVILEGEKEY, //available when connected - VIRTUALSERVER_HOSTBANNER_MODE, //available when connected, always up-to-date - VIRTUALSERVER_CHANNEL_TEMP_DELETE_DELAY_DEFAULT, //available when connected, always up-to-date - VIRTUALSERVER_MIN_ANDROID_VERSION, //only available on request (=> requestServerVariables) - VIRTUALSERVER_MIN_IOS_VERSION, //only available on request (=> requestServerVariables) - VIRTUALSERVER_MIN_WINPHONE_VERSION, //only available on request (=> requestServerVariables) - VIRTUALSERVER_NICKNAME, //available when connected, always up-to-date - VIRTUALSERVER_ACCOUNTING_TOKEN, //internal use | contains base64 encoded token data - VIRTUALSERVER_PROTOCOL_VERIFY_KEYPAIR, //internal use - VIRTUALSERVER_ANTIFLOOD_POINTS_NEEDED_PLUGIN_BLOCK, //only available on request (=> requestServerVariables) - VIRTUALSERVER_ENDMARKER_RARE + VIRTUALSERVER_DUMMY_1 = VIRTUALSERVER_ENDMARKER, + VIRTUALSERVER_DUMMY_2, + VIRTUALSERVER_DUMMY_3, + VIRTUALSERVER_DUMMY_4, + VIRTUALSERVER_DUMMY_5, + VIRTUALSERVER_DUMMY_6, + VIRTUALSERVER_DUMMY_7, + VIRTUALSERVER_DUMMY_8, + VIRTUALSERVER_KEYPAIR, //internal use + VIRTUALSERVER_HOSTMESSAGE, //available when connected, not updated while connected + VIRTUALSERVER_HOSTMESSAGE_MODE, //available when connected, not updated while connected + // VIRTUALSERVER_FILEBASE, // Moved to VirtualServerProperties due to SDK usage + VIRTUALSERVER_DEFAULT_SERVER_GROUP = 25, //the client permissions server group that a new client gets assigned + VIRTUALSERVER_DEFAULT_CHANNEL_GROUP, //the channel permissions group that a new client gets assigned when joining a channel + VIRTUALSERVER_FLAG_PASSWORD, //only available on request (=> requestServerVariables) + VIRTUALSERVER_DEFAULT_CHANNEL_ADMIN_GROUP, //the channel permissions group that a client gets assigned when creating a channel + // VIRTUALSERVER_MAX_DOWNLOAD_TOTAL_BANDWIDTH, // Moved to VirtualServerProperties due to SDK usage + // VIRTUALSERVER_MAX_UPLOAD_TOTAL_BANDWIDTH, // Moved to VirtualServerProperties due to SDK usage + VIRTUALSERVER_HOSTBANNER_URL = 31, //available when connected, always up-to-date + VIRTUALSERVER_HOSTBANNER_GFX_URL, //available when connected, always up-to-date + VIRTUALSERVER_HOSTBANNER_GFX_INTERVAL, //available when connected, always up-to-date + VIRTUALSERVER_COMPLAIN_AUTOBAN_COUNT, //only available on request (=> requestServerVariables) + VIRTUALSERVER_COMPLAIN_AUTOBAN_TIME, //only available on request (=> requestServerVariables) + VIRTUALSERVER_COMPLAIN_REMOVE_TIME, //only available on request (=> requestServerVariables) + VIRTUALSERVER_MIN_CLIENTS_IN_CHANNEL_BEFORE_FORCED_SILENCE, //only available on request (=> requestServerVariables) + VIRTUALSERVER_PRIORITY_SPEAKER_DIMM_MODIFICATOR, //available when connected, always up-to-date + VIRTUALSERVER_ID, //available when connected + VIRTUALSERVER_ANTIFLOOD_POINTS_TICK_REDUCE, //only available on request (=> requestServerVariables) + VIRTUALSERVER_ANTIFLOOD_POINTS_NEEDED_COMMAND_BLOCK, //only available on request (=> requestServerVariables) + VIRTUALSERVER_ANTIFLOOD_POINTS_NEEDED_IP_BLOCK, //only available on request (=> requestServerVariables) + VIRTUALSERVER_CLIENT_CONNECTIONS, //only available on request (=> requestServerVariables) + VIRTUALSERVER_QUERY_CLIENT_CONNECTIONS, //only available on request (=> requestServerVariables) + VIRTUALSERVER_HOSTBUTTON_TOOLTIP, //available when connected, always up-to-date + VIRTUALSERVER_HOSTBUTTON_URL, //available when connected, always up-to-date + VIRTUALSERVER_HOSTBUTTON_GFX_URL, //available when connected, always up-to-date + VIRTUALSERVER_QUERYCLIENTS_ONLINE, //only available on request (=> requestServerVariables) + VIRTUALSERVER_DOWNLOAD_QUOTA, //only available on request (=> requestServerVariables) + VIRTUALSERVER_UPLOAD_QUOTA, //only available on request (=> requestServerVariables) + VIRTUALSERVER_MONTH_BYTES_DOWNLOADED, //only available on request (=> requestServerVariables) + VIRTUALSERVER_MONTH_BYTES_UPLOADED, //only available on request (=> requestServerVariables) + VIRTUALSERVER_TOTAL_BYTES_DOWNLOADED, //only available on request (=> requestServerVariables) + VIRTUALSERVER_TOTAL_BYTES_UPLOADED, //only available on request (=> requestServerVariables) + VIRTUALSERVER_PORT, //only available on request (=> requestServerVariables) + VIRTUALSERVER_AUTOSTART, //only available on request (=> requestServerVariables) + VIRTUALSERVER_MACHINE_ID, //only available on request (=> requestServerVariables) + VIRTUALSERVER_NEEDED_IDENTITY_SECURITY_LEVEL, //only available on request (=> requestServerVariables) + VIRTUALSERVER_LOG_CLIENT, //only available on request (=> requestServerVariables) + VIRTUALSERVER_LOG_QUERY, //only available on request (=> requestServerVariables) + VIRTUALSERVER_LOG_CHANNEL, //only available on request (=> requestServerVariables) + VIRTUALSERVER_LOG_PERMISSIONS, //only available on request (=> requestServerVariables) + VIRTUALSERVER_LOG_SERVER, //only available on request (=> requestServerVariables) + // VIRTUALSERVER_LOG_FILETRANSFER, // Moved to VirtualServerProperties due to SDK usage + VIRTUALSERVER_MIN_CLIENT_VERSION = 65, //only available on request (=> requestServerVariables) + VIRTUALSERVER_NAME_PHONETIC, //available when connected, always up-to-date + VIRTUALSERVER_ICON_ID, //available when connected, always up-to-date + VIRTUALSERVER_RESERVED_SLOTS, //available when connected, always up-to-date + VIRTUALSERVER_TOTAL_PACKETLOSS_SPEECH, //only available on request (=> requestServerVariables) + VIRTUALSERVER_TOTAL_PACKETLOSS_KEEPALIVE, //only available on request (=> requestServerVariables) + VIRTUALSERVER_TOTAL_PACKETLOSS_CONTROL, //only available on request (=> requestServerVariables) + VIRTUALSERVER_TOTAL_PACKETLOSS_TOTAL, //only available on request (=> requestServerVariables) + VIRTUALSERVER_TOTAL_PING, //only available on request (=> requestServerVariables) + VIRTUALSERVER_IP, //internal use | contains comma separated ip list + VIRTUALSERVER_WEBLIST_ENABLED, //only available on request (=> requestServerVariables) + VIRTUALSERVER_AUTOGENERATED_PRIVILEGEKEY, //internal use + VIRTUALSERVER_ASK_FOR_PRIVILEGEKEY, //available when connected + VIRTUALSERVER_HOSTBANNER_MODE, //available when connected, always up-to-date + VIRTUALSERVER_CHANNEL_TEMP_DELETE_DELAY_DEFAULT, //available when connected, always up-to-date + VIRTUALSERVER_MIN_ANDROID_VERSION, //only available on request (=> requestServerVariables) + VIRTUALSERVER_MIN_IOS_VERSION, //only available on request (=> requestServerVariables) + VIRTUALSERVER_MIN_WINPHONE_VERSION, //only available on request (=> requestServerVariables) + VIRTUALSERVER_NICKNAME, //available when connected, always up-to-date + VIRTUALSERVER_ACCOUNTING_TOKEN, //internal use | contains base64 encoded token data + VIRTUALSERVER_PROTOCOL_VERIFY_KEYPAIR, //internal use + VIRTUALSERVER_ANTIFLOOD_POINTS_NEEDED_PLUGIN_BLOCK, //only available on request (=> requestServerVariables) + VIRTUALSERVER_CAPABILITY_EXTENSIONS, //available when connected, not updated while connected + VIRTUALSERVER_STORAGE_QUOTA, // Allowed filetransfer storage on this server (including chat attachments) in megabytes + VIRTUALSERVER_WEBRTC_CERTIFICATE, //internal use + VIRTUALSERVER_WEBRTC_PRIVATE_KEY, //internal use + VIRTUALSERVER_UUID, //the uuid of the server (uuid v5 of VIRTUALSERVER_UNIQUE_IDENTIFIER) + VIRTUALSERVER_ADMINISTRATIVE_DOMAIN, //The domain which is responsible for this teamspeak server (which hosts its .well-known file) + VIRTUALSERVER_CANONICAL_NAME, //The canonical name under which the server is reachable + VIRTUALSERVER_MYTSID_CONNECT_ONLY, //Only clients that have a valid mytsid can connect + VIRTUALSERVER_MAX_HOMEBASES, //How many matrix homebases this virtual server supports. -1 = no limit + VIRTUALSERVER_HOMEBASE_STORAGE_QUOTA, // Allowed filetransfer storage for homebase attachments in megabytes + VIRTUALSERVER_ENDMARKER_RARE }; enum ChannelPropertiesRare { - CHANNEL_DUMMY_2= CHANNEL_ENDMARKER, - CHANNEL_DUMMY_3, - CHANNEL_DUMMY_4, - CHANNEL_DUMMY_5, - CHANNEL_DUMMY_6, - CHANNEL_DUMMY_7, - CHANNEL_FLAG_MAXCLIENTS_UNLIMITED, //Available for all channels that are "in view", always up-to-date - CHANNEL_FLAG_MAXFAMILYCLIENTS_UNLIMITED,//Available for all channels that are "in view", always up-to-date - CHANNEL_FLAG_MAXFAMILYCLIENTS_INHERITED,//Available for all channels that are "in view", always up-to-date - CHANNEL_FLAG_ARE_SUBSCRIBED, //Only available client side, stores whether we are subscribed to this channel - CHANNEL_FILEPATH, //not available client side, the folder used for file-transfers for this channel - CHANNEL_NEEDED_TALK_POWER, //Available for all channels that are "in view", always up-to-date - CHANNEL_FORCED_SILENCE, //Available for all channels that are "in view", always up-to-date - CHANNEL_NAME_PHONETIC, //Available for all channels that are "in view", always up-to-date - CHANNEL_ICON_ID, //Available for all channels that are "in view", always up-to-date - CHANNEL_BANNER_GFX_URL, //Available for all channels that are "in view", always up-to-date - CHANNEL_BANNER_MODE, //Available for all channels that are "in view", always up-to-date - CHANNEL_ENDMARKER_RARE, - CHANNEL_DELETE_DELAY_DEADLINE = 127 //(for clientlibv2) expected delete time in monotonic clock seconds or 0 if nothing is expected + CHANNEL_DUMMY_3 = CHANNEL_ENDMARKER, + CHANNEL_DUMMY_4, + CHANNEL_DUMMY_5, + CHANNEL_DUMMY_6, + CHANNEL_DUMMY_7, + CHANNEL_FLAG_MAXCLIENTS_UNLIMITED, //Available for all channels that are "in view", always up-to-date + CHANNEL_FLAG_MAXFAMILYCLIENTS_UNLIMITED, //Available for all channels that are "in view", always up-to-date + CHANNEL_FLAG_MAXFAMILYCLIENTS_INHERITED, //Available for all channels that are "in view", always up-to-date + CHANNEL_FLAG_ARE_SUBSCRIBED, //Only available client side, stores whether we are subscribed to this channel + CHANNEL_FILEPATH, //not available client side, the folder used for file-transfers for this channel + CHANNEL_NEEDED_TALK_POWER, //Available for all channels that are "in view", always up-to-date + CHANNEL_FORCED_SILENCE, //Available for all channels that are "in view", always up-to-date + CHANNEL_NAME_PHONETIC, //Available for all channels that are "in view", always up-to-date + CHANNEL_ICON_ID, //Available for all channels that are "in view", always up-to-date + CHANNEL_BANNER_GFX_URL, //Available for all channels that are "in view", always up-to-date + CHANNEL_BANNER_MODE, //Available for all channels that are "in view", always up-to-date + CHANNEL_PERMISSION_HINTS, + CHANNEL_STORAGE_QUOTA, // Storage space that is allowed to be used by this channels files (in MiB) + CHANNEL_ENDMARKER_RARE, + CHANNEL_DELETE_DELAY_DEADLINE = 127 //(for clientlibv2) expected delete time in monotonic clock seconds or 0 if nothing is expected }; enum ClientPropertiesRare { - CLIENT_DUMMY_4 = CLIENT_ENDMARKER, - CLIENT_DUMMY_5, - CLIENT_DUMMY_6, - CLIENT_DUMMY_7, - CLIENT_DUMMY_8, - CLIENT_DUMMY_9, - CLIENT_KEY_OFFSET, //internal use - CLIENT_LAST_VAR_REQUEST, //internal use - CLIENT_LOGIN_NAME, //used for serverquery clients, makes no sense on normal clients currently - CLIENT_LOGIN_PASSWORD, //used for serverquery clients, makes no sense on normal clients currently - CLIENT_DATABASE_ID, //automatically up-to-date for any client "in view", only valid with PERMISSION feature, holds database client id - CLIENT_CHANNEL_GROUP_ID, //automatically up-to-date for any client "in view", only valid with PERMISSION feature, holds database client id - CLIENT_SERVERGROUPS, //automatically up-to-date for any client "in view", only valid with PERMISSION feature, holds all servergroups client belongs too - CLIENT_CREATED, //this needs to be requested (=> requestClientVariables), first time this client connected to this server - CLIENT_LASTCONNECTED, //this needs to be requested (=> requestClientVariables), last time this client connected to this server - CLIENT_TOTALCONNECTIONS, //this needs to be requested (=> requestClientVariables), how many times this client connected to this server - CLIENT_AWAY, //automatically up-to-date for any client "in view", this clients away status - CLIENT_AWAY_MESSAGE, //automatically up-to-date for any client "in view", this clients away message - CLIENT_TYPE, //automatically up-to-date for any client "in view", determines if this is a real client or a server-query connection - CLIENT_FLAG_AVATAR, //automatically up-to-date for any client "in view", this client got an avatar - CLIENT_TALK_POWER, //automatically up-to-date for any client "in view", only valid with PERMISSION feature, holds database client id - CLIENT_TALK_REQUEST, //automatically up-to-date for any client "in view", only valid with PERMISSION feature, holds timestamp where client requested to talk - CLIENT_TALK_REQUEST_MSG, //automatically up-to-date for any client "in view", only valid with PERMISSION feature, holds matter for the request - CLIENT_DESCRIPTION, //automatically up-to-date for any client "in view" - CLIENT_IS_TALKER, //automatically up-to-date for any client "in view" - CLIENT_MONTH_BYTES_UPLOADED, //this needs to be requested (=> requestClientVariables) - CLIENT_MONTH_BYTES_DOWNLOADED, //this needs to be requested (=> requestClientVariables) - CLIENT_TOTAL_BYTES_UPLOADED, //this needs to be requested (=> requestClientVariables) - CLIENT_TOTAL_BYTES_DOWNLOADED, //this needs to be requested (=> requestClientVariables) - CLIENT_IS_PRIORITY_SPEAKER, //automatically up-to-date for any client "in view" - CLIENT_UNREAD_MESSAGES, //automatically up-to-date for any client "in view" - CLIENT_NICKNAME_PHONETIC, //automatically up-to-date for any client "in view" - CLIENT_NEEDED_SERVERQUERY_VIEW_POWER, //automatically up-to-date for any client "in view" - CLIENT_DEFAULT_TOKEN, //only usable for ourself, the default token we used to connect on our last connection attempt - CLIENT_ICON_ID, //automatically up-to-date for any client "in view" - CLIENT_IS_CHANNEL_COMMANDER, //automatically up-to-date for any client "in view" - CLIENT_COUNTRY, //automatically up-to-date for any client "in view" - CLIENT_CHANNEL_GROUP_INHERITED_CHANNEL_ID, //automatically up-to-date for any client "in view", only valid with PERMISSION feature, contains channel_id where the channel_group_id is set from - CLIENT_BADGES, //automatically up-to-date for any client "in view", stores icons for partner badges - CLIENT_MYTEAMSPEAK_ID, //automatically up-to-date for any client "in view", stores myteamspeak id - CLIENT_INTEGRATIONS, //automatically up-to-date for any client "in view", stores integrations - CLIENT_ACTIVE_INTEGRATIONS_INFO, //stores info from the myts server and contains the subscription info + CLIENT_DUMMY_4 = CLIENT_ENDMARKER, + CLIENT_DUMMY_5, + CLIENT_DUMMY_6, + CLIENT_DUMMY_7, + CLIENT_DUMMY_8, + CLIENT_DUMMY_9, + CLIENT_KEY_OFFSET, //internal use + CLIENT_LAST_VAR_REQUEST, //internal use + CLIENT_LOGIN_NAME, //used for serverquery clients, makes no sense on normal clients currently + CLIENT_LOGIN_PASSWORD, //used for serverquery clients, makes no sense on normal clients currently + CLIENT_DATABASE_ID, //automatically up-to-date for any client "in view", only valid with PERMISSION feature, holds database client id + CLIENT_CHANNEL_GROUP_ID, //automatically up-to-date for any client "in view", only valid with PERMISSION feature, holds database client id + CLIENT_SERVERGROUPS, //automatically up-to-date for any client "in view", only valid with PERMISSION feature, holds all servergroups client belongs too + CLIENT_CREATED, //this needs to be requested (=> requestClientVariables), first time this client connected to this server + CLIENT_LASTCONNECTED, //this needs to be requested (=> requestClientVariables), last time this client connected to this server + CLIENT_TOTALCONNECTIONS, //this needs to be requested (=> requestClientVariables), how many times this client connected to this server + CLIENT_AWAY, //automatically up-to-date for any client "in view", this clients away status + CLIENT_AWAY_MESSAGE, //automatically up-to-date for any client "in view", this clients away message + CLIENT_TYPE, //automatically up-to-date for any client "in view", determines if this is a real client or a server-query connection + CLIENT_FLAG_AVATAR, //automatically up-to-date for any client "in view", this client got an avatar + CLIENT_TALK_POWER, //automatically up-to-date for any client "in view", only valid with PERMISSION feature, holds database client id + CLIENT_TALK_REQUEST, //automatically up-to-date for any client "in view", only valid with PERMISSION feature, holds timestamp where client requested to talk + CLIENT_TALK_REQUEST_MSG, //automatically up-to-date for any client "in view", only valid with PERMISSION feature, holds matter for the request + CLIENT_DESCRIPTION, //automatically up-to-date for any client "in view" + CLIENT_IS_TALKER, //automatically up-to-date for any client "in view" + CLIENT_MONTH_BYTES_UPLOADED, //this needs to be requested (=> requestClientVariables) + CLIENT_MONTH_BYTES_DOWNLOADED, //this needs to be requested (=> requestClientVariables) + CLIENT_TOTAL_BYTES_UPLOADED, //this needs to be requested (=> requestClientVariables) + CLIENT_TOTAL_BYTES_DOWNLOADED, //this needs to be requested (=> requestClientVariables) + CLIENT_IS_PRIORITY_SPEAKER, //automatically up-to-date for any client "in view" + CLIENT_UNREAD_MESSAGES, //automatically up-to-date for any client "in view" + CLIENT_NICKNAME_PHONETIC, //automatically up-to-date for any client "in view" + CLIENT_NEEDED_SERVERQUERY_VIEW_POWER, //automatically up-to-date for any client "in view" + CLIENT_DEFAULT_TOKEN, //only usable for ourself, the default token we used to connect on our last connection attempt + CLIENT_ICON_ID, //automatically up-to-date for any client "in view" + CLIENT_IS_CHANNEL_COMMANDER, //automatically up-to-date for any client "in view" + CLIENT_COUNTRY, //automatically up-to-date for any client "in view" + CLIENT_CHANNEL_GROUP_INHERITED_CHANNEL_ID, //automatically up-to-date for any client "in view", only valid with PERMISSION feature, contains channel_id where the channel_group_id is set from + CLIENT_BADGES, //automatically up-to-date for any client "in view", stores icons for partner badges + CLIENT_MYTEAMSPEAK_ID, //automatically up-to-date for any client "in view", stores myteamspeak id + CLIENT_INTEGRATIONS, //automatically up-to-date for any client "in view", stores integrations + CLIENT_ACTIVE_INTEGRATIONS_INFO, //stores info from the myts server and contains the subscription info CLIENT_MYTS_AVATAR, CLIENT_SIGNED_BADGES, - CLIENT_ENDMARKER_RARE, - CLIENT_HW_ID = 127 //(for clientlibv2) unique hardware id -}; - -enum ConnectionPropertiesRare { - CONNECTION_DUMMY_0= CONNECTION_ENDMARKER, - CONNECTION_DUMMY_1, - CONNECTION_DUMMY_2, - CONNECTION_DUMMY_3, - CONNECTION_DUMMY_4, - CONNECTION_DUMMY_5, - CONNECTION_DUMMY_6, - CONNECTION_DUMMY_7, - CONNECTION_DUMMY_8, - CONNECTION_DUMMY_9, - CONNECTION_FILETRANSFER_BANDWIDTH_SENT, //how many bytes per second are currently being sent by file transfers - CONNECTION_FILETRANSFER_BANDWIDTH_RECEIVED, //how many bytes per second are currently being received by file transfers - CONNECTION_FILETRANSFER_BYTES_RECEIVED_TOTAL, //how many bytes we received in total through file transfers - CONNECTION_FILETRANSFER_BYTES_SENT_TOTAL, //how many bytes we sent in total through file transfers - CONNECTION_ENDMARKER_RARE, + CLIENT_PERMISSION_HINTS, + CLIENT_USER_TAG, //automatically up-to-date for any client "in view", stores public chat user tag + CLIENT_ENDMARKER_RARE, + CLIENT_HW_ID = 127 //(for clientlibv2) unique hardware id }; enum BBCodeTags { - BBCodeTag_B = 0x00000001, - BBCodeTag_I = 0x00000002, - BBCodeTag_U = 0x00000004, - BBCodeTag_S = 0x00000008, - BBCodeTag_SUP = 0x00000010, - BBCodeTag_SUB = 0x00000020, - BBCodeTag_COLOR = 0x00000040, - BBCodeTag_SIZE = 0x00000080, - BBCodeTag_group_text = 0x000000FF, + BBCodeTag_B = 0x00000001, + BBCodeTag_I = 0x00000002, + BBCodeTag_U = 0x00000004, + BBCodeTag_S = 0x00000008, + BBCodeTag_SUP = 0x00000010, + BBCodeTag_SUB = 0x00000020, + BBCodeTag_COLOR = 0x00000040, + BBCodeTag_SIZE = 0x00000080, + BBCodeTag_group_text = 0x000000FF, - BBCodeTag_LEFT = 0x00001000, - BBCodeTag_RIGHT = 0x00002000, - BBCodeTag_CENTER = 0x00004000, - BBCodeTag_group_align = 0x00007000, + BBCodeTag_LEFT = 0x00001000, + BBCodeTag_RIGHT = 0x00002000, + BBCodeTag_CENTER = 0x00004000, + BBCodeTag_group_align = 0x00007000, - BBCodeTag_URL = 0x00010000, - BBCodeTag_IMAGE = 0x00020000, - BBCodeTag_HR = 0x00040000, + BBCodeTag_URL = 0x00010000, + BBCodeTag_IMAGE = 0x00020000, + BBCodeTag_HR = 0x00040000, - BBCodeTag_LIST = 0x00100000, - BBCodeTag_LISTITEM = 0x00200000, - BBCodeTag_group_list = 0x00300000, + BBCodeTag_LIST = 0x00100000, + BBCodeTag_LISTITEM = 0x00200000, + BBCodeTag_group_list = 0x00300000, - BBCodeTag_TABLE = 0x00400000, - BBCodeTag_TR = 0x00800000, - BBCodeTag_TH = 0x01000000, - BBCodeTag_TD = 0x02000000, - BBCodeTag_group_table = 0x03C00000, + BBCodeTag_TABLE = 0x00400000, + BBCodeTag_TR = 0x00800000, + BBCodeTag_TH = 0x01000000, + BBCodeTag_TD = 0x02000000, + BBCodeTag_group_table = 0x03C00000, - BBCodeTag_def_simple = BBCodeTag_B | BBCodeTag_I | BBCodeTag_U | BBCodeTag_S | BBCodeTag_SUP | BBCodeTag_SUB |BBCodeTag_COLOR | BBCodeTag_URL, - BBCodeTag_def_simple_Img = BBCodeTag_def_simple | BBCodeTag_IMAGE, - BBCodeTag_def_extended = BBCodeTag_group_text | BBCodeTag_group_align | BBCodeTag_URL | BBCodeTag_IMAGE | BBCodeTag_HR | BBCodeTag_group_list | BBCodeTag_group_table, + BBCodeTag_def_simple = BBCodeTag_B | BBCodeTag_I | BBCodeTag_U | BBCodeTag_S | BBCodeTag_SUP | BBCodeTag_SUB | BBCodeTag_COLOR | BBCodeTag_URL, + BBCodeTag_def_simple_Img = BBCodeTag_def_simple | BBCodeTag_IMAGE, + BBCodeTag_def_extended = BBCodeTag_group_text | BBCodeTag_group_align | BBCodeTag_URL | BBCodeTag_IMAGE | BBCodeTag_HR | BBCodeTag_group_list | BBCodeTag_group_table, }; -enum LicenseIssue { - Blacklisted = 0, - Greylisted -}; +enum LicenseIssue { Blacklisted = 0, Greylisted }; enum MytsDataUnsetFlags { MytsDataUnsetFlag_None = 0, @@ -353,7 +362,7 @@ enum MytsDataUnsetFlags { MytsDataUnsetFlag_All = MytsDataUnsetFlag_Badges | MytsDataUnsetFlag_Avatar // make sure "all" really contains all flags }; -typedef int(*ExtraBBCodeValidator)(void* userparam, const char* tag, const char* paramValue, int paramValueSize, const char* childValue, int childValueSize); +typedef int (*ExtraBBCodeValidator)(void* userparam, const char* tag, const char* paramValue, int paramValueSize, const char* childValue, int childValueSize); typedef const char* (*ExtraBBCodeParamTransform)(void* userparam, const char* tag, const char* paramValue); #endif //PUBLIC_RARE_DEFINITIONS_H diff --git a/include/teamspeak/server_commands_file_transfer.h b/include/teamspeak/server_commands_file_transfer.h new file mode 100644 index 0000000..a4e8ece --- /dev/null +++ b/include/teamspeak/server_commands_file_transfer.h @@ -0,0 +1,149 @@ +#pragma once +/*WARNING: This file is auto generated. Do not edit this file, but edit the server messages and regenerate! */ + +#include "teamspeak/public_definitions.h" + +#ifdef __cplusplus +extern "C" { +#endif + +/** Structure that contains the command data for an ftcreatedir message */ +struct ts3sc_data_ftcreatedir { + uint64 channelID; ///< The channel ID where the directory is to be created + const char* dirname; ///< utf8 encoded c string containing the directory name +}; + +/** Structure that contains the meta data for an ftcreatedir message */ +struct ts3sc_meta_ftcreatedir { + int RESERVED; ///< This is here because C forbids empty structs. DO NOT USE +}; + +/** C Structure that contains the meta data and data for an ftcreatedir message */ +struct ts3sc_ftcreatedir { + struct ts3sc_meta_ftcreatedir m; ///< meta data + struct ts3sc_data_ftcreatedir d; ///< data +}; + +/** Structure that contains the command data for an ftdeletefile message */ +struct ts3sc_data_ftdeletefile { + uint64 channelID; ///< The channel ID where the file is to be deleted +}; + +/** Structure that contains the repeat command data for an ftdeletefile message */ +struct ts3sc_array_ftdeletefile { + const char* fileName; ///< The file name to be deleted +}; + +/** Structure that contains the meta data for an ftdeletefile message */ +struct ts3sc_meta_ftdeletefile { + int RESERVED; ///< This is here because C forbids empty structs. DO NOT USE +}; + +/** C Structure that contains the meta data and data for an ftdeletefile message */ +struct ts3sc_ftdeletefile { + struct ts3sc_meta_ftdeletefile m; ///< meta data + struct ts3sc_data_ftdeletefile d; ///< data + int r_size; ///< number of items in r + struct ts3sc_array_ftdeletefile* r; ///< repeated data +}; + +/** Structure that contains the command data for an ftgetfileinfo message */ +struct ts3sc_data_ftgetfileinfo { + int RESERVED; ///< This is here because C forbids empty structs. DO NOT USE +}; + +/** Structure that contains the repeat command data for an ftgetfileinfo message */ +struct ts3sc_array_ftgetfileinfo { + uint64 channelID; ///< The channel ID where the file is located + const char* fileName; ///< utf8 encoded c string containing the file name +}; + +/** Structure that contains the meta data for an ftgetfileinfo message */ +struct ts3sc_meta_ftgetfileinfo { + int RESERVED; /** +#include + +#ifdef __cplusplus +extern "C" { +#endif + +struct TS3ChannelCreationParams; //opaque definition +struct TS3VirtualServerCreationParams; //opaque definition +struct TS3Variables; //opaque definition + +enum VirtualServerCreateFlags { + VIRTUALSERVER_CREATE_FLAG_NONE = 0x0000, ///< Server password is stored plaintext and will be encrypted by the server library before stored. + VIRTUALSERVER_CREATE_FLAG_PASSWORDS_ENCRYPTED = 0x0001, ///< Server password is already encrypted in the creation parameters. Will be stored as is. +}; + +enum ChannelCreateFlags { + CHANNEL_CREATE_FLAG_NONE = 0x000, ///< Channel password is stored plaintext and will be encrypted by the server library before stored. + CHANNEL_CREATE_FLAG_PASSWORDS_ENCRYPTED = 0x001, ///< Channel passwords are already encrypted in the creation parameters. Will be stored as is. +}; + +/** + * Server callbacks. + * Zero initialize and set members to functions that are to be called when the event in question happens. + * Every callback you use should exit quickly to avoid stalling the server. If you need any expensive activity + * upon receiving callbacks, consider starting the activity in a new thread and allow the callback to exit quickly. +*/ +struct ServerLibFunctions { + /** + * @brief called when audio data is received from any client. Allows access to audio data from any client. + * + * @details Can be used to implement server side voice recording. Do not implement if you don't need server side recording. + * Callback will be called for every client sending audio data, even if nobody can hear said client (e.g. alone in a channel). + * + * @param serverID the server for which the callback was called + * @param clientID the client which is sending audio data + * @param voiceData pointer to the voice buffer. Must not be invalidated or otherwise tampered with. + * @param voiceDataSize number of audio frames available in the buffer + * @param frequency audio data sample rate + */ + void (*onVoiceDataEvent) (uint64 serverID, anyID clientID, unsigned char* voiceData, unsigned int voiceDataSize, unsigned int frequency); + + /** + * @brief called when a client starts talking + * + * @param serverID the server for which the callback was called + * @param clientID the client that started talking + */ + void (*onClientStartTalkingEvent) (uint64 serverID, anyID clientID); + + /** + * @brief called when a client stops talking + * + * @param serverID the server for which the callback was called + * @param clientID the client that stopped talking + */ + void (*onClientStopTalkingEvent) (uint64 serverID, anyID clientID); + + /** + * @brief called when a client connects + * + * @param serverID the server for which the callback was called + * @param clientID the client that connected + * @param channelID the channel that the client connected to + * @param removeClientError whether to allow the client on the server. Set the value to one of the values from the @ref Ts3ErrorType enum if you want to reject the client. + */ + void (*onClientConnected) (uint64 serverID, anyID clientID, uint64 channelID, unsigned int* removeClientError); + + /** + * @brief called when a client disconnects + * + * @param serverID the server for which the callback was called + * @param clientID the client that disconnected. The client is already gone by the time this callback is called. The client id cannot be used to query information. + * @param channelID the channel that the client was in before disconnecting. + */ + void (*onClientDisconnected) (uint64 serverID, anyID clientID, uint64 channelID); + + /** + * @brief called when a client changed to a different channel by any means, including switching the channel themselves. + * + * @param serverID the server for which the callback was called + * @param clientID the client that switched to a different channel. + * @param oldChannelID the previous channel the client was in. + * @param newChannelID the current channel the client is in now. + */ + void (*onClientMoved) (uint64 serverID, anyID clientID, uint64 oldChannelID, uint64 newChannelID); + + /** + * @brief called when a channel has been created + * + * @param serverID the server for which the callback was called + * @param invokerClientID the id of the client that created the channel. 0 if the server created the channel. + * @param channelID the id of the newly created channel. + */ + void (*onChannelCreated) (uint64 serverID, anyID invokerClientID, uint64 channelID); + + /** + * @brief called when a channel has been edited + * + * @param serverID the server for which the callback was called + * @param invokerClientID the client that edited the channel. 0 if the server edited the channel. + * @param channelID the channel that was edited + */ + void (*onChannelEdited) (uint64 serverID, anyID invokerClientID, uint64 channelID); + + /** + * @brief called when a channel was deleted + * + * @param serverID the server for which the callback was called + * @param invokerClientID client that deleted the channel. 0 if the server deleted the channel + * @param channelID the id of the channel that was deleted. The channel is gone already by the time this callback is called and information about the channel is no longer available + */ + void (*onChannelDeleted) (uint64 serverID, anyID invokerClientID, uint64 channelID); + + /** + * @brief called when a server wide text message was sent + * + * @param serverID the server for which the callback was called + * @param invokerClientID the client that is sending the message + * @param textMessage utf8 encoded c string containing the text of the message sent + */ + void (*onServerTextMessageEvent) (uint64 serverID, anyID invokerClientID, const char* textMessage); + + /** + * @brief called when a channel text message was sent + * + * @param serverID the server for which the callback was called + * @param invokerClientID the client that is sending the message + * @param targetChannelID the channel in which the message is sent + * @param textMessage utf8 encoded c string containing the message sent + */ + void (*onChannelTextMessageEvent) (uint64 serverID, anyID invokerClientID, uint64 targetChannelID, const char* textMessage); + + /** + * @brief when user logging was enabled when calling @ref ts3server_initServerLib this callback is called whenever a message with at least the severity + * specified through @ref ts3server_setLogVerbosity is supposed to be logged. Allows to customize logging and handle errors or critical log events. + * + * @param logmessage utf8 encoded c string containing the message to be logged + * @param logLevel the severity of the message that the callback is called for. One of the values from the @ref LogLevel enum + * @param logChannel utf8 encoded c string containing the arbitrary text used for grouping messages. + * @param logID the server on which the message was logged + * @param logTime utf8 encoded c string containing the time and date in system format the message was logged + * @param completeLogString utf8 encoded c string containing all the previous parameters in a complete text string ready for logging. + */ + void (*onUserLoggingMessageEvent) (const char* logmessage, int logLevel, const char* logChannel, uint64 logID, const char* logTime, const char* completeLogString); + + /** + * @brief called when an error occurs with license checking. + * + * @details Allows you to gracefully handle errors like a missing or expired license for example, while keeping the rest of your application running. + * + * @param serverID the server on which the error occured. This server has been shut down automatically, other servers keep running. + * If this is 0 then all servers are affected by the error and have been shut down. In this case you may want to call @ref ts3server_destroyServerLib to clean up resources. + * @param errorCode the error that appeared. One of the values from the @ref Ts3ErrorType enum. You can use @ref ts3server_getGlobalErrorMessage to get a string representation for the error code. + */ + void (*onAccountingErrorEvent) (uint64 serverID, unsigned int errorCode); + + /** + * @brief called when a packet needs to be encrypted to be sent over the wire. + * + * @details Used to implement custom encryption of server communication. This needs to be implemented the same in the client and server, otherwise clients cannot communicate with the server. + * Only implement this callback when you need custom encryption. + * + * @param dataToSend pointer to an array of bytes that need to be encrypted. Must not be freed. Encrypt the data in place in this array if the size of your encrypted data + * is smaller than indicated in the sizeOfData parameter. Otherwise allocate your own memory and replace the pointer to point to your own allocated memory. In this case you need to take care of freeing the memory. + * @param sizeOfData size in byte of the dataToSend array. + */ + void (*onCustomPacketEncryptEvent) (char** dataToSend, unsigned int* sizeOfData); + + /** + * @brief called when a packet needs to be decrypted after it has been received. + * + * @details Used to implement custom encryption of server communication. This needs to be implemented the same in the client and server, otherwise clients cannot communicate with the server. + * Only implement this callback when you need custom encryption. + * + * @param dataReceived pointer to an array of bytes that need to be decrypted. Must not be freed. Decrypt the data in place in this array if the size of your decrypted data + * is smaller than indicated by the dataReceivedSize parameter. Otherwise allocate your own memory and replace the pointer to point to your own allocated memory. In this case you need to take care of freeing the memory + * @param dataReceivedSize size in byte of the dataReceived array. + */ + void (*onCustomPacketDecryptEvent) (char** dataReceived, unsigned int* dataReceivedSize); + + /** + * @brief called whenever a file transfer is done + * + * @param data pointer to a structure describing the file transfer that completed. See @ref FileTransferCallbackExport for details. + */ + void (*onFileTransferEvent) (const struct FileTransferCallbackExport* data); + + /** + * @brief called when a client is about to connect. Can be used to deny clients from connecting. + * + * Return @ref ERROR_ok to allow the client on the server, or @ref ERROR_permissions to reject the client. + * + * @param serverID the server the client wants to connect to + * @param client pointer to a @ref ClientMiniExport describing the client trying to connect + * @return @ref ERROR_ok to allow, @ref ERROR_permissions to deny + */ + unsigned int (*permClientCanConnect) (uint64 serverID, const struct ClientMiniExport* client); + + /** + * @brief called when a client requests channel description of a channel using @ref ts3client_requestChannelDescription. Can be used to deny access to channel descriptions. + * + * Return @ref ERROR_ok to allow the action, or @ref ERROR_permissions to reject it. + * + * @param serverID the server on which the request was received + * @param client pointer to a @ref ClientMiniExport describing the client requesting the channel description + * @return @ref ERROR_ok to allow, @ref ERROR_permissions to deny + */ + unsigned int (*permClientCanGetChannelDescription) (uint64 serverID, const struct ClientMiniExport* client); + + /** + * @brief called when a client wants to update a clients variables. Used to deny or allow updating certain client variables + * + * Return @ref ERROR_ok to allow the action, or @ref ERROR_permissions to reject it. + * + * @param serverID the server for which the callback was called + * @param clientID the client for which the variables are attempted to be changed. + * @param variables pointer to a @ref VariablesExport containing the variables, new and old values of the client. + * @return @ref ERROR_ok to allow, @ref ERROR_permissions to deny + */ + unsigned int (*permClientUpdate) (uint64 serverID, anyID clientID, const struct VariablesExport* variables); + + /** + * @brief called before a client is kicked from the channel. Allows you to control whether clients are allowed to kick another client + * + * Return @ref ERROR_ok to allow the action, or @ref ERROR_permissions to reject it. + * + * @param serverID the server for which the callback was called + * @param client pointer to a @ref ClientMiniExport describing the client attempting to kick another client. + * @param toKickCount number of clients that are supposed to be kicked + * @param toKickClients array of @ref ClientMiniExport describing the clients to be kicked + * @param reasonText utf8 encoded c string containing the reason for the kick provided. + * @return @ref ERROR_ok to allow, @ref ERROR_permissions to deny + */ + unsigned int (*permClientKickFromChannel) (uint64 serverID, const struct ClientMiniExport* client, int toKickCount, const struct ClientMiniExport* toKickClients, const char* reasonText); + + /** + * @brief called before a client is kicked from the server. Allows you to control whether clients are allowed to kick another client + * + * Return @ref ERROR_ok to allow the action, or @ref ERROR_permissions to reject it. + * + * @param serverID the server for which the callback was called + * @param client pointer to a @ref ClientMiniExport describing the client attempting to kick another client. + * @param toKickCount number of clients that are supposed to be kicked + * @param toKickClients array of @ref ClientMiniExport describing the clients to be kicked + * @param reasonText utf8 encoded c string containing the provided reason for the kick. + * @return @ref ERROR_ok to allow, @ref ERROR_permissions to deny + */ + unsigned int (*permClientKickFromServer) (uint64 serverID, const struct ClientMiniExport* client, int toKickCount, const struct ClientMiniExport* toKickClients, const char* reasonText); + + /** + * @brief called when a client requests to move one or more other clients. Allows you to control whether a client can move the clients. + * + * Return @ref ERROR_ok to allow the action, or @ref ERROR_permissions to reject it. + * + * @param serverID the server on which the move is attempted. + * @param client pointer to a @ref ClientMiniExport describing the client attempting to move the client(s). + * @param toMoveCount number of clients that are being moved. + * @param toMoveClients array of @ref ClientMiniExport describing which clients are being moved. + * @param newChannel id of the channel the clients are to be moved in to. + * @param reasonText utf8 encoded c string containing the reason provided for the move. + * @return @ref ERROR_ok to allow, @ref ERROR_permissions to deny + */ + unsigned int (*permClientMove) (uint64 serverID, const struct ClientMiniExport* client, int toMoveCount, const struct ClientMiniExport* toMoveClients, uint64 newChannel, const char* reasonText); + + /** + * @brief called when a client attempts to move a channel. Allows you to control whether the client is allowed to move the channel. + * + * Return @ref ERROR_ok to allow the action, or @ref ERROR_permissions to reject it. + * + * @param serverID the server for which the callback was called + * @param client a @ref ClientMiniExport describing the client attempting to move the channel. + * @param channelID the channel to be moved. + * @param newParentChannelID the new parent channel of the channel + * @return @ref ERROR_ok to allow, @ref ERROR_permissions to deny + */ + unsigned int (*permChannelMove) (uint64 serverID, const struct ClientMiniExport* client, uint64 channelID, uint64 newParentChannelID); + + /** + * @brief called when a client tries to send a message. Allows you to control whether the client is allowed to send the message. + * + * Return @ref ERROR_ok to allow the action, or @ref ERROR_permissions to reject it. + * + * @param serverID the server for which the callback was called + * @param client a @ref ClientMiniExport describing the client attempting to send the message + * @param targetMode describing the type of message attempting to be sent. One of the values from the @ref TextMessageTargetMode enum + * @param targetClientOrChannel id of the channel or client (depending of the targetMode) that the message is sent to. + * @param textMessage utf8 encoded c string containing the message to be sent. + * @return @ref ERROR_ok to allow, @ref ERROR_permissions to deny + */ + unsigned int (*permSendTextMessage) (uint64 serverID, const struct ClientMiniExport* client, anyID targetMode, uint64 targetClientOrChannel, const char* textMessage); + + /** + * @brief called when server connection information is requested using @ref ts3client_requestServerConnectionInfo. Can be used to deny access. + * + * Return @ref ERROR_ok to allow the action, or @ref ERROR_permissions to reject it. + * + * @param serverID the server for which the callback was called + * @param client a @ref ClientMiniExport describing the client requesting the action + * @return @ref ERROR_ok to allow, @ref ERROR_permissions to deny + */ + unsigned int (*permServerRequestConnectionInfo) (uint64 serverID, const struct ClientMiniExport* client); + + /** + * @brief called when a client attempts to request another clients connection variables using @ref ts3client_requestConnectionInfo + * + * Return @ref ERROR_ok to allow the action, or @ref ERROR_permissions to reject it. + * + * @param serverID the server for which the callback was called + * @param client describes the client requesting the other clients information + * @param mayViewIpPort pointer to a variable that controls whether the IP and port of the target client may be seen by the client. Set to 1 to allow the requesting client to see the IP and port. Set to 0 to deny IP and port. + * @param targetClient describes the client that the connection information is requested for. + * @return @ref ERROR_ok to allow, @ref ERROR_permissions to deny + */ + unsigned int (*permSendConnectionInfo) (uint64 serverID, const struct ClientMiniExport* client, int* mayViewIpPort, const struct ClientMiniExport* targetClient); + + /** + * @brief called when a client attempts to create a channel. Allows you to control whether or not the client may create the desired channel. + * + * Return @ref ERROR_ok to allow the action, or @ref ERROR_permissions to reject it. + * + * @param serverID the server on which the client attempts to create the channel + * @param client a @ref ClientMiniExport describing the client trying to create a channel + * @param parentChannelID the channel that is the parent channel of the channel to be created. 0 if the channel to be created will be a root channel. + * @param variables a @ref VariablesExport struct that describes the channel to be created. + * @return @ref ERROR_ok to allow, @ref ERROR_permissions to deny + */ + unsigned int (*permChannelCreate) (uint64 serverID, const struct ClientMiniExport* client, uint64 parentChannelID, const struct VariablesExport* variables); + + /** + * @brief called when a channel is about to be edited by a client. Allows you to prevent channel edits. + * + * Return @ref ERROR_ok to allow the action, or @ref ERROR_permissions to reject it. + * + * @param serverID the server for which the callback was called + * @param client a @ref ClientMiniExport describing the client trying to edit the channel + * @param parentChannelID the channel that is to be edited. + * @param variables a @ref VariablesExport struct that describes the channel after the edit. + * @return @ref ERROR_ok to allow, @ref ERROR_permissions to deny + */ + unsigned int (*permChannelEdit) (uint64 serverID, const struct ClientMiniExport* client, uint64 channelID, const struct VariablesExport* variables); + + /** + * @brief called before a channel is deleted by a client. Allows you to deny a client deleting channels. + * + * Return @ref ERROR_ok to allow the action, or @ref ERROR_permissions to reject it. + * + * @param serverID the server on which the channel is to be deleted + * @param client a @ref ClientMiniExport describing the client trying to delete the channel + * @param channelID the channel that is to be deleted + * @return @ref ERROR_ok to allow, @ref ERROR_permissions to deny + */ + unsigned int (*permChannelDelete) (uint64 serverID, const struct ClientMiniExport* client, uint64 channelID); + + /** + * @brief called when a client requests to subscribe a channel. Allows you to deny subscribing to a channel. + * + * Return @ref ERROR_ok to allow the action, or @ref ERROR_permissions to reject it. + * + * @param serverID the server on which the client attempts to subscribe to the channel. + * @param client a @ref ClientMiniExport describing the client trying to subscribe the channel + * @param channelID the channel that is to be subscribed + * @return @ref ERROR_ok to allow, @ref ERROR_permissions to deny + */ + unsigned int (*permChannelSubscribe) (uint64 serverID, const struct ClientMiniExport* client, uint64 channelID); + + /** + * @brief called when a file is to be uploaded. Allows you to deny a client from uploading files, files above a certain size, etc. + * + * Return @ref ERROR_ok to allow the action, or @ref ERROR_permissions to reject it. + * + * @param serverID the server for which the callback was called + * @param client describes the client that attempts to upload the file. + * @param params describes the file to be uploaded. + * @return @ref ERROR_ok to allow, @ref ERROR_permissions to deny + */ + unsigned int (*permFileTransferInitUpload) (uint64 serverID, const struct ClientMiniExport* client, const struct ts3sc_ftinitupload* params); + + /** + * @brief called when a file is to be downloaded. Allows you to deny a client from downloading files, files above a certain size, etc. + * + * Return @ref ERROR_ok to allow the action, or @ref ERROR_permissions to reject it. + * + * @param serverID the server for which the callback was called + * @param client describes the client that attempts to download the file + * @param params describes the file to be downloaded. + * @return @ref ERROR_ok to allow, @ref ERROR_permissions to deny + */ + unsigned int (*permFileTransferInitDownload) (uint64 serverID, const struct ClientMiniExport* client, const struct ts3sc_ftinitdownload* params); + + /** + * @brief called when a client requests file information using @ref ts3client_requestFileInfo. Allows to deny clients from getting file information. + * + * Return @ref ERROR_ok to allow the action, or @ref ERROR_permissions to reject it. + * + * @param serverID the server for which the callback was called + * @param client describes the client attempting to get information of the file. + * @param params describes the file that information is requested for. + * @return @ref ERROR_ok to allow, @ref ERROR_permissions to deny + */ + unsigned int (*permFileTransferGetFileInfo) (uint64 serverID, const struct ClientMiniExport* client, const struct ts3sc_ftgetfileinfo* params); + + /** + * @brief called when a client requests a directory listing using @ref ts3client_requestFileList. Allows to deny listing files and directories in channels / directories. + * + * Return @ref ERROR_ok to allow the action, or @ref ERROR_permissions to reject it. + * + * @param serverID the server for which the callback was called + * @return @ref ERROR_ok to allow, @ref ERROR_permissions to deny + */ + unsigned int (*permFileTransferGetFileList) (uint64 serverID, const struct ClientMiniExport* client, const struct ts3sc_ftgetfilelist* params); + + /** + * @brief called when a client attempts to delete one or more files using @ref ts3client_requestDeleteFile. Allows denying clients deleting files. + * + * Return @ref ERROR_ok to allow the action, or @ref ERROR_permissions to reject it. + * + * @param serverID the server for which the callback was called + * @param client describes the client attempting to delete the file + * @param params describes the file to be deleted + * @return @ref ERROR_ok to allow, @ref ERROR_permissions to deny + */ + unsigned int (*permFileTransferDeleteFile) (uint64 serverID, const struct ClientMiniExport* client, const struct ts3sc_ftdeletefile* params); + + /** + * @brief called when a directory is to be created using @ref ts3client_requestCreateDirectory. Allows to deny creating certain directories. + * + * Return @ref ERROR_ok to allow the action, or @ref ERROR_permissions to reject it. + * + * @param serverID the server for which the callback was called + * @param client describes the client attempting to create the directory + * @param params describes the directory to create. + * @return @ref ERROR_ok to allow, @ref ERROR_permissions to deny + */ + unsigned int (*permFileTransferCreateDirectory) (uint64 serverID, const struct ClientMiniExport* client, const struct ts3sc_ftcreatedir* params); + + /** + * @brief called when a file is to be renamed or moved using @ref ts3client_requestRenameFile. Allows to deny moving files or even renaming files. + * + * Return @ref ERROR_ok to allow the action, or @ref ERROR_permissions to reject it. + * + * @param serverID the server for which the callback was called + * @param client describes the client attempting to rename or move the file. + * @param params describes the file to be renamed or moved, and where the file should be moved to if it's being moved. + * @return @ref ERROR_ok to allow, @ref ERROR_permissions to deny + */ + unsigned int (*permFileTransferRenameFile) (uint64 serverID, const struct ClientMiniExport* client, const struct ts3sc_ftrenamefile* params); + + /** + * @brief called when a server or channel password is set. + * + * Used to hash the password or encrypt it for check with outside sources. + * + * @param serverID the server for which the callback was called + * @param plaintext the plaintext password to be encrypted. + * @param encryptedText the encrypted/hashed password. Fill with your encrypted password. Must be an utf8 encoded c string not larger than specified by encryptedTextByteSize + * @param encryptedTextByteSize the maximum number of bytes you may write to encryptedText + */ + void (*onClientPasswordEncrypt) (uint64 serverID, const char* plaintext, char* encryptedText, int encryptedTextByteSize); + + /** + * @brief Allows to rewrite the file path and name of the file to be transfered. Called when a transfer starts. + * @details If you don't need to control server side file name and path then don't implement this callback. + * The parameters are already filled with the default values intended by the client starting the transfer. These can be changed as required. + * When the callback exits with @ref ERROR_ok the transfer is started with the values present in the result struct. + * @verbatim embed:rst + See the :ref:`SDK documentation ` for further details. + @endverbatim + * + * @param serverID the server for which the callback was called + * @param invokerClientID the client which started the file transfer + * @param original the original file path and name desired by the client + * @param result the values from this struct will be used by the server when the callback exits. Already filled with a copy of original. Change the values in this struct as needed. + * @return a value from the @ref Ts3ErrorType enum. Return @ref ERROR_ok to start the transfer with the values in the result struct. When returning an error code the file transfer is not started. + */ + unsigned int (*onTransformFilePath) (uint64 serverID, anyID invokerClientID, const struct TransformFilePathExport* original, struct TransformFilePathExportReturns* result); + + /** + * @brief called when a client connects to the server. Used to verify the server password when using custom password encryption. + * + * @param serverID the server for which the callback was called + * @param client describes the client that connects to the server + * @param password utf8 encoded c string containing the password provided by the client. + * @return a value from the @ref Ts3ErrorType enum. @ref ERROR_ok if the password is valid, @ref ERROR_server_invalid_password if the password is not valid, @ref ERROR_parameter_invalid if the password is in invalid format. + */ + unsigned int (*onCustomServerPasswordCheck) (uint64 serverID, const struct ClientMiniExport* client, const char* password); + + /** + * @brief called when a client attempts to enter a password protected channel. Used to verify the channel password when using custom password encryption. + * + * @param serverID the server for which the callback was called + * @param client describes the client that enters a channel + * @param channelID the channel the client attempts to join + * @param password utf8 encoded c string containing the password provided by the client. + * @return a value from the @ref Ts3ErrorType enum. @ref ERROR_ok if the password is valid, @ref ERROR_server_invalid_password if the password is not valid, @ref ERROR_parameter_invalid if the password is in invalid format. + */ + unsigned int (*onCustomChannelPasswordCheck) (uint64 serverID, const struct ClientMiniExport* client, uint64 channelID, const char* password); + +}; //END OF ServerLibFunctions + +/*Memory management*/ + +/** + * @brief Releases memory allocated by the server library + * + * For every function that has output parameters which take pointers to memory (e.g. char**) + * the server library will allocate sufficient memory for you, however you need to take care + * of releasing the memory by passing the variable to this function. + * + * @param pointer pointer to memory allocated by server library +*/ +EXPORTDLL unsigned int ts3server_freeMemory(void* pointer); + +/*Construction and Destruction*/ + +/** + * @brief initializes the server library and defines callback functions + * + * This is the first function you need to call, before this all calls to the server library will fail. In this call you will also set the functions you would like to have called when + * certain changes or events happen. This function must not be called multiple times. + * + * @param functionPointers defines which functions in your code are to be called on specific events. Zero initialize it and assign the desired function to call to the respective members of the @ref ServerLibFunctions struct + * @param usedLogTypes a combination of values from the @ref LogTypes enum. Specifies which type(s) of logging you would like to use. + * @param logFileFolder path in which to create log files. Pass 0 to use the default of using a folder called logs in the working directory. + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason +*/ +EXPORTDLL unsigned int ts3server_initServerLib(const struct ServerLibFunctions* functionPointers, int usedLogTypes, const char* logFileFolder); + +/** + * @brief Initialize the file transfer subsystem. Allows clients to store files on the machine the server is running on and download them. + * + * If you want to support file transfer functionality, then call this function after calling @ref ts3server_initServerLib + * If you don't call this function file transfer features will not be available. + * The server library will create the directories necessary for storing files as needed, however directories will not be cleaned up by + * the server library. Instead it is the responsibility of the application to clean up these directories when they're no longer needed (e.g. after a virtual server was deleted) + * + * @param filebase path to where the server library will create necessary directories and store files uploaded by clients. + * @param ips zero terminated array of IP addresses to listen on for file transfer connections. IPv4 and IPv6 addresses are supported, do NOT pass host names. + * If set to 0, it will be treated as if you passed { "0.0.0.0", "::", 0 } + * @param port the TCP port to listen on for file transfer connections. + * @param downloadBandwidth limit in bytes per second which is available for downloading files from the server. Speed across all transfers will be limited to this number. Specify @ref BANDWIDTH_LIMIT_UNLIMITED for no limit. + * @param uploadBandwidth limit in bytes per second which is available for uploading files to the server. Speed across all transfers will be limited to this number. Specify @ref BANDWIDTH_LIMIT_UNLIMITED for no limit. + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason +*/ +EXPORTDLL unsigned int ts3server_enableFileManager(const char* filebase, const char** ips, int port, uint64 downloadBandwidth, uint64 uploadBandwidth); + +/** + * @brief Destroys the server lib. Must not be called from within a callback. + * + * All clients will lose connection and timeout, all servers will terminate. + * This is the last function to call. After this call you will no longer be able to use any server library functions. + * + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason +*/ +EXPORTDLL unsigned int ts3server_destroyServerLib(); + +/** + * @brief Prevents clients from performing certain actions. SDK only. + * + * Use this to disable certain features for clients, e.g. deleting channels or moving clients + * so that the server has authority over these matters and is the only entity who can do so. + * To disable multiple commands, call this function once for each command you would like to disable for clients. + * + * @param clientCommand the command to disable. One of the values from the @ref ClientCommand enum + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason +*/ +EXPORTDLL unsigned int ts3server_disableClientCommand(int clientCommand); + +/** + * @brief Retrieve the server version string + * + * @param result address of a variable to receive the server version. + * Memory is allocated by the server library and must be freed by caller using @ref ts3server_freeMemory + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason +*/ +EXPORTDLL unsigned int ts3server_getServerLibVersion(char** result); + +/** + * @brief Retrieve the server version number + * + * @param result address of a variable to receive the server version number. + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason +*/ +EXPORTDLL unsigned int ts3server_getServerLibVersionNumber(uint64* result); + +/*logging*/ + +/** + * @brief Specify which log messages to send to the @ref ServerLibFunctions.onUserLoggingMessageEvent callback + * + * @param logVerbosity Minimum verbosity of a log message to pass to the callback. One of the values from the @ref LogLevel enum. + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason +*/ +EXPORTDLL unsigned int ts3server_setLogVerbosity(enum LogLevel logVerbosity); + +/*error handling*/ + +/** + * @brief get a human readable error description string for an error code + * + * @param globalErrorCode the error code to retrieve the description for. One of the values from the @ref Ts3ErrorType enum. + * @param result address of a variable to receive the error description as a utf8 encoded c string. + * Memory is allocated by the server library and must be freed by caller using @ref ts3server_freeMemory + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason +*/ +EXPORTDLL unsigned int ts3server_getGlobalErrorMessage(unsigned int globalErrorCode, char** result); + +/*client info*/ + +/** + * @brief get the value of a client variable as integer. + * + * Not all variables are available as integer, some are only available as string or unsigned 64 bit integer. + * + * @param serverID specifies the server the client is on + * @param clientID which client to query + * @param flag specifies which variable to retrieve. One of the values from the @ref ClientProperties enum. + * @param result address of a variable to receive the value of the variable queried. + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason +*/ +EXPORTDLL unsigned int ts3server_getClientVariableAsInt(uint64 serverID, anyID clientID, enum ClientProperties flag, int* result); + +/** + * @brief get the value of a client variable as unsigned 64 bit integer. + * + * Not all variables are available as unsigned 64 bit integer, some are only available as string or integer. + * + * @param serverID specifies the server the client is on + * @param clientID which client to query + * @param flag specifies which variable to retrieve. One of the values from the @ref ClientProperties enum. + * @param result address of a variable to receive the value of the variable queried. + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason +*/ +EXPORTDLL unsigned int ts3server_getClientVariableAsUInt64(uint64 serverID, anyID clientID, enum ClientProperties flag, uint64* result); + +/** + * @brief get the value of the client variable as string + * + * Not all variables are available as string, some are only available as unsigned 64 bit integer or integer. + * + * @param serverID specifies the server the client is on + * @param clientID which client to query + * @param flag specifies which variable to retrieve. One of the values from the @ref ClientProperties enum. + * @param result address of a variable to receive the value of the variable queried. + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason +*/ +EXPORTDLL unsigned int ts3server_getClientVariableAsString(uint64 serverID, anyID clientID, enum ClientProperties flag, char** result); + +/** + * @brief set the value of a client variable. + * + * Not all variables can be set as integer. + * + * @param serverID specifies the server the client is on + * @param clientID which client to query + * @param flag specifies which variable to retrieve. One of the values from the @ref ClientProperties enum. + * @param value the new value to set + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason +*/ +EXPORTDLL unsigned int ts3server_setClientVariableAsInt(uint64 serverID, anyID clientID, enum ClientProperties flag, int value); + +/** + * @brief set the value of a client variable. + * + * Not all variables can be set as unsigned 64 bit integer. + * + * @param serverID specifies the server the client is on + * @param clientID which client to query + * @param flag specifies which variable to retrieve. One of the values from the @ref ClientProperties enum. + * @param value the new value to set + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason +*/ +EXPORTDLL unsigned int ts3server_setClientVariableAsUInt64(uint64 serverID, anyID clientID, enum ClientProperties flag, uint64 value); + +/** + * @brief set the value of a client variable. + * + * Not all variables can be set as string. + * + * @param serverID specifies the server the client is on + * @param clientID which client to query + * @param flag specifies which variable to retrieve. One of the values from the @ref ClientProperties enum. + * @param value the new value to set + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason +*/ +EXPORTDLL unsigned int ts3server_setClientVariableAsString(uint64 serverID, anyID clientID, enum ClientProperties flag, const char* value); + +/** + * @brief Apply and publish client changes after setting client variables. + * + * @param serverID specifies the server the client is on + * @param clientID the client which we have changed variables for. + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason +*/ +EXPORTDLL unsigned int ts3server_flushClientVariable(uint64 serverID, anyID clientID); + +/** + * @brief set a clients whisper list. Will stop transmitting that clients voice to their current channel. + * + * The client will still receive voice from their current channel, however their voice will not be transmitted to their current channel anymore. + * The voice data of the specified client will be transmitted to all specified channels and all the specified clients. + * Pass 0 to both channelID and clientID to restore default behavior of transmitting voice to current channel. + * + * @param serverID the server on which to set the whisper list + * @param clID the client for which to set the whisper list + * @param channelID zero terminated array of channel ids to add to the whisper list. Pass nullptr to reset. Like { 3, 94, 84, ..., 0 } + * @param clientID zero terminated array of client ids to add to the whisper list. Pass nullptr to reset. Like { 1, 4, ..., 0 } + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason +*/ +EXPORTDLL unsigned int ts3server_setClientWhisperList(uint64 serverID, anyID clID, const uint64* channelID, const anyID* clientID); + +/** + * @brief get a list of all clients connected to a server + * + * @param serverID specifies the server on which to get the list of clients + * @param result address of a variable to receive the zero terminated list of clients, like {1, 2, 50, ..., 0} + * Memory is allocated by the server library and caller must free the array using @ref ts3server_freeMemory + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason +*/ +EXPORTDLL unsigned int ts3server_getClientList(uint64 serverID, anyID** result); + +/** + * @brief get the id of the clients current channel + * + * @param serverID specifies the server the client is on + * @param clientID the client to get the channel of + * @param result address of a variable to receive the channel id + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason +*/ +EXPORTDLL unsigned int ts3server_getChannelOfClient(uint64 serverID, anyID clientID, uint64* result); + +/** + * @brief Move one or more clients to a different channel + * + * @param serverID specifies the server the client is connected to + * @param newChannelID the id of the channel to move the client(s) to + * @param clientIDArray zero terminated array of client ids to move. Like {4, 9, ..., 0} + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason +*/ +EXPORTDLL unsigned int ts3server_clientMove(uint64 serverID, uint64 newChannelID, const anyID* clientIDArray); + +/** + * @brief kick one or more clients from the server, terminating their connection. + * + * @param serverID the server the client(s) are connected to + * @param clientIDArray zero terminated array of client ids to kick. Like {4, 3, 12, ..., 0} + * @param kickReason utf8 encoded c string describing the reason for the kick. Pass an empty string if unused. + * @param failOnClientError boolean flag. If 1 the function will fail if clients to be kicked are not on the server. + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason +*/ +EXPORTDLL unsigned int ts3server_clientsKickFromServer(uint64 serverID, const anyID* clientIDArray, const char* kickReason, int failOnClientError); + +/** + * @brief get a list of clients that are using one of the specified public identities + * + * @param serverID the server to check for clients on + * @param clientUIDs address of a zero terminated array containing the client unique identifiers to find client ids for. Like { "uid1", "uid2", ..., '@0' } + * @param result address of a variable to receive the client ids using any of the supplied unique identifiers. + * Memory is allocated by the server library and caller must free the array using @ref ts3server_freeMemory + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason +*/ +EXPORTDLL unsigned int ts3server_getClientIDSfromUIDS(uint64 serverID, const char** clientUIDs, anyID** result); + +/*channel info*/ + +/** + * @brief get value of a channel variable as integer. + * + * Not all variables are available as integer, some are only available as string or unsigned 64 bit integer. + * + * @param serverID specifies the server the channel is located on + * @param channelID the id of the channel to get the variable for + * @param flag specifies which variable to retrieve. One of the values from the @ref ChannelProperties enum + * @param result address of a variable to receive the value of the queried variable. + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason +*/ +EXPORTDLL unsigned int ts3server_getChannelVariableAsInt(uint64 serverID, uint64 channelID, enum ChannelProperties flag, int* result); + +/** + * @brief get value of a channel variable as unsigned 64 bit integer. + * + * Not all variables are available as unsigned 64 bit integer, some are only available as string or integer. + * + * @param serverID specifies the server the channel is located on + * @param channelID the id of the channel to get the variable for + * @param flag specifies which variable to retrieve. One of the values from the @ref ChannelProperties enum + * @param result address of a variable to receive the value of the queried variable. + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason +*/ +EXPORTDLL unsigned int ts3server_getChannelVariableAsUInt64(uint64 serverID, uint64 channelID, enum ChannelProperties flag, uint64* result); + +/** + * @brief get value of a channel variable as string. + * + * Not all variables are available as string, some are only available as integer or unsigned 64 bit integer. + * + * @param serverID specifies the server the channel is located on + * @param channelID the id of the channel to get the variable for + * @param flag specifies which variable to retrieve. One of the values from the @ref ChannelProperties enum + * @param result address of a variable to receive the value of the queried variable. + * Memory is allocated by the server library and caller must free it using @ref ts3server_freeMemory + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason +*/ +EXPORTDLL unsigned int ts3server_getChannelVariableAsString(uint64 serverID, uint64 channelID, enum ChannelProperties flag, char** result); + +/** + * @brief set the variable of a channel to a new value. + * + * Call @ref ts3server_flushChannelVariable after having set all variables you need to change. + * + * @param serverID specifies the server the channel is located on + * @param channelID specifies the channel on which to change the variable + * @param flag specifies which variable to change. One of the values from the @ref ChannelProperties enum + * @param value the new value to set + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason +*/ +EXPORTDLL unsigned int ts3server_setChannelVariableAsInt(uint64 serverID, uint64 channelID, enum ChannelProperties flag, int value); + +/** + * @brief set a channel variable + * + * Call @ref ts3server_flushChannelVariable after having set all variables you need to change. + * + * @param serverID the server on which the channel is located + * @param channelID the id of the channel to set the variable for + * @param flag specifies which variable to set. One of the values from the @ref ChannelProperties enum + * @param value the new value to set + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason +*/ +EXPORTDLL unsigned int ts3server_setChannelVariableAsUInt64(uint64 serverID, uint64 channelID, enum ChannelProperties flag, uint64 value); + +/** + * @brief + * + * Call @ref ts3server_flushChannelVariable after having set all variables you need to change. + * + * @param serverID the server on which the channel is located + * @param channelID the id of the channel to set the variable for + * @param flag specifies which variable to set. One of the values from the @ref ChannelProperties enum + * @param value the new value to set + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason +*/ +EXPORTDLL unsigned int ts3server_setChannelVariableAsString(uint64 serverID, uint64 channelID, enum ChannelProperties flag, const char* value); + +/** + * @brief After changing channel variables call this function to publish the changes to connected clients + * + * @param serverID the server on which channels were edited + * @param channelID the channel which variables were changed + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason +*/ +EXPORTDLL unsigned int ts3server_flushChannelVariable(uint64 serverID, uint64 channelID); + +/** + * @brief After setting the channel properties on a new channel, call this function to publish the channel to clients + * + * @param serverID the server on which to create the channel + * @param channelParentID the id of the parent channel for the new channel + * @param result address of a variable to receive the channel id of the newly created channel + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason +*/ +EXPORTDLL unsigned int ts3server_flushChannelCreation(uint64 serverID, uint64 channelParentID, uint64* result); + +/** + * @brief Create a structure that defines channel properties for use with @ref ts3server_createChannel. + * + * @param result address of a variable to receive a pointer to the structure. Pointer must not be freed! + * After receiving the structure pointer, it must be filled using @ref ts3server_setChannelCreationParams + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason +*/ +EXPORTDLL unsigned int ts3server_makeChannelCreationParams(struct TS3ChannelCreationParams** result); + +/** + * @brief Specify mandatory details of a channel to be created at server creation using @ref ts3server_createVirtualServer2 + * + * @details Must be called after @ref ts3server_getVirtualServerCreationParamsChannelCreationParams to set basic properties of a channel. + * After this call you may set additional channel properties by calling @ref ts3server_getChannelCreationParamsVariables and @ref ts3server_setVariableAsInt, @ref ts3server_setVariableAsUInt64 or @ref ts3server_setVariableAsString + * + * @param channelCreationParams defines the channel for which we set basic properties. Obtained by calling @ref ts3server_getVirtualServerCreationParamsChannelCreationParams + * @param channelParentID the id of the channel that this channel is a sub channel of. Pass 0 to make this channel a root channel. + * @param channelID the id this channel should have. Pass 0 to have the server lib assign a free ID. This is used to identify the channel in other calls to the client and server library. Must be unique across all virtual servers during the lifetime of the server library. + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason +*/ +EXPORTDLL unsigned int ts3server_setChannelCreationParams(struct TS3ChannelCreationParams* channelCreationParams, uint64 channelParentID, uint64 channelID); /*0 id's means undefined*/ + +/** + * @brief Allows settings optional channel properties for channels to be created either at server creation using @ref ts3server_createVirtualServer2 or using @ref ts3server_createChannel. + * + * @param channelCreationParams defines which channel to set variables for. Address of the structure obtained by calling @ref ts3server_getVirtualServerCreationParamsChannelCreationParams + * when the channel is to be created at server creation (using @ref ts3server_createVirtualServer2) or obtained by calling @ref ts3server_makeChannelCreationParams when using with @ref ts3server_createChannel + * @param result address of a variable to receive a pointer that is to be filled using @ref ts3server_setVariableAsInt, @ref ts3server_setVariableAsUInt64 or @ref ts3server_setVariableAsString + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason +*/ +EXPORTDLL unsigned int ts3server_getChannelCreationParamsVariables(struct TS3ChannelCreationParams* channelCreationParams, struct TS3Variables** result); + +/** + * @brief create a new channel on an existing virtual server. + * + * @param serverID the server on which to create the channel. + * @param channelCreationParams defines channel properties. Address of the structure obtained by calling @ref ts3server_makeChannelCreationParams + * Must have been filled using @ref ts3server_setChannelCreationParams before this call. + * @param flags defines how certain information is presented in the channelCreationParams. Combination of the values from the @ref ChannelCreateFlags enum + * @param result address of a variable to receive the channel id of the newly created channel. + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason +*/ +EXPORTDLL unsigned int ts3server_createChannel(uint64 serverID, struct TS3ChannelCreationParams* channelCreationParams, enum ChannelCreateFlags flags, uint64* result); + +/** + * @brief list all channels on the server + * + * @param serverID the server to get the list of channels on + * @param result address of a variable to receive a zero terminted array of channel ids. Like {4, 65, 23, ..., 0} + * Memory is allocated by the server library and caller must free the array using @ref ts3server_freeMemory + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason +*/ +EXPORTDLL unsigned int ts3server_getChannelList(uint64 serverID, uint64** result); + +/** + * @brief get list of clients in a channel + * + * @param serverID the server on which the channel is located + * @param channelID the channel of which to get the list of clients + * @param result address of a variable to receive a zero terminated array of client ids in the channel. Like {3, 5, 39, ..., 0} + * Memory is allocated by the server library and caller must free the array using @ref ts3server_freeMemory + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason +*/ +EXPORTDLL unsigned int ts3server_getChannelClientList(uint64 serverID, uint64 channelID, anyID** result); + +/** + * @brief get the parent channel of a channel + * + * @param serverID the server on which the channel is located + * @param channelID the channel of which to get the parent channel + * @param result address of a variable to receive the parent channel id + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason +*/ +EXPORTDLL unsigned int ts3server_getParentChannelOfChannel(uint64 serverID, uint64 channelID, uint64* result); + +/** + * @brief delete a channel + * + * @param serverID the server on which the channel is located + * @param channelID the id of the channel to delete + * @param force boolean flag, 1 = delete even if there are clients or sub channels in the channel. 0 = fail if there are sub channels or clients in the channel or sub channels. + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason +*/ +EXPORTDLL unsigned int ts3server_channelDelete(uint64 serverID, uint64 channelID, int force); + +/** + * @brief move a channel within the tree, make it a sub channel or root channel. + * + * @param serverID the server on which to move a channel + * @param channelID the channel to move + * @param newChannelParentID id of the parent channel to move this channel into. Set to 0 to make this channel a root channel. + * @param newOrder id of the channel below which this channel is to be sorted. + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason +*/ +EXPORTDLL unsigned int ts3server_channelMove(uint64 serverID, uint64 channelID, uint64 newChannelParentID, uint64 newOrder); + +/*server info*/ + +/** + * @brief get the value of a server variable + * + * @param serverID the server of which to get a variable value + * @param flag specifies for which variable to get the value. One of the values from the @ref VirtualServerProperties enum + * @param result address of a variable to receive the result + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason +*/ +EXPORTDLL unsigned int ts3server_getVirtualServerVariableAsInt(uint64 serverID, enum VirtualServerProperties flag, int* result); + +/** + * @brief get the value of a server variable + * + * @param serverID the server of which to get a variable value + * @param flag specifies for which variable to get the value. One of the values from the @ref VirtualServerProperties enum + * @param result address of a variable to receive the result. + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason +*/ +EXPORTDLL unsigned int ts3server_getVirtualServerVariableAsUInt64(uint64 serverID, enum VirtualServerProperties flag, uint64* result); + +/** + * @brief get the value of a server variable + * + * @param serverID the server of which to get a variable value + * @param flag specifies for which variable to get the value. One of the values from the @ref VirtualServerProperties enum + * @param result address of a variable to receive a utf8 encoded c string containing the value. + * Memory is allocated by the server library and must be freed by the caller using @ref ts3server_freeMemory + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason +*/ +EXPORTDLL unsigned int ts3server_getVirtualServerVariableAsString(uint64 serverID, enum VirtualServerProperties flag, char** result); + +/** + * @brief set a new value for a server variable + * + * After you're done setting all the variables you need to change, a call to @ref ts3server_flushVirtualServerVariable is necessary to publish the changes + * + * @param serverID specifies which server to set the variable on + * @param flag specifies which server variable to set. One of the values from the @ref VirtualServerProperties enum + * @param value the new value to set + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason +*/ +EXPORTDLL unsigned int ts3server_setVirtualServerVariableAsInt(uint64 serverID, enum VirtualServerProperties flag, int value); + +/** + * @brief set a new value for a server variable + * + * After you're done setting all the variables you need to change, a call to @ref ts3server_flushVirtualServerVariable is necessary to publish the changes + * + * @param serverID specifies which server to set the variable on + * @param flag specifies which server variable to set. One of the values from the @ref VirtualServerProperties enum + * @param value the new value to set + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason +*/ +EXPORTDLL unsigned int ts3server_setVirtualServerVariableAsUInt64(uint64 serverID, enum VirtualServerProperties flag, uint64 value); + +/** + * @brief set a new value for a server variable + * + * After you're done setting all the variables you need to change, a call to @ref ts3server_flushVirtualServerVariable is necessary to publish the changes + * + * @param serverID specifies which server to set the variable on + * @param flag specifies which server variable to set. One of the values from the @ref VirtualServerProperties enum + * @param value the new value to set + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason +*/ +EXPORTDLL unsigned int ts3server_setVirtualServerVariableAsString(uint64 serverID, enum VirtualServerProperties flag, const char* value); + +/** + * @brief Publish server changes done through previous calls to @ref ts3server_setVirtualServerVariableAsInt, @ref ts3server_setVirtualServerVariableAsString, @ref ts3server_setVirtualServerVariableAsUInt64 + * + * @param serverID the server you previously called setVirtualServerVariableAs functions + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason +*/ +EXPORTDLL unsigned int ts3server_flushVirtualServerVariable(uint64 serverID); + +/** + * @brief Creates a structure to define an entire virtual server including the channel layout for server creation for use with @ref ts3server_createVirtualServer2 + * + * @details This is the first function to call when using the @ref ts3server_createVirtualServer2 meachanism of creating virtual servers in one go, including all of their channels. + * After receiving the structure using this function, you need to call @ref ts3server_setVirtualServerCreationParams to set basic configuration for this virtual server. + * Once that is done you can set additional parameters using @ref ts3server_getVirtualServerCreationParamsVariables and @ref ts3server_setVariableAsInt, @ref ts3server_setVariableAsUInt64 or @ref ts3server_setVariableAsString + * + * @param result address of a variable to receive a pointer to a structure defining the virtual server. This must be filled using @ref ts3server_setVirtualServerCreationParams after this. + * Pointer must not be freed by caller. + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason +*/ +EXPORTDLL unsigned int ts3server_makeVirtualServerCreationParams(struct TS3VirtualServerCreationParams** result); + +/** + * @brief Set mandatory server creation properties for server creation using @ref ts3server_createVirtualServer2. + * + * @details This call is mandatory after calling @ref ts3server_makeVirtualServerCreationParams when using @ref ts3server_createVirtualServer2 and sets the basic information to create a virtual server. + * After this call you can optionally set other variables by calling @ref ts3server_getVirtualServerCreationParamsVariables after this. + * + * @param virtualServerCreationParams pointer to a struct of creation parameters obtained by calling @ref ts3server_makeVirtualServerCreationParams + * @param serverPort the UDP port to listen for client connections on + * @param serverIp comma separated list of IP address(es) to listen for client connections on. IPv4 and IPv6 addresses are supported. + * @param serverKeyPair unique key for encryption. Pass an empty string when originally creating a new server, query the generated encryption key with @ref ts3server_getVirtualServerKeyPair, store it and use it on subsequent start ups. + * @param serverMaxClients maximum number of clients that can be connected simultaneously at any given time + * @param channelCount the amount of channels this server will have after creation. You must call @ref ts3server_getVirtualServerCreationParamsChannelCreationParams with this virtualServerCreationParams exactly this many times. + * @param serverID the id this virtual server will have when created. server id must be unique during life time of the server library. + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason +*/ +EXPORTDLL unsigned int ts3server_setVirtualServerCreationParams(struct TS3VirtualServerCreationParams* virtualServerCreationParams, unsigned int serverPort, const char* serverIp, const char* serverKeyPair, unsigned int serverMaxClients, unsigned int channelCount, uint64 serverID); + +/** + * @brief create struct to define optional server settings for server creation with @ref ts3server_createVirtualServer2 + * + * @param virtualServerCreationParams + * @param result address of a variable to receive a pointer to a TS3Variables struct, to set optional server settings using @ref ts3server_setVariableAsInt, @ref ts3server_setVariableAsString or @ref ts3server_setVariableAsUInt64. + * Memory must not be freed by caller. + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason +*/ +EXPORTDLL unsigned int ts3server_getVirtualServerCreationParamsVariables(struct TS3VirtualServerCreationParams* virtualServerCreationParams, struct TS3Variables** result); + +/** + * @brief Used to specify channels to create during advanced server creation using @ref ts3server_createVirtualServer2. + * + * @details Call this function exactly as often as you indicated channels to be created in the @ref ts3server_setVirtualServerCreationParams call. + * Once you have received the struct you must set the details using @ref ts3server_setChannelCreationParams and can optionally set additional parameters using + * @ref ts3server_getChannelCreationParamsVariables to get a structure to fill using @ref ts3server_setVariableAsInt, @ref ts3server_setVariableAsString, @ref ts3server_setVariableAsUInt64 + * + * @param virtualServerCreationParams pointer to the server structure on which to create this channel. Obtained by calling @ref ts3server_makeVirtualServerCreationParams + * @param channelIdx specifies the channel to specify creation parameters for. Must be > 0 and < the channelCount parameter specified in the @ref ts3server_setVirtualServerCreationParams call + * @param result address of a variable to receive a pointer that is to be filled using @ref ts3server_setChannelCreationParams. Must not be freed by caller. + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason +*/ +EXPORTDLL unsigned int ts3server_getVirtualServerCreationParamsChannelCreationParams(struct TS3VirtualServerCreationParams* virtualServerCreationParams, unsigned int channelIdx, struct TS3ChannelCreationParams** result); + +/** + * @brief Create an entire server structure in a single call. Useful for restoring an entire virtual server including channels including their ids after storing them on shutdown. + * See the SDK documentation for more in depth information. + * + * @details This requires a few other calls to be made in advance. First you need to call @ref ts3server_makeVirtualServerCreationParams to get a + * TS3VirtualServerCreationParams struct that then needs to be filled via @ref ts3server_setVirtualServerCreationParams. + * You can then use @ref ts3server_getVirtualServerCreationParamsVariables to set other server settings and use @ref ts3server_getVirtualServerCreationParamsChannelCreationParams + * to specify channels to create using @ref ts3server_setChannelCreationParams. + * + * @param virtualServerCreationParams pointer to the server parameters obtained by calling @ref ts3server_makeVirtualServerCreationParams. These must have been filled using + * @ref ts3server_setVirtualServerCreationParams before calling this function. + * @param flags defines how certain information is present in the virtualServerCreationParams. Combination of the values from the @ref VirtualServerCreateFlags enum + * @param result address of a variable to receive the created servers id. This is used in other calls to the server library to identify this server. + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason +*/ +EXPORTDLL unsigned int ts3server_createVirtualServer2(struct TS3VirtualServerCreationParams* virtualServerCreationParams, enum VirtualServerCreateFlags flags, uint64* result); + +/** + * @brief get value of server connection properties as unsigned integer. + * + * @param serverID which server to get connection properties of + * @param flag specifies which property to get the value of. One of the values from the @ref ConnectionProperties enum + * @param result address of a variable to receive the value of the connection property + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason +*/ +EXPORTDLL unsigned int ts3server_getVirtualServerConnectionVariableAsUInt64(uint64 serverID, enum ConnectionProperties flag, uint64* result); + +/** + * @brief get value of server connection properties as double + * + * @param serverID which server to get connection properties of + * @param flag specifies which value to get. One of the values from the @ref ConnectionProperties enum + * @param result address of a variable to receive the value of the connection property. + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason +*/ +EXPORTDLL unsigned int ts3server_getVirtualServerConnectionVariableAsDouble(uint64 serverID, enum ConnectionProperties flag, double* result); + +/** + * @brief get a list of virtual servers in this instance + * + * @param result address of a variable to receive a zero terminated array of virtual server ids. Like {4, 8, ..., 0} + * Memory is allocated by the server library and caller must free the array using @ref ts3server_freeMemory + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason +*/ +EXPORTDLL unsigned int ts3server_getVirtualServerList(uint64** result); + +/** + * @brief deletes a virtual server. All clients will be disconnected and no more connections are accepted. You need to recreate the server + * using @ref ts3server_createVirtualServer or @ref ts3server_createVirtualServer2 to make it available again. + * + * You may want to save the state of the virtual server if you need persistence. + * + * @param serverID specifies which server to stop + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason +*/ +EXPORTDLL unsigned int ts3server_stopVirtualServer(uint64 serverID); + +/** + * @brief create a new virtual server. The server is started automatically after being created. + * + * @param serverPort the UDP port to listen for client connections on + * @param serverIp comma separated list of IP address(es) to listen for client connections on. IPv4 and IPv6 addresses are supported. + * @param serverName display name of the server. + * @param serverKeyPair Key pair for encryption. Must be unique for each virtual server. Pass an empty string when originally creating a new server, query the generated encryption key with @ref ts3server_getVirtualServerKeyPair, store it and use it on subsequent start ups. + * @param serverMaxClients maximum number of clients that can be connected simultaneously at any given time + * @param result address of a variable that will receive the virtual server ID that can be used to specify this server in future calls to server library functions. + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason +*/ +EXPORTDLL unsigned int ts3server_createVirtualServer(unsigned int serverPort, const char* serverIp, const char* serverName, const char* serverKeyPair, unsigned int serverMaxClients, uint64* result); + +/** + * @brief retrieve the encryption keys used by the virtual server. + * + * Store these and use them on subsequent process startup to recreate this server when calling @ref ts3server_createVirtualServer + * + * @param serverID the server for which to get the key pair. + * @param result address of a variable to receive a utf8 encoded c string containing the key pair. + * Memory is allocated by the server library and must be freed by caller using @ref ts3server_freeMemory + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason +*/ +EXPORTDLL unsigned int ts3server_getVirtualServerKeyPair(uint64 serverID, char** result); + +/*security salt/hash*/ + +/** + * @brief Create a security salt to lock channel to identities. See the :ref:SDK Documentation<`channel_security_salt`> on the topic for more in depth explanation. + * + * @param options specifies which parameters to include in the security salt. A combination of values from the @ref SecuritySaltOptions enum. + * @param salt pointer to random data of cryptographic quality. + * @param saltByteSize number of bytes of random data to use. Larger is better but slower. + * @param securitySalt address of a variable to receive the security salt. + * Memory is allocated by the server library and needs to be freed by caller using @ref ts3server_freeMemory + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason +*/ +EXPORTDLL unsigned int ts3server_createSecuritySalt(int options, void* salt, int saltByteSize, char** securitySalt); + +/** + * @brief create a hash for a specific client from a security salt to lock an identity to a channel. See the :ref:SDK Documentation<`channel_security_salt`> on the topic for more in depth explanation. + * + * @param securitySalt the security salt of a channel as generated by @ref ts3server_createSecuritySalt + * @param clientUniqueIdentifier public identity of a client to generate a security hash for + * @param clientNickName nickname of the client to include in the hash if specified by the salt. + * @param clientMetaData meta data of the client to include in the hash if specified by the salt. + * @param securityHash address of a variable to receive the security hash. + * Memory is allocated by the server library and must be freed by caller using @ref ts3server_freeMemory + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason +*/ +EXPORTDLL unsigned int ts3server_calculateSecurityHash(const char* securitySalt, const char* clientUniqueIdentifier, const char* clientNickName, const char* clientMetaData, char** securityHash); + +/*variable editing*/ + +/** + * @brief get the value of a property of a server or channel when using @ref ts3server_createVirtualServer2 or @ref ts3server_createChannel + * + * Not all properties are available as integer. Some are only available as string or unsigned 64 bit integer. + * + * @param var pointer to a TS3Variables struct obtained by calling @ref ts3server_getVirtualServerCreationParamsVariables or @ref ts3server_getChannelCreationParamsVariables + * @param flag specifies which variable to receive the value of. One of the values from the @ref VirtualServerProperties enum + * @param result address of a variable to receive the desired value + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason +*/ +EXPORTDLL unsigned int ts3server_getVariableAsInt(struct TS3Variables* var, int flag, int* result); + +/** + * @brief get the value of a property of a server or channel when using @ref ts3server_createVirtualServer2 or @ref ts3server_createChannel + * + * Not all properties are available as unsigned 64 bit integer. Some are only available as string or integer. + * + * @param var pointer to a TS3Variables struct obtained by calling @ref ts3server_getVirtualServerCreationParamsVariables or @ref ts3server_getChannelCreationParamsVariables + * @param flag specifies which variable to receive the value of. One of the values from the @ref VirtualServerProperties enum + * @param result address of a variable to receive the desired value + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason +*/ +EXPORTDLL unsigned int ts3server_getVariableAsUInt64(struct TS3Variables* var, int flag, uint64* result); + +/** + * @brief get the value of a property of a server or channel when using @ref ts3server_createVirtualServer2 or @ref ts3server_createChannel + * + * Not all properties are available as string. Some are only available as unsigned 64 bit integer or integer. + * + * @param var pointer to a TS3Variables struct obtained by calling @ref ts3server_getVirtualServerCreationParamsVariables or @ref ts3server_getChannelCreationParamsVariables + * @param flag specifies which variable to receive the value of. One of the values from the @ref VirtualServerProperties enum + * @param result address of a variable to receive the desired value. + * Memory is allocated by the server library and must be freed by caller using @ref ts3server_freeMemory + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason +*/ +EXPORTDLL unsigned int ts3server_getVariableAsString(struct TS3Variables* var, int flag, char** result); + +/** + * @brief set the value of a property of a server or channel when using @ref ts3server_createVirtualServer2 or @ref ts3server_createChannel + * + * Not all properties are available as integer. Some are only available as string or unsigned 64 bit integer. + * + * @param var pointer to a TS3Variables struct obtained by calling @ref ts3server_getVirtualServerCreationParamsVariables or @ref ts3server_getChannelCreationParamsVariables + * @param flag specifies which variable to receive the value of. One of the values from the @ref VirtualServerProperties enum + * @param value the new value to set for the variable. + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason +*/ +EXPORTDLL unsigned int ts3server_setVariableAsInt(struct TS3Variables* var, int flag, int value); + +/** + * @brief set the value of a property of a server or channel when using @ref ts3server_createVirtualServer2 or @ref ts3server_createChannel + * + * Not all properties are available as unsigned 64 bit integer. Some are only available as string or integer. + * + * @param var pointer to a TS3Variables struct obtained by calling @ref ts3server_getVirtualServerCreationParamsVariables or @ref ts3server_getChannelCreationParamsVariables + * @param flag specifies which variable to receive the value of. One of the values from the @ref VirtualServerProperties enum + * @param value the new value to set for the variable. + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason +*/ +EXPORTDLL unsigned int ts3server_setVariableAsUInt64(struct TS3Variables* var, int flag, uint64 value); + +/** + * @brief set the value of a property of a server or channel when using @ref ts3server_createVirtualServer2 or @ref ts3server_createChannel + * + * Not all properties are available as string. Some are only available as unsigned 64 bit integer or integer. + * + * @param var pointer to a TS3Variables struct obtained by calling @ref ts3server_getVirtualServerCreationParamsVariables or @ref ts3server_getChannelCreationParamsVariables + * @param flag specifies which variable to receive the value of. One of the values from the @ref VirtualServerProperties enum + * @param value utf8 encoded c string containing the value to set the variable to + * @return An Error code from the @ref Ts3ErrorType enum indicating either success or the failure reason +*/ +EXPORTDLL unsigned int ts3server_setVariableAsString(struct TS3Variables* var, int flag, const char* value); + +#ifdef __cplusplus +} +#endif + +#endif diff --git a/include/teamspeak/serverlib_publicdefinitions.h b/include/teamspeak/serverlib_publicdefinitions.h new file mode 100644 index 0000000..0726f27 --- /dev/null +++ b/include/teamspeak/serverlib_publicdefinitions.h @@ -0,0 +1,4 @@ +#ifndef SERVERLIB_PUBLICDEFINITIONS_H +#define SERVERLIB_PUBLICDEFINITIONS_H + +#endif //SERVERLIB_PUBLICDEFINITIONS_H diff --git a/include/ts3_functions.h b/include/ts3_functions.h index 39236a1..8bc48ef 100644 --- a/include/ts3_functions.h +++ b/include/ts3_functions.h @@ -5,275 +5,304 @@ extern "C" { #endif -#include "teamspeak/clientlib_publicdefinitions.h" -#include "teamspeak/public_definitions.h" #include "plugin_definitions.h" +#include "teamspeak/public_definitions.h" /* Functions exported to plugin from main binary */ struct TS3Functions { - unsigned int (*getClientLibVersion)(char** result); - unsigned int (*getClientLibVersionNumber)(uint64* result); - unsigned int (*spawnNewServerConnectionHandler)(int port, uint64* result); - unsigned int (*destroyServerConnectionHandler)(uint64 serverConnectionHandlerID); + unsigned int (*getClientLibVersion)(char** result); + unsigned int (*getClientLibVersionNumber)(uint64* result); + unsigned int (*spawnNewServerConnectionHandler)(int port, uint64* result); + unsigned int (*destroyServerConnectionHandler)(uint64 serverConnectionHandlerID); - /* Error handling */ - unsigned int (*getErrorMessage)(unsigned int errorCode, char** error); + /* Error handling */ + unsigned int (*getErrorMessage)(unsigned int errorCode, char** error); - /* Memory management */ - unsigned int (*freeMemory)(void* pointer); + /* Memory management */ + unsigned int (*freeMemory)(void* pointer); - /* Logging */ - unsigned int (*logMessage)(const char* logMessage, enum LogLevel severity, const char* channel, uint64 logID); + /* Logging */ + unsigned int (*logMessage)(const char* logMessage, enum LogLevel severity, const char* channel, uint64 logID); - /* Sound */ - unsigned int (*getPlaybackDeviceList)(const char* modeID, char**** result); - unsigned int (*getPlaybackModeList)(char*** result); - unsigned int (*getCaptureDeviceList)(const char* modeID, char**** result); - unsigned int (*getCaptureModeList)(char*** result); - unsigned int (*getDefaultPlaybackDevice)(const char* modeID, char*** result); - unsigned int (*getDefaultPlayBackMode)(char** result); - unsigned int (*getDefaultCaptureDevice)(const char* modeID, char*** result); - unsigned int (*getDefaultCaptureMode)(char** result); - unsigned int (*openPlaybackDevice)(uint64 serverConnectionHandlerID, const char* modeID, const char* playbackDevice); - unsigned int (*openCaptureDevice)(uint64 serverConnectionHandlerID, const char* modeID, const char* captureDevice); - unsigned int (*getCurrentPlaybackDeviceName)(uint64 serverConnectionHandlerID, char** result, int* isDefault); - unsigned int (*getCurrentPlayBackMode)(uint64 serverConnectionHandlerID, char** result); - unsigned int (*getCurrentCaptureDeviceName)(uint64 serverConnectionHandlerID, char** result, int* isDefault); - unsigned int (*getCurrentCaptureMode)(uint64 serverConnectionHandlerID, char** result); - unsigned int (*initiateGracefulPlaybackShutdown)(uint64 serverConnectionHandlerID); - unsigned int (*closePlaybackDevice)(uint64 serverConnectionHandlerID); - unsigned int (*closeCaptureDevice)(uint64 serverConnectionHandlerID); - unsigned int (*activateCaptureDevice)(uint64 serverConnectionHandlerID); - unsigned int (*playWaveFileHandle)(uint64 serverConnectionHandlerID, const char* path, int loop, uint64* waveHandle); - unsigned int (*pauseWaveFileHandle)(uint64 serverConnectionHandlerID, uint64 waveHandle, int pause); - unsigned int (*closeWaveFileHandle)(uint64 serverConnectionHandlerID, uint64 waveHandle); - unsigned int (*playWaveFile)(uint64 serverConnectionHandlerID, const char* path); - unsigned int (*registerCustomDevice)(const char* deviceID, const char* deviceDisplayName, int capFrequency, int capChannels, int playFrequency, int playChannels); - unsigned int (*unregisterCustomDevice)(const char* deviceID); - unsigned int (*processCustomCaptureData)(const char* deviceName, const short* buffer, int samples); - unsigned int (*acquireCustomPlaybackData)(const char* deviceName, short* buffer, int samples); + /* Sound */ + unsigned int (*getPlaybackDeviceList)(const char* modeID, char**** result); + unsigned int (*getPlaybackModeList)(char*** result); + unsigned int (*getCaptureDeviceList)(const char* modeID, char**** result); + unsigned int (*getCaptureModeList)(char*** result); + unsigned int (*getDefaultPlaybackDevice)(const char* modeID, char*** result); + unsigned int (*getDefaultPlayBackMode)(char** result); + unsigned int (*getDefaultCaptureDevice)(const char* modeID, char*** result); + unsigned int (*getDefaultCaptureMode)(char** result); + unsigned int (*openPlaybackDevice)(uint64 serverConnectionHandlerID, const char* modeID, const char* playbackDevice); + unsigned int (*openCaptureDevice)(uint64 serverConnectionHandlerID, const char* modeID, const char* captureDevice); + unsigned int (*getCurrentPlaybackDeviceName)(uint64 serverConnectionHandlerID, char** result, int* isDefault); + unsigned int (*getCurrentPlayBackMode)(uint64 serverConnectionHandlerID, char** result); + unsigned int (*getCurrentCaptureDeviceName)(uint64 serverConnectionHandlerID, char** result, int* isDefault); + unsigned int (*getCurrentCaptureMode)(uint64 serverConnectionHandlerID, char** result); + unsigned int (*initiateGracefulPlaybackShutdown)(uint64 serverConnectionHandlerID); + unsigned int (*closePlaybackDevice)(uint64 serverConnectionHandlerID); + unsigned int (*closeCaptureDevice)(uint64 serverConnectionHandlerID); + unsigned int (*activateCaptureDevice)(uint64 serverConnectionHandlerID); + unsigned int (*playWaveFileHandle)(uint64 serverConnectionHandlerID, const char* path, int loop, uint64* waveHandle); + unsigned int (*pauseWaveFileHandle)(uint64 serverConnectionHandlerID, uint64 waveHandle, int pause); + unsigned int (*closeWaveFileHandle)(uint64 serverConnectionHandlerID, uint64 waveHandle); + unsigned int (*playWaveFile)(uint64 serverConnectionHandlerID, const char* path); + unsigned int (*registerCustomDevice)(const char* deviceID, const char* deviceDisplayName, int capFrequency, int capChannels, int playFrequency, int playChannels); + unsigned int (*unregisterCustomDevice)(const char* deviceID); + unsigned int (*processCustomCaptureData)(const char* deviceName, const short* buffer, int samples); + unsigned int (*acquireCustomPlaybackData)(const char* deviceName, short* buffer, int samples); - /* Preprocessor */ - unsigned int (*getPreProcessorInfoValueFloat)(uint64 serverConnectionHandlerID, const char* ident, float* result); - unsigned int (*getPreProcessorConfigValue)(uint64 serverConnectionHandlerID, const char* ident, char** result); - unsigned int (*setPreProcessorConfigValue)(uint64 serverConnectionHandlerID, const char* ident, const char* value); + /* Preprocessor */ + unsigned int (*getPreProcessorInfoValueFloat)(uint64 serverConnectionHandlerID, const char* ident, float* result); + unsigned int (*getPreProcessorConfigValue)(uint64 serverConnectionHandlerID, const char* ident, char** result); + unsigned int (*setPreProcessorConfigValue)(uint64 serverConnectionHandlerID, const char* ident, const char* value); - /* Encoder */ - unsigned int (*getEncodeConfigValue)(uint64 serverConnectionHandlerID, const char* ident, char** result); + /* Encoder */ + unsigned int (*getEncodeConfigValue)(uint64 serverConnectionHandlerID, const char* ident, char** result); - /* Playback */ - unsigned int (*getPlaybackConfigValueAsFloat)(uint64 serverConnectionHandlerID, const char* ident, float* result); - unsigned int (*setPlaybackConfigValue)(uint64 serverConnectionHandlerID, const char* ident, const char* value); - unsigned int (*setClientVolumeModifier)(uint64 serverConnectionHandlerID, anyID clientID, float value); + /* Playback */ + unsigned int (*getPlaybackConfigValueAsFloat)(uint64 serverConnectionHandlerID, const char* ident, float* result); + unsigned int (*setPlaybackConfigValue)(uint64 serverConnectionHandlerID, const char* ident, const char* value); + unsigned int (*setClientVolumeModifier)(uint64 serverConnectionHandlerID, anyID clientID, float value); - /* Recording */ - unsigned int (*startVoiceRecording)(uint64 serverConnectionHandlerID); - unsigned int (*stopVoiceRecording)(uint64 serverConnectionHandlerID); + /* Recording status */ + unsigned int (*startVoiceRecording)(uint64 serverConnectionHandlerID); + unsigned int (*stopVoiceRecording)(uint64 serverConnectionHandlerID); - /* 3d sound positioning */ - unsigned int (*systemset3DListenerAttributes) (uint64 serverConnectionHandlerID, const TS3_VECTOR* position, const TS3_VECTOR* forward, const TS3_VECTOR* up); - unsigned int (*set3DWaveAttributes) (uint64 serverConnectionHandlerID, uint64 waveHandle, const TS3_VECTOR* position); - unsigned int (*systemset3DSettings) (uint64 serverConnectionHandlerID, float distanceFactor, float rolloffScale); - unsigned int (*channelset3DAttributes) (uint64 serverConnectionHandlerID, anyID clientID, const TS3_VECTOR* position); + /* 3d sound positioning */ + unsigned int (*systemset3DListenerAttributes)(uint64 serverConnectionHandlerID, const TS3_VECTOR* position, const TS3_VECTOR* forward, const TS3_VECTOR* up); + unsigned int (*set3DWaveAttributes)(uint64 serverConnectionHandlerID, uint64 waveHandle, const TS3_VECTOR* position); + unsigned int (*systemset3DSettings)(uint64 serverConnectionHandlerID, float distanceFactor, float rolloffScale); + unsigned int (*channelset3DAttributes)(uint64 serverConnectionHandlerID, anyID clientID, const TS3_VECTOR* position); - /* Interaction with the server */ - unsigned int (*startConnection)(uint64 serverConnectionHandlerID, const char* identity, const char* ip, unsigned int port, const char* nickname, - const char** defaultChannelArray, const char* defaultChannelPassword, const char* serverPassword); - unsigned int (*stopConnection)(uint64 serverConnectionHandlerID, const char* quitMessage); - unsigned int (*requestClientMove)(uint64 serverConnectionHandlerID, anyID clientID, uint64 newChannelID, const char* password, const char* returnCode); - unsigned int (*requestClientVariables)(uint64 serverConnectionHandlerID, anyID clientID, const char* returnCode); - unsigned int (*requestClientKickFromChannel)(uint64 serverConnectionHandlerID, anyID clientID, const char* kickReason, const char* returnCode); - unsigned int (*requestClientKickFromServer)(uint64 serverConnectionHandlerID, anyID clientID, const char* kickReason, const char* returnCode); - unsigned int (*requestChannelDelete)(uint64 serverConnectionHandlerID, uint64 channelID, int force, const char* returnCode); - unsigned int (*requestChannelMove)(uint64 serverConnectionHandlerID, uint64 channelID, uint64 newChannelParentID, uint64 newChannelOrder, const char* returnCode); - unsigned int (*requestSendPrivateTextMsg)(uint64 serverConnectionHandlerID, const char* message, anyID targetClientID, const char* returnCode); - unsigned int (*requestSendChannelTextMsg)(uint64 serverConnectionHandlerID, const char* message, uint64 targetChannelID, const char* returnCode); - unsigned int (*requestSendServerTextMsg)(uint64 serverConnectionHandlerID, const char* message, const char* returnCode); - unsigned int (*requestConnectionInfo)(uint64 serverConnectionHandlerID, anyID clientID, const char* returnCode); - unsigned int (*requestClientSetWhisperList)(uint64 serverConnectionHandlerID, anyID clientID, const uint64* targetChannelIDArray, const anyID* targetClientIDArray, const char* returnCode); - unsigned int (*requestChannelSubscribe)(uint64 serverConnectionHandlerID, const uint64* channelIDArray, const char* returnCode); - unsigned int (*requestChannelSubscribeAll)(uint64 serverConnectionHandlerID, const char* returnCode); - unsigned int (*requestChannelUnsubscribe)(uint64 serverConnectionHandlerID, const uint64* channelIDArray, const char* returnCode); - unsigned int (*requestChannelUnsubscribeAll)(uint64 serverConnectionHandlerID, const char* returnCode); - unsigned int (*requestChannelDescription)(uint64 serverConnectionHandlerID, uint64 channelID, const char* returnCode); - unsigned int (*requestMuteClients)(uint64 serverConnectionHandlerID, const anyID* clientIDArray, const char* returnCode); - unsigned int (*requestUnmuteClients)(uint64 serverConnectionHandlerID, const anyID* clientIDArray, const char* returnCode); - unsigned int (*requestClientPoke)(uint64 serverConnectionHandlerID, anyID clientID, const char* message, const char* returnCode); - unsigned int (*requestClientIDs)(uint64 serverConnectionHandlerID, const char* clientUniqueIdentifier, const char* returnCode); - unsigned int (*clientChatClosed)(uint64 serverConnectionHandlerID, const char* clientUniqueIdentifier, anyID clientID, const char* returnCode); - unsigned int (*clientChatComposing)(uint64 serverConnectionHandlerID, anyID clientID, const char* returnCode); - unsigned int (*requestServerTemporaryPasswordAdd)(uint64 serverConnectionHandlerID, const char* password, const char* description, uint64 duration, uint64 targetChannelID, const char* targetChannelPW, const char* returnCode); - unsigned int (*requestServerTemporaryPasswordDel)(uint64 serverConnectionHandlerID, const char* password, const char* returnCode); - unsigned int (*requestServerTemporaryPasswordList)(uint64 serverConnectionHandlerID, const char* returnCode); + /* Interaction with the server */ + unsigned int (*startConnection)(uint64 serverConnectionHandlerID, const char* identity, const char* ip, unsigned int port, const char* nickname, const char** defaultChannelArray, const char* defaultChannelPassword, const char* serverPassword); + unsigned int (*stopConnection)(uint64 serverConnectionHandlerID, const char* quitMessage); + unsigned int (*requestClientMove)(uint64 serverConnectionHandlerID, anyID clientID, uint64 newChannelID, const char* password, const char* returnCode); + unsigned int (*requestClientVariables)(uint64 serverConnectionHandlerID, anyID clientID, const char* returnCode); + unsigned int (*requestClientKickFromChannel)(uint64 serverConnectionHandlerID, anyID clientID, const char* kickReason, const char* returnCode); + unsigned int (*requestClientKickFromServer)(uint64 serverConnectionHandlerID, anyID clientID, const char* kickReason, const char* returnCode); + unsigned int (*requestChannelDelete)(uint64 serverConnectionHandlerID, uint64 channelID, int force, const char* returnCode); + unsigned int (*requestChannelMove)(uint64 serverConnectionHandlerID, uint64 channelID, uint64 newChannelParentID, uint64 newChannelOrder, const char* returnCode); + unsigned int (*requestSendPrivateTextMsg)(uint64 serverConnectionHandlerID, const char* message, anyID targetClientID, const char* returnCode); + unsigned int (*requestSendChannelTextMsg)(uint64 serverConnectionHandlerID, const char* message, uint64 targetChannelID, const char* returnCode); + unsigned int (*requestSendServerTextMsg)(uint64 serverConnectionHandlerID, const char* message, const char* returnCode); + unsigned int (*requestConnectionInfo)(uint64 serverConnectionHandlerID, anyID clientID, const char* returnCode); + unsigned int (*requestClientSetWhisperList)(uint64 serverConnectionHandlerID, anyID clientID, const uint64* targetChannelIDArray, const anyID* targetClientIDArray, const char* returnCode); + unsigned int (*requestChannelSubscribe)(uint64 serverConnectionHandlerID, const uint64* channelIDArray, const char* returnCode); + unsigned int (*requestChannelSubscribeAll)(uint64 serverConnectionHandlerID, const char* returnCode); + unsigned int (*requestChannelUnsubscribe)(uint64 serverConnectionHandlerID, const uint64* channelIDArray, const char* returnCode); + unsigned int (*requestChannelUnsubscribeAll)(uint64 serverConnectionHandlerID, const char* returnCode); + unsigned int (*requestChannelDescription)(uint64 serverConnectionHandlerID, uint64 channelID, const char* returnCode); + unsigned int (*requestMuteClients)(uint64 serverConnectionHandlerID, const anyID* clientIDArray, const char* returnCode); + unsigned int (*requestUnmuteClients)(uint64 serverConnectionHandlerID, const anyID* clientIDArray, const char* returnCode); + unsigned int (*requestClientPoke)(uint64 serverConnectionHandlerID, anyID clientID, const char* message, const char* returnCode); + unsigned int (*requestClientIDs)(uint64 serverConnectionHandlerID, const char* clientUniqueIdentifier, const char* returnCode); + unsigned int (*clientChatClosed)(uint64 serverConnectionHandlerID, const char* clientUniqueIdentifier, anyID clientID, const char* returnCode); + unsigned int (*clientChatComposing)(uint64 serverConnectionHandlerID, anyID clientID, const char* returnCode); + unsigned int (*requestServerTemporaryPasswordAdd)(uint64 serverConnectionHandlerID, const char* password, const char* description, uint64 duration, uint64 targetChannelID, const char* targetChannelPW, const char* returnCode); + unsigned int (*requestServerTemporaryPasswordDel)(uint64 serverConnectionHandlerID, const char* password, const char* returnCode); + unsigned int (*requestServerTemporaryPasswordList)(uint64 serverConnectionHandlerID, const char* returnCode); - /* Access clientlib information */ + /* Access clientlib information */ - /* Query own client ID */ - unsigned int (*getClientID)(uint64 serverConnectionHandlerID, anyID* result); + /* Query own client ID */ + unsigned int (*getClientID)(uint64 serverConnectionHandlerID, anyID* result); - /* Client info */ - unsigned int (*getClientSelfVariableAsInt)(uint64 serverConnectionHandlerID, size_t flag, int* result); - unsigned int (*getClientSelfVariableAsString)(uint64 serverConnectionHandlerID, size_t flag, char** result); - unsigned int (*setClientSelfVariableAsInt)(uint64 serverConnectionHandlerID, size_t flag, int value); - unsigned int (*setClientSelfVariableAsString)(uint64 serverConnectionHandlerID, size_t flag, const char* value); - unsigned int (*flushClientSelfUpdates)(uint64 serverConnectionHandlerID, const char* returnCode); - unsigned int (*getClientVariableAsInt)(uint64 serverConnectionHandlerID, anyID clientID, size_t flag, int* result); - unsigned int (*getClientVariableAsUInt64)(uint64 serverConnectionHandlerID, anyID clientID, size_t flag, uint64* result); - unsigned int (*getClientVariableAsString)(uint64 serverConnectionHandlerID, anyID clientID, size_t flag, char** result); - unsigned int (*getClientList)(uint64 serverConnectionHandlerID, anyID** result); - unsigned int (*getChannelOfClient)(uint64 serverConnectionHandlerID, anyID clientID, uint64* result); + /* Client info */ + unsigned int (*getClientSelfVariableAsInt)(uint64 serverConnectionHandlerID, size_t flag, int* result); + unsigned int (*getClientSelfVariableAsString)(uint64 serverConnectionHandlerID, size_t flag, char** result); + unsigned int (*setClientSelfVariableAsInt)(uint64 serverConnectionHandlerID, size_t flag, int value); + unsigned int (*setClientSelfVariableAsString)(uint64 serverConnectionHandlerID, size_t flag, const char* value); + unsigned int (*flushClientSelfUpdates)(uint64 serverConnectionHandlerID, const char* returnCode); + unsigned int (*getClientVariableAsInt)(uint64 serverConnectionHandlerID, anyID clientID, size_t flag, int* result); + unsigned int (*getClientVariableAsUInt64)(uint64 serverConnectionHandlerID, anyID clientID, size_t flag, uint64* result); + unsigned int (*getClientVariableAsString)(uint64 serverConnectionHandlerID, anyID clientID, size_t flag, char** result); + unsigned int (*getClientList)(uint64 serverConnectionHandlerID, anyID** result); + unsigned int (*getChannelOfClient)(uint64 serverConnectionHandlerID, anyID clientID, uint64* result); - /* Channel info */ - unsigned int (*getChannelVariableAsInt)(uint64 serverConnectionHandlerID, uint64 channelID, size_t flag, int* result); - unsigned int (*getChannelVariableAsUInt64)(uint64 serverConnectionHandlerID, uint64 channelID, size_t flag, uint64* result); - unsigned int (*getChannelVariableAsString)(uint64 serverConnectionHandlerID, uint64 channelID, size_t flag, char** result); - unsigned int (*getChannelIDFromChannelNames)(uint64 serverConnectionHandlerID, char** channelNameArray, uint64* result); - unsigned int (*setChannelVariableAsInt)(uint64 serverConnectionHandlerID, uint64 channelID, size_t flag, int value); - unsigned int (*setChannelVariableAsUInt64)(uint64 serverConnectionHandlerID, uint64 channelID, size_t flag, uint64 value); - unsigned int (*setChannelVariableAsString)(uint64 serverConnectionHandlerID, uint64 channelID, size_t flag, const char* value); - unsigned int (*flushChannelUpdates)(uint64 serverConnectionHandlerID, uint64 channelID, const char* returnCode); - unsigned int (*flushChannelCreation)(uint64 serverConnectionHandlerID, uint64 channelParentID, const char* returnCode); - unsigned int (*getChannelList)(uint64 serverConnectionHandlerID, uint64** result); - unsigned int (*getChannelClientList)(uint64 serverConnectionHandlerID, uint64 channelID, anyID** result); - unsigned int (*getParentChannelOfChannel)(uint64 serverConnectionHandlerID, uint64 channelID, uint64* result); + /* Channel info */ + unsigned int (*getChannelVariableAsInt)(uint64 serverConnectionHandlerID, uint64 channelID, size_t flag, int* result); + unsigned int (*getChannelVariableAsUInt64)(uint64 serverConnectionHandlerID, uint64 channelID, size_t flag, uint64* result); + unsigned int (*getChannelVariableAsString)(uint64 serverConnectionHandlerID, uint64 channelID, size_t flag, char** result); + unsigned int (*getChannelIDFromChannelNames)(uint64 serverConnectionHandlerID, char** channelNameArray, uint64* result); + unsigned int (*setChannelVariableAsInt)(uint64 serverConnectionHandlerID, uint64 channelID, size_t flag, int value); + unsigned int (*setChannelVariableAsUInt64)(uint64 serverConnectionHandlerID, uint64 channelID, size_t flag, uint64 value); + unsigned int (*setChannelVariableAsString)(uint64 serverConnectionHandlerID, uint64 channelID, size_t flag, const char* value); + unsigned int (*flushChannelUpdates)(uint64 serverConnectionHandlerID, uint64 channelID, const char* returnCode); + unsigned int (*flushChannelCreation)(uint64 serverConnectionHandlerID, uint64 channelParentID, const char* returnCode); + unsigned int (*getChannelList)(uint64 serverConnectionHandlerID, uint64** result); + unsigned int (*getChannelClientList)(uint64 serverConnectionHandlerID, uint64 channelID, anyID** result); + unsigned int (*getParentChannelOfChannel)(uint64 serverConnectionHandlerID, uint64 channelID, uint64* result); - /* Server info */ - unsigned int (*getServerConnectionHandlerList)(uint64** result); - unsigned int (*getServerVariableAsInt)(uint64 serverConnectionHandlerID, size_t flag, int* result); - unsigned int (*getServerVariableAsUInt64)(uint64 serverConnectionHandlerID, size_t flag, uint64* result); - unsigned int (*getServerVariableAsString)(uint64 serverConnectionHandlerID, size_t flag, char** result); - unsigned int (*requestServerVariables)(uint64 serverConnectionHandlerID); + /* Server info */ + unsigned int (*getServerConnectionHandlerList)(uint64** result); + unsigned int (*getServerVariableAsInt)(uint64 serverConnectionHandlerID, size_t flag, int* result); + unsigned int (*getServerVariableAsUInt64)(uint64 serverConnectionHandlerID, size_t flag, uint64* result); + unsigned int (*getServerVariableAsString)(uint64 serverConnectionHandlerID, size_t flag, char** result); + unsigned int (*requestServerVariables)(uint64 serverConnectionHandlerID); - /* Connection info */ - unsigned int (*getConnectionStatus)(uint64 serverConnectionHandlerID, int* result); - unsigned int (*getConnectionVariableAsUInt64)(uint64 serverConnectionHandlerID, anyID clientID, size_t flag, uint64* result); - unsigned int (*getConnectionVariableAsDouble)(uint64 serverConnectionHandlerID, anyID clientID, size_t flag, double* result); - unsigned int (*getConnectionVariableAsString)(uint64 serverConnectionHandlerID, anyID clientID, size_t flag, char** result); - unsigned int (*cleanUpConnectionInfo)(uint64 serverConnectionHandlerID, anyID clientID); + /* Connection info */ + unsigned int (*getConnectionStatus)(uint64 serverConnectionHandlerID, int* result); + unsigned int (*getConnectionVariableAsUInt64)(uint64 serverConnectionHandlerID, anyID clientID, size_t flag, uint64* result); + unsigned int (*getConnectionVariableAsDouble)(uint64 serverConnectionHandlerID, anyID clientID, size_t flag, double* result); + unsigned int (*getConnectionVariableAsString)(uint64 serverConnectionHandlerID, anyID clientID, size_t flag, char** result); + unsigned int (*cleanUpConnectionInfo)(uint64 serverConnectionHandlerID, anyID clientID); - /* Client related */ - unsigned int (*requestClientDBIDfromUID)(uint64 serverConnectionHandlerID, const char* clientUniqueIdentifier, const char* returnCode); - unsigned int (*requestClientNamefromUID)(uint64 serverConnectionHandlerID, const char* clientUniqueIdentifier, const char* returnCode); - unsigned int (*requestClientNamefromDBID)(uint64 serverConnectionHandlerID, uint64 clientDatabaseID, const char* returnCode); - unsigned int (*requestClientEditDescription)(uint64 serverConnectionHandlerID, anyID clientID, const char* clientDescription, const char* returnCode); - unsigned int (*requestClientSetIsTalker)(uint64 serverConnectionHandlerID, anyID clientID, int isTalker, const char* returnCode); - unsigned int (*requestIsTalker)(uint64 serverConnectionHandlerID, int isTalkerRequest, const char* isTalkerRequestMessage, const char* returnCode); + /* Client related */ + unsigned int (*requestClientDBIDfromUID)(uint64 serverConnectionHandlerID, const char* clientUniqueIdentifier, const char* returnCode); + unsigned int (*requestClientNamefromUID)(uint64 serverConnectionHandlerID, const char* clientUniqueIdentifier, const char* returnCode); + unsigned int (*requestClientNamefromDBID)(uint64 serverConnectionHandlerID, uint64 clientDatabaseID, const char* returnCode); + unsigned int (*requestClientEditDescription)(uint64 serverConnectionHandlerID, anyID clientID, const char* clientDescription, const char* returnCode); + unsigned int (*requestClientSetIsTalker)(uint64 serverConnectionHandlerID, anyID clientID, int isTalker, const char* returnCode); + unsigned int (*requestIsTalker)(uint64 serverConnectionHandlerID, int isTalkerRequest, const char* isTalkerRequestMessage, const char* returnCode); - /* Plugin related */ - unsigned int (*requestSendClientQueryCommand)(uint64 serverConnectionHandlerID, const char* command, const char* returnCode); + /* Plugin related */ + unsigned int (*requestSendClientQueryCommand)(uint64 serverConnectionHandlerID, const char* command, const char* returnCode); - /* Filetransfer */ - unsigned int (*getTransferFileName)(anyID transferID, char** result); - unsigned int (*getTransferFilePath)(anyID transferID, char** result); - unsigned int (*getTransferFileSize)(anyID transferID, uint64* result); - unsigned int (*getTransferFileSizeDone)(anyID transferID, uint64* result); - unsigned int (*isTransferSender)(anyID transferID, int* result); /* 1 == upload, 0 == download */ - unsigned int (*getTransferStatus)(anyID transferID, int* result); - unsigned int (*getCurrentTransferSpeed)(anyID transferID, float* result); - unsigned int (*getAverageTransferSpeed)(anyID transferID, float* result); - unsigned int (*getTransferRunTime)(anyID transferID, uint64* result); - unsigned int (*sendFile)(uint64 serverConnectionHandlerID, uint64 channelID, const char* channelPW, const char* file, int overwrite, int resume, const char* sourceDirectory, anyID* result, const char* returnCode); - unsigned int (*requestFile)(uint64 serverConnectionHandlerID, uint64 channelID, const char* channelPW, const char* file, int overwrite, int resume, const char* destinationDirectory, anyID* result, const char* returnCode); - unsigned int (*haltTransfer)(uint64 serverConnectionHandlerID, anyID transferID, int deleteUnfinishedFile, const char* returnCode); - unsigned int (*requestFileList)(uint64 serverConnectionHandlerID, uint64 channelID, const char* channelPW, const char* path, const char* returnCode); - unsigned int (*requestFileInfo)(uint64 serverConnectionHandlerID, uint64 channelID, const char* channelPW, const char* file, const char* returnCode); - unsigned int (*requestDeleteFile)(uint64 serverConnectionHandlerID, uint64 channelID, const char* channelPW, const char** file, const char* returnCode); - unsigned int (*requestCreateDirectory)(uint64 serverConnectionHandlerID, uint64 channelID, const char* channelPW, const char* directoryPath, const char* returnCode); - unsigned int (*requestRenameFile)(uint64 serverConnectionHandlerID, uint64 fromChannelID, const char* channelPW, uint64 toChannelID, const char* toChannelPW, const char* oldFile, const char* newFile, const char* returnCode); + /* Filetransfer */ + unsigned int (*getTransferFileName)(anyID transferID, char** result); + unsigned int (*getTransferFilePath)(anyID transferID, char** result); + unsigned int (*getTransferFileSize)(anyID transferID, uint64* result); + unsigned int (*getTransferFileSizeDone)(anyID transferID, uint64* result); + unsigned int (*isTransferSender)(anyID transferID, int* result); /* 1 == upload, 0 == download */ + unsigned int (*getTransferStatus)(anyID transferID, int* result); + unsigned int (*getCurrentTransferSpeed)(anyID transferID, float* result); + unsigned int (*getAverageTransferSpeed)(anyID transferID, float* result); + unsigned int (*getTransferRunTime)(anyID transferID, uint64* result); + unsigned int (*sendFile)(uint64 serverConnectionHandlerID, uint64 channelID, const char* channelPW, const char* file, int overwrite, int resume, const char* sourceDirectory, anyID* result, const char* returnCode); + unsigned int (*requestFile)(uint64 serverConnectionHandlerID, uint64 channelID, const char* channelPW, const char* file, int overwrite, int resume, const char* destinationDirectory, anyID* result, const char* returnCode); + unsigned int (*haltTransfer)(uint64 serverConnectionHandlerID, anyID transferID, int deleteUnfinishedFile, const char* returnCode); + unsigned int (*requestFileList)(uint64 serverConnectionHandlerID, uint64 channelID, const char* channelPW, const char* path, const char* returnCode); + unsigned int (*requestFileInfo)(uint64 serverConnectionHandlerID, uint64 channelID, const char* channelPW, const char* file, const char* returnCode); + unsigned int (*requestDeleteFile)(uint64 serverConnectionHandlerID, uint64 channelID, const char* channelPW, const char** file, const char* returnCode); + unsigned int (*requestCreateDirectory)(uint64 serverConnectionHandlerID, uint64 channelID, const char* channelPW, const char* directoryPath, const char* returnCode); + unsigned int (*requestRenameFile)(uint64 serverConnectionHandlerID, uint64 fromChannelID, const char* channelPW, uint64 toChannelID, const char* toChannelPW, const char* oldFile, const char* newFile, const char* returnCode); - /* Offline message management */ - unsigned int (*requestMessageAdd)(uint64 serverConnectionHandlerID, const char* toClientUID, const char* subject, const char* message, const char* returnCode); - unsigned int (*requestMessageDel)(uint64 serverConnectionHandlerID, uint64 messageID, const char* returnCode); - unsigned int (*requestMessageGet)(uint64 serverConnectionHandlerID, uint64 messageID, const char* returnCode); - unsigned int (*requestMessageList)(uint64 serverConnectionHandlerID, const char* returnCode); - unsigned int (*requestMessageUpdateFlag)(uint64 serverConnectionHandlerID, uint64 messageID, int flag, const char* returnCode); + /* Offline message management */ + unsigned int (*requestMessageAdd)(uint64 serverConnectionHandlerID, const char* toClientUID, const char* subject, const char* message, const char* returnCode); + unsigned int (*requestMessageDel)(uint64 serverConnectionHandlerID, uint64 messageID, const char* returnCode); + unsigned int (*requestMessageGet)(uint64 serverConnectionHandlerID, uint64 messageID, const char* returnCode); + unsigned int (*requestMessageList)(uint64 serverConnectionHandlerID, const char* returnCode); + unsigned int (*requestMessageUpdateFlag)(uint64 serverConnectionHandlerID, uint64 messageID, int flag, const char* returnCode); - /* Interacting with the server - confirming passwords */ - unsigned int (*verifyServerPassword)(uint64 serverConnectionHandlerID, const char* serverPassword, const char* returnCode); - unsigned int (*verifyChannelPassword)(uint64 serverConnectionHandlerID, uint64 channelID, const char* channelPassword, const char* returnCode); + /* Interacting with the server - confirming passwords */ + unsigned int (*verifyServerPassword)(uint64 serverConnectionHandlerID, const char* serverPassword, const char* returnCode); + unsigned int (*verifyChannelPassword)(uint64 serverConnectionHandlerID, uint64 channelID, const char* channelPassword, const char* returnCode); - /* Interacting with the server - banning */ - unsigned int (*banclient)(uint64 serverConnectionHandlerID, anyID clientID, uint64 timeInSeconds, const char* banReason, const char* returnCode); - unsigned int (*banadd)(uint64 serverConnectionHandlerID, const char* ipRegExp, const char* nameRegexp, const char* uniqueIdentity, const char* mytsID, uint64 timeInSeconds, const char* banReason, const char* returnCode); - unsigned int (*banclientdbid)(uint64 serverConnectionHandlerID, uint64 clientDBID, uint64 timeInSeconds, const char* banReason, const char* returnCode); - unsigned int (*bandel)(uint64 serverConnectionHandlerID, uint64 banID, const char* returnCode); - unsigned int (*bandelall)(uint64 serverConnectionHandlerID, const char* returnCode); - unsigned int (*requestBanList)(uint64 serverConnectionHandlerID, uint64 start, unsigned int duration, const char* returnCode); + /* Interacting with the server - banning */ + unsigned int (*banclient)(uint64 serverConnectionHandlerID, anyID clientID, uint64 timeInSeconds, const char* banReason, const char* returnCode); + unsigned int (*banadd)(uint64 serverConnectionHandlerID, const char* ipRegExp, const char* nameRegexp, const char* uniqueIdentity, const char* mytsID, uint64 timeInSeconds, const char* banReason, const char* returnCode); + unsigned int (*banclientdbid)(uint64 serverConnectionHandlerID, uint64 clientDBID, uint64 timeInSeconds, const char* banReason, const char* returnCode); + unsigned int (*bandel)(uint64 serverConnectionHandlerID, uint64 banID, const char* returnCode); + unsigned int (*bandelall)(uint64 serverConnectionHandlerID, const char* returnCode); + unsigned int (*requestBanList)(uint64 serverConnectionHandlerID, uint64 start, unsigned int duration, const char* returnCode); - /* Interacting with the server - complain */ - unsigned int (*requestComplainAdd)(uint64 serverConnectionHandlerID, uint64 targetClientDatabaseID, const char* complainReason, const char* returnCode); - unsigned int (*requestComplainDel)(uint64 serverConnectionHandlerID, uint64 targetClientDatabaseID, uint64 fromClientDatabaseID, const char* returnCode); - unsigned int (*requestComplainDelAll)(uint64 serverConnectionHandlerID, uint64 targetClientDatabaseID, const char* returnCode); - unsigned int (*requestComplainList)(uint64 serverConnectionHandlerID, uint64 targetClientDatabaseID, const char* returnCode); + /* Interacting with the server - complain */ + unsigned int (*requestComplainAdd)(uint64 serverConnectionHandlerID, uint64 targetClientDatabaseID, const char* complainReason, const char* returnCode); + unsigned int (*requestComplainDel)(uint64 serverConnectionHandlerID, uint64 targetClientDatabaseID, uint64 fromClientDatabaseID, const char* returnCode); + unsigned int (*requestComplainDelAll)(uint64 serverConnectionHandlerID, uint64 targetClientDatabaseID, const char* returnCode); + unsigned int (*requestComplainList)(uint64 serverConnectionHandlerID, uint64 targetClientDatabaseID, const char* returnCode); - /* Permissions */ - unsigned int (*requestServerGroupList)(uint64 serverConnectionHandlerID, const char* returnCode); - unsigned int (*requestServerGroupAdd)(uint64 serverConnectionHandlerID, const char* groupName, int groupType, const char* returnCode); - unsigned int (*requestServerGroupDel)(uint64 serverConnectionHandlerID, uint64 serverGroupID, int force, const char* returnCode); - unsigned int (*requestServerGroupAddClient)(uint64 serverConnectionHandlerID, uint64 serverGroupID, uint64 clientDatabaseID, const char* returnCode); - unsigned int (*requestServerGroupDelClient)(uint64 serverConnectionHandlerID, uint64 serverGroupID, uint64 clientDatabaseID, const char* returnCode); - unsigned int (*requestServerGroupsByClientID)(uint64 serverConnectionHandlerID, uint64 clientDatabaseID, const char* returnCode); - unsigned int (*requestServerGroupAddPerm)(uint64 serverConnectionHandlerID, uint64 serverGroupID, int continueonerror, const unsigned int* permissionIDArray, const int* permissionValueArray, const int* permissionNegatedArray, const int* permissionSkipArray, int arraySize, const char* returnCode); - unsigned int (*requestServerGroupDelPerm)(uint64 serverConnectionHandlerID, uint64 serverGroupID, int continueOnError, const unsigned int* permissionIDArray, int arraySize, const char* returnCode); - unsigned int (*requestServerGroupPermList)(uint64 serverConnectionHandlerID, uint64 serverGroupID, const char* returnCode); - unsigned int (*requestServerGroupClientList)(uint64 serverConnectionHandlerID, uint64 serverGroupID, int withNames, const char* returnCode); - unsigned int (*requestChannelGroupList)(uint64 serverConnectionHandlerID, const char* returnCode); - unsigned int (*requestChannelGroupAdd)(uint64 serverConnectionHandlerID, const char* groupName, int groupType, const char* returnCode); - unsigned int (*requestChannelGroupDel)(uint64 serverConnectionHandlerID, uint64 channelGroupID, int force, const char* returnCode); - unsigned int (*requestChannelGroupAddPerm)(uint64 serverConnectionHandlerID, uint64 channelGroupID, int continueonerror, const unsigned int* permissionIDArray, const int* permissionValueArray, int arraySize, const char* returnCode); - unsigned int (*requestChannelGroupDelPerm)(uint64 serverConnectionHandlerID, uint64 channelGroupID, int continueOnError, const unsigned int* permissionIDArray, int arraySize, const char* returnCode); - unsigned int (*requestChannelGroupPermList)(uint64 serverConnectionHandlerID, uint64 channelGroupID, const char* returnCode); - unsigned int (*requestSetClientChannelGroup)(uint64 serverConnectionHandlerID, const uint64* channelGroupIDArray, const uint64* channelIDArray, const uint64* clientDatabaseIDArray, int arraySize, const char* returnCode); - unsigned int (*requestChannelAddPerm)(uint64 serverConnectionHandlerID, uint64 channelID, const unsigned int* permissionIDArray, const int* permissionValueArray, int arraySize, const char* returnCode); - unsigned int (*requestChannelDelPerm)(uint64 serverConnectionHandlerID, uint64 channelID, const unsigned int* permissionIDArray, int arraySize, const char* returnCode); - unsigned int (*requestChannelPermList)(uint64 serverConnectionHandlerID, uint64 channelID, const char* returnCode); - unsigned int (*requestClientAddPerm)(uint64 serverConnectionHandlerID, uint64 clientDatabaseID, const unsigned int* permissionIDArray, const int* permissionValueArray, const int* permissionSkipArray, int arraySize, const char* returnCode); - unsigned int (*requestClientDelPerm)(uint64 serverConnectionHandlerID, uint64 clientDatabaseID, const unsigned int* permissionIDArray, int arraySize, const char* returnCode); - unsigned int (*requestClientPermList)(uint64 serverConnectionHandlerID, uint64 clientDatabaseID, const char* returnCode); - unsigned int (*requestChannelClientAddPerm)(uint64 serverConnectionHandlerID, uint64 channelID, uint64 clientDatabaseID, const unsigned int* permissionIDArray, const int* permissionValueArray, int arraySize, const char* returnCode); - unsigned int (*requestChannelClientDelPerm)(uint64 serverConnectionHandlerID, uint64 channelID, uint64 clientDatabaseID, const unsigned int* permissionIDArray, int arraySize, const char* returnCode); - unsigned int (*requestChannelClientPermList)(uint64 serverConnectionHandlerID, uint64 channelID, uint64 clientDatabaseID, const char* returnCode); - unsigned int (*privilegeKeyUse)(uint64 serverConnectionHandler, const char* tokenKey, const char* returnCode); - unsigned int (*requestPermissionList)(uint64 serverConnectionHandler, const char* returnCode); - unsigned int (*requestPermissionOverview)(uint64 serverConnectionHandler, uint64 clientDBID, uint64 channelID, const char* returnCode); + /* Permissions */ + unsigned int (*requestServerGroupList)(uint64 serverConnectionHandlerID, const char* returnCode); + unsigned int (*requestServerGroupAdd)(uint64 serverConnectionHandlerID, const char* groupName, int groupType, const char* returnCode); + unsigned int (*requestServerGroupDel)(uint64 serverConnectionHandlerID, uint64 serverGroupID, int force, const char* returnCode); + unsigned int (*requestServerGroupAddClient)(uint64 serverConnectionHandlerID, uint64 serverGroupID, uint64 clientDatabaseID, const char* returnCode); + unsigned int (*requestServerGroupDelClient)(uint64 serverConnectionHandlerID, uint64 serverGroupID, uint64 clientDatabaseID, const char* returnCode); + unsigned int (*requestServerGroupsByClientID)(uint64 serverConnectionHandlerID, uint64 clientDatabaseID, const char* returnCode); + unsigned int (*requestServerGroupAddPerm)(uint64 serverConnectionHandlerID, uint64 serverGroupID, int continueonerror, const unsigned int* permissionIDArray, const int* permissionValueArray, const int* permissionNegatedArray, + const int* permissionSkipArray, int arraySize, const char* returnCode); + unsigned int (*requestServerGroupDelPerm)(uint64 serverConnectionHandlerID, uint64 serverGroupID, int continueOnError, const unsigned int* permissionIDArray, int arraySize, const char* returnCode); + unsigned int (*requestServerGroupPermList)(uint64 serverConnectionHandlerID, uint64 serverGroupID, const char* returnCode); + unsigned int (*requestServerGroupClientList)(uint64 serverConnectionHandlerID, uint64 serverGroupID, int withNames, const char* returnCode); + unsigned int (*requestChannelGroupList)(uint64 serverConnectionHandlerID, const char* returnCode); + unsigned int (*requestChannelGroupAdd)(uint64 serverConnectionHandlerID, const char* groupName, int groupType, const char* returnCode); + unsigned int (*requestChannelGroupDel)(uint64 serverConnectionHandlerID, uint64 channelGroupID, int force, const char* returnCode); + unsigned int (*requestChannelGroupAddPerm)(uint64 serverConnectionHandlerID, uint64 channelGroupID, int continueonerror, const unsigned int* permissionIDArray, const int* permissionValueArray, int arraySize, const char* returnCode); + unsigned int (*requestChannelGroupDelPerm)(uint64 serverConnectionHandlerID, uint64 channelGroupID, int continueOnError, const unsigned int* permissionIDArray, int arraySize, const char* returnCode); + unsigned int (*requestChannelGroupPermList)(uint64 serverConnectionHandlerID, uint64 channelGroupID, const char* returnCode); + unsigned int (*requestSetClientChannelGroup)(uint64 serverConnectionHandlerID, const uint64* channelGroupIDArray, const uint64* channelIDArray, const uint64* clientDatabaseIDArray, int arraySize, const char* returnCode); + unsigned int (*requestChannelAddPerm)(uint64 serverConnectionHandlerID, uint64 channelID, const unsigned int* permissionIDArray, const int* permissionValueArray, int arraySize, const char* returnCode); + unsigned int (*requestChannelDelPerm)(uint64 serverConnectionHandlerID, uint64 channelID, const unsigned int* permissionIDArray, int arraySize, const char* returnCode); + unsigned int (*requestChannelPermList)(uint64 serverConnectionHandlerID, uint64 channelID, const char* returnCode); + unsigned int (*requestClientAddPerm)(uint64 serverConnectionHandlerID, uint64 clientDatabaseID, const unsigned int* permissionIDArray, const int* permissionValueArray, const int* permissionSkipArray, int arraySize, const char* returnCode); + unsigned int (*requestClientDelPerm)(uint64 serverConnectionHandlerID, uint64 clientDatabaseID, const unsigned int* permissionIDArray, int arraySize, const char* returnCode); + unsigned int (*requestClientPermList)(uint64 serverConnectionHandlerID, uint64 clientDatabaseID, const char* returnCode); + unsigned int (*requestChannelClientAddPerm)(uint64 serverConnectionHandlerID, uint64 channelID, uint64 clientDatabaseID, const unsigned int* permissionIDArray, const int* permissionValueArray, int arraySize, const char* returnCode); + unsigned int (*requestChannelClientDelPerm)(uint64 serverConnectionHandlerID, uint64 channelID, uint64 clientDatabaseID, const unsigned int* permissionIDArray, int arraySize, const char* returnCode); + unsigned int (*requestChannelClientPermList)(uint64 serverConnectionHandlerID, uint64 channelID, uint64 clientDatabaseID, const char* returnCode); + unsigned int (*privilegeKeyUse)(uint64 serverConnectionHandler, const char* tokenKey, const char* returnCode); + unsigned int (*requestPermissionList)(uint64 serverConnectionHandler, const char* returnCode); + unsigned int (*requestPermissionOverview)(uint64 serverConnectionHandler, uint64 clientDBID, uint64 channelID, const char* returnCode); - /* Helper Functions */ - unsigned int (*clientPropertyStringToFlag)(const char* clientPropertyString, size_t* resultFlag); - unsigned int (*channelPropertyStringToFlag)(const char* channelPropertyString, size_t* resultFlag); - unsigned int (*serverPropertyStringToFlag)(const char* serverPropertyString, size_t* resultFlag); + /* Helper Functions */ + unsigned int (*clientPropertyStringToFlag)(const char* clientPropertyString, size_t* resultFlag); + unsigned int (*channelPropertyStringToFlag)(const char* channelPropertyString, size_t* resultFlag); + unsigned int (*serverPropertyStringToFlag)(const char* serverPropertyString, size_t* resultFlag); - /* Client functions */ - void (*getAppPath)(char* path, size_t maxLen); - void (*getResourcesPath)(char* path, size_t maxLen); - void (*getConfigPath)(char* path, size_t maxLen); - void (*getPluginPath)(char* path, size_t maxLen, const char* pluginID); - uint64 (*getCurrentServerConnectionHandlerID)(); - void (*printMessage)(uint64 serverConnectionHandlerID, const char* message, enum PluginMessageTarget messageTarget); - void (*printMessageToCurrentTab)(const char* message); - void (*urlsToBB)(const char* text, char* result, size_t maxLen); - void (*sendPluginCommand)(uint64 serverConnectionHandlerID, const char* pluginID, const char* command, int targetMode, const anyID* targetIDs, const char* returnCode); - void (*getDirectories)(const char* path, char* result, size_t maxLen); - unsigned int (*getServerConnectInfo)(uint64 scHandlerID, char* host, unsigned short* port, char* password, size_t maxLen); - unsigned int (*getChannelConnectInfo)(uint64 scHandlerID, uint64 channelID, char* path, char* password, size_t maxLen); - void (*createReturnCode)(const char* pluginID, char* returnCode, size_t maxLen); - unsigned int (*requestInfoUpdate)(uint64 scHandlerID, enum PluginItemType itemType, uint64 itemID); - uint64 (*getServerVersion)(uint64 scHandlerID); - unsigned int (*isWhispering)(uint64 scHandlerID, anyID clientID, int* result); - unsigned int (*isReceivingWhisper)(uint64 scHandlerID, anyID clientID, int* result); - unsigned int (*getAvatar)(uint64 scHandlerID, anyID clientID, char* result, size_t maxLen); - void (*setPluginMenuEnabled)(const char* pluginID, int menuID, int enabled); - void (*showHotkeySetup)(); - void (*requestHotkeyInputDialog)(const char* pluginID, const char* keyword, int isDown, void* qParentWindow); - unsigned int (*getHotkeyFromKeyword)(const char* pluginID, const char** keywords, char** hotkeys, size_t arrayLen, size_t hotkeyBufSize); - unsigned int (*getClientDisplayName)(uint64 scHandlerID, anyID clientID, char* result, size_t maxLen); - unsigned int (*getBookmarkList)(struct PluginBookmarkList** list); - unsigned int (*getProfileList)(enum PluginGuiProfile profile, int* defaultProfileIdx, char*** result); - unsigned int (*guiConnect)(enum PluginConnectTab connectTab, const char* serverLabel, const char* serverAddress, const char* serverPassword, const char* nickname, const char* channel, const char* channelPassword, const char* captureProfile, const char* playbackProfile, const char* hotkeyProfile, const char* soundProfile, const char* userIdentity, const char* oneTimeKey, const char* phoneticName, uint64* scHandlerID); - unsigned int (*guiConnectBookmark)(enum PluginConnectTab connectTab, const char* bookmarkuuid, uint64* scHandlerID); - unsigned int (*createBookmark)(const char* bookmarkuuid, const char* serverLabel, const char* serverAddress, const char* serverPassword, const char* nickname, const char* channel, const char* channelPassword, const char* captureProfile, const char* playbackProfile, const char* hotkeyProfile, const char* soundProfile, const char* uniqueUserId, const char* oneTimeKey, const char* phoneticName); - unsigned int (*getPermissionIDByName)(uint64 serverConnectionHandlerID, const char* permissionName, unsigned int* result); - unsigned int (*getClientNeededPermission)(uint64 serverConnectionHandlerID, const char* permissionName, int* result); - void(*notifyKeyEvent)(const char *pluginID, const char *keyIdentifier, int up_down); + /* Client functions */ + void (*getAppPath)(char* path, size_t maxLen); + void (*getResourcesPath)(char* path, size_t maxLen); + void (*getConfigPath)(char* path, size_t maxLen); + void (*getPluginPath)(char* path, size_t maxLen, const char* pluginID); + uint64 (*getCurrentServerConnectionHandlerID)(void); + void (*printMessage)(uint64 serverConnectionHandlerID, const char* message, enum PluginMessageTarget messageTarget); + void (*printMessageToCurrentTab)(const char* message); + void (*urlsToBB)(const char* text, char* result, size_t maxLen); + void (*sendPluginCommand)(uint64 serverConnectionHandlerID, const char* pluginID, const char* command, int targetMode, const anyID* targetIDs, const char* returnCode); + void (*getDirectories)(const char* path, char* result, size_t maxLen); + unsigned int (*getServerConnectInfo)(uint64 scHandlerID, char* host, unsigned short* port, char* password, size_t maxLen); + unsigned int (*getChannelConnectInfo)(uint64 scHandlerID, uint64 channelID, char* path, char* password, size_t maxLen); + void (*createReturnCode)(const char* pluginID, char* returnCode, size_t maxLen); + unsigned int (*requestInfoUpdate)(uint64 scHandlerID, enum PluginItemType itemType, uint64 itemID); + uint64 (*getServerVersion)(uint64 scHandlerID); + unsigned int (*isWhispering)(uint64 scHandlerID, anyID clientID, int* result); + unsigned int (*isReceivingWhisper)(uint64 scHandlerID, anyID clientID, int* result); + unsigned int (*getAvatar)(uint64 scHandlerID, anyID clientID, char* result, size_t maxLen); + void (*setPluginMenuEnabled)(const char* pluginID, int menuID, int enabled); + void (*showHotkeySetup)(void); + void (*requestHotkeyInputDialog)(const char* pluginID, const char* keyword, int isDown, void* qParentWindow); + unsigned int (*getHotkeyFromKeyword)(const char* pluginID, const char** keywords, char** hotkeys, size_t arrayLen, size_t hotkeyBufSize); + unsigned int (*getClientDisplayName)(uint64 scHandlerID, anyID clientID, char* result, size_t maxLen); + unsigned int (*getBookmarkList)(struct PluginBookmarkList** list); + unsigned int (*getProfileList)(enum PluginGuiProfile profile, int* defaultProfileIdx, char*** result); + unsigned int (*guiConnect)(enum PluginConnectTab connectTab, const char* serverLabel, const char* serverAddress, const char* serverPassword, const char* nickname, const char* channel, const char* channelPassword, const char* captureProfile, + const char* playbackProfile, const char* hotkeyProfile, const char* soundProfile, const char* userIdentity, const char* oneTimeKey, const char* phoneticName, uint64* scHandlerID); + unsigned int (*guiConnectBookmark)(enum PluginConnectTab connectTab, const char* bookmarkuuid, uint64* scHandlerID); + unsigned int (*createBookmark)(const char* bookmarkuuid, const char* serverLabel, const char* serverAddress, const char* serverPassword, const char* nickname, const char* channel, const char* channelPassword, const char* captureProfile, + const char* playbackProfile, const char* hotkeyProfile, const char* soundProfile, const char* uniqueUserId, const char* oneTimeKey, const char* phoneticName); + unsigned int (*getPermissionIDByName)(uint64 serverConnectionHandlerID, const char* permissionName, unsigned int* result); + unsigned int (*getClientNeededPermission)(uint64 serverConnectionHandlerID, const char* permissionName, int* result); + void (*notifyKeyEvent)(const char* pluginID, const char* keyIdentifier, int up_down); + + /* Single-Track/Multi-Track recording */ + unsigned int (*startRecording)(uint64 serverConnectionHandlerID, int multitrack, int noFileSelector, const char* path); + unsigned int (*stopRecording)(uint64 serverConnectionHandlerID); + + /* Convenience functions */ + unsigned int (*requestClientsMove)(uint64 serverConnectionHandlerID, const anyID* clientIDArray, uint64 newChannelID, const char* password, const char* returnCode); + unsigned int (*requestClientsKickFromChannel)(uint64 serverConnectionHandlerID, const anyID* clientIDArray, const char* kickReason, const char* returnCode); + unsigned int (*requestClientsKickFromServer)(uint64 serverConnectionHandlerID, const anyID* clientIDArray, const char* kickReason, const char* returnCode); + unsigned int (*requestMuteClientsTemporary)(uint64 serverConnectionHandlerID, const anyID* clientIDArray, const char* returnCode); + unsigned int (*requestUnmuteClientsTemporary)(uint64 serverConnectionHandlerID, const anyID* clientIDArray, const char* returnCode); + unsigned int (*getPermissionNameByID)(uint64 scHandlerID, unsigned int permissionID, char* result, size_t max_len); + unsigned int (*clientPropertyFlagToString)(size_t clientPropertyFlag, char** resultString); + unsigned int (*channelPropertyFlagToString)(size_t channelPropertyFlag, char** resultString); + unsigned int (*serverPropertyFlagToString)(size_t serverPropertyFlag, char** resultString); + + /* Server editing */ + unsigned int (*setServerVariableAsInt)(uint64 serverConnectionHandlerID, size_t flag, int value); + unsigned int (*setServerVariableAsUInt64)(uint64 serverConnectionHandlerID, size_t flag, uint64 value); + unsigned int (*setServerVariableAsDouble)(uint64 serverConnectionHandlerID, size_t flag, double value); + unsigned int (*setServerVariableAsString)(uint64 serverConnectionHandlerID, size_t flag, const char* value); + unsigned int (*flushServerUpdates)(uint64 serverConnectionHandlerID, const char* returnCode); + + /* Server/Channel group helper functions */ + unsigned int (*getServerGroupIDByName)(uint64 serverConnectionHandlerID, const char* groupName, unsigned int* result); + unsigned int (*getServerGroupNameByID)(uint64 scHandlerID, unsigned int groupID, char* result, size_t max_len); + unsigned int (*getChannelGroupIDByName)(uint64 serverConnectionHandlerID, const char* groupName, unsigned int* result); + unsigned int (*getChannelGroupNameByID)(uint64 scHandlerID, unsigned int groupID, char* result, size_t max_len); }; #ifdef __cplusplus diff --git a/src/icons/1.png b/src/icons/1.png new file mode 100644 index 0000000000000000000000000000000000000000..aa4632b227078b84715b6281b03b83a5dd407038 GIT binary patch literal 234 zcmeAS@N?(olHy`uVBq!ia0vp^0wB!61|;P_|4#%`jKx9jP7LeL$-D$|*pj^6T^Rm@ z;DWu&Cj&(|3p^r=85p>QL70(Y)*K0-AbW|YuPgg)9!^eC4MvuU%YZ^WnIRD+&iT2y zsd*(pE(61!b(>}asUS}m#}JFt$q5qI4m312Ch{>eA2w%WYx~c`!=tn$BP<~yA>zz| z0}uGF{+THh{wF;lVMmiUqp+Y}B2cEnAd4Z7nWK^a$&yCd0N)!M&KR6AU^vMuy5W`3 Qz9x_@p00i_>zopr0D#;@UH||9 literal 0 HcmV?d00001 diff --git a/src/icons/2.png b/src/icons/2.png new file mode 100644 index 0000000000000000000000000000000000000000..fe83f3f6ff5d25588760c97a6995b349dff5115f GIT binary patch literal 297 zcmeAS@N?(olHy`uVBq!ia0vp^0wB!61|;P_|4#%`jKx9jP7LeL$-D$|*pj^6T^Rm@ z;DWu&Cj&(|3p^r=85p>QL70(Y)*K0-AbW|YuPgg)9!^d%Q&0VMdw@bbnIRD+&iT2y zsd*(pE(61!b(>}asfnI0jv*GO?_Rd&V=NRn`q4k6Lqp^>lhyPCqGp9Go!uE)1X3C13uNw~t^2cm&3v-#1*eVly#qcQm?kg^9 z4R-w3%VOm{X82w6i{QG63i`@934Q5bmh@CKI0yJkh>337ctqO#%mp3idn~2hai1t{zb@#%zbRn6vcNwdyx!sq^GN&%Q~loCIG;&Y3cv~ literal 0 HcmV?d00001 diff --git a/src/icons/3.png b/src/icons/3.png new file mode 100644 index 0000000000000000000000000000000000000000..bcc6557ea9bcbc4f3fe4a6e91be8b8c7c1a1e417 GIT binary patch literal 303 zcmeAS@N?(olHy`uVBq!ia0vp^0wB!61|;P_|4#%`jKx9jP7LeL$-D$|*pj^6T^Rm@ z;DWu&Cj&(|3p^r=85p>QL70(Y)*K0-AbW|YuPgg)9!^d%;n_;sjzA%v%#er@=ltB< z)VvZPmw{o=x=k~I)O1f5#}JFtcP|-oA1o9&_R&9LiO5o&P13w!`3GLe&e+4cx^oZ5 zdWU-r<_TM)474RhxK7{XvH$J72^x)lX9L{9>}dSvI~q3v#NbtDnm{r-UW|Y4d2f literal 0 HcmV?d00001 diff --git a/src/icons/t.png b/src/icons/t.png new file mode 100644 index 0000000000000000000000000000000000000000..3c825217fe4225daa307b20aa1ae4fa846e3faaa GIT binary patch literal 241 zcmeAS@N?(olHy`uVBq!ia0vp^0wB!61|;P_|4#%`jKx9jP7LeL$-D$|*pj^6T^Rm@ z;DWu&Cj&(|3p^r=85p>QL70(Y)*K0-AbW|YuPgg)9!^eSp@~87Cjo_cGD9Ltobz*Y zQ}arITn2_c>o&~S?1~L=d#Wzp$PyC4@~v| literal 0 HcmV?d00001 diff --git a/src/ledhandler.cpp b/src/ledhandler.cpp index e7f1639..b82d7cb 100644 --- a/src/ledhandler.cpp +++ b/src/ledhandler.cpp @@ -3,34 +3,49 @@ #include #include -LEDHandler::LEDHandler(QUdpSocket* sock, TS3Functions ts3Functions) +LEDHandler::LEDHandler(QUdpSocket* sock, TS3Functions ts3Functions, QSettings* settings) : mSettings(settings) { mSock = sock; mTs3Functions = ts3Functions; + mBrightness = mSettings->value("Global/Brightness", 60).toInt(); connect(mSock, &QUdpSocket::hostFound, this, &LEDHandler::hostFound); } void LEDHandler::talkingStarted() { printf("started\n"); - sendColor(0, 0, 255, 0, 255); + sendColor(mSettings->value("Talk/R").toInt(), + mSettings->value("Talk/G").toInt(), + mSettings->value("Talk/B").toInt(), + mSettings->value("Talk/W").toInt(), + 255); } void LEDHandler::talkingEnded() { printf("stopped\n"); sendColor(0, 0, 0, 0, 0); + + mSettings->sync(); // update for external changes } void LEDHandler::poked() { - sendColor(0, 0, 0, 255, 5); + sendColor(mSettings->value("Poked/R").toInt(), + mSettings->value("Poked/G").toInt(), + mSettings->value("Poked/B").toInt(), + mSettings->value("Poked/W").toInt(), + mSettings->value("Poked/Duration").toInt()); } void LEDHandler::clientMoved() { - sendColor(255, 255, 0, 0, 1); + sendColor(mSettings->value("ClientMoved/R").toInt(), + mSettings->value("ClientMoved/G").toInt(), + mSettings->value("ClientMoved/B").toInt(), + mSettings->value("ClientMoved/W").toInt(), + mSettings->value("ClientMoved/Duration").toInt()); } void LEDHandler::sendColor(int R, int G, int B, int W, int t) @@ -38,24 +53,35 @@ void LEDHandler::sendColor(int R, int G, int B, int W, int t) QByteArray msg; msg.append(3); msg.append((uint)t); - for (int n = 0; n < cLEDNUM; n++) { + for (int n = mSettings->value("Global/StartLED").toInt(); + n < mSettings->value("Global/EndLED").toInt(); n++) { msg.append((int)R * mBrightness/100); msg.append((int)G * mBrightness/100); msg.append((int)B * mBrightness/100); msg.append((int)W * mBrightness/100); } - mSock->writeDatagram(msg, QHostAddress(cURL), cPORT); + mSock->writeDatagram(msg, + QHostAddress(mSettings->value("Global/IP").toString()), + mSettings->value("Global/Port").toInt()); } void LEDHandler::connected() { - sendColor(0, 255, 0, 0, 1); + sendColor(mSettings->value("Connected/R").toInt(), + mSettings->value("Connected/G").toInt(), + mSettings->value("Connected/B").toInt(), + mSettings->value("Connected/W").toInt(), + mSettings->value("Connected/Duration").toInt()); } void LEDHandler::disconnected() { - sendColor(255, 0, 0, 0, 1); + sendColor(mSettings->value("Disconnected/R").toInt(), + mSettings->value("Disconnected/G").toInt(), + mSettings->value("Disconnected/B").toInt(), + mSettings->value("Disconnected/W").toInt(), + mSettings->value("Disconnected/Duration").toInt()); } void LEDHandler::hostFound() diff --git a/src/ledhandler.h b/src/ledhandler.h index 1e46fff..f9d63b4 100644 --- a/src/ledhandler.h +++ b/src/ledhandler.h @@ -1,18 +1,19 @@ #ifndef LEDHANDLER_H #define LEDHANDLER_H +#include #include #include - class LEDHandler : public QObject { public: - QString cURL = "10.0.0.222"; - int cPORT = 21324; - int cLEDNUM = 90; + QString cURL; + int cPORT; + int cLEDFROM; + int cLEDTO; - LEDHandler(QUdpSocket* sock, TS3Functions ts3Functions); + LEDHandler(QUdpSocket* sock, TS3Functions ts3Functions, QSettings* settings); void talkingEnded(); void talkingStarted(); @@ -27,7 +28,45 @@ public slots: private: QUdpSocket* mSock; TS3Functions mTs3Functions; - int mBrightness = 80; + QSettings* mSettings; + + int mBrightness; + + int cConnectedR; + int cConnectedG; + int cConnectedB; + int cConnectedW; + int cConnectedDur; + + int cDisconnectedR; + int cDisconnectedG; + int cDisconnectedB; + int cDisconnectedW; + int cDisconnectedDur; + + int cTalkR; + int cTalkG; + int cTalkB; + int cTalkW; + + int cNewUserR; + int cNewUserG; + int cNewUserB; + int cNewUserW; + int cNewUserDur; + + int cMovedR; + int cMovedG; + int cMovedB; + int cMovedW; + int cMovedDur; + + int cPokedR; + int cPokedG; + int cPokedB; + int cPokedW; + int cPokedDur; + void sendColor(int R, int G, int B, int W, int t); }; diff --git a/src/plugin.cpp b/src/plugin.cpp index 8a9458c..9fbc721 100644 --- a/src/plugin.cpp +++ b/src/plugin.cpp @@ -4,6 +4,7 @@ * Copyright (c) TeamSpeak Systems GmbH */ +#include "ts3_functions.h" #if defined(WIN32) || defined(__WIN32__) || defined(_WIN32) #pragma warning (disable : 4100) /* Disable Unreferenced parameter warning */ #include @@ -18,7 +19,6 @@ #include "teamspeak/public_errors_rare.h" #include "teamspeak/public_definitions.h" #include "teamspeak/public_rare_definitions.h" -#include "teamspeak/clientlib_publicdefinitions.h" static struct TS3Functions ts3Functions; @@ -29,7 +29,7 @@ static struct TS3Functions ts3Functions; #define _strcpy(dest, destSize, src) { strncpy(dest, src, destSize-1); (dest)[destSize-1] = '\0'; } #endif -#define PLUGIN_API_VERSION 23 +#define PLUGIN_API_VERSION 26 #define PATH_BUFSIZE 512 #define COMMAND_BUFSIZE 128 @@ -56,7 +56,7 @@ const char* ts3plugin_name() { /* Plugin version */ const char* ts3plugin_version() { - return "0.4b"; + return "0.8"; } /* Plugin API version. Must be the same as the clients API major version, else the plugin fails to load. */ @@ -67,7 +67,7 @@ int ts3plugin_apiVersion() { /* Plugin author */ const char* ts3plugin_author() { /* If you want to use wchar_t, see ts3plugin_name() on how to use */ - return "Rogosoftware"; + return "Rogo Software"; } /* Plugin description */ @@ -94,6 +94,8 @@ int ts3plugin_init() { /* Your plugin init code here */ printf("PLUGIN: init\n"); + + /* Example on how to query application, resources and configuration paths from client */ /* Note: Console client returns empty string for app and resources path */ ts3Functions.getAppPath(appPath, PATH_BUFSIZE); @@ -103,8 +105,13 @@ int ts3plugin_init() { printf("PLUGIN: App path: %s\nResources path: %s\nConfig path: %s\nPlugin path: %s\n", appPath, resourcesPath, configPath, pluginPath); + mConfig = new QSettings(QString(pluginPath) + "/LEDconf.ini", QSettings::IniFormat); + initConfig(); + printf("Initializing LED Settings: %d \n", mConfig->status()); + printf("Settings Location: %s \n", mConfig->fileName().toStdString().c_str()); + mUdpSock = new QUdpSocket(); - mLedHandler = new LEDHandler(mUdpSock, ts3Functions); + mLedHandler = new LEDHandler(mUdpSock, ts3Functions, mConfig); return 0; /* 0 = success, 1 = failure, -2 = failure but client will not show a "failed to load" warning */ /* -2 is a very special case and should only be used if a plugin displays a dialog (e.g. overlay) asking the user to disable @@ -112,6 +119,57 @@ int ts3plugin_init() { * For normal case, if a plugin really failed to load because of an error, the correct return value is 1. */ } +void initConfig() { + + mConfig->sync(); + if (!mConfig->value("init", false).toBool()) return; + + mConfig->setValue("init", true); + + mConfig->setValue("Global/IP", "10.0.0.167"); + mConfig->setValue("Global/Port", 21324); + mConfig->setValue("Global/Brightness", 60); + mConfig->setValue("Global/StartLED", 0); + mConfig->setValue("Global/EndLED", 90); + + mConfig->setValue("Connected/R", 0); + mConfig->setValue("Connected/G", 255); + mConfig->setValue("Connected/B", 0); + mConfig->setValue("Connected/W", 0); + mConfig->setValue("Connected/Duration", 1); + + mConfig->setValue("Disconnected/R", 255); + mConfig->setValue("Disconnected/G", 0); + mConfig->setValue("Disconnected/B", 0); + mConfig->setValue("Disconnected/W", 0); + mConfig->setValue("Disconnected/Duration", 1); + + mConfig->setValue("Talk/R", 0); + mConfig->setValue("Talk/G", 0); + mConfig->setValue("Talk/B", 255); + mConfig->setValue("Talk/W", 0); + + mConfig->setValue("UserJoined/R", 125); + mConfig->setValue("UserJoined/G", 25); + mConfig->setValue("UserJoined/B", 250); + mConfig->setValue("UserJoined/W", 0); + mConfig->setValue("UserJoined/Duration", 1); + + mConfig->setValue("ClientMoved/R", 0); + mConfig->setValue("ClientMoved/G", 255); + mConfig->setValue("ClientMoved/B", 255); + mConfig->setValue("ClientMoved/W", 15); + mConfig->setValue("ClientMoved/Duration", 1); + + mConfig->setValue("Poked/R", 0); + mConfig->setValue("Poked/G", 0); + mConfig->setValue("Poked/B", 0); + mConfig->setValue("Poked/W", 255); + mConfig->setValue("Poked/Duration", 5); + + mConfig->sync(); +} + /* Custom code called right before the plugin is unloaded */ void ts3plugin_shutdown() { /* Your plugin cleanup code here */ @@ -119,6 +177,7 @@ void ts3plugin_shutdown() { delete mUdpSock; delete mLedHandler; + delete mConfig; /* * Note: diff --git a/src/plugin.h b/src/plugin.h index ded8748..e4d02c2 100644 --- a/src/plugin.h +++ b/src/plugin.h @@ -7,53 +7,49 @@ #ifndef PLUGIN_H #define PLUGIN_H -#include +#include +#include "ledhandler.h" +#include "public_definitions.h" +#include "qudpsocket.h" #if defined(WIN32) || defined(__WIN32__) || defined(_WIN32) -#include #define PLUGINS_EXPORTDLL __declspec(dllexport) #else -#define PLUGINS_EXPORTDLL __attribute__ ((visibility("default"))) +#define PLUGINS_EXPORTDLL __attribute__((visibility("default"))) #endif -#include "ledhandler.h" -#include "ts3_functions.h" - -#include -#include -#include -#include - #ifdef __cplusplus extern "C" { #endif +QSettings* mConfig; QUdpSocket *mUdpSock; LEDHandler *mLedHandler; +void initConfig(); /* Required functions */ PLUGINS_EXPORTDLL const char* ts3plugin_name(); PLUGINS_EXPORTDLL const char* ts3plugin_version(); -PLUGINS_EXPORTDLL int ts3plugin_apiVersion(); +PLUGINS_EXPORTDLL int ts3plugin_apiVersion(); PLUGINS_EXPORTDLL const char* ts3plugin_author(); PLUGINS_EXPORTDLL const char* ts3plugin_description(); -PLUGINS_EXPORTDLL void ts3plugin_setFunctionPointers(const struct TS3Functions funcs); -PLUGINS_EXPORTDLL int ts3plugin_init(); -PLUGINS_EXPORTDLL void ts3plugin_shutdown(); +PLUGINS_EXPORTDLL void ts3plugin_setFunctionPointers(const struct TS3Functions funcs); +PLUGINS_EXPORTDLL int ts3plugin_init(); +PLUGINS_EXPORTDLL void ts3plugin_shutdown(); /* Optional functions */ -PLUGINS_EXPORTDLL int ts3plugin_offersConfigure(); -PLUGINS_EXPORTDLL void ts3plugin_configure(void* handle, void* qParentWidget); -PLUGINS_EXPORTDLL void ts3plugin_registerPluginID(const char* id); +PLUGINS_EXPORTDLL int ts3plugin_offersConfigure(); +PLUGINS_EXPORTDLL void ts3plugin_configure(void* handle, void* qParentWidget); +PLUGINS_EXPORTDLL void ts3plugin_registerPluginID(const char* id); PLUGINS_EXPORTDLL const char* ts3plugin_commandKeyword(); -PLUGINS_EXPORTDLL int ts3plugin_processCommand(uint64 serverConnectionHandlerID, const char* command); -PLUGINS_EXPORTDLL void ts3plugin_currentServerConnectionChanged(uint64 serverConnectionHandlerID); +PLUGINS_EXPORTDLL int ts3plugin_processCommand(uint64 serverConnectionHandlerID, const char* command); +PLUGINS_EXPORTDLL void ts3plugin_currentServerConnectionChanged(uint64 serverConnectionHandlerID); PLUGINS_EXPORTDLL const char* ts3plugin_infoTitle(); -PLUGINS_EXPORTDLL void ts3plugin_infoData(uint64 serverConnectionHandlerID, uint64 id, enum PluginItemType type, char** data); -PLUGINS_EXPORTDLL void ts3plugin_freeMemory(void* data); -PLUGINS_EXPORTDLL int ts3plugin_requestAutoload(); -PLUGINS_EXPORTDLL void ts3plugin_initMenus(struct PluginMenuItem*** menuItems, char** menuIcon); -PLUGINS_EXPORTDLL void ts3plugin_initHotkeys(struct PluginHotkey*** hotkeys); +PLUGINS_EXPORTDLL void ts3plugin_infoData(uint64 serverConnectionHandlerID, uint64 id, enum PluginItemType type, char** data); +PLUGINS_EXPORTDLL void ts3plugin_freeMemory(void* data); +PLUGINS_EXPORTDLL int ts3plugin_requestAutoload(); +PLUGINS_EXPORTDLL void ts3plugin_initMenus(struct PluginMenuItem*** menuItems, char** menuIcon); +PLUGINS_EXPORTDLL void ts3plugin_initHotkeys(struct PluginHotkey*** hotkeys); /* Clientlib */ PLUGINS_EXPORTDLL void ts3plugin_onConnectStatusChangeEvent(uint64 serverConnectionHandlerID, int newStatus, unsigned int errorNumber); @@ -67,9 +63,12 @@ PLUGINS_EXPORTDLL void ts3plugin_onUpdateClientEvent(uint64 serverConnectionHand PLUGINS_EXPORTDLL void ts3plugin_onClientMoveEvent(uint64 serverConnectionHandlerID, anyID clientID, uint64 oldChannelID, uint64 newChannelID, int visibility, const char* moveMessage); PLUGINS_EXPORTDLL void ts3plugin_onClientMoveSubscriptionEvent(uint64 serverConnectionHandlerID, anyID clientID, uint64 oldChannelID, uint64 newChannelID, int visibility); PLUGINS_EXPORTDLL void ts3plugin_onClientMoveTimeoutEvent(uint64 serverConnectionHandlerID, anyID clientID, uint64 oldChannelID, uint64 newChannelID, int visibility, const char* timeoutMessage); -PLUGINS_EXPORTDLL void ts3plugin_onClientMoveMovedEvent(uint64 serverConnectionHandlerID, anyID clientID, uint64 oldChannelID, uint64 newChannelID, int visibility, anyID moverID, const char* moverName, const char* moverUniqueIdentifier, const char* moveMessage); -PLUGINS_EXPORTDLL void ts3plugin_onClientKickFromChannelEvent(uint64 serverConnectionHandlerID, anyID clientID, uint64 oldChannelID, uint64 newChannelID, int visibility, anyID kickerID, const char* kickerName, const char* kickerUniqueIdentifier, const char* kickMessage); -PLUGINS_EXPORTDLL void ts3plugin_onClientKickFromServerEvent(uint64 serverConnectionHandlerID, anyID clientID, uint64 oldChannelID, uint64 newChannelID, int visibility, anyID kickerID, const char* kickerName, const char* kickerUniqueIdentifier, const char* kickMessage); +PLUGINS_EXPORTDLL void ts3plugin_onClientMoveMovedEvent(uint64 serverConnectionHandlerID, anyID clientID, uint64 oldChannelID, uint64 newChannelID, int visibility, anyID moverID, const char* moverName, const char* moverUniqueIdentifier, + const char* moveMessage); +PLUGINS_EXPORTDLL void ts3plugin_onClientKickFromChannelEvent(uint64 serverConnectionHandlerID, anyID clientID, uint64 oldChannelID, uint64 newChannelID, int visibility, anyID kickerID, const char* kickerName, const char* kickerUniqueIdentifier, + const char* kickMessage); +PLUGINS_EXPORTDLL void ts3plugin_onClientKickFromServerEvent(uint64 serverConnectionHandlerID, anyID clientID, uint64 oldChannelID, uint64 newChannelID, int visibility, anyID kickerID, const char* kickerName, const char* kickerUniqueIdentifier, + const char* kickMessage); PLUGINS_EXPORTDLL void ts3plugin_onClientIDsEvent(uint64 serverConnectionHandlerID, const char* uniqueClientIdentifier, anyID clientID, const char* clientName); PLUGINS_EXPORTDLL void ts3plugin_onClientIDsFinishedEvent(uint64 serverConnectionHandlerID); PLUGINS_EXPORTDLL void ts3plugin_onServerEditedEvent(uint64 serverConnectionHandlerID, anyID editerID, const char* editerName, const char* editerUniqueIdentifier); @@ -97,7 +96,8 @@ PLUGINS_EXPORTDLL void ts3plugin_onCustom3dRolloffCalculationWaveEvent(uint64 se PLUGINS_EXPORTDLL void ts3plugin_onUserLoggingMessageEvent(const char* logMessage, int logLevel, const char* logChannel, uint64 logID, const char* logTime, const char* completeLogString); /* Clientlib rare */ -PLUGINS_EXPORTDLL void ts3plugin_onClientBanFromServerEvent(uint64 serverConnectionHandlerID, anyID clientID, uint64 oldChannelID, uint64 newChannelID, int visibility, anyID kickerID, const char* kickerName, const char* kickerUniqueIdentifier, uint64 time, const char* kickMessage); +PLUGINS_EXPORTDLL void ts3plugin_onClientBanFromServerEvent(uint64 serverConnectionHandlerID, anyID clientID, uint64 oldChannelID, uint64 newChannelID, int visibility, anyID kickerID, const char* kickerName, const char* kickerUniqueIdentifier, uint64 time, + const char* kickMessage); PLUGINS_EXPORTDLL int ts3plugin_onClientPokeEvent(uint64 serverConnectionHandlerID, anyID fromClientID, const char* pokerName, const char* pokerUniqueIdentity, const char* message, int ffIgnored); PLUGINS_EXPORTDLL void ts3plugin_onClientSelfVariableUpdateEvent(uint64 serverConnectionHandlerID, int flag, const char* oldValue, const char* newValue); PLUGINS_EXPORTDLL void ts3plugin_onFileListEvent(uint64 serverConnectionHandlerID, uint64 channelID, const char* path, const char* name, uint64 size, uint64 datetime, int type, uint64 incompletesize, const char* returnCode); @@ -124,10 +124,13 @@ PLUGINS_EXPORTDLL int ts3plugin_onServerPermissionErrorEvent(uint64 serverConne PLUGINS_EXPORTDLL void ts3plugin_onPermissionListGroupEndIDEvent(uint64 serverConnectionHandlerID, unsigned int groupEndID); PLUGINS_EXPORTDLL void ts3plugin_onPermissionListEvent(uint64 serverConnectionHandlerID, unsigned int permissionID, const char* permissionName, const char* permissionDescription); PLUGINS_EXPORTDLL void ts3plugin_onPermissionListFinishedEvent(uint64 serverConnectionHandlerID); -PLUGINS_EXPORTDLL void ts3plugin_onPermissionOverviewEvent(uint64 serverConnectionHandlerID, uint64 clientDatabaseID, uint64 channelID, int overviewType, uint64 overviewID1, uint64 overviewID2, unsigned int permissionID, int permissionValue, int permissionNegated, int permissionSkip); +PLUGINS_EXPORTDLL void ts3plugin_onPermissionOverviewEvent(uint64 serverConnectionHandlerID, uint64 clientDatabaseID, uint64 channelID, int overviewType, uint64 overviewID1, uint64 overviewID2, unsigned int permissionID, int permissionValue, + int permissionNegated, int permissionSkip); PLUGINS_EXPORTDLL void ts3plugin_onPermissionOverviewFinishedEvent(uint64 serverConnectionHandlerID); -PLUGINS_EXPORTDLL void ts3plugin_onServerGroupClientAddedEvent(uint64 serverConnectionHandlerID, anyID clientID, const char* clientName, const char* clientUniqueIdentity, uint64 serverGroupID, anyID invokerClientID, const char* invokerName, const char* invokerUniqueIdentity); -PLUGINS_EXPORTDLL void ts3plugin_onServerGroupClientDeletedEvent(uint64 serverConnectionHandlerID, anyID clientID, const char* clientName, const char* clientUniqueIdentity, uint64 serverGroupID, anyID invokerClientID, const char* invokerName, const char* invokerUniqueIdentity); +PLUGINS_EXPORTDLL void ts3plugin_onServerGroupClientAddedEvent(uint64 serverConnectionHandlerID, anyID clientID, const char* clientName, const char* clientUniqueIdentity, uint64 serverGroupID, anyID invokerClientID, const char* invokerName, + const char* invokerUniqueIdentity); +PLUGINS_EXPORTDLL void ts3plugin_onServerGroupClientDeletedEvent(uint64 serverConnectionHandlerID, anyID clientID, const char* clientName, const char* clientUniqueIdentity, uint64 serverGroupID, anyID invokerClientID, const char* invokerName, + const char* invokerUniqueIdentity); PLUGINS_EXPORTDLL void ts3plugin_onClientNeededPermissionsEvent(uint64 serverConnectionHandlerID, unsigned int permissionID, int permissionValue); PLUGINS_EXPORTDLL void ts3plugin_onClientNeededPermissionsFinishedEvent(uint64 serverConnectionHandlerID); PLUGINS_EXPORTDLL void ts3plugin_onFileTransferStatusEvent(anyID transferID, unsigned int status, const char* statusMessage, uint64 remotefileSize, uint64 serverConnectionHandlerID); @@ -140,19 +143,22 @@ PLUGINS_EXPORTDLL void ts3plugin_onMessageGetEvent(uint64 serverConnectionHandle PLUGINS_EXPORTDLL void ts3plugin_onClientDBIDfromUIDEvent(uint64 serverConnectionHandlerID, const char* uniqueClientIdentifier, uint64 clientDatabaseID); PLUGINS_EXPORTDLL void ts3plugin_onClientNamefromUIDEvent(uint64 serverConnectionHandlerID, const char* uniqueClientIdentifier, uint64 clientDatabaseID, const char* clientNickName); PLUGINS_EXPORTDLL void ts3plugin_onClientNamefromDBIDEvent(uint64 serverConnectionHandlerID, const char* uniqueClientIdentifier, uint64 clientDatabaseID, const char* clientNickName); -PLUGINS_EXPORTDLL void ts3plugin_onComplainListEvent(uint64 serverConnectionHandlerID, uint64 targetClientDatabaseID, const char* targetClientNickName, uint64 fromClientDatabaseID, const char* fromClientNickName, const char* complainReason, uint64 timestamp); -PLUGINS_EXPORTDLL void ts3plugin_onBanListEvent(uint64 serverConnectionHandlerID, uint64 banid, const char* ip, const char* name, const char* uid, const char* mytsid, uint64 creationTime, uint64 durationTime, const char* invokerName, uint64 invokercldbid, const char* invokeruid, const char* reason, int numberOfEnforcements, const char* lastNickName); +PLUGINS_EXPORTDLL void ts3plugin_onComplainListEvent(uint64 serverConnectionHandlerID, uint64 targetClientDatabaseID, const char* targetClientNickName, uint64 fromClientDatabaseID, const char* fromClientNickName, const char* complainReason, + uint64 timestamp); +PLUGINS_EXPORTDLL void ts3plugin_onBanListEvent(uint64 serverConnectionHandlerID, uint64 banid, const char* ip, const char* name, const char* uid, const char* mytsid, uint64 creationTime, uint64 durationTime, const char* invokerName, uint64 invokercldbid, + const char* invokeruid, const char* reason, int numberOfEnforcements, const char* lastNickName); PLUGINS_EXPORTDLL void ts3plugin_onClientServerQueryLoginPasswordEvent(uint64 serverConnectionHandlerID, const char* loginPassword); PLUGINS_EXPORTDLL void ts3plugin_onPluginCommandEvent(uint64 serverConnectionHandlerID, const char* pluginName, const char* pluginCommand, anyID invokerClientID, const char* invokerName, const char* invokerUniqueIdentity); PLUGINS_EXPORTDLL void ts3plugin_onIncomingClientQueryEvent(uint64 serverConnectionHandlerID, const char* commandText); -PLUGINS_EXPORTDLL void ts3plugin_onServerTemporaryPasswordListEvent(uint64 serverConnectionHandlerID, const char* clientNickname, const char* uniqueClientIdentifier, const char* description, const char* password, uint64 timestampStart, uint64 timestampEnd, uint64 targetChannelID, const char* targetChannelPW); +PLUGINS_EXPORTDLL void ts3plugin_onServerTemporaryPasswordListEvent(uint64 serverConnectionHandlerID, const char* clientNickname, const char* uniqueClientIdentifier, const char* description, const char* password, uint64 timestampStart, uint64 timestampEnd, + uint64 targetChannelID, const char* targetChannelPW); /* Client UI callbacks */ -PLUGINS_EXPORTDLL void ts3plugin_onAvatarUpdated(uint64 serverConnectionHandlerID, anyID clientID, const char* avatarPath); -PLUGINS_EXPORTDLL void ts3plugin_onMenuItemEvent(uint64 serverConnectionHandlerID, enum PluginMenuType type, int menuItemID, uint64 selectedItemID); -PLUGINS_EXPORTDLL void ts3plugin_onHotkeyEvent(const char* keyword); -PLUGINS_EXPORTDLL void ts3plugin_onHotkeyRecordedEvent(const char* keyword, const char* key); -PLUGINS_EXPORTDLL void ts3plugin_onClientDisplayNameChanged(uint64 serverConnectionHandlerID, anyID clientID, const char* displayName, const char* uniqueClientIdentifier); +PLUGINS_EXPORTDLL void ts3plugin_onAvatarUpdated(uint64 serverConnectionHandlerID, anyID clientID, const char* avatarPath); +PLUGINS_EXPORTDLL void ts3plugin_onMenuItemEvent(uint64 serverConnectionHandlerID, enum PluginMenuType type, int menuItemID, uint64 selectedItemID); +PLUGINS_EXPORTDLL void ts3plugin_onHotkeyEvent(const char* keyword); +PLUGINS_EXPORTDLL void ts3plugin_onHotkeyRecordedEvent(const char* keyword, const char* key); +PLUGINS_EXPORTDLL void ts3plugin_onClientDisplayNameChanged(uint64 serverConnectionHandlerID, anyID clientID, const char* displayName, const char* uniqueClientIdentifier); PLUGINS_EXPORTDLL const char* ts3plugin_keyDeviceName(const char* keyIdentifier); PLUGINS_EXPORTDLL const char* ts3plugin_displayKeyText(const char* keyIdentifier); PLUGINS_EXPORTDLL const char* ts3plugin_keyPrefix();