Legacy Documentation: Version 5.0
Language: English
  • C#
  • JS

Script language

Select your preferred scripting language. All code snippets will be displayed in this language.

PrefabUtility.CreatePrefab

Switch to Manual
public static function CreatePrefab(path: string, go: GameObject, options: ReplacePrefabOptions = ReplacePrefabOptions.Default): GameObject;

Parameters

Description

Creates a prefab from a game object hierarchy.