private function createFileEntry($output, $curPath, $curFile) { // See if we need to reject it based on our rules.. if ($output->ruleReject($curFile)) { return null; } // Get the extension - is it one of our allowed values? if (!$output->allowedFileExt($curFile)) { return null; } // Cool - note in the list! $newEntry = new stdClass(); $newEntry->name = $curFile; $newEntry->path = FileUtil::collapsePath($curPath . "/" . $curFile); if (!FileUtil::isAbsolutePath($newEntry->path)) { // This could be consolidated into a single OR statement but it is easier to // read as two separate if's if (!T3D_Generator::$absPath) { $newEntry->path = $output->project_rel_path . $newEntry->path; } if (T3D_Generator::$absPath && !stristr($newEntry->path, T3D_Generator::$absPath)) { $newEntry->path = $output->project_rel_path . $newEntry->path; } } // Store a project-unique ID here for Xcode projects // It will be appended by a single char in the templates. $newEntry->hash = Project::generateXUID(); return $newEntry; }