Hello everyone.

The Mixed Reality Forums here are no longer being used or maintained.

There are a few other places we would like to direct you to for support, both from Microsoft and from the community.

The first way we want to connect with you is our mixed reality developer program, which you can sign up for at https://aka.ms/IWantMR.

For technical questions, please use Stack Overflow, and tag your questions using either hololens or windows-mixed-reality.

If you want to join in discussions, please do so in the HoloDevelopers Slack, which you can join by going to https://aka.ms/holodevelopers, or in our Microsoft Tech Communities forums at https://techcommunity.microsoft.com/t5/mixed-reality/ct-p/MicrosoftMixedReality.

And always feel free to hit us up on Twitter @MxdRealityDev.
Options

Material changes after LoadScene

Hey everyone,
I'm currently trying to load a scene which has a gameObject with a specific material attached to in it. If I start the scene itself, it works perfectly well and the material can be seen. However, I want to start the game by pressing a button on a menu screen. Therefore, I'm loading the scene with the gameobject after the scene was chosen from the start menu. The problem is: If I start the game this way, the material is somehow lost and my gameobject is just black. This is the code for the Sceneload:
public void Level1()
{
SceneManager.LoadScene("Spider_baker_2");
}
public void DemoLevel()
{
SceneManager.LoadScene("Level_0");
}
public void EndScene()
{
SceneManager.UnloadSceneAsync("Menu 3D");
}

It tried to use Scenemode.Additive, but then another issue occurs, since I can't instantiate more instances of my singleton classes from the menu scene. If I then try to develop it for the HoloLens, the application crashes completey, so I'd rather stay away from the Scenemode.Additive.
Has anyone ever had this issue?

Answers

  • Options

    Where is the material in your project Hierarchy? Make sure it is under the Resources folder to be included. Also make sure in your build properties that each of these scenes are checked to be included in the project.

    Taqtile

Sign In or Register to comment.