Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add GamePlus-Editor as default level editor #753

Closed
wants to merge 4 commits into from

Conversation

ShivamKR12
Copy link

@ShivamKR12 ShivamKR12 commented Jan 31, 2025

Integrate a custom level editor based on GamePlus-Editor into the project.

  • Add level_editor/editor.py to handle the main UI and logic for level editing.
  • Add level_editor/file_manager.py to manage level saving/loading.
  • Add level_editor/main.py to launch the editor from the game menu.
  • Add level_editor/ui/editor_window.py to create the editor window UI.
  • Add level_editor/ui/tool_panel.py to create the tool panel UI.
  • Add level_editor/tools/object_placer.py to implement the object placer tool.
  • Add level_editor/tools/object_scaler.py to implement the object scaler tool.
  • Add level_editor/tools/object_rotator.py to implement the object rotator tool.
  • Add level_editor/data/level_loader.py to handle level file loading.
  • Add level_editor/data/level_saver.py to handle level file saving.
  • Modify samples/main_menu.py to add an option in the game’s menu to launch the editor.

For more details, open the Copilot Workspace session.

Integrate a custom level editor based on GamePlus-Editor into the project.

* Add `level_editor/editor.py` to handle the main UI and logic for level editing.
* Add `level_editor/file_manager.py` to manage level saving/loading.
* Add `level_editor/main.py` to launch the editor from the game menu.
* Add `level_editor/ui/editor_window.py` to create the editor window UI.
* Add `level_editor/ui/tool_panel.py` to create the tool panel UI.
* Add `level_editor/tools/object_placer.py` to implement the object placer tool.
* Add `level_editor/tools/object_scaler.py` to implement the object scaler tool.
* Add `level_editor/tools/object_rotator.py` to implement the object rotator tool.
* Add `level_editor/data/level_loader.py` to handle level file loading.
* Add `level_editor/data/level_saver.py` to handle level file saving.
* Modify `samples/main_menu.py` to add an option in the game’s menu to launch the editor.

---

For more details, open the [Copilot Workspace session](https://copilot-workspace.githubnext.com/pokepetter/ursina?shareId=XXXX-XXXX-XXXX-XXXX).
* Add `modify_object` method to `LevelEditor` class in `level_editor/editor.py`
* Add `start_level_editor` function in `level_editor/main.py`
* Add `create_layout` method and buttons for placing, scaling, and rotating objects in `level_editor/ui/editor_window.py`
* Add `enable`, `start_scaling`, `perform_scaling`, and `stop_scaling` methods to `ObjectScaler` class in `level_editor/tools/object_scaler.py`
* Add `enable`, `start_rotating`, `perform_rotating`, and `stop_rotating` methods to `ObjectRotator` class in `level_editor/tools/object_rotator.py`
* **UrsinaEditor class**
  - Implement methods for starting, saving, and exporting projects
  - Add methods for setting up the editor, handling project data, and managing project editors
  - Include methods for adding different types of editors (Scene, Python Code, UrsaVisor)
  - Add methods for playing and hosting projects

* **BaseRunner function**
  - Initialize and run the UrsinaEditor

* **Imports**
  - Add necessary imports for the new functionality
* Ensure the `re` module is imported correctly
@pokepetter pokepetter closed this Feb 1, 2025
@ShivamKR12 ShivamKR12 deleted the add-gameplus-editor branch February 2, 2025 12:49
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants