示例#1
0
文件: mod_tundra.py 项目: ushmal/wot
def new_onControlModeChanged(current, eMode, **args):
    old_onControlModeChanged(current, eMode, **args)
    if eMode == 'sniper':
        BigWorld.wg_setTreeHidingRadius(600, 0.0)
        BigWorld.wg_enableTreeTransparency(False)
    else:
        BigWorld.wg_setTreeHidingRadius(15.0, 10.0)
        BigWorld.wg_enableTreeTransparency(True)
示例#2
0
文件: mod_tundra.py 项目: ushmal/wot
def new_PlayerHandleKey(current, isDown, key, mods):
    if hasattr(BigWorld.player(), 'arena'):
        if key == Keys.KEY_LALT:
            player = BigWorld.player()
            if player.inputHandler.ctrl == player.inputHandler.ctrls['sniper']:
                if isDown:
                    BigWorld.wg_setTreeHidingRadius(15.0, 15.0)
                    BigWorld.wg_enableTreeTransparency(True)
                else:
                    BigWorld.wg_setTreeHidingRadius(600, 0.0)
                    BigWorld.wg_enableTreeTransparency(False)
            else:
                if isDown:
                    BigWorld.wg_enableTreeHiding(True)
                    BigWorld.wg_setTreeHidingRadius(600, 0.0)
                    BigWorld.wg_enableTreeTransparency(False)
                else:
                    BigWorld.wg_enableTreeHiding(False)
                    BigWorld.wg_enableTreeTransparency(True)
    return old_PlayerHandleKey(current, isDown, key, mods)