- Home /
Loading a scene from an external source
Hey guys,
So I'm trying to make a script that displays all the .unity scene files in an external folder, which it does but then open the scene once clicked. The only part I'm stuck on is the opeing scene part.
I'm trying to use EditorApplication.OpenScene(Path) but because its editor I need to put my script in the editor folder which I've now done. But I'm now presented with a new issue. When I run the game the script doesn't run and throws a warning that says the class defined isn't derived from monobehaviour. I'm using Jscript and am not sure how to fix this.
Basically I'm going to make it so players of the game can create their own scene and place predefined prefabs in the scene, save it then upload it for others. The first part I'm working on is opening the scenes, but as said above I have a problem.
Any ideas?
Cheers.