Hi all , I would like to tell you how I made b3 understand the Cyrillic alphabet
I'm using b3 v 1.7.0b
Attention! This only works with cod4 when B3 displays messages.
Work with Echelon, chatlogger plugin with loggining in database doesn't test.
1. in b3/parsers/cod.py
find this 3 lines
339 return b3.events.Event(b3.events.EVT_CLIENT_SAY, data, client)
361 return b3.events.Event(b3.events.EVT_CLIENT_TEAM_SAY, data, client)
382 return b3.events.Event(b3.events.EVT_CLIENT_PRIVATE_SAY, data, client, tclient)
and replace on this
339 return b3.events.Event(b3.events.EVT_CLIENT_SAY, data.decode('cp1251'), client)
361 return b3.events.Event(b3.events.EVT_CLIENT_TEAM_SAY, data.decode('cp1251'), client)
382 return b3.events.Event(b3.events.EVT_CLIENT_PRIVATE_SAY, data.decode('cp1251'), client, tclient)
2. in b3/parsers/q3a/rcon.py
find this 2 lines
120 writeables[0].send(self.qserversendstring % data)
166 writeables[0].send(self.rconsendstring % (self.password, data))
and replace on
120 writeables[0].send(self.qserversendstring % unicode(data).encode('cp1251','replace'))
166 writeables[0].send(self.rconsendstring % (self.password, unicode(data).encode('cp1251','replace')))
3. Save your translate config as UTF-8 without BOM
As example I'm added in attach my modified plugin pingwatch