Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .github/workflows/upm-subtree-split.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,5 +13,5 @@ jobs:
fetch-depth: 0
- name: upm subtree split
run: |
git subtree split --prefix="ProjectName/Packages/com.projectscope.projectname" -b upm
git subtree split --prefix="OpenAI/Packages/com.openai.unity" -b upm
git push -u origin upm --force
Empty file added .gitmodules
Empty file.
125 changes: 0 additions & 125 deletions InitializeTemplate.ps1

This file was deleted.

2 changes: 1 addition & 1 deletion LICENSE.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
MIT License

Copyright (c) #CURRENT_YEAR# ProjectAuthor
Copyright (c) 2021 Stephen Hodgson

Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
Expand Down
File renamed without changes.
File renamed without changes.
7 changes: 7 additions & 0 deletions OpenAI/Assets/csc.rsp.meta

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

7 changes: 7 additions & 0 deletions OpenAI/Packages/com.openai.unity/CHANGELOG.md.meta

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
8 changes: 8 additions & 0 deletions OpenAI/Packages/com.openai.unity/Editor.meta

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

11 changes: 11 additions & 0 deletions OpenAI/Packages/com.openai.unity/Editor/AssemblyInfo.cs.meta

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

17 changes: 17 additions & 0 deletions OpenAI/Packages/com.openai.unity/Editor/OpenAI.Editor.asmdef
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
{
"name": "OpenAI.Editor",
"references": [
"GUID:3248779d86bd31747b5d2214f30b01ac"
],
"includePlatforms": [
"Editor"
],
"excludePlatforms": [],
"allowUnsafeCode": false,
"overrideReferences": false,
"precompiledReferences": [],
"autoReferenced": true,
"defineConstraints": [],
"versionDefines": [],
"noEngineReferences": false
}

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Original file line number Diff line number Diff line change
@@ -0,0 +1,44 @@
// Licensed under the MIT License. See LICENSE in the project root for license information.

using System.IO;
using UnityEditor;

namespace OpenAI.Editor
{
[CustomEditor(typeof(OpenAIConfigurationSettings))]
internal class OpenAIConfigurationSettingsInspector : UnityEditor.Editor
{
private void OnEnable()
{
var update = false;
var currentPath = AssetDatabase.GetAssetPath(target);

if (string.IsNullOrWhiteSpace(currentPath))
{
return;
}

if (!Directory.Exists("Assets/Resources"))
{
Directory.CreateDirectory("Assets/Resources");
update = true;
}

if (!currentPath.Contains("Resources"))
{
File.Move(Path.GetFullPath(currentPath), Path.GetFullPath($"Assets/Resources/{target.name}.asset"));
File.Move(Path.GetFullPath($"{currentPath}.meta"), Path.GetFullPath($"Assets/Resources/{target.name}.asset.meta"));
update = true;
}

if (update)
{
EditorApplication.delayCall += () =>
{
AssetDatabase.Refresh(ImportAssetOptions.ForceUpdate);
EditorGUIUtility.PingObject(target);
};
}
}
}
}

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
MIT License

Copyright (c) #CURRENT_YEAR# ProjectAuthor
Copyright (c) 2021 Stephen Hodgson

Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
Expand Down
7 changes: 7 additions & 0 deletions OpenAI/Packages/com.openai.unity/LICENSE.md.meta

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Loading