Package pyfics :: Package server :: Module fics
[hide private]

Source Code for Module pyfics.server.fics

 1  #!/usr/bin/env python 
 2  # -*- coding: utf-8 -*- 
 3  # vim: set sw=4 ts=4 sts=4 et tw=79 : 
 4  # Copyright 2006-2007 Ali Polatel <hawking@gentoo.org> 
 5  # Distributed under the terms of the GNU General Public License v3 
 6   
 7  """fics server definitions 
 8  """ 
 9   
10  from pyfics.server import IcsServer 
11   
12  # Fics Interface Variables 
13  # keep these sorted, the login string for interface variables depends on that. 
14  IV_SINGLEBOARD, IV_OBSPING, IV_NOWRAP, IV_FR, IV_WILDCASTLE, IV_LOSERS, \ 
15  IV_CRAZYHOUSE, IV_SUICIDE, IV_MOVECASE, IV_SMARTMOVE, IV_PREMOVE, \ 
16  IV_SHOWOWNSEEK, IV_SEEKCA, IV_EXTUSERINFO, IV_BOARDINFO, IV_PINGINFO, \ 
17  IV_MS, IV_PIN, IV_SHOWSERVER, IV_VTHILIGHT, IV_NOHILIGHT, IV_EXTASCII, \ 
18  IV_SEEKINFO, IV_GRAPH, IV_PENDINFO, IV_XDR, IV_GAMEINFO, IV_BLOCK, \ 
19  IV_STARTPOS, IV_LOCK, IV_DEFPROMPT, IV_SEEKREMOVE, IV_AUDIOCHAT, \ 
20  IV_COMPRESSMOVE = [ 2**__x for __x in range(0,34) ] 
21   
22  # Default interface variables 
23  IVARS = 0 
24  IVARS = IV_SEEKREMOVE 
25  IVARS = IV_DEFPROMPT 
26  #IVARS |= IV_BLOCK 
27  IVARS |= IV_GAMEINFO 
28  IVARS |= IV_PENDINFO 
29  IVARS |= IV_SEEKINFO 
30  IVARS |= IV_NOHILIGHT 
31  IVARS |= IV_NOWRAP 
32  IVARS |= IV_SINGLEBOARD 
33   
34 -class Fics(IcsServer):
35 ivars = IVARS 36 login = 'guest' 37 password = '' 38
39 - def __init__(self, ifs="\n\r", prompt='fics% ', misc_login = True, 40 send_ivars = True):
42 - def genloginstr(self, ivars, count=34, prefix='%b'):
43 return IcsServer.genloginstr(self, ivars, count, prefix)
44