Notice to all users

We are migrating towards a new forum system located at, as such this forum will become read-only on January 29, 2020

Results 1 to 9 of 9

Hybrid View

  1. #1
    Join Date
    October 2014

    Send extra information

    Not strictly a Teamspeak question but I'm looking for a way to send extra info over Teamspeak so think this is the right place.

    I've built a client and server based on the C# SDK examples.

    All is working great.

    My project is to replicate an aircraft radio for use with flight simulators.

    One of the things I'd like to do is to adjust the audio quality the further away a client gets from another client.

    I have mostly achieved this and I can calculate how far clients are away from each other by using their latitude and longitude, great.

    The question is...
    I can't think of a way to get a clients lat lon when they join the server.
    I would also need it again every few seconds as they move closer or further away.

    Has anybody any ideas?

  2. #2
    Join Date
    August 2013
    Do you mean their IRL lat, lon? You can get that from their IP though it's not very accurate. (example:

    If you're talking about their ingame lat, lon you probably want to go with metadata or plugincmd

  3. #3
    Join Date
    October 2014
    Thanks Bluscream.

    The lat lon is fictional as it comes from a simulator.
    In any case that part is sorted, I have that data.

    The part I am stuck on is each client sending their lat lon (or postion) to the other clients connected to the same channel.

    I've already written the code to calculate how far a client is away from the others.
    I just need to get the other positions somehow.

    For example:
    If everybody's client.nickname was their position.
    That gets sent to all clients in the same channel and I would be able to get it.

    I obviously wouldn't use nickname, I was just trying to explain.

  4. #4
    Join Date
    August 2013

  5. #5
    Join Date
    October 2014
    Having a quick look, that is totally beyond my skills.
    It looks as if it gets positional data as to where a client is (in front, behind, left or right)?

    I'm just looking for a double (or string) to be sent from one client to the others.

    My thinking is I could then use it in a for each statement and base the audio quality on the result from each client.
    Similar to is client muted.

  6. #6
    Join Date
    September 2012
    Ignore all of that, it's C++ and a different SDK (that code is using the SDK for writing plugins for the official client).

    You can use Client.MetaData and set it to any value and then use it elsewhere. It's published to other clients (that can see the client) through the server.

    The following code is untested but should give you an idea.
    connection.Self.MetaData = String.Format("{0},{1}", game.getLat(), game.getLon()); // Store game coordinates of your own client.
    // print coordinates of visible clients
    foreach (Client cl in connection.AllClients) {
        Console.WriteLine("Client {0} is at position {1}", cl.Nickname, cl.MetaData);
    Note that in this case each client sets their own position. Depending on your needs this may not be the best choice w/ regards to cheating.
    When sending PMs please make sure to include a reference link to the thread in question in the body of your message.

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. How do I add extra server channels?
    By Daqtar in forum General Questions
    Replies: 1
    Last Post: August 3rd, 2012, 10:56 PM
  2. TS3 extra or plugin question?
    By hthammond in forum General Questions
    Replies: 2
    Last Post: October 28th, 2010, 04:49 PM
  3. teamspeak extra
    By justisero in forum General Questions
    Replies: 1
    Last Post: May 14th, 2010, 01:57 PM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts