-
Notifications
You must be signed in to change notification settings - Fork 0
Master Manager
The Master Manager handles transitioning between the different states of the project, like the edit and play states.
List of connecting/parent/subsystems.
Connecting Systems: This system only consists of subsystems.
Subsystems:
List of related controls.
Key(s):
- Play Button: Shows the play scene when clicked
- Pause Button: Shows the edit scene when clicked
- Reset Button: Resets the play scene when clicked
List of known bugs. Be descriptive but keep it brief!
- The transition to the play scene does not fully close the edit scene, so tiles from there are invisible but can be interacted with. This will likely be fixed when carrying over tiles is implemented.
List of features and descriptions within system.
Feature Name:
- State Switch: Switches the state from editing/playing. This sets all flags and scenes as the user may expect when switching.
- Loading Screen Transitions: Displays a screen wipe animation before expensive state transitions begin and hides it only after the destination state has finished initializing.
- Saving and Loading Tilemaps: Saves and loads tilemaps from their resource in the user folder.
- Creating a Border: Creates a border around the buildable grid.
Name the most important variables, their type, and what their purpose is
-
editorManager: Node2D= An exported reference to the editor manager. -
toolManager : Node2D= An exported reference to the tool manager. -
gameManager: Node2D= An exported reference to the game manager. -
entityManager: Node2D= An exported reference to the entity manager. -
audioManager: Node= An exported reference to the audio manager. -
cameraManager: Camera2D= An exported reference to the camera manager. -
editorManagerCanvas: CanvasLayer= An exported reference to the UI for the editor manager. -
gameManagerCanvas: CanvasLayer= An exported reference to the UI for the game manager. -
loadingScreen: CanvasLayer= An exported reference to the loading screen overlay used during state transitions. -
loadingAnimation: AnimationPlayer= An exported reference to the AnimationPlayer that controls the screen wipe animations. -
mainMenuControl: Control= An exported reference to the main menu control node.
Name of the most important functions, their parameters, and what they do.
-
func screen_wipe_in() -> void: Plays the screen wipe animation that covers the screen before expensive loading or initialization begins. -
func screen_wipe_out() -> void: Plays the screen wipe animation that reveals the destination state after loading has completed. -
func level_setup(levelName: String, newSize: Vector2i) -> void: Creates a new level by initializing the world size, camera, level data, and entering the edit state. -
func create_bedrock_border() -> void: Creates a border of unbreakable tiles around the buildable grid. -
func import_level_and_edit() -> void: Imports the selected level into the editor, restores saved properties, and transitions into the edit state. -
func edit() -> void: Transitions the project into the editor state, restoring editor UI, tools, and enemy positions. -
func play() -> void: Transitions the project into the play state, saves the current level, initializes gameplay, and loads the playable tilemap. -
func main_menu() -> void: Transitions the project into the main menu state, hides gameplay/editor systems, and refreshes the level list. -
func save_tilemap() -> void: Saves the editor tilemap as a PackedScene in the user folder. -
func load_tilemap() -> void: Loads the saved tilemap from the user folder into the Game Manager.
List and description of upcoming work/risks.
Future Work: None
Risks:
- None
A place for miscellaneous notes pertaining to this system.
- None
Resources
Known Issues
Future Work
Globals
Managers
- Main Menu Manager
- Master Manager
- Camera Manager
- Hotkey Manager
- Import Export Manager
- Audio Manager
- Animation Manager
- PopUp Manager
UI
Managers
- Editor Manager
- Tile Manager
- Entity Manager
- Icon Manager
- Preview Manager
- Tool Manager
- Asset Manager
- Custom Cursor Manager
Tiles & Entities
- Grid Lines
- Preview Line
- Tiles & Entities
- Enemies
- Patrolling Enemy
- Flying Enemy
- Shooting Enemy
- Stationary Enemy
- Moving Platform
- Property Editing
Asset Swapping
UI
Managers
Player