Exemple #1
0
 def __init__(self):
     content = []
     with open(self.pwpath, encoding="utf8") as f:
         content = f.readlines()
     self.pws = [x.strip() for x in content]
     self.timer.timeout.connect(self.tick)
     ts3lib.requestServerVariables(ts3lib.getCurrentServerConnectionHandlerID())
     if self.debug: ts3lib.printMessageToCurrentTab("{0}[color=orange]{1}[/color] Plugin for pyTSon by [url=https://github.com/{2}]{2}[/url] loaded.".format(timestamp(),self.name,self.author))
Exemple #2
0
 def onConnectStatusChangeEvent(self, schid, newStatus, errorNumber):
     if newStatus == ConnectStatus.STATUS_CONNECTION_ESTABLISHED:
         # self.getInterval(schid)
         ts3lib.requestServerVariables(schid)
     if newStatus == ConnectStatus.STATUS_DISCONNECTED:
         if not self.schid == schid: return
         self.timer.stop()
         (err, name) = ts3lib.getChannelVariable(schid, self.cid, ChannelProperties.CHANNEL_NAME)
         msgBox("Server left\n\nStopping Cracker!", QMessageBox.Warning)
         self.schid = 0;self.cid = 0;self.pwc = 0
 def loadVars(self, schid=False):
     if not schid: return; schid = ts3lib.getCurrentServerConnectionHandlerID()
     self.purgeDB(schid)
     # for cid in clist:
     if schid in self.cgroups: return
     self.cgroups[schid] = {"groups": {}}
     self.requestedCGroups = True;self.requestedRVars = True
     ts3lib.requestChannelGroupList(schid)
     ts3lib.requestServerVariables(schid)
     if PluginHost.cfg.getboolean("general", "verbose"): print(self.name, ">", "requested vars for #", schid)