def accept_clients(self): while 1: (clientsocket, address) = self.accept() #Adding client to clients list self.clients.append(clientsocket) #Client Connected self.onopen(clientsocket) #Receiving data from client thread.start_new_thread(self.recieve, (clientsocket,))
def input(key): if key == 'space': loading_screen.enabled = True t = time.time() window.color = color.black try: thread.start_new_thread(function=load_textures, args='') except: print('error starting thread') # load_textures() print('---', time.time() - t)
def input(key): if key == 'space': loading_screen.enabled = True info_text.enabled = False t = time.time() try: thread.start_new_thread(function=load_textures, args='') except Exception as e: print('error starting thread', e) print('---', time.time() - t)
def openInjector(): print 'TTCY Injector Enabled' root.geometry('600x600') root.title('Toontown Crystal Dev Injector') root.resizable(True, True) global text text.pack(side="left") tk.Button(root, text="Inject!", command=runInjectorCode).pack() scroll = tk.Scrollbar(frame) scroll.pack(fill="y", side="right") scroll.config(command=text.yview) text.config(yscrollcommand=scroll.set) frame.pack(fill="y") thread.start_new_thread(root.mainloop, ())
def openInjector(): print 'TTCY Injector Enabled' root.geometry('600x600') root.title('Toontown Crystal Dev Injector') root.resizable(True,True) global text text.pack(side="left") tk.Button(root,text="Inject!",command=runInjectorCode).pack() scroll = tk.Scrollbar(frame) scroll.pack(fill="y",side="right") scroll.config(command=text.yview) text.config(yscrollcommand=scroll.set) frame.pack(fill="y") thread.start_new_thread(root.mainloop,())
def __init__(self, pipe=PIPE_FILE): self.tex = Texture("CameraTexture") self.pipe = pipe self.redis = Redis() self.redis.delete("camera-lock") self.image = None self.thread = thread.start_new_thread(self.readImage, ())
def openInjector(): print 'Injector Opened' import Tkinter as tk from direct.stdpy import thread root = tk.Tk() root.geometry('600x400') root.title('INJECTOR') root.resizable(False, False) global text frame = tk.Frame(root) text = tk.Text(frame, width=70, height=20) text.pack(side="left") tk.Button(root, text="Inject!", command=runInjectorCode).pack() scroll = tk.Scrollbar(frame) scroll.pack(fill="y", side="right") scroll.config(command=text.yview) text.config(yscrollcommand=scroll.set) frame.pack(fill="y") thread.start_new_thread(root.mainloop, ())
def openInjector(): print 'INJECTOR ENABLED' import Tkinter as tk from direct.stdpy import thread root = tk.Tk() root.geometry('600x400') root.title('INJECTOR') root.resizable(False,False) global text frame = tk.Frame(root) text = tk.Text(frame,width=70,height=20) text.pack(side="left") tk.Button(root,text="Inject!",command=runInjectorCode).pack() scroll = tk.Scrollbar(frame) scroll.pack(fill="y",side="right") scroll.config(command=text.yview) text.config(yscrollcommand=scroll.set) frame.pack(fill="y") thread.start_new_thread(root.mainloop,())
def openInjector_tk(): import Tkinter as tk from direct.stdpy import thread root = tk.Tk() root.geometry('600x400') root.title('Cogtown (TTH version) Injector') root.resizable(False, False) global text frame = tk.Frame(root) text = tk.Text(frame,width=70,height=20) text.insert(1.0, defaultText) text.pack(side="left") tk.Button(root,text="Inject!",command=runInjectorCode_tk).pack() scroll = tk.Scrollbar(frame) scroll.pack(fill="y",side="right") scroll.config(command=text.yview) text.config(yscrollcommand=scroll.set) frame.pack(fill="y") thread.start_new_thread(root.mainloop,())
def updateWithNewImage(self): posX = base.camera.getX() + MAPSIZE/2 posY = base.camera.getY() + MAPSIZE/2 if self.terrain2.getRoot().isHidden(): self.terrain2.setHeightfield(self.myImage) self.terrain2.setFocalPoint(posX, posY) if Thread.isThreadingSupported(): thread.start_new_thread(self.updateWithNewImageThread,(self.terrain2,1)) else: self.updateWithNewImageThread(self.terrain2) self.terrain1.getRoot().hide() self.terrain2.getRoot().show() print "done" else: self.terrain1.setHeightfield(self.myImage) self.terrain1.setFocalPoint(posX, posY) if Thread.isThreadingSupported(): thread.start_new_thread(self.updateWithNewImageThread,(self.terrain1,1)) else: self.updateWithNewImageThread(self.terrain1) self.terrain2.getRoot().hide() self.terrain1.getRoot().show() print "done2"
def playSingleplayer(self): self.ld_scr = LoadingScreen() self.mm.cleanDel() thread.start_new_thread(function=self.loadEntities, args='')
def start(mgr): ws = ShardAPIWebServer(mgr) start_new_thread(ws.run, []) return ws
def startThreads(self): thread.start_new_thread(self.rotateQuad, (server,)) thread.start_new_thread(self.handleServerMsg, (server,)) thread.start_new_thread(self.moveCamera, (server,)) thread.start_new_thread(self.spinQuad, (server, )) thread.start_new_thread(self.evaluateHits, (server, )) thread.start_new_thread(self.runTimer, (server, ))