발표자료(http://zeropage.org/pub/devilscamp/2005/SocketProgramming.ppt)
타자게임 클라이언트(코딩용, 쌔거)(http://zeropage.org/pub/devilscamp/2005/TajaClientSrc1.zip)
타자게임 클라이언트(데모용)(http://zeropage.org/pub/devilscamp/2005/TajaClientThatWorks.zip)
전체(http://zeropage.org/pub/devilscamp/2005/TajaGame.zip)
Python 2.4.1(http://zeropage.org/~dduk/dcmp/python-2.4.1.msi)
wxPython 2.6.0.1(http://zeropage.org/~dduk/dcmp/wxPython2.6-win32-unicode-2.6.0.1-py24.exe)
message.py
~cpp
# -*- coding: UTF-8 -*-
ID_OK = 200
ID_SENTENCE = 201
ID_TEXT = 202
ID_SAYNICK = 203
ID_SCOREBOARD = 204
MSG_OK = 'OKAY'
MSG_SENTENCE = 'SENTENCE'
class Message:
def __init__(self, msgType, sNum, msgBody, msgInfo=None):
self.messageType = msgType
self.seqNum = sNum
self.messageBody = msgBody
self.delimiter = '\r\n'
self.msgInfo = msgInfo
def __str__(self):
return 'MessageType : %d\nSequence Number : %d\nMessage Body : %s\nmsgInfo : %s\n' \
% (self.messageType, self.seqNum, self.messageBody, self.msgInfo)