Forum


Notice to all users

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

Results 1 to 9 of 9

Hybrid View

  1. #1
    Join Date
    September 2012
    Posts
    45

    3.0.4 Server SDK

    Wow, what a change.. *specifically* to the server_creation_params example. This will take a bit of time to digest, for sure. There are certainly several things "of note" to deal with, especially when it comes to adding proper database support. I am working on an example of "how to", and when I get some success I will post that for reference.

    Anyway, with that said.... there is certainly one issue that needs updating, dealing with the "key_pair" file. In the current sample, there is no 'write to the file when it doesn't exist' function. I tried copying the code from the 3.0.3.2 server and putting it into the same "generic" place into the new version, but that failed. I suspect that it had to do with the new creation array stuff, where the virtual server had not yet 'officially' been created... until after all of the channels have been defined and validated, and then the array is used to create the server. So, I create a local variable at the top of the code
    Code:
    #ifdef _WINDOWS
    #define SLEEP(x) Sleep(x)
    #else
    #define SLEEP(x) usleep(x*1000)
    #endif
    
    #define CHECK_ERROR(x) if((error = x) != ERROR_ok) { goto on_error; }
    
    bool found_kp = false; // <<< added this line
    In "create_VirtualServer2" I made this change
    Code:
        /* Assemble filename: keypair_<port>.txt */
        strcpy(filename, "keypair_");
        sprintf(port_str, "%d", port);
        strcat(filename, port_str);
        strcat(filename, ".txt");
    
        /* Try reading keyPair from file */
        if(readKeyPairFromFile(filename, buffer) == 0) {
            keyPair = buffer;  /* Id read from file */
    		found_kp = true; // <<< added this line
        } else {
            keyPair = "";  /* No Id saved, start virtual server with empty keyPair string */
        }
    and then at the "leave" label in the same function above, I modified it as follows
    Code:
    leave:
        /* Cleanup struct virtual server param. The included struct channel param will be automatically
         * freed when the virtual server param is freed, so you do not need to call freeMemory on
         * the channel params, too. */
        ts3server_freeMemory(vscp);
    
    	/* If we didn't load the keyPair before, query it from virtual server and save to file */
    	if (!found_kp) {
    		if ((error = ts3server_getVirtualServerKeyPair(serverID, &keyPair)) != ERROR_ok) {
    			char* errormsg;
    			if (ts3server_getGlobalErrorMessage(error, &errormsg) == ERROR_ok) {
    				printf("Error querying keyPair: %s\n\n", errormsg);
    				ts3server_freeMemory(errormsg);
    			}
    			return 0;
    		}
    
    		/* Save keyPair to file "keypair_<port>.txt"*/
    		if (writeKeyPairToFile(filename, keyPair) != 0) {
    			ts3server_freeMemory(keyPair);
    			return 0;
    		}
    		ts3server_freeMemory(keyPair);
    	}
    
        /* Finally return the virtual server ID of our just created virtual server */
        return serverID;
    Now, it's possible that the "return 0" should be -1 instead, just in case one of those 2 internal functions fails... but, it worked for me. It wrote a proper keypair code, and loaded it properly at the next run.

  2. #2
    Join Date
    September 2012
    Posts
    45
    well, I've tried 2 times to add some stuff into this thread, but it seems the forums time out... "checking browser" stuff.. and then its lost.

    I won't bother with the third time.

    I'll just say that the new server API to create channels does not work properly yet.

  3. #3
    Join Date
    September 2012
    Posts
    6,079
    Quote Originally Posted by dbsDev View Post
    well, I've tried 2 times to add some stuff into this thread, but it seems the forums time out... "checking browser" stuff.. and then its lost.

    I won't bother with the third time.

    I'll just say that the new server API to create channels does not work properly yet.
    If cloudflare decides to jump in (again) when posting, it won't work because it eats the post action or doesn't relay it properly.
    In any case you can copy your post content before clicking submit, then after the check finished go back to the thread and paste your post content then click submit. It usually works then.
    When sending PMs please make sure to include a reference link to the thread in question in the body of your message.

  4. #4
    Join Date
    September 2012
    Posts
    45
    Yeah, I figured I would have to end back up doing that. I'll wait till my mindset is in a better place. Waiting weeks for answer and support from the sdk team has driven my frustration level to an all time high.

  5. #5
    Join Date
    September 2012
    Posts
    45
    Since day 1 of the "starting" to get into the old SDK, I have encountered a ton of problems in development. The server doesn't seem to want to give the client certain variables, even though the calls to fetch that data have been sent. The biggest flaw was the auto generated channels, something which could have never ever worked in the real world.

    The new SDK came out, which addressed that to some degree, but it still doesn't work when the channels are not in numerical order (aka 1, 2, 3, 5, 9, etc).

    I have put tons of time into this, sent in a whole amount of emails to the SDK support team, most of which I would never get a response to. In my latest issues (none of them whinny in nature) I got no responses. One of the SDK members did send me some updated code after I sent them full source plus screen shots... but that code did not work.

    I've been going nuts asking questions and not getting responses, only to find out that I have reached my "free limit" of support. And I've been told that it is going to cost me to get support.

    Considering the past has been like pulling teeth... I have terminated my project. I simply can not afford the time it is going to take to get the SDK into something that even closely resembles what the real teamspeak does.
    Last edited by James; March 28th, 2017 at 05:20 PM. Reason: confidential information

  6. #6
    Join Date
    October 2013
    Posts
    2
    Hello,

    As much as we'd like to provide free support to everyone who utilizes the evaluation version of the TeamSpeak SDK, our Support and Development team must understandably focus on currently licensed SDK customers and those who are evaluating the SDK with plans to productize their game or application. The majority of our customers are able to integrate the SDK into their project with a few days of TeamSpeak's assistance and have gone live successfully. Unfortunately we are unable to dedicate resources for extended periods of time (approximately 3 years in this case) for projects that donít materialize. That being said, we are always willing to take a look at any bugs that you may encounter.

    Best Regards,
    James

Thread Information

Users Browsing this Thread

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

Posting Permissions

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