def __onVehicleLoading(self, ctxEvent):
     if self.__customizationCD is not None and not ctxEvent.ctx.get(
             'started'):
         customizationItem = self.__itemsCache.items.getItemByCD(
             self.__customizationCD)
         if customizationItem is None:
             return
         if customizationItem.itemTypeID == GUI_ITEM_TYPE.STYLE:
             g_currentPreviewVehicle.previewStyle(customizationItem)
         elif customizationItem.itemTypeID == GUI_ITEM_TYPE.CAMOUFLAGE:
             g_currentPreviewVehicle.previewCamouflage(customizationItem)
     return
 def __onVehicleLoading(self, ctxEvent):
     vehicle = g_currentPreviewVehicle.item
     if vehicle is None:
         return
     else:
         groupID = self.__vehicleByGroup.get(vehicle.intCD)
         if not ctxEvent.ctx.get(
                 'started') and groupID in self.__styleByGroup:
             customizationStyle = self.__styleByGroup[groupID]
             style = self._itemsCache.items.getItemByCD(customizationStyle)
             if style is not None and not style.isRentable:
                 g_currentPreviewVehicle.previewStyle(style)
         return
Ejemplo n.º 3
0
 def __onVehicleLoaded(self):
     g_currentPreviewVehicle.previewStyle(self.__style)