Open holke opened 4 years ago
Started by renaming all levels. The names don’t have numbers anymore.
I am not done yet xD
Ups 😬 Ich dachte du wolltest es in zwei requests aufteilen
Von meinem Telefon gesendet
Am 01.05.2020 um 21:08 schrieb holke notifications@github.com:
I am not done yet xD
— You are receiving this because you modified the open/close state. Reply to this email directly, view it on GitHub, or unsubscribe.
Maybe the merge request closed the issue automatically? I will split this in 2 mr, so it was good that the first mr is merged.
If you link this to the merge request the mr closes the issue automatically.
I see, that’s annoying.
It would also be possible to use directories for the different scenes which really makes it easier to find stuff. And you do not have to give unity the whole path, it still finds the scene. Maybe we should use directories for the levels and the scripts that belong to the levels in the script and scene folder, respectively.
yes we should. It starts to get crowded.
This
NextLevel = LevelList.GetNextLevel("CollectMasks"); UnityEngine.SceneManagement.SceneManager.LoadScene(NextLevel);
is more or less exactly what we are doing now in the new Menu.
It is not necessary to give the level a specific name for this.
Unity knows the order form the build settings and we can navigate to the current, next (and previous) level that way.
We still have some
if levelname == STRING
constructs in the code that i would love to eliminate.
We first implemented level3 and then decided to change level3 to level4. This means that we have to rename some ~20 scripts, classes and game objects from "level3" to "level4". This is a tedious and error prone process and we should avoid having to do this again in the future, when we decide to squeeze in another level.
I suggest that we use a different naming scheme for our levels that is more robust against adding new levels in between.
How about:
but instead something like