FCV Engine 0.1
A tool and framework for tutorials in game development
Loading...
Searching...
No Matches
SceneCreatorEditor Class Reference

Provides an editor window for creating new Unity scenes by duplicating a base scene. Allows users to specify the new scene name and base scene, checks for unsaved changes in the current scene, and adds the new scene to the build settings. More...

Inheritance diagram for SceneCreatorEditor:

Protected Member Functions

void CheckAndCreateScene ()
 Checks whether the current scene has unsaved changes and prompts the user to save them before creating a new scene. Prevents scene creation in play mode or without a specified scene name.
 
void CreateScene ()
 Creates a new scene by duplicating the specified base scene. Opens the new scene and adds it to the build settings.
 
void CopyAndMakeNewScene (string path, string newScenePath)
 Copies a scene from the given path and saves it at the specified new scene path. Refreshes the AssetDatabase after the operation.
 

Static Private Member Functions

static void Init ()
 Initializes the editor window and sets the default new scene name.
 

Detailed Description

Provides an editor window for creating new Unity scenes by duplicating a base scene. Allows users to specify the new scene name and base scene, checks for unsaved changes in the current scene, and adds the new scene to the build settings.

Definition at line 13 of file SceneCreatorEditor.cs.

Member Function Documentation

◆ CopyAndMakeNewScene()

void CopyAndMakeNewScene ( string path,
string newScenePath )
protected

Copies a scene from the given path and saves it at the specified new scene path. Refreshes the AssetDatabase after the operation.

Parameters
pathPath to the scene to copy.
newScenePathDestination path for the new scene.

Definition at line 117 of file SceneCreatorEditor.cs.


The documentation for this class was generated from the following file: