xxxxxxxxxx
if (Input.GetKeyDown(KeyCode.R))
SceneManager.LoadScene( SceneManager.GetActiveScene().buildIndex ) ;
xxxxxxxxxx
//for unity c#
using UnityEngine.SceneManagement;
SceneManager.LoadScene(SceneManager.GetActiveScene().buildIndex);
xxxxxxxxxx
if (Input.GetKeyDown(KeyCode.R))
SceneManager.LoadScene( SceneManager.GetActiveScene().buildIndex ) ;