Add Loading Screen in MFPS 2.0
Posted: Wed Aug 14, 2019 9:04 pm
Some people have been asking me how to integrate my Loading Screen asset in MFPS, even though the procedure is the same as in any other project, I am going to publish the simple steps here:
1 - Import the Loading Screen package from the Asset Store into your MFPS Unity Project.
2 - Add and Setup all your game scenes in SceneLoaderManager (Check the Loading Screen documentation for more info)
3 - In the MainMenu scene Select and Drag one of the SceneLoaders prefabs into the Canvas object:
4 - in bl_Lobby.cs -> IEnumerator MoveToGameScene() -> replace or comment this line:
And add this:
Since version 1.6 of MFPS, there's a new feature "Waiting Room", so if you are using that feature you also have to change this:
in bl_WaitingRoom.cs -> LoadMap() ->
Replace:
with:
That's
1 - Import the Loading Screen package from the Asset Store into your MFPS Unity Project.
2 - Add and Setup all your game scenes in SceneLoaderManager (Check the Loading Screen documentation for more info)
3 - In the MainMenu scene Select and Drag one of the SceneLoaders prefabs into the Canvas object:
4 - in bl_Lobby.cs -> IEnumerator MoveToGameScene() -> replace or comment this line:
Code: Select all
bl_UtilityHelper.LoadLevel((string)PhotonNetwork.CurrentRoom.CustomProperties[PropertiesKeys.SceneNameKey]);
Code: Select all
bl_SceneLoaderUtils.GetLoader.LoadLevel((string)PhotonNetwork.CurrentRoom.CustomProperties[PropertiesKeys.SceneNameKey]);
Since version 1.6 of MFPS, there's a new feature "Waiting Room", so if you are using that feature you also have to change this:
in bl_WaitingRoom.cs -> LoadMap() ->
Replace:
Code: Select all
bl_UtilityHelper.LoadLevel((string)PhotonNetwork.CurrentRoom.CustomProperties[PropertiesKeys.SceneNameKey]);
Code: Select all
bl_SceneLoaderUtils.GetLoader.LoadLevel((string)PhotonNetwork.CurrentRoom.CustomProperties[PropertiesKeys.SceneNameKey]);