CRAW now runs on Windows 7 too - the problem was that Windows 7 has moved some functi...
[craw.git] / script / skills.py
blob9ad76e91731f040a850f9eb0de8d5cf80b999260
1 import configuration, craw
3 class skill_handler_class:
4 def __init__(self):
5 self.skills = {
6 105: configuration.faster_cast_rate,
7 102: configuration.faster_block_rate,
8 99: configuration.faster_hit_recovery,
9 93: configuration.increased_attack_speed,
10 95: configuration.faster_run_walk
13 def set_skills(self):
14 #print 'Setting the skills'
15 for skill in self.skills:
16 value = self.skills[skill]
17 packet = '\x1d' + chr(skill) + chr(value)
19 craw.receive_packet(packet)
21 def process_bytes(self, bytes):
22 if len(bytes) == 1 and bytes[0] == 0x04:
23 self.set_skills()