INNER CODE UNIT · Python

_load_asset

skarndev/umodel_tools · umodel_tools/asset_importer.py:85

    def _load_asset(self,
                    context: bpy.types.Context,
                    asset_dir: str,
                    asset_path: str,
                    umodel_export_dir: str,
                    game_profile: str,
                    load: bool = True,
                    db: t.Optional[asset_db.AssetDB] = None
                    ) -> bpy.types.Object | None:
        """Loads the asset from library dir, or adds it to library and loads it.

        :param context: Current Blender context.
        :param asset_dir: Asset library directory.
        :param asset_path: Asset path in game format.
        :param umodel_export_dir: UModel output directory.
        :param game_profile: Game profile to import.
        :param load: If False, the asset will be imported to the library, but no the current scene.
        :param db: Asset database to operate on. If given, no saving is performed, else the function handles

View source record →

📰 Research Paper
Loading…
⏳ Fetching content…