pyTSon bot

CravingCheese

New Member
Dec 11, 2018
3
2
15
So I'm working on my own teamspeak bot using pyTSon.
It's a really simple bot as I'm not experienced at all with python or programming in general, I'm learning tho.

Basically what I want is moving every client on the server to the channel of the invoker/fromID, there are probably better ways of doing this but I'm just a rookie :)
What I've tried is replacing "chlid" with a channel ID which works flawlessly but I want to be able to drag everyone to whatever channel I'm in
Any help is very appreciated!


Anyways here's the snippet of the code I need help with

Python:
def onTextMessageEvent(self, schid, targetMode, toID, fromID, fromName, fromUniqueIdentifier, message, ffIgnored):
   ~~~~irrelevant code~~~~~~

    elif (message == "!mm"):
        (error, clients) = ts3lib.getClientList(schid)
        (error, ownID) = ts3lib.getClientID(schid)
        chlid= ts3lib.getChannelOfClient(schid, fromID)
            for c in clients:
                if c != ownID:
                    ts3lib.requestClientMove(schid, c, chlid, "")
 

CravingCheese

New Member
Dec 11, 2018
3
2
15
Nevermind I figured it out, had to put (error, chlid), no idea why tho so if anyone would take their time and explain I would appreciate it!
 
Top