Scenes - kagenocookie/ReachForGodot GitHub Wiki
Scenes (.scn files) are used to store all the game levels and in some cases item/data/characters as well by RE Engine titles, and are therefore the most important file for map editing.
Import the .scn
file you wish to edit by any method described in Asset management. If you know the specific area/scenario file you wish to edit, that's the best starting point. .scn
files get imported as Godot .tscn
files that you can then open in the editor and navigate to any nested scene files from there. Find the .tscn file from the Godot file system and double click to open it.
Newly created scenes will not always be fully loaded in because some data doesn't immediately get populated. In these cases, selecting the root folder node and pressing Import should finish setting up anything that's still missing. Nested scenes are also imported only on demand, either by using the "nested scene" import options, or by importing the specific individual scenes.
Import options
There are several import options to choose from so you don't need to wait for the whole game to convert:
- Discard and reimport: (the default option) The full tree will be recreated from the source .scn file, but meshes and other assets will be kept and reused
- The "this scene" option will only do this for the current scene, while creating placeholders or reusing any linked .scn files
- The "nested scenes" option will also do the same for any linked .scn files, otherwise those will be reused when possible.
- Import missing objects: Will try and keep any existing tree changes unchanged, while adding anything from the imported .scn file that's still missing. GameObject and component data will be overwritten from the imported file when a match is found.
- The "this scene" option will only do this for the current scene, while creating placeholders or reusing any linked .scn files
- The "nested scenes" option will also do the same for any linked .scn files, otherwise those will be reused when possible
- Placeholders: will generate the absolute minimal structure with only gameobjects owned by the scene, with no components, and only placeholders for any subfolders. Not all data is included here and exported files will not be fully complete.
- Force reimport: same as "Discard and reimport", except that any meshes and other assets will also be reimported instead of being reused
Tooling additions
- Object template system
- Node context menu additions:
- "Reposition camera to center" will reposition to camera to the center of the folder's detected bounds
- "Toggle proxy subfolders" will toggle the visibility state of all subfolder proxy nodes
- "Make/revert child scenes editable" will toggle the "editable children" setting of all folders below it. This makes it possible to edit linked scenes within the context of where it's actually used
- Inspector button additions:
- Import and export buttons
- "Recalc bounds": will recalculate the folder's AABB bounds for the repositioning feature
- "Add/Remove proxy": will swap this folder with a proxy node or reverse the operation
- "Save child scene changes": for folders with "Editable Children" enabled, will overwrite the source scene with whatever changes were done to it
Notes
- nested scn files can be imported using a proxy node system and linked through PackedScenes, to mitigate editor performance dying due to having too much stuff loaded at once. The threshold of child node count at which a proxy node is created by default can be configured from the editor settings
- to make the proxy folder's contents show, use the Show Linked Folder checkbox or use the Toggle subfolders context menu item
- except when doing Placeholders import, all prefabs and gameobjects linked from scn files will automatically be imported
- the "Reposition to scene center" context menu item will move the editor camera to the center of a scene's bounds since positions aren't always centered around (0,0,0)
- this is mainly a concern with the open world games (DD2, MHWs) since they're all over the coordinate system
- if the button isn't working, check the "Known Bounds" value - if it's all 0, try opening the scene file directly in editor, as well as the "Recalc bounds" button to make the values properly reflect. If it's still all 0, it might just not have any visual nodes inside it or it wasn't fully imported