Ejemplo n.º 1
0
 def cursorVisibility(self, callbackId, visible, x = None, y = None, customCall = False, enableAiming = True):
     if visible:
         g_cursorDelegator.syncMousePosition(self, x, y, customCall)
     else:
         g_cursorDelegator.restoreMousePosition()
     if BigWorld.player() is not None and isPlayerAvatar():
         BigWorld.player().setForcedGuiControlMode(visible, False, enableAiming)
Ejemplo n.º 2
0
 def cursorVisibility(self, callbackId, visible, x = None, y = None, customCall = False, enableAiming = True):
     if visible:
         g_cursorDelegator.syncMousePosition(self, x, y, customCall)
     else:
         g_cursorDelegator.restoreMousePosition()
     if BigWorld.player() is not None and isPlayerAvatar():
         BigWorld.player().setForcedGuiControlMode(visible, False, enableAiming)
     return
Ejemplo n.º 3
0
 def cursorVisibility(self,
                      _,
                      visible,
                      x=None,
                      y=None,
                      customCall=False,
                      enableAiming=True):
     if visible:
         g_cursorDelegator.syncMousePosition(self, x, y, customCall)
     else:
         g_cursorDelegator.restoreMousePosition()
     avatar_getter.setForcedGuiControlMode(visible,
                                           stopVehicle=False,
                                           enableAiming=enableAiming)
Ejemplo n.º 4
0
 def show(self, reason = None, isBan = None, expiryTime = None):
     Waiting.close()
     g_cursorDelegator.syncMousePosition(self, None, None)
     params = {'reason': '',
      'expiryTime': ''}
     if reason:
         params['reason'] = makeString('#dialogs:disconnected/reason', makeString(reason))
     if expiryTime:
         from helpers.time_utils import makeLocalServerTime
         expiryTime = makeLocalServerTime(int(expiryTime))
         params['expiryTime'] = BigWorld.wg_getLongDateFormat(expiryTime) + ' ' + BigWorld.wg_getLongTimeFormat(expiryTime)
     message = 'messageKick' if not isBan else 'messageBanPeriod' if expiryTime else 'messageBan'
     message = makeString('#dialogs:disconnected/' + message) % params
     self.setMovieVariable('_root._level0.setMessage', [message])
Ejemplo n.º 5
0
 def show(self, reason = None, isBan = None, expiryTime = None):
     Waiting.close()
     g_cursorDelegator.syncMousePosition(self, None, None)
     params = {'reason': '',
      'expiryTime': ''}
     if reason:
         params['reason'] = makeString('#dialogs:disconnected/reason', makeString(reason))
     if expiryTime:
         from helpers.time_utils import makeLocalServerTime
         expiryTime = makeLocalServerTime(int(expiryTime))
         params['expiryTime'] = BigWorld.wg_getLongDateFormat(expiryTime) + ' ' + BigWorld.wg_getLongTimeFormat(expiryTime)
     message = 'messageKick' if not isBan else ('messageBanPeriod' if expiryTime else 'messageBan')
     message = makeString('#dialogs:disconnected/' + message) % params
     self.setMovieVariable('_root._level0.setMessage', [message])
     return
Ejemplo n.º 6
0
 def cursorVisibility(self, _, visible, x = None, y = None, customCall = False, enableAiming = True):
     if visible:
         g_cursorDelegator.syncMousePosition(self, x, y, customCall)
     else:
         g_cursorDelegator.restoreMousePosition()
     avatar_getter.setForcedGuiControlMode(visible, stopVehicle=False, enableAiming=enableAiming)