Now that the basic UI is set up, I've started working on level management. I had a tough choice to make with how I'm managing levels, but I think my decision is the optimal one.
DILEMMA: How do I set up my level management to be scalable long term?
- Option 1: Make each game level as an individual Scene.
- Pros:
- Simple and clean to load
- Easy to tune individual level layouts
- Cons:
- End up with MANY Scene files.
- Have to add the Scene files to the Build Settings or face a build break (scary!!!)
- Have to set up necessary prefabs and components for each Scene, like managers, ui, etc.
- Could be mitigated with a primary prefab that contains all of that anyway. Just seems like a hassle.
- Option 2: Set each level as a Prefab instance, and manage everything in a single Scene.
- Pros:
- Less build/Scene management
- Easier level loading/testing
- Easier course/level data setup and management
- Cons:
- A little trickier to debug/edit each level (need to do it in the prefab, or push overrides)
- I can mitigate this with some debug tools
- Possibility for some manager wonkiness between level loads.
I'm going with Option 2! When I go to make a new level, I want as little in my way as possible to set it up and get playing. I also don't like the idea of having a million scenes in my project.
Now how am I to structure my level management? I hit up my old whiteboarding friend Miro to work things out.
Getting the scriptable objects set up for Course and Levels took 10 minutes, maybe. Making a new Level Manager and UI Manager to run the level loading and UI updates properly took a lot longer.
I needed to do a bunch of updates to the Player Manager, and add necessary signal dispatches to make sure Levels and the Player Ball were spawning correctly based on the data. Then I ran through and made sure the UI was updating correctly. I also moved a bunch of small UI scripts into my main UI Manager for ease of use.
I needed to do a bunch of updates to the Player Manager, and add necessary signal dispatches to make sure Levels and the Player Ball were spawning correctly based on the data. Then I ran through and made sure the UI was updating correctly. I also moved a bunch of small UI scripts into my main UI Manager for ease of use.
It's now all working, and currently bug free! See the video below for progress!
Next up on my list are the following:
- Detail out level design metrics and tune gameplay
- Create level building blocks (with updated visuals)
- Build a suite of levels to test out!
Stay tuned for more!
No comments:
Post a Comment