I need to make the following as the default template of my new C# scripts added in Unity Editor.
using System.Collections;
using System.Collections.Generic;
using UnityEngine;
namespace ProjectName
{
public class ScriptName: MonoBehaviour
{
/// <summary>
///
/// </summary>
#region Fields
#endregion
#region MonoBehaviour Messages
void Start()
{
}
void Update()
{
}
#endregion
#region Methods
#endregion
}
}
The ProjectName is a constant for all scripts, while ScriptName is defined on script asset creation.
I tried using UnityEditor documentation and checked this question "Unity Add Default Namespace to Script Template?" but couldn't implement the above template
but couldn't implement the above template- why not? Any errors/ unexpected behaviour?