コード例 #1
0
 def __genKey(self, idx):
     if not -1 < idx < PANEL_MAX_LENGTH - 1:
         raise AssertionError
         cmdMappingKey = COMMAND_AMMO_CHOICE_MASK.format(idx + 1 if idx < 9 else 0)
         bwKey = CommandMapping.g_instance.get(cmdMappingKey)
         sfKey = 0
         sfKey = bwKey is not None and bwKey != 0 and getScaleformKey(bwKey)
     return (bwKey, sfKey)
コード例 #2
0
ファイル: consumablespanel.py プロジェクト: kblw/wot_client
 def __genKey(self, idx):
     assert -1 < idx < PANEL_MAX_LENGTH - 1
     cmdMappingKey = COMMAND_AMMO_CHOICE_MASK.format(idx + 1 if idx < 9 else 0)
     bwKey = CommandMapping.g_instance.get(cmdMappingKey)
     sfKey = 0
     if bwKey is not None and bwKey != 0:
         sfKey = getScaleformKey(bwKey)
     return (bwKey, sfKey)
コード例 #3
0
 def __genKey(self, idx):
     assert -1 < idx < PANEL_MAX_LENGTH - 1
     cmdMappingKey = COMMAND_AMMO_CHOICE_MASK.format(idx +
                                                     1 if idx < 9 else 0)
     bwKey = CommandMapping.g_instance.get(cmdMappingKey)
     sfKey = 0
     if bwKey is not None and bwKey != 0:
         sfKey = getScaleformKey(bwKey)
     return (bwKey, sfKey)
コード例 #4
0
 def __genKey(self, idx):
     if not -1 < idx < PANEL_MAX_LENGTH - 1:
         raise AssertionError
         cmdMappingKey = COMMAND_AMMO_CHOICE_MASK.format(
             idx + 1 if idx < 9 else 0)
         bwKey = CommandMapping.g_instance.get(cmdMappingKey)
         sfKey = 0
         sfKey = bwKey is not None and bwKey != 0 and getScaleformKey(bwKey)
     return (bwKey, sfKey)