├── .idea └── .idea.YukataScript │ └── .idea │ ├── .gitignore │ ├── encodings.xml │ ├── indexLayout.xml │ └── inspectionProfiles │ └── Project_Default.xml ├── Assembly-CSharp.csproj.DotSettings ├── Assets ├── Plugins.meta ├── Plugins │ ├── System.Runtime.CompilerServices.Unsafe.dll │ └── System.Runtime.CompilerServices.Unsafe.dll.meta ├── Scenes.meta ├── Scenes │ ├── RuntimeUI.unity │ ├── SampleScene.unity │ └── SampleScene.unity.meta ├── Scripts.meta ├── Scripts │ ├── DemoForBuild.cs │ ├── DemoForBuild.cs.meta │ ├── JsonTest.cs │ ├── JsonTest.cs.meta │ ├── MySettings.cs │ ├── MySettings.cs.meta │ ├── NewText.txt │ ├── NewText.txt.meta │ ├── UITest.cs │ ├── UITest.cs.meta │ ├── Variables.asset │ ├── Variables.asset.meta │ ├── VariablesObject.cs │ ├── VariablesObject.cs.meta │ ├── YSTest.cs │ ├── YSTest.cs.meta │ ├── conditions.ys.txt │ └── forLoop.ys.txt ├── UI Toolkit │ └── UnityThemes │ │ └── UnityDefaultRuntimeTheme.tss ├── YS.Generated.meta ├── YS.Generated │ ├── .editorconfig │ ├── CodeGenData.cs │ ├── CodeGenData.cs.meta │ ├── InspectorVariables.cs │ ├── InspectorVariables.cs.meta │ ├── Modules.meta │ ├── Modules │ │ ├── .editorconfig │ │ ├── Wrapper.System.Enum.cs │ │ ├── Wrapper.System.Enum.cs.meta │ │ ├── Wrapper.UnityEngine.AnimationCurve.cs │ │ ├── Wrapper.UnityEngine.AnimationCurve.cs.meta │ │ ├── Wrapper.UnityEngine.Behaviour.cs │ │ ├── Wrapper.UnityEngine.Behaviour.cs.meta │ │ ├── Wrapper.UnityEngine.Color.cs │ │ ├── Wrapper.UnityEngine.Color.cs.meta │ │ ├── Wrapper.UnityEngine.Component.cs │ │ ├── Wrapper.UnityEngine.Component.cs.meta │ │ ├── Wrapper.UnityEngine.GameObject.cs │ │ ├── Wrapper.UnityEngine.GameObject.cs.meta │ │ ├── Wrapper.UnityEngine.Mathf.cs │ │ ├── Wrapper.UnityEngine.Mathf.cs.meta │ │ ├── Wrapper.UnityEngine.MonoBehaviour.cs │ │ ├── Wrapper.UnityEngine.MonoBehaviour.cs.meta │ │ ├── Wrapper.UnityEngine.Object.cs │ │ ├── Wrapper.UnityEngine.Object.cs.meta │ │ ├── Wrapper.UnityEngine.Renderer.cs │ │ ├── Wrapper.UnityEngine.Renderer.cs.meta │ │ ├── Wrapper.UnityEngine.SpriteRenderer.cs │ │ ├── Wrapper.UnityEngine.SpriteRenderer.cs.meta │ │ ├── Wrapper.UnityEngine.Time.cs │ │ ├── Wrapper.UnityEngine.Time.cs.meta │ │ ├── Wrapper.UnityEngine.Transform.cs │ │ ├── Wrapper.UnityEngine.Transform.cs.meta │ │ ├── Wrapper.UnityEngine.Vector3.cs │ │ ├── Wrapper.UnityEngine.Vector3.cs.meta │ │ ├── Wrapper.YS.EasingType.cs │ │ ├── Wrapper.YS.Timer.cs │ │ ├── Wrapper.YS.Timer.cs.meta │ │ ├── assembly_data.json │ │ ├── assembly_data.json.meta │ │ ├── type_data.json │ │ └── type_data.json.meta │ ├── Wrapper.RegisterModules.cs │ ├── Wrapper.cs │ └── Wrapper.cs.meta ├── YS.UI │ ├── Fields.cs │ ├── Fields.cs.meta │ ├── I.cs │ ├── I.cs.meta │ ├── New Panel Settings.asset │ ├── UITest.uxml │ └── inputfield.uss ├── YS.meta └── YS │ ├── Editor.meta │ ├── Editor │ ├── CodeGeneration.meta │ ├── CodeGeneration │ │ ├── WrapperGenerator.cs │ │ └── WrapperGenerator.cs.meta │ ├── LibraryWindow.cs │ ├── LibraryWindow.cs.meta │ ├── NamedVariableDrawer.cs │ ├── NamedVariableDrawer.cs.meta │ ├── Resources.meta │ ├── Resources │ │ ├── GenericIcon.png │ │ ├── GenericIcon.png.meta │ │ ├── namespaceIcon.png │ │ └── namespaceIcon.png.meta │ ├── TreeDropDown.cs │ ├── TreeDropDown.cs.meta │ ├── VariableDrawer.cs │ ├── VariableDrawer.cs.meta │ ├── WrapperGenerationWindow.cs │ ├── WrapperGenerationWindow.cs.meta │ ├── YS.Editor.asmdef │ └── YS.Editor.asmdef.meta │ ├── Runtime.meta │ └── Runtime │ ├── AST.meta │ ├── AST │ ├── Expressions.meta │ ├── Expressions │ │ ├── AssignExpression.cs │ │ ├── AssignExpression.cs.meta │ │ ├── AwaitExpression.cs │ │ ├── AwaitExpression.cs.meta │ │ ├── BinaryExpression.cs │ │ ├── BinaryExpression.cs.meta │ │ ├── BooleanLiteral.cs │ │ ├── BooleanLiteral.cs.meta │ │ ├── CallExpression.cs │ │ ├── CallExpression.cs.meta │ │ ├── CastExpression.cs │ │ ├── CastExpression.cs.meta │ │ ├── ConditionalExpression.cs │ │ ├── ConditionalExpression.cs.meta │ │ ├── DefaultExpression.cs │ │ ├── DefaultExpression.cs.meta │ │ ├── Identifier.cs │ │ ├── Identifier.cs.meta │ │ ├── IndexerExpression.cs │ │ ├── IndexerExpression.cs.meta │ │ ├── KeywordIdentifier.cs │ │ ├── KeywordIdentifier.cs.meta │ │ ├── LinkedIdentifierExpression.cs │ │ ├── LinkedIdentifierExpression.cs.meta │ │ ├── ListedExpression.cs │ │ ├── ListedExpression.cs.meta │ │ ├── MemberExpression.cs │ │ ├── MemberExpression.cs.meta │ │ ├── NewExpression.cs │ │ ├── NewExpression.cs.meta │ │ ├── NullExpression.cs │ │ ├── NullExpression.cs.meta │ │ ├── NumericLiteral.cs │ │ ├── NumericLiteral.cs.meta │ │ ├── OutVarNameExpression.cs │ │ ├── OutVarNameExpression.cs.meta │ │ ├── PostIncrementDecrementExpression.cs │ │ ├── PostIncrementDecrementExpression.cs.meta │ │ ├── PreIncrementDecrementExpression.cs │ │ ├── PreIncrementDecrementExpression.cs.meta │ │ ├── RangeExpression.cs │ │ ├── RangeExpression.cs.meta │ │ ├── StringLiteral.cs │ │ ├── StringLiteral.cs.meta │ │ ├── TypeOfExpression.cs │ │ ├── TypeOfExpression.cs.meta │ │ ├── UnaryExpression.cs │ │ └── UnaryExpression.cs.meta │ ├── IExpression.cs │ ├── IExpression.cs.meta │ ├── IStatement.cs │ ├── IStatement.cs.meta │ ├── LiteralType.cs │ ├── LiteralType.cs.meta │ ├── Root.cs │ ├── Root.cs.meta │ ├── Statements.meta │ ├── Statements │ │ ├── AsyncStatement.cs │ │ ├── AsyncStatement.cs.meta │ │ ├── BlockStatement.cs │ │ ├── BlockStatement.cs.meta │ │ ├── BreakStatement.cs │ │ ├── BreakStatement.cs.meta │ │ ├── ConstStatement.cs │ │ ├── ConstStatement.cs.meta │ │ ├── ContinueStatement.cs │ │ ├── ContinueStatement.cs.meta │ │ ├── ExpressionStatement.cs │ │ ├── ExpressionStatement.cs.meta │ │ ├── ForEachStatement.cs │ │ ├── ForEachStatement.cs.meta │ │ ├── FunctionStatement.cs │ │ ├── FunctionStatement.cs.meta │ │ ├── IfStatement.cs │ │ ├── IfStatement.cs.meta │ │ ├── ReturnStatement.cs │ │ ├── ReturnStatement.cs.meta │ │ ├── UsingStatement.cs │ │ ├── UsingStatement.cs.meta │ │ ├── VarStatement.cs │ │ ├── VarStatement.cs.meta │ │ ├── WhileStatement.cs │ │ └── WhileStatement.cs.meta │ ├── Validator.cs │ └── Validator.cs.meta │ ├── Async.meta │ ├── Async │ ├── ILoopItem.cs │ ├── ILoopItem.cs.meta │ ├── IPoolableCorutine.cs │ ├── IPoolableCorutine.cs.meta │ ├── LoopRunner.cs │ ├── LoopRunner.cs.meta │ ├── PlayerLoop.cs │ ├── PlayerLoop.cs.meta │ ├── ProcessHandler.cs │ └── ProcessHandler.cs.meta │ ├── Attributes.meta │ ├── Attributes │ ├── YSMethodAttribute.cs │ └── YSMethodAttribute.cs.meta │ ├── CodeGenerationType.cs │ ├── CodeGenerationType.cs.meta │ ├── Collections.meta │ ├── Collections │ ├── AddableSpan.cs │ ├── AddableSpan.cs.meta │ ├── ArrayWrapper.cs │ ├── ArrayWrapper.cs.meta │ ├── CollectionsUtility.cs │ ├── CollectionsUtility.cs.meta │ ├── FixedArray.cs │ ├── FixedArray.cs.meta │ ├── FixedDictionary.cs │ ├── FixedDictionary.cs.meta │ ├── LinkedPool.cs │ ├── LinkedPool.cs.meta │ ├── ListLike.cs │ ├── ListLike.cs.meta │ ├── RentSpan.cs │ ├── RentSpan.cs.meta │ ├── ReversedSpan.cs │ ├── ReversedSpan.cs.meta │ ├── SimpleList.cs │ ├── SimpleList.cs.meta │ ├── StringDictionary`1.cs │ ├── StringDictionary`1.cs.meta │ ├── StringHashSet.cs │ ├── StringHashSet.cs.meta │ ├── TypeKeyAddOnlyDictionary.cs │ ├── TypeKeyAddOnlyDictionary.cs.meta │ ├── UshortDictionary`1.cs │ ├── UshortDictionary`1.cs.meta │ ├── UshortSet.cs │ ├── UshortSet.cs.meta │ ├── ValueList.cs │ └── ValueList.cs.meta │ ├── Constants.cs │ ├── Constants.cs.meta │ ├── Easing.cs │ ├── ElapsedTimeLogger.cs │ ├── ElapsedTimeLogger.cs.meta │ ├── Extension.cs │ ├── Fields.meta │ ├── Fields │ ├── NameSpaceTree.cs │ ├── NameSpaceTree.cs.meta │ ├── NameSplitTree.cs │ ├── NameSplitTree.cs.meta │ ├── NamedVariable.cs │ └── NamedVariable.cs.meta │ ├── Frame.cs │ ├── Frame.cs.meta │ ├── Instructions.meta │ ├── Instructions │ ├── Async.cs │ ├── Async.cs.meta │ ├── CastAndCopy.cs │ ├── CastAndCopy.cs.meta │ ├── ControlStatements.cs │ ├── ControlStatements.cs.meta │ ├── Delegates.cs │ ├── Delegates.cs.meta │ ├── IInstruction.cs │ ├── IInstruction.cs.meta │ ├── IntrinsicFunction.cs │ ├── IntrinsicFunction.cs.meta │ ├── MethodInfoInvoker.cs │ └── MethodInfoInvoker.cs.meta │ ├── Lexer.meta │ ├── Lexer │ ├── Lexer.cs │ ├── Lexer.cs.meta │ ├── Token.cs │ └── Token.cs.meta │ ├── Modules.meta │ ├── Modules │ ├── GlobalModule.cs │ ├── GlobalModule.cs.meta │ ├── MethodData.cs │ ├── MethodData.cs.meta │ ├── ModuleLibrary.cs │ ├── ModuleLibrary.cs.meta │ ├── TypeModule.cs │ ├── TypeModule.cs.meta │ ├── TypeSignature.cs │ └── TypeSignature.cs.meta │ ├── Parser.meta │ ├── Parser │ ├── NumericParser.cs │ ├── NumericParser.cs.meta │ ├── Parser.cs │ ├── Parser.cs.meta │ ├── ParserException.cs │ └── ParserException.cs.meta │ ├── Ranges.cs │ ├── Ranges.cs.meta │ ├── Text.meta │ ├── Text │ ├── ReadOnlySpanSegments.cs │ ├── ReadOnlySpanSegments.cs.meta │ ├── ReadOnlyStringSegmentSpan.cs │ ├── ReadOnlyStringSegmentSpan.cs.meta │ ├── StringEx.cs │ ├── StringEx.cs.meta │ ├── StringSegment.cs │ ├── StringSegment.cs.meta │ ├── StringSegmentList.cs │ └── StringSegmentList.cs.meta │ ├── Timer.cs │ ├── Timer.cs.meta │ ├── UniTime.cs │ ├── UniTime.cs.meta │ ├── Util.cs │ ├── Util.cs.meta │ ├── VM.meta │ ├── VM │ ├── Compiler.cs │ ├── Compiler.cs.meta │ ├── CompilingContext.cs │ ├── CompilingContext.cs.meta │ ├── DelegateLibrary.cs │ ├── DelegateLibrary.cs.meta │ ├── IntegratedEngine.cs │ ├── IntegratedEngine.cs.meta │ ├── ProcessState.cs │ ├── ProcessState.cs.meta │ ├── VirtualMachine.Execution.cs │ ├── VirtualMachine.Execution.cs.meta │ ├── VirtualMachine.Instructions.Aync.cs │ ├── VirtualMachine.Instructions.Aync.cs.meta │ ├── VirtualMachine.Instructions.Cast.cs │ ├── VirtualMachine.Instructions.Cast.cs.meta │ ├── VirtualMachine.Instructions.Control.cs │ ├── VirtualMachine.Instructions.Control.cs.meta │ ├── VirtualMachine.Instructions.Copy.cs │ ├── VirtualMachine.Instructions.Copy.cs.meta │ ├── VirtualMachine.Instructions.Delegate.cs │ ├── VirtualMachine.Instructions.Delegate.cs.meta │ ├── VirtualMachine.Instructions.IntrinsicFunctions.cs │ ├── VirtualMachine.Instructions.IntrinsicFunctions.cs.meta │ ├── VirtualMachine.Instructions.MethodInfoInvoke.cs │ ├── VirtualMachine.Instructions.MethodInfoInvoke.cs.meta │ ├── VirtualMachine.Instructions.cs │ ├── VirtualMachine.Instructions.cs.meta │ ├── VirtualMachine.cs │ ├── VirtualMachine.cs.meta │ ├── YSAwaiter.cs │ ├── YSAwaiter.cs.meta │ ├── YSEnumerator.cs │ └── YSEnumerator.cs.meta │ ├── ValueStopwatch.cs │ ├── ValueStopwatch.cs.meta │ ├── Variable.cs │ ├── Variable.cs.meta │ ├── YS.Runtime.asmdef │ └── YS.Runtime.asmdef.meta ├── Images ├── Reflection.png ├── YSAsync.gif ├── YSFieldTypeSelect.gif ├── YSJson.gif ├── YSPerformance.gif └── YSTypeSelect.gif ├── LICENSE ├── Packages ├── manifest.json └── packages-lock.json ├── ProjectSettings ├── AudioManager.asset ├── ClusterInputManager.asset ├── DynamicsManager.asset ├── EditorBuildSettings.asset ├── EditorSettings.asset ├── GraphicsSettings.asset ├── InputManager.asset ├── MemorySettings.asset ├── NavMeshAreas.asset ├── PackageManagerSettings.asset ├── Packages │ └── com.unity.testtools.codecoverage │ │ └── Settings.json ├── Physics2DSettings.asset ├── PresetManager.asset ├── ProjectSettings.asset ├── ProjectVersion.txt ├── QualitySettings.asset ├── SceneTemplateSettings.json ├── TagManager.asset ├── TimeManager.asset ├── TimelineSettings.asset ├── UnityConnectSettings.asset ├── VFXManager.asset ├── VersionControlSettings.asset ├── VisualScriptingSettings.asset ├── XRSettings.asset └── boot.config ├── README.md ├── Third Party Notices.md ├── UserSettings ├── EditorUserSettings.asset ├── Layouts │ ├── CurrentMaximizeLayout.dwlt │ └── default-2021.dwlt └── Search.settings ├── YS.csproj.DotSettings └── docs ├── Build ├── docs.data ├── docs.framework.js ├── docs.loader.js └── docs.wasm ├── StreamingAssets └── UnityServicesProjectConfiguration.json ├── TemplateData ├── favicon.ico ├── fullscreen-button.png ├── progress-bar-empty-dark.png ├── progress-bar-empty-light.png ├── progress-bar-full-dark.png ├── progress-bar-full-light.png ├── style.css ├── unity-logo-dark.png ├── unity-logo-light.png └── webgl-logo.png └── index.html /.idea/.idea.YukataScript/.idea/.gitignore: -------------------------------------------------------------------------------- 1 | # Default ignored files 2 | /shelf/ 3 | /workspace.xml 4 | # Rider ignored files 5 | /contentModel.xml 6 | /.idea.YukataScript.iml 7 | /projectSettingsUpdater.xml 8 | /modules.xml 9 | # Editor-based HTTP Client requests 10 | /httpRequests/ 11 | # Datasource local storage ignored files 12 | /dataSources/ 13 | /dataSources.local.xml 14 | -------------------------------------------------------------------------------- /.idea/.idea.YukataScript/.idea/encodings.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | -------------------------------------------------------------------------------- /.idea/.idea.YukataScript/.idea/indexLayout.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | -------------------------------------------------------------------------------- /.idea/.idea.YukataScript/.idea/inspectionProfiles/Project_Default.xml: -------------------------------------------------------------------------------- 1 |  2 | 3 | 10 | -------------------------------------------------------------------------------- /Assembly-CSharp.csproj.DotSettings: -------------------------------------------------------------------------------- 1 |  2 | True -------------------------------------------------------------------------------- /Assets/Plugins.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: ef3a7d4d91b8fbc43bb6c51704fb3ba2 3 | folderAsset: yes 4 | DefaultImporter: 5 | externalObjects: {} 6 | userData: 7 | assetBundleName: 8 | assetBundleVariant: 9 | -------------------------------------------------------------------------------- /Assets/Plugins/System.Runtime.CompilerServices.Unsafe.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Akeit0/YukataScript/bb06c77046e3f67169cfa28ab24953538c3c692f/Assets/Plugins/System.Runtime.CompilerServices.Unsafe.dll -------------------------------------------------------------------------------- /Assets/Plugins/System.Runtime.CompilerServices.Unsafe.dll.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 7f5fd6900c4f48345b2d2b4dc2029425 3 | PluginImporter: 4 | externalObjects: {} 5 | serializedVersion: 2 6 | iconMap: {} 7 | executionOrder: {} 8 | defineConstraints: [] 9 | isPreloaded: 0 10 | isOverridable: 0 11 | isExplicitlyReferenced: 0 12 | validateReferences: 1 13 | platformData: 14 | - first: 15 | Any: 16 | second: 17 | enabled: 1 18 | settings: {} 19 | - first: 20 | Editor: Editor 21 | second: 22 | enabled: 0 23 | settings: 24 | DefaultValueInitialized: true 25 | - first: 26 | Windows Store Apps: WindowsStoreApps 27 | second: 28 | enabled: 0 29 | settings: 30 | CPU: AnyCPU 31 | userData: 32 | assetBundleName: 33 | assetBundleVariant: 34 | -------------------------------------------------------------------------------- /Assets/Scenes.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 6ea315d0fd7389c41b19996891e99ae3 3 | folderAsset: yes 4 | DefaultImporter: 5 | externalObjects: {} 6 | userData: 7 | assetBundleName: 8 | assetBundleVariant: 9 | -------------------------------------------------------------------------------- /Assets/Scenes/SampleScene.unity.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 9fc0d4010bbf28b4594072e72b8655ab 3 | DefaultImporter: 4 | externalObjects: {} 5 | userData: 6 | assetBundleName: 7 | assetBundleVariant: 8 | -------------------------------------------------------------------------------- /Assets/Scripts.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 955fb868e04438941ab3fa84660827af 3 | folderAsset: yes 4 | DefaultImporter: 5 | externalObjects: {} 6 | userData: 7 | assetBundleName: 8 | assetBundleVariant: 9 | -------------------------------------------------------------------------------- /Assets/Scripts/DemoForBuild.cs.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: e1efb2b320314dbeb9a31d861a55f76f 3 | timeCreated: 1676714416 -------------------------------------------------------------------------------- /Assets/Scripts/JsonTest.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Buffers; 3 | using System.Collections.Generic; 4 | using System.Text; 5 | using NaughtyAttributes; 6 | using UnityEngine; 7 | using YS; 8 | using YS.Fields; 9 | using YS.Modules; 10 | 11 | namespace DefaultNamespace { 12 | public class JsonTest :MonoBehaviour { 13 | public List Fields; 14 | [TextArea(3,20)] 15 | public string Json; 16 | StringBuilder _builder = new StringBuilder(); 17 | 18 | 19 | static Dictionary _dictionary = new Dictionary(); 20 | 21 | [Button()] 22 | public void ToJson () { 23 | 24 | _builder.AppendLine("{"); 25 | for (var i = 0; i < Fields.Count; i++) { 26 | var namedVariable = Fields[i]; 27 | _builder.Append('"'); 28 | _builder.Append(namedVariable.Name); 29 | _builder.Append("\":"); 30 | ModuleLibrary.ToJson(namedVariable.Variable, _builder); 31 | if(i+1 json, List list) { 47 | list.Clear(); 48 | if (json.Length < 9) return; 49 | int start = 0; 50 | while (true) { 51 | while (json[start++] != '"') { } 52 | int end = start; 53 | while (json[++end] != '"') { } 54 | string name = json.Slice(start, end - start).ToString(); 55 | start = end + 1; 56 | var variable = ModuleLibrary.FromJson(json[start..], out var count); 57 | list.Add(new NameVariablePair(name,variable)); 58 | start +=count; 59 | while (true) { 60 | var c = json[start++]; 61 | if (c == ',') { 62 | break; 63 | } 64 | if (c == '}') return; 65 | } 66 | } 67 | 68 | 69 | } 70 | } 71 | 72 | } -------------------------------------------------------------------------------- /Assets/Scripts/JsonTest.cs.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 88e98cecffd74582996b9bd6d0573b86 3 | timeCreated: 1675228160 -------------------------------------------------------------------------------- /Assets/Scripts/MySettings.cs: -------------------------------------------------------------------------------- 1 | using System.Collections; 2 | using System.Collections.Generic; 3 | using UnityEngine; 4 | 5 | public class MySettings : MonoBehaviour { 6 | // Start is called before the first frame update 7 | void Start() { 8 | Application.targetFrameRate = 60; 9 | } 10 | 11 | } 12 | -------------------------------------------------------------------------------- /Assets/Scripts/MySettings.cs.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: ec255996ac013b845a8548bcd3e8296d 3 | MonoImporter: 4 | externalObjects: {} 5 | serializedVersion: 2 6 | defaultReferences: [] 7 | executionOrder: 0 8 | icon: {instanceID: 0} 9 | userData: 10 | assetBundleName: 11 | assetBundleVariant: 12 | -------------------------------------------------------------------------------- /Assets/Scripts/NewText.txt: -------------------------------------------------------------------------------- 1 | using UnityEngine 2 | print("Start") 3 | for i in ..100{ 4 | await 30.ms() 5 | transform.position+=new Vector3(f,0,0) 6 | } -------------------------------------------------------------------------------- /Assets/Scripts/NewText.txt.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: c3ea19c53bfdc644e928789941fd362a 3 | TextScriptImporter: 4 | externalObjects: {} 5 | userData: 6 | assetBundleName: 7 | assetBundleVariant: 8 | -------------------------------------------------------------------------------- /Assets/Scripts/UITest.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections; 3 | using System.Collections.Generic; 4 | using System.Diagnostics; 5 | using System.Linq; 6 | using System.Runtime.CompilerServices; 7 | using NaughtyAttributes; 8 | using UnityEngine; 9 | using UnityEngine.UIElements; 10 | using YS; 11 | using YS.Fields; 12 | using YS.UI; 13 | 14 | namespace DefaultNamespace { 15 | [RequireComponent(typeof(UIDocument))] 16 | public class UITest : MonoBehaviour { 17 | VisualElement root; 18 | public Variable FloatVariable; 19 | public VariableVector3Variable; 20 | public VariableColorVariable; 21 | public VariableTransformVariable; 22 | 23 | VariableField _floatField; 24 | VariableField _vector3Field; 25 | VariableField _colorField; 26 | VariableField _transformField; 27 | public void Start() { 28 | Application.targetFrameRate = 60; 29 | 30 | 31 | root = GetComponent().rootVisualElement; 32 | var inputRoot=root.Q(); 33 | 34 | VariableField.VariableView = inputRoot; 35 | var holder = inputRoot.Q("Variables"); 36 | var _ = new I(holder) { 37 | (_floatField = VariableField.Create(FloatVariable)), 38 | (_vector3Field = VariableField.Create(Vector3Variable)), 39 | (_colorField = VariableField.Create(ColorVariable)), 40 | (_transformField = VariableField.Create(TransformVariable)), 41 | }; 42 | var button = new Button(() => holder.Insert(holder.childCount-1,new SelfRemoveElement(new SelectableField()))) { 43 | text = "+", 44 | style = { 45 | unityTextAlign = TextAnchor.MiddleCenter 46 | } 47 | }; 48 | holder.Add(button); 49 | 50 | } 51 | 52 | public void Update() { 53 | if (Input.GetKeyDown(KeyCode.F12)||Input.GetKeyDown(KeyCode.Escape)) { 54 | root.visible = !root.visible; 55 | } 56 | _floatField.Validate(); 57 | _vector3Field.Validate(); 58 | _colorField.Validate(); 59 | _transformField.Validate(); 60 | 61 | } 62 | } 63 | 64 | public class SelfRemoveElement : VisualElement { 65 | public SelfRemoveElement(VisualElement element) { 66 | style.flexDirection = FlexDirection.Row; 67 | element.style.flexGrow = 1; 68 | Add(element); 69 | Add(new Button(()=>parent.Remove(this)){style={unityTextAlign = TextAnchor.UpperCenter,width=20,height = new Length(100,LengthUnit.Percent)},text = "-"}); 70 | } 71 | 72 | } 73 | } -------------------------------------------------------------------------------- /Assets/Scripts/UITest.cs.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: ba0f75cfdbd94340bb2b17a835eecfe0 3 | timeCreated: 1676713649 -------------------------------------------------------------------------------- /Assets/Scripts/Variables.asset: -------------------------------------------------------------------------------- 1 | %YAML 1.1 2 | %TAG !u! tag:unity3d.com,2011: 3 | --- !u!114 &11400000 4 | MonoBehaviour: 5 | m_ObjectHideFlags: 0 6 | m_CorrespondingSourceObject: {fileID: 0} 7 | m_PrefabInstance: {fileID: 0} 8 | m_PrefabAsset: {fileID: 0} 9 | m_GameObject: {fileID: 0} 10 | m_Enabled: 1 11 | m_EditorHideFlags: 0 12 | m_Script: {fileID: 11500000, guid: f8bc664981804022806608ec2b34fdfa, type: 3} 13 | m_Name: Variables 14 | m_EditorClassIdentifier: 15 | Fields: 16 | - Name: f 17 | Variable: 18 | rid: 9208754235765161990 19 | - Name: text 20 | Variable: 21 | rid: 9208754304739966979 22 | - Name: color 23 | Variable: 24 | rid: 9208754304739966978 25 | - Name: v3 26 | Variable: 27 | rid: 9208754235765161993 28 | - Name: obj 29 | Variable: 30 | rid: 9208754304739966980 31 | references: 32 | version: 2 33 | RefIds: 34 | - rid: 9208754235765161990 35 | type: {class: floatVariable, ns: YS.Generated, asm: Assembly-CSharp} 36 | data: 37 | value: 4.95 38 | - rid: 9208754235765161993 39 | type: {class: UnityEngine_Vector3Variable, ns: YS.Generated, asm: Assembly-CSharp} 40 | data: 41 | value: {x: 0, y: 0, z: 0} 42 | - rid: 9208754304739966978 43 | type: {class: UnityEngine_ColorVariable, ns: YS.Generated, asm: Assembly-CSharp} 44 | data: 45 | value: {r: 0.4552704, g: 1, b: 0, a: 1} 46 | - rid: 9208754304739966979 47 | type: {class: stringVariable, ns: YS.Generated, asm: Assembly-CSharp} 48 | data: 49 | value: HelloWorld!! 50 | - rid: 9208754304739966980 51 | type: {class: UnityEngine_ObjectVariable, ns: YS.Generated, asm: Assembly-CSharp} 52 | data: 53 | value: {fileID: 0} 54 | -------------------------------------------------------------------------------- /Assets/Scripts/Variables.asset.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: ed46673786c458a4782d0a8c023e9c9b 3 | NativeFormatImporter: 4 | externalObjects: {} 5 | mainObjectFileID: 11400000 6 | userData: 7 | assetBundleName: 8 | assetBundleVariant: 9 | -------------------------------------------------------------------------------- /Assets/Scripts/VariablesObject.cs: -------------------------------------------------------------------------------- 1 | using UnityEngine; 2 | using YS.Fields; 3 | 4 | namespace DefaultNamespace { 5 | [CreateAssetMenu(fileName = "Variables", menuName = "ScriptableObjects/VariablesObject")] 6 | public class VariablesObject :ScriptableObject { 7 | public NamedVariable[] Fields; 8 | } 9 | } -------------------------------------------------------------------------------- /Assets/Scripts/VariablesObject.cs.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: f8bc664981804022806608ec2b34fdfa 3 | timeCreated: 1675228922 -------------------------------------------------------------------------------- /Assets/Scripts/YSTest.cs.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: ba27cbf03b404bcba3a3999823aeccbe 3 | timeCreated: 1673088435 -------------------------------------------------------------------------------- /Assets/Scripts/conditions.ys.txt: -------------------------------------------------------------------------------- 1 | var ok = true 2 | isZero := 1 + 1 == 0; 3 | if ok && isZero{ 4 | print("a") 5 | } 6 | if (not isZero){ 7 | print("b") 8 | } -------------------------------------------------------------------------------- /Assets/Scripts/forLoop.ys.txt: -------------------------------------------------------------------------------- 1 | for i in 1..10{ 2 | if( i<3){ 3 | continue; 4 | } 5 | if i>=7{ 6 | break; 7 | } 8 | else{ 9 | print(i) 10 | } 11 | } -------------------------------------------------------------------------------- /Assets/UI Toolkit/UnityThemes/UnityDefaultRuntimeTheme.tss: -------------------------------------------------------------------------------- 1 | @import url("unity-theme://default"); -------------------------------------------------------------------------------- /Assets/YS.Generated.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 93b509df4bdf41b18f154252645ac703 3 | timeCreated: 1675352343 -------------------------------------------------------------------------------- /Assets/YS.Generated/.editorconfig: -------------------------------------------------------------------------------- 1 | [*Wrapper.RegisterModules.cs] 2 | generated_code = true -------------------------------------------------------------------------------- /Assets/YS.Generated/CodeGenData.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using static YS.CodeGenerationType; 4 | namespace YS.Generated { 5 | public static class CodeGenData { 6 | [CodeGenAssembly] 7 | public static List AssemblyNameList=new List() { 8 | "mscorlib", 9 | "UnityEngine.CoreModule" 10 | }; 11 | [CodeGenTypes] 12 | public static List<(CodeGenerationType,Type)> TypeList=new List<(CodeGenerationType, Type)>() { 13 | (InspectorOnly,typeof(int)), 14 | (InspectorOnly,typeof(float)), 15 | }; 16 | } 17 | } -------------------------------------------------------------------------------- /Assets/YS.Generated/CodeGenData.cs.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 838a58d1830c407eb78f48c0251c87f1 3 | timeCreated: 1675929730 -------------------------------------------------------------------------------- /Assets/YS.Generated/InspectorVariables.cs: -------------------------------------------------------------------------------- 1 | 2 | namespace YS.Generated { 3 | public class boolVariable:Variable{} 4 | public class intVariable:Variable{} 5 | public class doubleVariable:Variable{} 6 | public class floatVariable:Variable{} 7 | public class stringVariable:Variable{} 8 | public class UnityEngine_MonoBehaviourVariable:Variable{} 9 | public class UnityEngine_BehaviourVariable:Variable{} 10 | public class UnityEngine_ComponentVariable:Variable{} 11 | public class UnityEngine_ObjectVariable:Variable{} 12 | public class UnityEngine_Vector3Variable:Variable{} 13 | public class UnityEngine_TransformVariable:Variable{} 14 | public class UnityEngine_GameObjectVariable:Variable{} 15 | public class UnityEngine_ColorVariable:Variable{} 16 | public class UnityEngine_AnimationCurveVariable:Variable{} 17 | public class UnityEngine_SpriteRendererVariable:Variable{} 18 | public class UnityEngine_RendererVariable:Variable{} 19 | public class YS_EasingTypeVariable:Variable{} 20 | 21 | } 22 | -------------------------------------------------------------------------------- /Assets/YS.Generated/InspectorVariables.cs.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 9a6f8ef52168499eb95c192c8f7fce29 3 | MonoImporter: 4 | externalObjects: {} 5 | serializedVersion: 2 6 | defaultReferences: [] 7 | executionOrder: 0 8 | icon: {instanceID: 0} 9 | userData: 10 | assetBundleName: 11 | assetBundleVariant: 12 | -------------------------------------------------------------------------------- /Assets/YS.Generated/Modules.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 6a0eb0c500304ad99072c805af070893 3 | timeCreated: 1675352679 -------------------------------------------------------------------------------- /Assets/YS.Generated/Modules/.editorconfig: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Akeit0/YukataScript/bb06c77046e3f67169cfa28ab24953538c3c692f/Assets/YS.Generated/Modules/.editorconfig -------------------------------------------------------------------------------- /Assets/YS.Generated/Modules/Wrapper.System.Enum.cs.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 4846969481644574c9206a61e2105273 3 | MonoImporter: 4 | externalObjects: {} 5 | serializedVersion: 2 6 | defaultReferences: [] 7 | executionOrder: 0 8 | icon: {instanceID: 0} 9 | userData: 10 | assetBundleName: 11 | assetBundleVariant: 12 | -------------------------------------------------------------------------------- /Assets/YS.Generated/Modules/Wrapper.UnityEngine.AnimationCurve.cs.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 185a0dd9939ac3a4489991f5a639ed06 3 | MonoImporter: 4 | externalObjects: {} 5 | serializedVersion: 2 6 | defaultReferences: [] 7 | executionOrder: 0 8 | icon: {instanceID: 0} 9 | userData: 10 | assetBundleName: 11 | assetBundleVariant: 12 | -------------------------------------------------------------------------------- /Assets/YS.Generated/Modules/Wrapper.UnityEngine.Behaviour.cs: -------------------------------------------------------------------------------- 1 | #if !UNITY_EDITOR&&ENABLE_IL2CPP 2 | #define AOT 3 | #endif 4 | using Behaviour = UnityEngine.Behaviour; 5 | using _Behaviour = YS.Variable; 6 | using _bool = YS.Variable; 7 | 8 | using static System.Runtime.CompilerServices.Unsafe; 9 | using __V = YS.Variable; 10 | namespace YS.Generated { 11 | public static partial class Wrapper { 12 | static void UnityEngine_Behaviour_ctor(__V res) => As<_Behaviour>(res).value = new Behaviour(); 13 | static void UnityEngine_Behaviour_get_enabled(__V res, __V i1) => As<_bool>(res).value=As<_Behaviour>(i1).value.enabled; 14 | static void UnityEngine_Behaviour_set_enabled(__V i1, __V i2) => As<_Behaviour>(i1).value.enabled = As<_bool>(i2).value; 15 | static void UnityEngine_Behaviour_get_isActiveAndEnabled(__V res, __V i1) => As<_bool>(res).value=As<_Behaviour>(i1).value.isActiveAndEnabled; 16 | #if !AOT 17 | 18 | static TypeModule Create_UnityEngine_BehaviourModule(global::System.Type baseType=null) { 19 | var module = new TypeModule(typeof(Behaviour)); 20 | module.RegisterConstructor(UnityEngine_Behaviour_ctor); 21 | module.RegisterPropertyGetter("enabled", UnityEngine_Behaviour_get_enabled); 22 | module.RegisterPropertySetter("enabled", UnityEngine_Behaviour_set_enabled); 23 | module.RegisterPropertyGetter("isActiveAndEnabled", UnityEngine_Behaviour_get_isActiveAndEnabled); 24 | #else 25 | static unsafe TypeModule Create_UnityEngine_BehaviourModule(global::System.Type baseType=null) { 26 | var module = new TypeModule(typeof(Behaviour)); 27 | module.RegisterConstructor(&UnityEngine_Behaviour_ctor); 28 | module.RegisterPropertyGetter("enabled", &UnityEngine_Behaviour_get_enabled); 29 | module.RegisterPropertySetter("enabled",& UnityEngine_Behaviour_set_enabled); 30 | module.RegisterPropertyGetter("isActiveAndEnabled", &UnityEngine_Behaviour_get_isActiveAndEnabled); 31 | #endif 32 | module.ClearTempMembers(); 33 | if (baseType != null) module.BaseModule = baseType.GetModule(); 34 | return module; 35 | } 36 | } 37 | } -------------------------------------------------------------------------------- /Assets/YS.Generated/Modules/Wrapper.UnityEngine.Behaviour.cs.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 7530bbf6ba1e76b449bf44d8be066197 3 | MonoImporter: 4 | externalObjects: {} 5 | serializedVersion: 2 6 | defaultReferences: [] 7 | executionOrder: 0 8 | icon: {instanceID: 0} 9 | userData: 10 | assetBundleName: 11 | assetBundleVariant: 12 | -------------------------------------------------------------------------------- /Assets/YS.Generated/Modules/Wrapper.UnityEngine.Color.cs.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: fe071572682ae374da08df8c797e2f92 3 | MonoImporter: 4 | externalObjects: {} 5 | serializedVersion: 2 6 | defaultReferences: [] 7 | executionOrder: 0 8 | icon: {instanceID: 0} 9 | userData: 10 | assetBundleName: 11 | assetBundleVariant: 12 | -------------------------------------------------------------------------------- /Assets/YS.Generated/Modules/Wrapper.UnityEngine.Component.cs.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 2f256eef80257c846a15bfb4a74e2694 3 | MonoImporter: 4 | externalObjects: {} 5 | serializedVersion: 2 6 | defaultReferences: [] 7 | executionOrder: 0 8 | icon: {instanceID: 0} 9 | userData: 10 | assetBundleName: 11 | assetBundleVariant: 12 | -------------------------------------------------------------------------------- /Assets/YS.Generated/Modules/Wrapper.UnityEngine.GameObject.cs.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: b8577a53ce4c3a44c98dd69290acefea 3 | MonoImporter: 4 | externalObjects: {} 5 | serializedVersion: 2 6 | defaultReferences: [] 7 | executionOrder: 0 8 | icon: {instanceID: 0} 9 | userData: 10 | assetBundleName: 11 | assetBundleVariant: 12 | -------------------------------------------------------------------------------- /Assets/YS.Generated/Modules/Wrapper.UnityEngine.Mathf.cs.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: b1a418a9f30265649a2b0f8a567b65bf 3 | MonoImporter: 4 | externalObjects: {} 5 | serializedVersion: 2 6 | defaultReferences: [] 7 | executionOrder: 0 8 | icon: {instanceID: 0} 9 | userData: 10 | assetBundleName: 11 | assetBundleVariant: 12 | -------------------------------------------------------------------------------- /Assets/YS.Generated/Modules/Wrapper.UnityEngine.MonoBehaviour.cs.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 6514ed592bafc494fb27347e03ba43e8 3 | MonoImporter: 4 | externalObjects: {} 5 | serializedVersion: 2 6 | defaultReferences: [] 7 | executionOrder: 0 8 | icon: {instanceID: 0} 9 | userData: 10 | assetBundleName: 11 | assetBundleVariant: 12 | -------------------------------------------------------------------------------- /Assets/YS.Generated/Modules/Wrapper.UnityEngine.Object.cs.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: fddef61ac3be5284284ab2a89c6c9912 3 | MonoImporter: 4 | externalObjects: {} 5 | serializedVersion: 2 6 | defaultReferences: [] 7 | executionOrder: 0 8 | icon: {instanceID: 0} 9 | userData: 10 | assetBundleName: 11 | assetBundleVariant: 12 | -------------------------------------------------------------------------------- /Assets/YS.Generated/Modules/Wrapper.UnityEngine.Renderer.cs.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: f8549e360a6595f47bea44717adb00ed 3 | MonoImporter: 4 | externalObjects: {} 5 | serializedVersion: 2 6 | defaultReferences: [] 7 | executionOrder: 0 8 | icon: {instanceID: 0} 9 | userData: 10 | assetBundleName: 11 | assetBundleVariant: 12 | -------------------------------------------------------------------------------- /Assets/YS.Generated/Modules/Wrapper.UnityEngine.SpriteRenderer.cs.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 083f99bed471e794582bfa3b1c6be66a 3 | MonoImporter: 4 | externalObjects: {} 5 | serializedVersion: 2 6 | defaultReferences: [] 7 | executionOrder: 0 8 | icon: {instanceID: 0} 9 | userData: 10 | assetBundleName: 11 | assetBundleVariant: 12 | -------------------------------------------------------------------------------- /Assets/YS.Generated/Modules/Wrapper.UnityEngine.Time.cs.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 18082e6bd41484844b42fffbfec1ae07 3 | MonoImporter: 4 | externalObjects: {} 5 | serializedVersion: 2 6 | defaultReferences: [] 7 | executionOrder: 0 8 | icon: {instanceID: 0} 9 | userData: 10 | assetBundleName: 11 | assetBundleVariant: 12 | -------------------------------------------------------------------------------- /Assets/YS.Generated/Modules/Wrapper.UnityEngine.Transform.cs.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 6f8c9483a0541db478f90fb1eee9728c 3 | MonoImporter: 4 | externalObjects: {} 5 | serializedVersion: 2 6 | defaultReferences: [] 7 | executionOrder: 0 8 | icon: {instanceID: 0} 9 | userData: 10 | assetBundleName: 11 | assetBundleVariant: 12 | -------------------------------------------------------------------------------- /Assets/YS.Generated/Modules/Wrapper.UnityEngine.Vector3.cs.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: ece187e6441f6e04b97c686920b3216f 3 | MonoImporter: 4 | externalObjects: {} 5 | serializedVersion: 2 6 | defaultReferences: [] 7 | executionOrder: 0 8 | icon: {instanceID: 0} 9 | userData: 10 | assetBundleName: 11 | assetBundleVariant: 12 | -------------------------------------------------------------------------------- /Assets/YS.Generated/Modules/Wrapper.YS.Timer.cs.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 609d069e1b397ea43964501756ac2973 3 | MonoImporter: 4 | externalObjects: {} 5 | serializedVersion: 2 6 | defaultReferences: [] 7 | executionOrder: 0 8 | icon: {instanceID: 0} 9 | userData: 10 | assetBundleName: 11 | assetBundleVariant: 12 | -------------------------------------------------------------------------------- /Assets/YS.Generated/Modules/assembly_data.json: -------------------------------------------------------------------------------- 1 | { 2 | "value": [ 3 | "mscorlib", 4 | "UnityEngine.CoreModule", 5 | "YS.Runtime", 6 | "UnityEngine.UI" 7 | ] 8 | } -------------------------------------------------------------------------------- /Assets/YS.Generated/Modules/assembly_data.json.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: b236e2dd7ff6bc84a907ec6538dbcf36 3 | TextScriptImporter: 4 | externalObjects: {} 5 | userData: 6 | assetBundleName: 7 | assetBundleVariant: 8 | -------------------------------------------------------------------------------- /Assets/YS.Generated/Modules/type_data.json: -------------------------------------------------------------------------------- 1 | { 2 | "value": [ 3 | { 4 | "Name": "bool", 5 | "CodeGenerationType": 1 6 | }, 7 | { 8 | "Name": "int", 9 | "CodeGenerationType": 1 10 | }, 11 | { 12 | "Name": "double", 13 | "CodeGenerationType": 1 14 | }, 15 | { 16 | "Name": "float", 17 | "CodeGenerationType": 1 18 | }, 19 | { 20 | "Name": "string", 21 | "CodeGenerationType": 1 22 | }, 23 | { 24 | "Name": "UnityEngine.MonoBehaviour", 25 | "CodeGenerationType": 2 26 | }, 27 | { 28 | "Name": "UnityEngine.Behaviour", 29 | "CodeGenerationType": 2 30 | }, 31 | { 32 | "Name": "UnityEngine.Component", 33 | "CodeGenerationType": 2 34 | }, 35 | { 36 | "Name": "UnityEngine.Object", 37 | "CodeGenerationType": 2 38 | }, 39 | { 40 | "Name": "UnityEngine.Vector3", 41 | "CodeGenerationType": 2 42 | }, 43 | { 44 | "Name": "UnityEngine.Mathf", 45 | "CodeGenerationType": 0 46 | }, 47 | { 48 | "Name": "UnityEngine.Transform", 49 | "CodeGenerationType": 2 50 | }, 51 | { 52 | "Name": "UnityEngine.GameObject", 53 | "CodeGenerationType": 2 54 | }, 55 | { 56 | "Name": "System.Enum", 57 | "CodeGenerationType": 0 58 | }, 59 | { 60 | "Name": "UnityEngine.Color", 61 | "CodeGenerationType": 2 62 | }, 63 | { 64 | "Name": "UnityEngine.AnimationCurve", 65 | "CodeGenerationType": 2 66 | }, 67 | { 68 | "Name": "YS.Timer", 69 | "CodeGenerationType": 0 70 | }, 71 | { 72 | "Name": "UnityEngine.Time", 73 | "CodeGenerationType": 0 74 | }, 75 | { 76 | "Name": "UnityEngine.SpriteRenderer", 77 | "CodeGenerationType": 2 78 | }, 79 | { 80 | "Name": "UnityEngine.Renderer", 81 | "CodeGenerationType": 2 82 | }, 83 | { 84 | "Name": "YS.EasingType", 85 | "CodeGenerationType": 2 86 | } 87 | ] 88 | } -------------------------------------------------------------------------------- /Assets/YS.Generated/Modules/type_data.json.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 8e9117bcef8712b43a4845d6f9a49a41 3 | TextScriptImporter: 4 | externalObjects: {} 5 | userData: 6 | assetBundleName: 7 | assetBundleVariant: 8 | -------------------------------------------------------------------------------- /Assets/YS.Generated/Wrapper.RegisterModules.cs: -------------------------------------------------------------------------------- 1 | using static YS.Modules.ModuleLibrary; 2 | namespace YS.Generated { 3 | public static partial class Wrapper { 4 | static void RegisterModules() { 5 | Register(new Variable(),()=>Create_UnityEngine_MonoBehaviourModule(typeof(UnityEngine.Behaviour))); 6 | Register(new Variable(),()=>Create_UnityEngine_BehaviourModule(typeof(UnityEngine.Component))); 7 | Register(new Variable(),()=>Create_UnityEngine_ComponentModule(typeof(UnityEngine.Object))); 8 | Register(new Variable(),()=>Create_UnityEngine_ObjectModule()); 9 | Register(new Variable(),()=>Create_UnityEngine_Vector3Module()); 10 | Register(new Variable(),()=>Create_UnityEngine_MathfModule()); 11 | Register(new Variable(),()=>Create_UnityEngine_TransformModule(typeof(UnityEngine.Component))); 12 | Register(new Variable(),()=>Create_UnityEngine_GameObjectModule(typeof(UnityEngine.Object))); 13 | Register(new Variable(),()=>Create_System_EnumModule()); 14 | Register(new Variable(),()=>Create_UnityEngine_ColorModule()); 15 | Register(new Variable(),()=>Create_UnityEngine_AnimationCurveModule()); 16 | Register(new Variable(),()=>Create_YS_TimerModule()); 17 | Register(new Variable(),()=>Create_UnityEngine_TimeModule()); 18 | Register(new Variable(),()=>Create_UnityEngine_SpriteRendererModule(typeof(UnityEngine.Renderer))); 19 | Register(new Variable(),()=>Create_UnityEngine_RendererModule(typeof(UnityEngine.Component))); 20 | Register(new Variable(),()=>Create_YS_EasingTypeModule(typeof(System.Enum))); 21 | } 22 | } 23 | } 24 | -------------------------------------------------------------------------------- /Assets/YS.Generated/Wrapper.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using UnityEngine; 3 | using UnityEngine.Scripting; 4 | using YS.Modules; 5 | 6 | namespace YS.Generated { 7 | [Preserve] 8 | public static partial class Wrapper { 9 | [RuntimeInitializeOnLoadMethod] 10 | public static void Init(){} 11 | 12 | public static bool Registered; 13 | 14 | static Wrapper() { 15 | RegisterModules(); 16 | Registered = true; 17 | } 18 | static Type[] Types() => Util.Types(); 19 | static Type[] Types(Type arg1) => Util.Types(arg1); 20 | static Type[] Types(Type arg1, Type arg2) => Util.Types(arg1, arg2); 21 | static Type[] Types(Type arg1,Type arg2,Type arg3) => Util.Types(arg1, arg2,arg3); 22 | static Type[] Types(Type arg1,Type arg2,Type arg3,Type arg4)=> Util.Types(arg1, arg2,arg3,arg4); 23 | static Type[] Types(Type arg1,Type arg2,Type arg3,Type arg4,Type arg5)=> Util.Types(arg1, arg2,arg3,arg4,arg5); 24 | static Type[] Types(Type arg1,Type arg2,Type arg3,Type arg4,Type arg5,Type arg6)=> Util.Types(arg1, arg2,arg3,arg4,arg5, arg6); 25 | 26 | static TypeModule GetModule(this Type type) => ModuleLibrary.GetModule(type); 27 | 28 | } 29 | } -------------------------------------------------------------------------------- /Assets/YS.Generated/Wrapper.cs.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 98f6ea0380ee41f2a3b1bb3eff3c4cef 3 | timeCreated: 1710124929 -------------------------------------------------------------------------------- /Assets/YS.UI/Fields.cs.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 6d5d176844794e598991c0617c02f2aa 3 | timeCreated: 1676713510 -------------------------------------------------------------------------------- /Assets/YS.UI/I.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections; 3 | using System.Collections.Generic; 4 | using System.Globalization; 5 | using System.Linq; 6 | using UnityEngine; 7 | using UnityEngine.UIElements; 8 | namespace YS.UI { 9 | public readonly struct I:IEnumerable { 10 | public readonly VisualElement self; 11 | public I(VisualElement element) => self = element; 12 | public I(I element) => self = element.self; 13 | 14 | public IStyle style => self.style; 15 | public void Add(VisualElement child) => self.Add(child); 16 | public IEnumerator GetEnumerator() { 17 | return self.Children().GetEnumerator(); 18 | } 19 | 20 | IEnumerator IEnumerable.GetEnumerator() { 21 | return GetEnumerator(); 22 | } 23 | 24 | 25 | } 26 | public readonly struct I:IEnumerable where T:VisualElement{ 27 | public readonly T self; 28 | public I(T element) => self = element; 29 | public I(I element) => self = element.self; 30 | public IStyle style => self.style; 31 | 32 | public void Add(VisualElement child) => self.Add(child); 33 | public IEnumerator GetEnumerator() { 34 | return self.Children().GetEnumerator(); 35 | } 36 | 37 | IEnumerator IEnumerable.GetEnumerator() { 38 | return GetEnumerator(); 39 | } 40 | } 41 | } -------------------------------------------------------------------------------- /Assets/YS.UI/I.cs.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 0a1c61c92f3a436b8667285d02aa7988 3 | timeCreated: 1676713561 -------------------------------------------------------------------------------- /Assets/YS.UI/New Panel Settings.asset: -------------------------------------------------------------------------------- 1 | %YAML 1.1 2 | %TAG !u! tag:unity3d.com,2011: 3 | --- !u!114 &11400000 4 | MonoBehaviour: 5 | m_ObjectHideFlags: 0 6 | m_CorrespondingSourceObject: {fileID: 0} 7 | m_PrefabInstance: {fileID: 0} 8 | m_PrefabAsset: {fileID: 0} 9 | m_GameObject: {fileID: 0} 10 | m_Enabled: 1 11 | m_EditorHideFlags: 0 12 | m_Script: {fileID: 19101, guid: 0000000000000000e000000000000000, type: 0} 13 | m_Name: New Panel Settings 14 | m_EditorClassIdentifier: 15 | themeUss: {fileID: -4733365628477956816, guid: f222d765f69d43947b9092935982f177, type: 3} 16 | m_TargetTexture: {fileID: 0} 17 | m_ScaleMode: 1 18 | m_Scale: 1 19 | m_ReferenceDpi: 96 20 | m_FallbackDpi: 96 21 | m_ReferenceResolution: {x: 1200, y: 800} 22 | m_ScreenMatchMode: 0 23 | m_Match: 0 24 | m_SortingOrder: 0 25 | m_TargetDisplay: 0 26 | m_ClearDepthStencil: 1 27 | m_ClearColor: 0 28 | m_ColorClearValue: {r: 0, g: 0, b: 0, a: 0} 29 | m_DynamicAtlasSettings: 30 | m_MinAtlasSize: 64 31 | m_MaxAtlasSize: 4096 32 | m_MaxSubTextureSize: 64 33 | m_ActiveFilters: 31 34 | m_AtlasBlitShader: {fileID: 9101, guid: 0000000000000000f000000000000000, type: 0} 35 | m_RuntimeShader: {fileID: 9100, guid: 0000000000000000f000000000000000, type: 0} 36 | m_RuntimeWorldShader: {fileID: 9102, guid: 0000000000000000f000000000000000, type: 0} 37 | textSettings: {fileID: 0} 38 | -------------------------------------------------------------------------------- /Assets/YS.UI/UITest.uxml: -------------------------------------------------------------------------------- 1 | 2 |