simvx.editor.project¶
Project Session — Scene I/O, project settings, and recent files.
Module Contents¶
Classes¶
Persistent project-level configuration stored in simvx.toml. |
|
Higher-level project and scene operations. |
Data¶
API¶
- simvx.editor.project.log¶
‘getLogger(…)’
- class simvx.editor.project.ProjectMetadata[source]¶
Persistent project-level configuration stored in simvx.toml.
- project_name: str¶
‘Untitled Project’
- default_scene: str = <Multiline-String>¶
- physics_fps: int¶
60
- window_width: int¶
1280
- window_height: int¶
720
- gravity: float¶
9.8
- engine_version: str = <Multiline-String>¶
- classmethod from_dict(data: dict) simvx.editor.project.ProjectMetadata[source]¶
Create from a dict, ignoring unknown keys for forward compat.
- class simvx.editor.project.ProjectSession[source]¶
Higher-level project and scene operations.
All public methods accept an State so the session stays stateless with respect to the scene — easy to test and re-entrant.
Initialization
- new_scene(state: simvx.editor.state.State) None[source]¶
Create a fresh scene with a single root Node3D.
- open_scene(state: simvx.editor.state.State) None[source]¶
Emit open_file_requested so the editor shows a FileDialog.
- save_scene(state: simvx.editor.state.State) bool[source]¶
Save directly if path exists, otherwise trigger save-as.
- save_scene_as(state: simvx.editor.state.State) None[source]¶
Emit save_file_requested so the editor shows a FileDialog.
- load_project(path: str | pathlib.Path) bool[source]¶
Load simvx.toml from directory path (or a direct file path).
- save_project(path: str | pathlib.Path) bool[source]¶
Save simvx.toml into directory path. Returns True on success.
- get_window_title(state: simvx.editor.state.State) str[source]¶
Return ‘SimVX Editor - scene_name*’ (asterisk if modified).
- static get_scene_node_count(state: simvx.editor.state.State) int[source]¶
Count every node in the current scene (including root).