def loaderPhaseChecker(self, path, loaderOptions): if 'audio/' in path: return 1 file = Filename(path) if not file.getExtension(): file.setExtension('bam') mp = getModelPath() path = mp.findFile(file).cStr() if not path: return match = re.match('.*phase_([^/]+)/', path) if not match: if 'dmodels' in path: return self.errorAccumulatorBuffer += 'file not in phase (%s, %s)\n' % ( file, path) return basePhase = float(match.groups()[0]) if not launcher.getPhaseComplete(basePhase): self.errorAccumulatorBuffer += 'phase is not loaded for this model %s\n' % path model = loader.loader.loadSync(Filename(path), loaderOptions) if model: model = NodePath(model) for tex in model.findAllTextures(): texPath = tex.getFullpath().cStr() match = re.match('.*phase_([^/]+)/', texPath) if match: texPhase = float(match.groups()[0]) if texPhase > basePhase: self.errorAccumulatorBuffer += 'texture phase is higher than the models (%s, %s)\n' % ( path, texPath)