public static void ShowInfo(Type infoType)
        {
            InfoAttribute infoAttribute = infoType.GetCustomAttribute <InfoAttribute>();

            if (infoAttribute == null)
            {
                throw new Exception("Info attribute not found");
            }
            if (infoAttribute.Editor)
            {
                FortScriptableObject fortScriptableObject =
                    AssetDatabase.LoadAssetAtPath <FortScriptableObject>(GetInfoLocation(infoType));
                if (fortScriptableObject == null)
                {
                    Resolve(infoType).Save();
                    fortScriptableObject =
                        AssetDatabase.LoadAssetAtPath <FortScriptableObject>(GetInfoLocation(infoType));
                }
                Selection.activeObject = fortScriptableObject;
            }
            else
            {
                FortScriptableObject fortScriptableObject = Resources.Load <FortScriptableObject>(InfoResolver.GetInfoResourceRelativeLocation(infoType));
                if (fortScriptableObject == null)
                {
                    InfoResolver.Resolve(infoType).Save();
                    fortScriptableObject = Resources.Load <FortScriptableObject>(InfoResolver.GetInfoResourceRelativeLocation(infoType));
                }
                Selection.activeObject = fortScriptableObject;
            }
        }
        public static void Save(Type infoType, IInfo info)
        {
            InfoAttribute infoAttribute = infoType.GetCustomAttribute <InfoAttribute>();

            if (infoAttribute == null)
            {
                throw new Exception("Info attribute not found");
            }
            if (infoAttribute.Editor)
            {
                string infoLocation          = GetInfoLocation(infoType);
                string resourceDirectoryName = Path.GetDirectoryName(infoLocation);
                AssetDatabaseHelper.CreateFolderRecursive(resourceDirectoryName);
                FortScriptableObject fortScriptableObject =
                    AssetDatabase.LoadAssetAtPath <FortScriptableObject>(infoLocation);
                bool newCreation = false;
                if (fortScriptableObject == null)
                {
                    fortScriptableObject = (FortScriptableObject)ScriptableObject.CreateInstance(infoAttribute.ScriptableType);
                    AssetDatabase.CreateAsset(fortScriptableObject, infoLocation);
                    newCreation = true;
                }
                if (!newCreation)
                {
                    fortScriptableObject.Save(info);
                    EditorUtility.SetDirty(fortScriptableObject);
                }
            }
            else
            {
                FortScriptableObject fortInfoScriptable = Resources.Load <FortScriptableObject>(InfoResolver.GetInfoResourceRelativeLocation(infoType));
                bool newCreation = false;

                if (fortInfoScriptable == null)
                {
                    string infoResourceFullLocation = InfoResolver.GetInfoResourceFullLocation(infoType);
                    string resourceDirectoryName    = Path.GetDirectoryName(infoResourceFullLocation);
                    AssetDatabaseHelper.CreateFolderRecursive(resourceDirectoryName);

                    fortInfoScriptable = (FortScriptableObject)ScriptableObject.CreateInstance(infoAttribute.ScriptableType);
                    AssetDatabase.CreateAsset(fortInfoScriptable, infoResourceFullLocation);
                    newCreation = true;
                }
                if (!newCreation)
                {
                    fortInfoScriptable.Save(info);
                    EditorUtility.SetDirty(fortInfoScriptable);
                }
            }
        }