StompyRobot / StompyRobot.TypeSafe

TypeSafe generates strong-typed static classes for Unity resources.
https://stompyrobot.uk/tools/typesafe/
MIT License
27 stars 1 forks source link

Using a scenelist that is different from the build settings causes an index mismatch #2

Open Bmandk opened 1 year ago

Bmandk commented 1 year ago

It is not uncommon for devs to not use the build settings, instead opting to create their own build tools. In my game, I have created a build script that uses a scene list that is different from the ones listed in build settings. Since TypeSafe uses the build settings scenes to create the types, they will mismatch from what is actually in the build.

While there are workarounds (use e.g. SRScenes.MainMenu.name instead of SRScenes.MainMenu), it caused quite some confusion initially and more lost time than should have been necessary to debug this issue.