Digital Paint Discussion Board

Development => General Development => Topic started by: mRokita on December 29, 2014, 03:37:10 PM

Title: pypb2lib 1.0
Post by: mRokita on December 29, 2014, 03:37:10 PM
Deprecated, use DPLib - https://github.com/mRokita/DPLib

This is my smart python lib for writing paintball server bots and many many more.
A simple hello world bot:
Code: [Select]
from pypb2lib import *
def onChat(l):
   if l['text'].find('!hi')==0:
      server1.Say('Hi!')
server1=Server(hostname='127.0.0.1', port=27910, logfile='qconsole27910.log', rcon_password='1234')
server1.Bind(EVT_CHAT, onChat)
More events/functions available in the source, I'll make some "wiki" later.
https://github.com/hTmlDP/pypb2lib/ (https://github.com/hTmlDP/pypb2lib/)