当前位置: 首页>>代码示例>>Python>>正文


Python GlobalStorage.clearFlags方法代码示例

本文整理汇总了Python中tutorial.control.context.GlobalStorage.clearFlags方法的典型用法代码示例。如果您正苦于以下问题:Python GlobalStorage.clearFlags方法的具体用法?Python GlobalStorage.clearFlags怎么用?Python GlobalStorage.clearFlags使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在tutorial.control.context.GlobalStorage的用法示例。


在下文中一共展示了GlobalStorage.clearFlags方法的2个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Python代码示例。

示例1: stop

# 需要导入模块: from tutorial.control.context import GlobalStorage [as 别名]
# 或者: from tutorial.control.context.GlobalStorage import clearFlags [as 别名]
 def stop(self, finished = False, reason = TUTORIAL_STOP_REASON.DEFAULT):
     if self._tutorialStopped:
         return
     else:
         if self.__callbackID is not None:
             BigWorld.cancelCallback(self.__callbackID)
             self.__callbackID = None
         if self._funcScene is not None:
             self._funcScene.leave()
         if self._data is not None:
             self._data.clear()
         GlobalStorage.clearFlags()
         if self._sound is not None:
             self._sound.stop()
         self._sound = None
         if self._gui is not None:
             self._gui.fini(isItemsRevert=self._descriptor.isItemsRevertIfStop(reason))
         self._gui = None
         if finished:
             self._cache.setFinished(True).write()
         else:
             self._cache.update(self._currentChapter, self._flags.getDict() if self._flags else None)
         self._cache = None
         g_tutorialWeaver.clear()
         clearTutorialProxy()
         self.removeEffectsInQueue()
         self._nextChapter = False
         self._tutorialStopped = True
         self._initialized = 0
         return
开发者ID:webiumsk,项目名称:WoT,代码行数:32,代码来源:__init__.py

示例2: stop

# 需要导入模块: from tutorial.control.context import GlobalStorage [as 别名]
# 或者: from tutorial.control.context.GlobalStorage import clearFlags [as 别名]
 def stop(self, finished = False):
     """
     Stops the process of training.
     :param finished: if it equals True than training completed.
     """
     if self._stopped:
         return
     else:
         if self.__callbackID is not None:
             BigWorld.cancelCallback(self.__callbackID)
             self.__callbackID = None
         if self._funcScene is not None:
             self._funcScene.leave()
         if self._data is not None:
             self._data.clear()
         GlobalStorage.clearFlags()
         if self._sound is not None:
             self._sound.stop()
         self._sound = None
         if self._gui is not None:
             self._gui.fini()
         self._gui = None
         if finished:
             self._cache.setFinished(True).write()
         else:
             self._cache.update(self._currentChapter, self._flags.getDict() if self._flags else None)
         self._cache = None
         g_tutorialWeaver.clear()
         clearTutorialProxy()
         self.removeEffectsInQueue()
         self._nextChapter = False
         self._stopped = True
         self._initialized = 0
         self._triggeredEffects.clear()
         self.onStopped()
         return
开发者ID:webiumsk,项目名称:WOT-0.9.15.1,代码行数:38,代码来源:__init__.py


注:本文中的tutorial.control.context.GlobalStorage.clearFlags方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。