pip install -r requirements.txt
12 |
13 | ## Manual
14 | NOTE: Currently the editor is heavily work in progress so things may change later
15 |
16 | ### Starting the editor
17 | To start the Scene Editor, simply run the main.py script
18 |
19 | python main.py
20 |
21 | ### Shortcuts
22 | #### Basic
23 | |shortcut|action|
24 | |---|---|
25 | |Ctrl-Q|Quit the editor|
26 | |Ctrl-N|New Scene|
27 | |Ctrl-O|Open Scene from JSON format|
28 | |Ctrl-S|Save Scene to JSON format|
29 | |Ctrl-E|Export Scene to Python format|
30 |
31 | #### Navigation
32 | Navigating the scene is similar to Blender in that you can move around with the mouse.
33 | |shortcut|action|
34 | |---|---|
35 | |Middle mouse button|Rotate around pivot|
36 | |Shift + Middle mouse button|Pan|
37 | |mouse wheel|Zoom|
38 | |Left mouse button|Select|
39 | |Shift + Left mouse button|Multiselect|
40 | |Ctrl-G|Toggle grid|
41 | |5|Toggle Perspective/Orthographic lense|
42 | |7|Show top|
43 | |Ctrl-7|Show bottom|
44 | |1|Show front|
45 | |Ctrl-1|Show back|
46 | |3|Show right|
47 | |Ctrl-3|Show left|
48 |
49 | #### Editing
50 | |shortcut|action|
51 | |---|---|
52 | |G|Move selected objects|
53 | |R|Rotate selected objects around objects center|
54 | |S|Scale selected objects|
55 | |X, Y and Z|During moving and rotating clips to the respective axis|
56 | |Del|Remove objects|
57 | |Ctrl-Z|Undo|
58 | |Ctrl-Y|Redo|
59 | |Ctrl-Shift-Y|Switch between redo branches|
60 | |C|Show collision solids|
61 | |H|Toggle model hidden status|
62 | |Ctrl-C|Copy|
63 | |Ctrl-X|Cut|
64 | |Ctrl-V|Paste (makes last selected object parent or render if none is selected)|
65 | |Page Up|Increase objects sort value|
66 | |Page Down|Decrease objects sort value|
67 |
68 | ### Save and export
69 | To save The Scene as a project file, hit Ctrl-S or the respective button in the toolbar.
70 | This will save a Json file that can later be loaded by the editor again.
71 |
72 | To export as a python script that can directly be used in projects, either hit Ctrl-E or click the button in the toolbar.
73 |
74 | ### Use exported scripts
75 | The python script will always contain a class called Scene which you can pass a NodePath to be used as root parent element for the scene. Simply instancing the class will load and show the scene by default. If this is not desired, hide the root NodePath as given on initialization. As you shouldn't edit the exported class due to edits being overwritten with a new export, you should create another python module which will handle the logic for the scene. This dedicated module could for example implement a show and hide method to easily change the visibility of the scene. All objects can be accessed from the instantiated scene by their name with special characters being replaced with an underscore.
76 |
77 | Here is a small example of how to load and instantiate a Scene. We expect the scene to be exported to a file called myScene.py and contain a model named panda:
78 | from myScene import Scene as MyScene
79 | myScene = MyScene()
80 | myScene.panda.set_pos(0,0,0)
81 |
82 |
83 | ## Screenshots
84 |