Skip to content

Commit 4dc7452

Browse files
Merge pull request #152 from SideQuestVR/dev
Dev
2 parents c75593e + dd15d19 commit 4dc7452

711 files changed

Lines changed: 53694 additions & 133073 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

.claude/settings.local.json

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
{
2+
"permissions": {
3+
"allow": [
4+
"Bash(git log:*)"
5+
],
6+
"deny": [],
7+
"ask": []
8+
}
9+
}

.gitattributes

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1 +1,2 @@
11
Editor/banter-link/banter-link.exe filter=lfs diff=lfs merge=lfs -text
2+
OraPackage/com.sidequest.ora.zip filter=lfs diff=lfs merge=lfs -text

.gitignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -73,3 +73,4 @@ crashlytics-build.properties
7373

7474
# Samples.meta is auto created if Samples~ becomes Samples
7575
Samples.meta
76+
node_modules

Editor/Banter.SDKEditor.asmdef

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,7 @@
33
"rootNamespace": "Banter.SDKEditor",
44
"references": [
55
"GUID:478a2357cc57436488a56e564b08d223",
6+
"GUID:96338e729defced4d8d19cacd9eb0503",
67
"GUID:21b0c8d1703a94250bfac916590cea4f",
78
"GUID:54cb1906aeb4e4264bc1d2aa3818a43f",
89
"GUID:ea715009a4efd4c6cbc85be3ae097dd3",
@@ -13,7 +14,8 @@
1314
"GUID:f06555f75b070af458a003d92f9efb00",
1415
"GUID:7cd3a65c85d0c264eb3581defd7f2c63",
1516
"GUID:b4ae365a73764ee478adc74cb89832fe",
16-
"GUID:dde09067b7f7a054ca208a3c17c8f7c5"
17+
"GUID:dde09067b7f7a054ca208a3c17c8f7c5",
18+
"GUID:fe5c9d210f6859a4eac877d630830953"
1719
],
1820
"includePlatforms": [
1921
"Editor"

Editor/BanterObjectIdEditor.cs

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,6 @@ public override VisualElement CreateInspectorGUI()
2323
script.ForceGenerateId();
2424
myInspector.Q<TextField>("id").value = script.Id;
2525
EditorUtility.SetDirty(script);
26-
Debug.Log(EditorUtility.IsPersistent(script));
2726
PrefabUtility.RecordPrefabInstancePropertyModifications(script);
2827
});
2928
return myInspector;
Lines changed: 55 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,55 @@
1+
using UnityEditor;
2+
using UnityEngine;
3+
using UnityEngine.UIElements;
4+
using Banter.SDK;
5+
6+
namespace Banter.SDKEditor
7+
{
8+
[CustomEditor(typeof(BanterAOBaking))]
9+
public class BanterAOBakingEditor : Editor
10+
{
11+
void OnEnable()
12+
{
13+
if (target is BanterAOBaking)
14+
{
15+
var script = (BanterAOBaking)target;
16+
// script.gameObject.GetComponent<MeshFilter>().hideFlags = HideFlags.HideInInspector;
17+
var path = AssetDatabase.GetAssetPath(script);
18+
}
19+
}
20+
public override bool UseDefaultMargins() => false;
21+
public override VisualElement CreateInspectorGUI()
22+
{
23+
var script = (BanterAOBaking)target;
24+
Editor editor = Editor.CreateEditor(script);
25+
// script.gameObject.GetComponent<MeshFilter>().hideFlags = HideFlags.HideInInspector;
26+
VisualElement myInspector = new VisualElement();
27+
28+
var _mainWindowStyleSheet = Resources.Load<StyleSheet>("BanterCustomInspector");
29+
myInspector.styleSheets.Add(_mainWindowStyleSheet);
30+
31+
var title = new Label("PROPERTIES SEEN BY JS");
32+
title.style.fontSize = 14;
33+
myInspector.Add(title);
34+
var seeFields = new Label("subdivisionLevel, sampleCount, aoIntensity, aoBias, aoRadius, hideSourceObjects, targetShaderName, isProcessing, progress, ");
35+
seeFields.style.unityFontStyleAndWeight = FontStyle.Bold;
36+
seeFields.style.flexWrap = Wrap.Wrap;
37+
seeFields.style.whiteSpace = WhiteSpace.Normal;
38+
seeFields.style.marginBottom = 10;
39+
seeFields.style.marginTop = 10;
40+
seeFields.style.color = Color.gray;
41+
myInspector.Add(seeFields);
42+
43+
//#if BANTER_EDITOR
44+
var foldout = new Foldout();
45+
foldout.text = "Available Properties";
46+
IMGUIContainer inspectorIMGUI = new IMGUIContainer(() => { editor.OnInspectorGUI(); });
47+
foldout.value = false;
48+
foldout.Add(inspectorIMGUI);
49+
myInspector.Add(foldout);
50+
//#endif
51+
52+
return myInspector;
53+
}
54+
}
55+
}

Editor/Components/BanterAOBakingEditor.cs.meta

Lines changed: 2 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.
Lines changed: 55 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,55 @@
1+
using UnityEditor;
2+
using UnityEngine;
3+
using UnityEngine.UIElements;
4+
using Banter.SDK;
5+
6+
namespace Banter.SDKEditor
7+
{
8+
[CustomEditor(typeof(BanterApple))]
9+
public class BanterAppleEditor : Editor
10+
{
11+
void OnEnable()
12+
{
13+
if (target is BanterApple)
14+
{
15+
var script = (BanterApple)target;
16+
// script.gameObject.GetComponent<MeshFilter>().hideFlags = HideFlags.HideInInspector;
17+
var path = AssetDatabase.GetAssetPath(script);
18+
}
19+
}
20+
public override bool UseDefaultMargins() => false;
21+
public override VisualElement CreateInspectorGUI()
22+
{
23+
var script = (BanterApple)target;
24+
Editor editor = Editor.CreateEditor(script);
25+
// script.gameObject.GetComponent<MeshFilter>().hideFlags = HideFlags.HideInInspector;
26+
VisualElement myInspector = new VisualElement();
27+
28+
var _mainWindowStyleSheet = Resources.Load<StyleSheet>("BanterCustomInspector");
29+
myInspector.styleSheets.Add(_mainWindowStyleSheet);
30+
31+
var title = new Label("PROPERTIES SEEN BY JS");
32+
title.style.fontSize = 14;
33+
myInspector.Add(title);
34+
var seeFields = new Label("stacks, slices, ");
35+
seeFields.style.unityFontStyleAndWeight = FontStyle.Bold;
36+
seeFields.style.flexWrap = Wrap.Wrap;
37+
seeFields.style.whiteSpace = WhiteSpace.Normal;
38+
seeFields.style.marginBottom = 10;
39+
seeFields.style.marginTop = 10;
40+
seeFields.style.color = Color.gray;
41+
myInspector.Add(seeFields);
42+
43+
//#if BANTER_EDITOR
44+
var foldout = new Foldout();
45+
foldout.text = "Available Properties";
46+
IMGUIContainer inspectorIMGUI = new IMGUIContainer(() => { editor.OnInspectorGUI(); });
47+
foldout.value = false;
48+
foldout.Add(inspectorIMGUI);
49+
myInspector.Add(foldout);
50+
//#endif
51+
52+
return myInspector;
53+
}
54+
}
55+
}

Editor/Components/BanterAppleEditor.cs.meta

Lines changed: 2 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

Editor/Components/BanterAssetBundleEditor.cs.meta

Lines changed: 1 addition & 10 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)