[Plugin] Can I code plugins in C#?

I’d like to write some plugins for TS3 for make some utilities, and I’d like to know is can plugins written with C#.

Teamspeak version is 3.5.6, I guess is the last one.

On the SDK Download Area I found this: TeamSpeak 3 SDK C# Wrapper but I’m not sure if is can be used for the purpose, also it seems a bit old.

Someone knows more?

Thanks in advance.

The TeamSpeak SDK is not the same as the TeamSpeak plugin SDK and cannot be used as a substitute.
It is meant to develop standalone products like an in-game voice chat.

The plugin SDK is available as an example C++ project. A plugin is just a dynamic library with specific exported functions. As long as the compiled library is self-contained and respects the function signatures you can theoretically use any language.

You can find the signatures here on GitHub.

During the initialization of the plugin you also receive a pointer to a struct of function pointers you can call. This struct is defined here.

1 Like

Ok so I suppose I should take plugin.c as a sample and write in it the code.

What about plugin API version? I remember this was important.

The GitHub repo seems to be a demo of a plugin using API v23, and as I remember the teamspeak API version must be the same, how can I check which version does my client have?

Previous TS3Client versions allowed me to know that while importing plugins.

Edit: I think I have v25, so I’ll be unable to create plugins?

Well kinda.
In the plugin you specify the api version. Since TeamSpeak refuses to properly update the plugin SDK I usually resort to simply returning the required version and hoping nothing breaks. This normally works as the changes across versions are so minor you won’t really notice it. I think the version currently on their repo is 24, whereas the documentation in the same repo is for 23.

I did create a template that makes the creation of (GUI) Plugins a lot easier. You can have a look at it here:

1 Like

On plugin.c of the last their release, on row 33:

#define PLUGIN_API_VERSION 23

But when I go for compile it, the effective API version is v21 :confused:
Also, it’s not clear if is better to download TeamSpeak 3 SDK 3.1.1 from official website, or Plugin SDK API 23 (Jun 13, 2019) from GitHub, idk which is newer, anyway it says API 23, but when I compile I get a v21 one.

Edit: ok I had to change compilation settings to x64 :confused: now it works.
Next step will be to learn how to code it.