This all applies to TASClient ofc.
You can enable scripts in lobby, and then enable the debug window.
Scripts are in python, and should be placed in lobby/python/scripts.
Then you can load the by pressing reload.
Tasclient has a great and stable API, all detailed in lobby/python/api.txt
Example script: auto reconnect
Code: Select all
import lobbyscript
import datetime
connected=0
first=1
def onConnected():
global connected
connected=1
print "Connected "+datetime.datetime.now().isoformat()
def onDisconnect():
global connected
connected=0
print "Disconnected "+datetime.datetime.now().isoformat()
def timer_30():
global first
global connected
if first==1:
first-=1
else:
#print "tick"
if connected==0:
api.SocketConnect("91.121.98.29",8200)
print "Reconnecting "+datetime.datetime.now().isoformat()