public static ComponentType AddOrGet <ComponentType>(this GameObject go) where ComponentType : Component
    {
        ComponentType val = go.GetComponent <ComponentType>();

        if ((UnityEngine.Object)val == (UnityEngine.Object)null)
        {
            val = go.AddComponent <ComponentType>();
        }
        KMonoBehaviour kMonoBehaviour = val as KMonoBehaviour;

        if ((UnityEngine.Object)kMonoBehaviour != (UnityEngine.Object)null)
        {
            kMonoBehaviour.CreateDef();
        }
        return(val);
    }