本文整理汇总了Python中gui.prb_control.context.PrbCtrlRequestCtx.clearFlags方法的典型用法代码示例。如果您正苦于以下问题:Python PrbCtrlRequestCtx.clearFlags方法的具体用法?Python PrbCtrlRequestCtx.clearFlags怎么用?Python PrbCtrlRequestCtx.clearFlags使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类gui.prb_control.context.PrbCtrlRequestCtx
的用法示例。
在下文中一共展示了PrbCtrlRequestCtx.clearFlags方法的1个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Python代码示例。
示例1: _PrebattleDispatcher
# 需要导入模块: from gui.prb_control.context import PrbCtrlRequestCtx [as 别名]
# 或者: from gui.prb_control.context.PrbCtrlRequestCtx import clearFlags [as 别名]
#.........这里部分代码省略.........
else:
self.__requestCtx = ctx
return result
def pe_onArenaJoinFailure(self, errorCode, _):
self.__collection.reset()
SystemMessages.pushMessage(messages.getJoinFailureMessage(errorCode), type=SystemMessages.SM_TYPE.Error)
def pe_onKickedFromArena(self, reasonCode):
self.__collection.reset()
SystemMessages.pushMessage(messages.getKickReasonMessage(reasonCode), type=SystemMessages.SM_TYPE.Error)
def pe_onPrebattleAutoInvitesChanged(self):
if GUI_SETTINGS.specPrebatlesVisible:
isHidden = prb_getters.areSpecBattlesHidden()
if isHidden:
g_eventDispatcher.removeSpecBattlesFromCarousel()
else:
g_eventDispatcher.addSpecBattlesToCarousel()
g_eventDispatcher.updateUI()
def pe_onPrebattleJoined(self):
if prb_getters.getClientPrebattle() is not None:
flags = self.__requestCtx.getFlags()
self.__setFunctional(CreateFunctionalCtx(_CTRL_TYPE.PREBATTLE, flags=flags))
else:
LOG_ERROR("ClientPrebattle is not defined")
self.__requestCtx.stopProcessing(result=False)
return
def pe_onPrebattleJoinFailure(self, errorCode):
SystemMessages.pushMessage(messages.getJoinFailureMessage(errorCode), type=SystemMessages.SM_TYPE.Error)
self.__requestCtx.stopProcessing(result=False)
self.__requestCtx.clearFlags()
g_eventDispatcher.updateUI()
def pe_onPrebattleLeft(self):
if self.__nextPrbFunctional is not None:
self.__nextPrbFunctional()
self.__nextPrbFunctional = None
return
else:
flags = self.__requestCtx.getFlags()
flags |= FUNCTIONAL_FLAG.LEAVE_ENTITY
prbType = 0
if flags & FUNCTIONAL_FLAG.SWITCH > 0:
prbFunctional = self.getFunctional(_CTRL_TYPE.PREBATTLE)
if prbFunctional is not None:
prbType = prbFunctional.getEntityType()
self.__changePrbFunctional(flags=flags, prbType=prbType, stop=False)
return
def pe_onKickedFromPrebattle(self, _):
self.__changePrbFunctional(stop=True)
def gs_onTillBanNotification(self, isPlayTimeBan, timeTillBlock):
if prb_getters.isParentControlActivated():
self.__collection.reset()
key = "#system_messages:gameSessionControl/korea/{0:>s}"
if isPlayTimeBan:
SystemMessages.g_instance.pushI18nMessage(
key.format("playTimeNotification"), timeTillBlock, type=SystemMessages.SM_TYPE.Warning
)
else:
gameSession = game_control.g_instance.gameSession
notifyStartTime, blockTime = gameSession.getCurfewBlockTime()