MCPcopy Create free account
hub / github.com/FlaxEngine/FlaxEngine / NewProject

Method NewProject

Source/Editor/Editor.cs:801–813  ·  view source on GitHub ↗

Creates the given project. Afterwards closes this project with running editor and opens the given project. The project file path.

(string projectFilePath)

Source from the content-addressed store, hash-verified

799 /// </summary>
800 /// <param name="projectFilePath">The project file path.</param>
801 public void NewProject(string projectFilePath)
802 {
803 if (projectFilePath == null)
804 {
805 MessageBox.Show("Missing project");
806 return;
807 }
808
809 // Cache project path and start editor exit (it will open new instance on valid closing)
810 _projectToOpen = StringUtils.NormalizePath(Path.GetDirectoryName(projectFilePath));
811 _projectIsNew = true;
812 Windows.MainWindow.Close(ClosingReason.User);
813 }
814
815 /// <summary>
816 /// Closes this project with running editor and opens the given project.

Callers

nothing calls this directly

Calls 4

GetDirectoryNameMethod · 0.80
ShowMethod · 0.45
NormalizePathMethod · 0.45
CloseMethod · 0.45

Tested by

no test coverage detected