Ejemplo n.º 1
0
def init(scriptConfig, engineConfig, userPreferences, loadingScreenGUI=None):
    global g_replayCtrl
    global g_onBeforeSendEvent
    try:
        log.config.setupFromXML()
        if constants.IS_DEVELOPMENT:
            autoFlushPythonLog()
            from development_features import initDevBonusTypes
            initDevBonusTypes()
        import Event
        g_onBeforeSendEvent = Event.Event()
        BigWorld.wg_initCustomSettings()
        Settings.g_instance = Settings.Settings(scriptConfig, engineConfig, userPreferences)
        CommandMapping.g_instance = CommandMapping.CommandMapping()
        from helpers import DecalMap
        DecalMap.g_instance = DecalMap.DecalMap(scriptConfig['decal'])
        from helpers import EdgeDetectColorController
        EdgeDetectColorController.g_instance = EdgeDetectColorController.EdgeDetectColorController(scriptConfig['silhouetteColors'])
        SoundGroups.g_instance = SoundGroups.SoundGroups()
        import BattleReplay
        g_replayCtrl = BattleReplay.g_replayCtrl = BattleReplay.BattleReplay()
        g_replayCtrl.registerWotReplayFileExtension()
        g_bootcamp.replayCallbackSubscribe()
        try:
            from Vibroeffects import VibroManager
            VibroManager.g_instance = VibroManager.VibroManager()
            VibroManager.g_instance.connect()
        except Exception:
            LOG_CURRENT_EXCEPTION()

        tutorialLoaderInit()
        BigWorld.callback(0.1, asyncore_call)
        import items
        items.init(True, None if not constants.IS_DEVELOPMENT else {})
        import win_points
        win_points.init()
        import rage
        rage.init()
        import ArenaType
        ArenaType.init()
        import dossiers2
        dossiers2.init()
        import personal_missions
        personal_missions.init()
        import motivation_quests
        motivation_quests.init()
        BigWorld.worldDrawEnabled(False)
        dependency.configure(services_config.getClientServicesConfig)
        gui_personality.init(loadingScreenGUI=loadingScreenGUI)
        EdgeDetectColorController.g_instance.create()
        g_replayCtrl.subscribe()
        MessengerEntry.g_instance.init()
        AreaDestructibles.init()
        MusicControllerWWISE.create()
        TriggersManager.init()
        RSSDownloader.init()
        items.clearXMLCache()
        SoundGroups.loadLightSoundsDB()
        import player_ranks
        player_ranks.init()
        import destructible_entities
        destructible_entities.init()
        try:
            from LightFx import LightManager
            LightManager.g_instance = LightManager.LightManager()
            import AuxiliaryFx
            AuxiliaryFx.g_instance = AuxiliaryFx.AuxiliaryFxManager()
        except Exception:
            LOG_CURRENT_EXCEPTION()

        from AvatarInputHandler.cameras import FovExtended
        FovExtended.instance().resetFov()
        BigWorld.pauseDRRAutoscaling(True)
    except Exception:
        LOG_CURRENT_EXCEPTION()
        BigWorld.quit()

    return
Ejemplo n.º 2
0
def init(scriptConfig, engineConfig, userPreferences, loadingScreenGUI=None):
    global g_replayCtrl
    try:
        if constants.IS_DEVELOPMENT:
            autoFlushPythonLog()
        BigWorld.wg_initCustomSettings()
        g_postProcessing.init()
        Settings.g_instance = Settings.Settings(scriptConfig, engineConfig,
                                                userPreferences)
        CommandMapping.g_instance = CommandMapping.CommandMapping()
        from helpers import DecalMap
        DecalMap.g_instance = DecalMap.DecalMap(scriptConfig['decal'])
        from helpers import EdgeDetectColorController
        EdgeDetectColorController.g_instance = EdgeDetectColorController.EdgeDetectColorController(
            scriptConfig['silhouetteColors'])
        import SoundGroups
        SoundGroups.g_instance = SoundGroups.SoundGroups()
        import BattleReplay
        g_replayCtrl = BattleReplay.g_replayCtrl = BattleReplay.BattleReplay()
        g_replayCtrl.registerWotReplayFileExtension()
        try:
            from Vibroeffects import VibroManager
            VibroManager.g_instance = VibroManager.VibroManager()
            VibroManager.g_instance.connect()
        except:
            LOG_CURRENT_EXCEPTION()

        tutorialLoaderInit()
        BigWorld.callback(0.1, asyncore_call)
        import items
        items.init(True, None if not constants.IS_DEVELOPMENT else {})
        import win_points
        win_points.init()
        import rage
        rage.init()
        import ArenaType
        ArenaType.init()
        import dossiers2
        dossiers2.init()
        import fortified_regions
        fortified_regions.init()
        import clubs_settings
        clubs_settings.init()
        import potapov_quests
        potapov_quests.init()
        import clubs_quests
        clubs_quests.init()
        import motivation_quests
        motivation_quests.init()
        BigWorld.worldDrawEnabled(False)
        import LcdKeyboard
        LcdKeyboard.enableLcdKeyboardSpecificKeys(True)
        dependency.configure(services_config.getClientServicesConfig)
        gui_personality.init(loadingScreenGUI=loadingScreenGUI)
        EdgeDetectColorController.g_instance.create()
        g_replayCtrl.subscribe()
        MessengerEntry.g_instance.init()
        AreaDestructibles.init()
        MusicControllerWWISE.create()
        TriggersManager.init()
        RSSDownloader.init()
        SoundGroups.loadLightSoundsDB()
        try:
            from LightFx import LightManager
            LightManager.g_instance = LightManager.LightManager()
            import AuxiliaryFx
            AuxiliaryFx.g_instance = AuxiliaryFx.AuxiliaryFxManager()
        except:
            LOG_CURRENT_EXCEPTION()

        from AvatarInputHandler.cameras import FovExtended
        FovExtended.instance().resetFov()
        BigWorld.pauseDRRAutoscaling(True)
    except Exception:
        LOG_CURRENT_EXCEPTION()
        BigWorld.quit()

    return
Ejemplo n.º 3
0
def init(scriptConfig, engineConfig, userPreferences, loadingScreenGUI = None):
    global g_replayCtrl
    try:
        if constants.IS_DEVELOPMENT:
            autoFlushPythonLog()
        BigWorld.wg_initCustomSettings()
        Settings.g_instance = Settings.Settings(scriptConfig, engineConfig, userPreferences)
        CommandMapping.g_instance = CommandMapping.CommandMapping()
        from helpers import DecalMap
        DecalMap.g_instance = DecalMap.DecalMap(scriptConfig['decal'])
        from helpers import EdgeDetectColorController
        EdgeDetectColorController.g_instance = EdgeDetectColorController.EdgeDetectColorController(scriptConfig['silhouetteColors'])
        import SoundGroups
        SoundGroups.g_instance = SoundGroups.SoundGroups()
        import BattleReplay
        g_replayCtrl = BattleReplay.g_replayCtrl = BattleReplay.BattleReplay()
        g_replayCtrl.registerWotReplayFileExtension()
        try:
            import Vibroeffects
            Vibroeffects.VibroManager.g_instance = Vibroeffects.VibroManager.VibroManager()
            Vibroeffects.VibroManager.g_instance.connect()
        except:
            LOG_CURRENT_EXCEPTION()

        tutorialLoaderInit()
        BigWorld.callback(0.1, asyncore_call)
        MessengerEntry.g_instance.init()
        import items
        items.init(True, None if not constants.IS_DEVELOPMENT else {})
        import win_points
        win_points.init()
        import rage
        rage.init()
        import ArenaType
        ArenaType.init()
        import dossiers2
        dossiers2.init()
        import fortified_regions
        fortified_regions.init()
        import clubs_settings
        clubs_settings.init()
        import potapov_quests
        potapov_quests.init()
        import clubs_quests
        clubs_quests.init()
        BigWorld.worldDrawEnabled(False)
        import LcdKeyboard
        LcdKeyboard.enableLcdKeyboardSpecificKeys(True)
        gui_personality.init(loadingScreenGUI=loadingScreenGUI)
        AreaDestructibles.init()
        MusicController.init()
        TriggersManager.init()
        RSSDownloader.init()
        g_postProcessing.init()
        SoundGroups.loadLightSoundsDB()
        try:
            from LightFx import LightManager
            LightManager.g_instance = LightManager.LightManager()
            import AuxiliaryFx
            AuxiliaryFx.g_instance = AuxiliaryFx.AuxiliaryFxManager()
        except:
            LOG_CURRENT_EXCEPTION()

        from AvatarInputHandler.cameras import FovExtended
        FovExtended.instance().resetFov()
        SoundGroups.loadPluginDB()
        BigWorld.pauseDRRAutoscaling(True)
    except Exception:
        LOG_CURRENT_EXCEPTION()
        BigWorld.quit()

    return