avatar_parse.py

Release/Chat/Avatars/avatar_parse.py · 702 B

From the archive MUDPyE v0.04.tar.gz

Download the archive   « Back to the archive contents

#This is the main input processor for connections.

_imports = ["lib_login", "commandlib_user"]
_parents = ["avatar_abstract"]
_version = 1

def _Sys_Create(self, client):
  #Upon creation, go to login handler automatically.
  self._persist = True
  self.handler = lib_login.NameEntry
  self.account = None
  self.passwordTries = 0
  self.newAccountArgs = {}
  self.commandLists = [commandlib_user.commandList]


def Avatar_Connect(self):
  ExAsType(self, "avatar_abstract", "Avatar_Connect")
  Send(self, lib_login.welcome)
  Send(self, lib_login.nameRequest)

def _Sys_ReceiveCommand(self, command):
  #This avatar just passes commands on to the handler.
  print self.handler
  self.handler(command)

Site Stats

Snippets: 1791
Codebases: 571