#NEWLINE# def func( self ) : #NEWLINE# #INDENT# 'Execute the command' #NEWLINE# playername = self . args #NEWLINE# if ( ( not re . findall ( '^[\\w. @+-]+$' , playername ) ) or ( not ( 3 <= len ( playername ) <= 30 ) ) ) : #NEWLINE# #INDENT# self . caller . msg ( '\n\r {rAccount name should be between 3 and 30 characters. Letters, spaces, digits and @/./+/-/_ only.{n' ) #NEWLINE# self . menutree . goto ( 'node2a' ) #NEWLINE# return #NEWLINE# #UNINDENT# if managers . players . get_player_from_name ( self ) : #NEWLINE# #INDENT# self . caller . msg ( ( '\n\r {rAccount name %s already exists.{n' % playername ) ) #NEWLINE# self . menutree . goto ( 'node2a' ) #NEWLINE# return #NEWLINE# #UNINDENT# self . menutree . playername = playername #NEWLINE# self . caller . msg ( echo = False ) #NEWLINE# self . menutree . goto ( 'node2b' )