id
stringlengths
15
22
source
stringclasses
2 values
category
stringclasses
12 values
instruction
stringlengths
22
180
response
stringlengths
100
46.1k
system
stringclasses
5 values
local_sr_eccfcebed127
unity_docs
rendering
What is `SystemInfo.maxCubemapSize` in Unity? Explain its purpose and usage.
SystemInfo.maxCubemapSize public static int maxCubemapSize ; Description Maximum cubemap texture size in pixels (Read Only). The largest cubemap texture width and height that your graphics hardware supports. Unity only supports textures up to a size of 16384, even if maxCubemapSize returns a larger size. Yo...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_1013b40e9967
unity_docs
scripting
What is `Categorization.ElementInfoAttribute.Order` in Unity? Explain its purpose and usage.
ElementInfoAttribute.Order public int Order ; Description The position this element should take in the parent category. If elements with different Name are at same Order, they are sorted by their Name. If Order is not specified, int.MaxValue will be used.
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
gh_09645b4b1a23_doc_0
github
scripting
What does `this member` do in this Unity script? Explain its purpose and signature.
This is the main entry point to one of the scenes Signature: ```csharp public class Scene02_CustomizeCharacter : MonoBehaviour ```
You are a senior Unity engineer. Answer questions about Unity scripting, XR/VR development, and game systems with working code examples.
local_sr_ae3d75f0ebae
unity_docs
scripting
What is `AudioClip` in Unity? Explain its purpose and usage.
AudioClip class in UnityEngine / Inherits from: Audio.AudioResource / Implemented in: UnityEngine.AudioModule Description A container for audio data. An AudioClip stores the audio file either compressed as ogg vorbis or uncompressed. AudioClips are referenced and used by AudioSources to play sounds. Addition...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_053d7f6082c4
unity_docs
editor
What is `Search.SearchSettings` in Unity? Explain its purpose and usage.
SearchSettings class in UnityEditor.Search Description Search settings give access to the user global preferences regarding Search. Static Properties Property Description searchItemFavorites Returns a list of all item IDs that are marked as favorite by the user for in the current project. Static Methods Meth...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_3f89a37d742c
unity_docs
rendering
What is `ParticleSystem.time` in Unity? Explain its purpose and usage.
ParticleSystem.time public float time ; Description Playback position in seconds. Use this to read the current playback time or to seek to a new playback time. For a looping system, this value wraps within the duration. For systems that specify a Start Delay, getting the time ignores the delay. Additional reso...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_c7d9b9babfda
unity_docs
scripting
What is `Rendering.VertexAttributeFormat.UNorm16` in Unity? Explain its purpose and usage.
VertexAttributeFormat.UNorm16 Description 16-bit unsigned normalized number. This format stores uniformly quantized numbers in [0..1] range, with 16 bits of precision (65536 possible different values). Additional resources: Mesh class, VertexAttribute enum, Mesh.GetVertexAttributeFormat .
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_26d88c08e167
unity_docs
scripting
What is `Windows.Directory` in Unity? Explain its purpose and usage.
Directory class in UnityEngine.Windows / Implemented in: UnityEngine.CoreModule Description Exposes static methods for directory operations. This is an alternative to System.IO.Directory class. Note: this class is only available when targeting Universal Windows Platform. Static Properties Property Descriptio...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_be9fc89989d7
unity_docs
scripting
What is `Unity.Properties.ICollectionPropertyVisitor` in Unity? Explain its purpose and usage.
ICollectionPropertyVisitor interface in Unity.Properties Description Interface for receiving strongly typed property callbacks for collections. Public Methods Method Description Visit Implement this method to accept visitation for a specialized collection property.
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_e688047147b2
unity_docs
scripting
What is `XR.HandFinger` in Unity? Explain its purpose and usage.
HandFinger enumeration Description Enumeration describing the AR rendering mode used with Hand . Properties Property Description Thumb Thumb finger on a hand. Index Index finger on a hand. Middle Middle finger on a hand. Ring Ring finger on a hand. Pinky Pinky finger on a hand.
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_man_2f1856fc692e
unity_docs
rendering
Explain 'Graphics performance and profiling in the Built-In Render Pipeline' in Unity.
Resources for understanding and improving rendering performance in the Built-In Render Pipeline . Page Description Creating custom shaders that support GPU instancing Resources for writing HLSL shaders or Surface Shaders in the Built-In Render Pipeline that support GPU instancing.
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_27360f7cb69c
unity_docs
rendering
What is `ParticleSystem.randomSeed` in Unity? Explain its purpose and usage.
ParticleSystem.randomSeed public uint randomSeed ; Description Override the random seed used for the Particle System emission. Setting this will also set ParticleSystem.useAutoRandomSeed to false.
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_60297289a61d
unity_docs
rendering
What is `MeshRenderer` in Unity? Explain its purpose and usage.
MeshRenderer class in UnityEngine / Inherits from: Renderer / Implemented in: UnityEngine.CoreModule Description Renders meshes inserted by the MeshFilter or TextMesh . Properties Property Description additionalVertexStreams Vertex attributes in this mesh will override or add attributes of the primary ...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_54840ec27fe0
unity_docs
math
Give me an overview of the `Pose` class in Unity.
Pose struct in UnityEngine / Implemented in: UnityEngine.CoreModule Description Representation of a Position, and a Rotation in 3D Space This structure is used primarily in XR applications to describe the current "pose" of a device in 3D space. Static Properties Property Description identity Shorthand for p...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_014a65bacb9d
unity_docs
rendering
Show me a Unity C# example demonstrating `ParticleSystem.RotationOverLifetimeModule.y`.
ParticleSystem.RotationOverLifetimeModule.y public ParticleSystem.MinMaxCurve y ; Description Rotation over lifetime curve for the y-axis. Additional resources: MinMaxCurve . ```csharp using UnityEngine; using System.Collections;[RequireComponent(typeof(ParticleSystem))] public class ExampleClass : MonoBeh...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_fa338bb6a68a
unity_docs
math
What is `Rendering.BatchDrawCommandProceduralIndirect.sortingPosition` in Unity? Explain its purpose and usage.
BatchDrawCommandProceduralIndirect.sortingPosition public int sortingPosition ; Description Together with BatchDrawCommand.flags , this specifies how to depth sort the instances in this draw command. If BatchDrawCommandFlags.HasSortingPosition is set, this contains the index of the first position in the Ba...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_3c0c00130b9d
unity_docs
scripting
What is `VersionControl.RevertMode` in Unity? Explain its purpose and usage.
RevertMode enumeration Description Defines the behaviour of the version control revert methods. Properties Property Description Normal Use the version control regular revert approach. Unchanged Revert only unchanged files. KeepModifications Revert files but keep locally changed ones.
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
gh_9736bf133383
github
scripting
Write a Unity C# script called Contrast Enhance
```csharp using System; using UnityEngine; namespace UnityStandardAssets.ImageEffects { [ExecuteInEditMode] [RequireComponent(typeof(Camera))] [AddComponentMenu("Image Effects/Color Adjustments/Contrast Enhance (Unsharp Mask)")] public class ContrastEnhance : PostEffectsBase { [Range...
You are a knowledgeable Unity developer. Explain Unity concepts clearly and provide practical, tested code examples.
local_sr_af4662517d3e
unity_docs
editor
Show me a Unity C# example demonstrating `iOS.Xcode.PBXProject.RemoveFileFromBuild`.
PBXProject.RemoveFileFromBuild Declaration public void RemoveFileFromBuild (string targetGuid , string fileGuid ); Parameters Parameter Description targetGuid The GUID of the target, such as the one returned by TargetGuidByName . fileGuid The GUID of the file or folder reference. Description Removes th...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_61da10c1938b
unity_docs
scripting
What is `Experimental.Rendering.GraphicsFormat.RGB_ETC2_SRGB` in Unity? Explain its purpose and usage.
Experimental : this API is experimental and might be changed or removed in the future. GraphicsFormat.RGB_ETC2_SRGB Description A three-component, ETC2 compressed format where each 64-bit compressed texel block encodes a 4×4 rectangle of unsigned normalized RGB texel data with sRGB nonlinear encoding. This format h...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_dd1867f217fb
unity_docs
physics
What is `Collider2D.Raycast` in Unity? Explain its purpose and usage.
Collider2D.Raycast Declaration public int Raycast ( Vector2 direction , RaycastHit2D[] results , float distance = Mathf.Infinity, int layerMask = Physics2D.AllLayers, float minDepth = -Mathf.Infinity, float maxDepth = Mathf.Infinity); Declaration public int Raycast ( Vector2 direction , ContactFilt...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_7b8f986a72d1
unity_docs
scripting
What is `Playables.PlayableExtensions.GetOutput` in Unity? Explain its purpose and usage.
PlayableExtensions.GetOutput Declaration public static Playables.Playable GetOutput (U playable , int outputPort ); Parameters Parameter Description playable The Playable used by this operation. outputPort The port index. Returns Playable Playable connected at the output index specified, or null i...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_man_087ee945bd92
unity_docs
editor
In Unity's 'Install Unity Accelerator with the installer', what is 'Run the installer on the command line' and how does it work?
To run the installer in unattended mode from the command line, use the --mode unattended argument. Execute the installer with an argument of --help to display the options available. Command line argument Description --install-dir Sets the directory where the binaries are copied. --storage-dir Sets the directory for the...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_f94fd6129ca3
unity_docs
scripting
What is `Rendering.BatchDrawCommandProceduralIndirect.visibleInstancesBufferWindowOffset` in Unity? Explain its purpose and usage.
BatchDrawCommandProceduralIndirect.visibleInstancesBufferWindowOffset public uint visibleInstancesBufferWindowOffset ; Description Offset of the visible instances buffer that will be bound as element zero.
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_2183d0007130
unity_docs
physics
What is `PhysicsVisualizationSettings.SetShowStaticColliders` in Unity? Explain its purpose and usage.
PhysicsVisualizationSettings.SetShowStaticColliders Declaration public static void SetShowStaticColliders (bool show ); Description Should the Colliders without a Rigidbody component be considered by the display filter. Additional resources: Collider .
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_751bf66f7e17
unity_docs
animation
Give me an overview of the `AnimationClipCurveData` class in Unity.
AnimationClipCurveData class in UnityEditor Description An AnimationClipCurveData object contains all the information needed to identify a specific curve in an AnimationClip. The curve animates a specific property of a component / material attached to a game object / animated bone. Additional resources: Animatio...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
gh_1ef5686d0e5f
github
scripting
Write a Unity C# script called Score Screen Type
```csharp using UnityEngine; using UnityEngine.UI; public abstract class ScoreScreenType<T> : BaseScreen<T> where T : Component { [SerializeField] protected Text scoreText; protected string mScorePrefix = "SCORE\n"; protected void SetScoreText(int value) { scoreText.text = mScorePrefix + value; ...
You are an experienced Unity developer specializing in C# scripting, XR/VR development, and performance optimization.
local_man_84a28d3b770e
unity_docs
editor
In Unity's 'Create an aspect ratio custom control', what is 'Use the custom control' and how does it work?
Create a custom Editor window that uses the custom control. Test the custom control to see how it behaves when you change the aspect ratio. Create a C# script named AspectRatioDemo.cs with the following content: ```csharp using UnityEditor; using UnityEngine; using UnityEngine.UIElements; public class AspectRatioDemo...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_f550f0a45be8
unity_docs
rendering
What is `RenderTextureDescriptor.graphicsFormat` in Unity? Explain its purpose and usage.
RenderTextureDescriptor.graphicsFormat public Experimental.Rendering.GraphicsFormat graphicsFormat ; Description The color format for the RenderTexture. You can set this format to None to achieve depth-only rendering. See Also: GraphicsFormat .
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_f297e0a3e1b7
unity_docs
ui
Show me a Unity C# example demonstrating `EditorWindow.OnSelectionChange`.
EditorWindow.OnSelectionChange() Description Called whenever the selection has changed. Saves the current selection and load it later with a simple click. ```csharp // Simple example that lets you save the current selection and load it. using UnityEditor; using UnityEngine.UIElements; public class OnSelectionCha...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_8c574cf90bb9
unity_docs
scripting
What is `AwaitableCompletionSource_1.TrySetCanceled` in Unity? Explain its purpose and usage.
AwaitableCompletionSource<T0>.TrySetCanceled Declaration public bool TrySetCanceled (); Returns bool Indicates if the cancellation was successfuly raised. Description Raise cancellation (returns false if the awaitable was already completed or canceled).
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_man_fbdd92bd8c59
unity_docs
ui
In Unity's 'Reuse UXML files', what is 'Import a UXML template' and how does it work?
When you design a large user interface, you can create template UXML files that define parts of the UI, and use the <Template> and <Instance> elements to import it into another UXML file. For example, if you have a portrait UI element that has an image, a name, and a label, you can create a UXML template file as Portra...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_man_14dcc8668d0d
unity_docs
xr
In Unity's 'USS data types', what is 'Length' and how does it work?
UI Toolkit supports pixels ( px ) and percentages ( % ) as units of measurement for length. Pixel values are absolute, while percentages are relative to the element’s parent. Examples: width:200px; expresses a width of 200 px. width:50%; expresses a width of half of the parent element’s width. It’s important to specify...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_0c789c70d827
unity_docs
audio
What is `SceneView.audioPlay` in Unity? Explain its purpose and usage.
SceneView.audioPlay public bool audioPlay ; Description Enables or disables Scene view audio effects. Only one Scene view may have active audio at a time. Setting this property makes this view the active audio scene.
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_fde50882d79d
unity_docs
ui
Show me a Unity C# example demonstrating `GUIStyle.onNormal`.
GUIStyle.onNormal public GUIStyleState onNormal ; Description Rendering settings for when the control is turned on. ```csharp using UnityEngine;public class Example : MonoBehaviour { void OnGUI() { GUI.skin.button.onNormal.textColor = Color.red; } } ```
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_man_0d58523ef542
unity_docs
scripting
In Unity's 'LayerField', what is 'Example' and how does it work?
The following UXML example creates a LayerField: ``` <UXML xmlns="UnityEngine.UIElements" xmlns:uie="UnityEditor.UIElements"> <uie:LayerField label="UXML Field" name="the-uxml-field" /> </UXML> ``` The following C# example illustrates some of the customizable functionalities of the LayerField: ``` /// <sample> // Get ...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_fbe8af847f71
unity_docs
scripting
What is `Time.smoothDeltaTime` in Unity? Explain its purpose and usage.
Time.smoothDeltaTime public static float smoothDeltaTime ; Description A smoothed out Time.deltaTime (Read Only). This value is equal to Time.deltaTime when it is constant (i.e. smooth frame rate). When deltaTime varies between frames (e.g. on a frame hitch), this value increases or decreases gradually toward...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_7eb934b12988
unity_docs
editor
What are the parameters of `EditorGUI.MaskField` in Unity?
Returns int The value modified by the user. Description Makes a field for masks. Note: The mask values for the flags associated with each option in the menu will be consecutive powers of 2 starting with 1, i.e. 1, 2, 4, 8, 16, and so on. Simple window that shows the mask field. ```csharp using UnityEngine; using UnityE...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_9b88cf18ce6c
unity_docs
rendering
What is `TextureImporterPlatformSettings.textureCompression` in Unity? Explain its purpose and usage.
TextureImporterPlatformSettings.textureCompression public TextureImporterCompression textureCompression ; Description Compression of imported texture. Additional resources: TextureImporterCompression .
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_3cafa010bae9
unity_docs
scripting
Show me a Unity C# example demonstrating `HideFlags.HideInHierarchy`.
HideFlags.HideInHierarchy Description The object will not appear in the hierarchy. ```csharp using UnityEngine;public class Example : MonoBehaviour { // Creates 5 planes and hides them from the Hierarchy in the Editor. void Start() { for (int i = 0; i < 5; i++) { GameObject createdGO = GameObject.CreatePrimiti...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_man_2971c4fd5899
unity_docs
scripting
In Unity's 'Customize IMGUI controls', what is 'Working with styles' and how does it work?
All GUI Control functions have an optional last parameter: the GUIStyle to use for displaying the Control. If this is omitted, Unity’s default GUIStyle will be used. This works internally by applying the name of the control type as a string, so GUI.Button() uses the “button” style, GUI.Toggle() uses the “toggle” style,...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_man_f402285d4257
unity_docs
animation
Explain 'Avatar Mapping tab reference' in Unity.
The Avatar Mapping tab is available when the Unity Editor is in Avatar Configuration mode. To enter Avatar Configuration mode, either: select the Avatar Asset in the Project window , and click “Configure Avatar” in the Inspector, or select the Model Asset in the Project window, go to the “Rig” tab in the Inspector, and...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_6da0427bf94e
unity_docs
rendering
What is `Shader.SetGlobalConstantBuffer` in Unity? Explain its purpose and usage.
Shader.SetGlobalConstantBuffer Declaration public static void SetGlobalConstantBuffer (string name , ComputeBuffer value , int offset , int size ); Declaration public static void SetGlobalConstantBuffer (int nameID , ComputeBuffer value , int offset , int size ); Declaration public static void S...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_93170b16f8f5
unity_docs
rendering
What is `Light.lightUnit` in Unity? Explain its purpose and usage.
Light.lightUnit public Rendering.LightUnit lightUnit ; Description The unit Light.intensity should be displayed in. This property indicates how intensity should displayed in the UI. Only Scriptable Render Pipelines use this property; the built-in renderer does not support it. Additional resources: LightUn...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_307e318f8f97
unity_docs
scripting
What is `UIElements.CommandEventBase_1` in Unity? Explain its purpose and usage.
CommandEventBase<T0> class in UnityEngine.UIElements / Inherits from: UIElements.EventBase_1 / Implemented in: UnityEngine.UIElementsModule Implements interfaces: ICommandEvent Description Base class for command events. Properties Property Description commandName The command to validate or execute. ...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_man_111de77216fb
unity_docs
rendering
In Unity's 'Upgrade your Unity project', what is 'Determine if you should upgrade' and how does it work?
Before you upgrade your project, make sure that the advantages of upgrading outweigh the effort required to upgrade for your specific case. Large, complex projects with several third-party assets and packages attached might take a long time to upgrade and require significant changes. If your project uses many third-par...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_man_019a6136966d
unity_docs
rendering
In Unity's 'Reduce rendering work on the CPU or GPU', what is 'Reducing the GPU cost of rendering' and how does it work?
There are three main reasons why the GPU might fail to complete its work in time to render a frame. If an application is limited by fill rate, the GPU is trying to draw more pixels per frame than it can handle. If this is the case, consider these options: Identify and reduce overdraw in your application. The most commo...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_man_0cd1dd42ecd3
unity_docs
physics
Explain 'Call Unity C# script functions from JavaScript' in Unity.
You might want to call some Unity code from your JavaScript plug-in or browser code. For example, you might want a JavaScript UI element that triggers a Unity behaviour and needs access to that method. The recommended way to send data or notifications to the Unity C# script from the browser’s JavaScript is to use the S...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_man_30ff047a5528
unity_docs
rendering
Explain 'Manage search queries' in Unity.
Save and reuse queries. You can save queries only for yourself, or save them to the project to share with others. ## Save searches Saving searches allows you to keep useful searches to reuse as needed. Save the search to your personal Unity for your own use (User), or to project to save it as an Asset to make the sea...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_man_e8ebe4f5ad33
unity_docs
performance
In Unity's 'Copying NativeContainer structures', what is 'Version numbers' and how does it work?
If a NativeContainer is disposed of, all the copies of the NativeContainer structure must recognize that the original NativeContainer is invalid. Disposing of the original NativeContainer means that the block of memory that used to hold the data for the NativeContainer has been deallocated. In this situation, the point...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
gh_287120a92924_doc_1
github
scripting
What does `SetIndex` do in this Unity script? Explain its purpose and signature.
Set the current index without loading (used by VRFileBrowser after direct load). Signature: ```csharp public void SetIndex(int index) ```
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_8afc30336136
unity_docs
animation
What is `AvatarIKHint` in Unity? Explain its purpose and usage.
AvatarIKHint enumeration Description IK Hint. Used to set and get IK weights and position. Additional resources: Animator.GetIKHintPosition , Animator.GetIKHintPositionWeight , Animator.SetIKHintPosition , and Animator.SetIKHintPositionWeight . Properties Property Description LeftKnee The left knee IK hint...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_90e8cfdd682c
unity_docs
scripting
What is `U2D.SpriteAtlasExtensions.SetMasterAtlas` in Unity? Explain its purpose and usage.
SpriteAtlasExtensions.SetMasterAtlas Declaration public static void SetMasterAtlas ( U2D.SpriteAtlas spriteAtlas , U2D.SpriteAtlas value ); Description Set an atlas to be the master atlas. Setting a valid master atlas will not turn this into a variant Sprite Atlas. You have to use SpriteAtlasExtensions.Se...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_51921971a6fe
unity_docs
input
What is `UIElements.INotifyValueChanged_1` in Unity? Explain its purpose and usage.
INotifyValueChanged<T0> interface in UnityEngine.UIElements Description Interface for controls that hold a value and can notify when it is changed by user input. Properties Property Description value The value the control holds.
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_dc9b6969dd36
unity_docs
ui
Show me a Unity C# example demonstrating `GUI.DragWindow`.
GUI.DragWindow Declaration public static void DragWindow ( Rect position ); Parameters Parameter Description position The part of the window that can be dragged. This is clipped to the actual window. Description Make a window draggable. Insert a call to this function inside your window code to make a win...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_d150af0e507b
unity_docs
scripting
Show me a Unity C# example demonstrating `ParticleSystem.ExternalForcesModule.multiplierCurve`.
ParticleSystem.ExternalForcesModule.multiplierCurve public ParticleSystem.MinMaxCurve multiplierCurve ; Description Multiplies the magnitude of applied external forces. ```csharp using UnityEngine; using System.Collections;[RequireComponent(typeof(ParticleSystem))] public class ExampleClass : MonoBehaviour {...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_335ed2b4ed6c
unity_docs
networking
What is `Android.AndroidConfiguration.navigationHidden` in Unity? Explain its purpose and usage.
AndroidConfiguration.navigationHidden public Android.AndroidNavigationHidden navigationHidden ; Description Mirrors the Android property navigationHidden . For information about this property, refer to the Android developer documentation on navigationHidden .
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_ee9bde651f3a
unity_docs
animation
What is `ModelImporter.animationScaleError` in Unity? Explain its purpose and usage.
ModelImporter.animationScaleError public float animationScaleError ; Description Allowed error of animation scale compression. Allowed error is defined in distance (in percents) between compressed and original scale on a curve. This settings used only when animation keyframe reduction is enabled. Additional res...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_cda06d03bb15
unity_docs
editor
Show me a Unity C# example demonstrating `EditorWindow.CreateGUI`.
ailable. Keep the event registration code inside CreateGUI or after CreateGUI is called. It's important to note that CreateGUI might not be called before the first call to Update . For more information, refer to the order of execution of the Editor window . For an example on how to create an Editor window to...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_40cf69473dc5
unity_docs
scripting
What is `XR.MeshTransform.Timestamp` in Unity? Explain its purpose and usage.
MeshTransform.Timestamp public ulong Timestamp ; Description The timestamp associated with this transform. A larger value indicates a more recent time. This timestamp can be compared with MeshGenerationResult.Timestamp to determine whether the generation result (which is asynchronous) contains a newer transf...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_d0b6192f523f
unity_docs
input
What is `UILineInfo` in Unity? Explain its purpose and usage.
UILineInfo struct in UnityEngine / Implemented in: UnityEngine.TextRenderingModule Description Information about a generated line of text. Properties Property Description height Height of the line. leading Space in pixels between this line and the next line. startCharIdx Index of the first character in the...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_e3ad3cfae1f3
unity_docs
rendering
What is `TextureImporterCubemapConvolution.Diffuse` in Unity? Explain its purpose and usage.
TextureImporterCubemapConvolution.Diffuse Description Diffuse convolution (aka irradiance Cubemap ). Each pixel of this Cubemap texture is replaced with the cosine-weighted integral of the corresponding hemisphere of incident illumination. In simpler terms texture is nicely blurred. Can be used to light diffuse ...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_0afa65c5e5f1
unity_docs
animation
Show me a Unity C# example demonstrating `AssetPostprocessor.OnPreprocessAsset`.
AssetPostprocessor.OnPreprocessAsset() Description Add this function to a subclass to get a notification just before any Asset is imported. This lets you control the import settings through code. ```csharp using UnityEditor;class MyModelPostprocessor : AssetPostprocessor { void OnPreprocessAsset() { if (assetIm...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_man_ead83cc0c680
unity_docs
rendering
In Unity's 'Introduction to panoramic videos', what is 'Equirectangular 2D videos' and how does it work?
Equirectangular 2D videos have an aspect ratio of exactly 2:1 for 360 content, or 1:1 for 180 content. This layout flattens a spherical image onto a 2D plane, which makes it possible to display 360° content in a video. The horizontal axis represents the full 360° field of view around the viewer. The vertical axis repre...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_edeb2d25c297
unity_docs
scripting
What are the parameters of `Unity.Properties.PropertyContainer.TryAccept` in Unity?
Returns bool true if the visitation succeeded; false otherwise. Description Tries to visit the specified by ref using the specified . Declaration public static bool TryAccept ( Unity.Properties.IPropertyBagVisitor visitor , ref TContainer container , out Unity.Properties.VisitReturnCode returnCode , Unity.Properties.V...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_d448b60a01e5
unity_docs
input
Give me an overview of the `LocationInfo` class in Unity.
LocationInfo struct in UnityEngine / Implemented in: UnityEngine.InputLegacyModule Description Structure describing device location. Properties Property Description altitude Geographical device location altitude in meters. horizontalAccuracy Horizontal accuracy radius of the location in meters. latitude Ge...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_man_196c7f45dbe5
unity_docs
editor
In Unity's 'Import assets simultaneously', what is 'Supported file types' and how does it work?
The Parallel Import setting supports only certain types of asset. The specific types of asset which Unity can import in parallel are as follows: Image file types imported by the Texture Importer . Model file types imported by the Model Importer . Audio file types imported by the Audio Importer Other types of asset are ...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_934a3132cbc7
unity_docs
scripting
What are the parameters of `Search.PropertyDatabase.Store` in Unity?
Returns bool True if the store operation succeeded, false if not. Description Stores a document property. ``` // Store a property of a document, like a property of an asset. var stored = propertyDatabase.Store("path/to/my/asset", "m_Color", new Color(1, 0, 1)); if (!stored) Debug.LogWarning("Property m_Color did no...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_0e052faf0746
unity_docs
scripting
What is `AI.NavMeshAgent` in Unity? Explain its purpose and usage.
NavMeshAgent class in UnityEngine.AI / Inherits from: Behaviour / Implemented in: UnityEngine.AIModule Description Navigation mesh agent. Attach this component to a mobile character in the game to allow the character to use the NavMesh to navigate the scene. For more details refer to AI Navigation . Propert...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_94b244963a15
unity_docs
rendering
What are the parameters of `Rect.ctor` in Unity?
Description Creates a new rectangle. ```csharp using UnityEngine;public class RectExample : MonoBehaviour { void Start() { Rect rect = new Rect(0, 0, 10, 10); // prints: (x:0, y:0, width:10, height:10) Debug.Log(rect); } } ``` Note: Rect represents an abstract rectangle, and can be us...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_6a422100b5e8
unity_docs
editor
What is `SettingsProvider.ctor` in Unity? Explain its purpose and usage.
SettingsProvider Constructor Declaration public SettingsProvider (string path , SettingsScope scopes , IEnumerable<string> keywords ); Parameters Parameter Description path Path of the settings in the Settings window. Uses "/" as separator. The last token becomes the settings label if none is provided. ...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_1e64478a529b
unity_docs
scripting
Show me a Unity C# example demonstrating `FrameTiming.cpuTimePresentCalled`.
entCalled ; Description This is the CPU clock time at the point Present was called for the current frame. The CPU clock time at the point Present() is called for the frame. This is the time at which Unity finishes submitting objects for rendering and informs the GPU that the frame can be presented to the user. U...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_71aabcde6851
unity_docs
ui
What is `UIElements.BaseListView.footerAddButtonName` in Unity? Explain its purpose and usage.
BaseListView.footerAddButtonName public static string footerAddButtonName ; Description The name of the add button element in the footer. Unity uses this name of BaseListView add button when showAddRemoveFooter is set to true .
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_7a0d523768c2
unity_docs
physics
What is `Collider2D.OverlapPoint` in Unity? Explain its purpose and usage.
Collider2D.OverlapPoint Declaration public bool OverlapPoint ( Vector2 point ); Parameters Parameter Description point A point in world space. Returns bool Does point overlap the collider? Description Check if a collider overlaps a point in space. This will always return false when used on an Ed...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_e5cd83543039
unity_docs
rendering
What is `LightingSettings.albedoBoost` in Unity? Explain its purpose and usage.
LightingSettings.albedoBoost public float albedoBoost ; Description The intensity of surface albedo throughout the Scene when considered in lighting calculations. This value influences the energy of light at each bounce. (Editor only). When light bounces off a surface, it is multiplied by the albedo of the sur...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_4293ee58c312
unity_docs
input
What is `Experimental.GraphView.EdgeControl.inputOrientation` in Unity? Explain its purpose and usage.
Experimental : this API is experimental and might be changed or removed in the future. EdgeControl.inputOrientation public Experimental.GraphView.Orientation inputOrientation ; Description Edge input port orientation (vertical/horizontal).
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_82099db376cd
unity_docs
math
What is `TerrainTools.BrushTransform.FromBrushUV` in Unity? Explain its purpose and usage.
BrushTransform.FromBrushUV Declaration public Vector2 FromBrushUV ( Vector2 brushUV ); Parameters Parameter Description brushUV Brush UV coordinate to transform. Returns Vector2 Target XY coordinate. Description Applies the transform to convert a Brush UV coordinate to the target XY space.
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_88a9b9f25223
unity_docs
scripting
What is `Playables.PlayableGraph.IsPlaying` in Unity? Explain its purpose and usage.
PlayableGraph.IsPlaying Declaration public bool IsPlaying (); Returns bool A boolean indicating if the graph is playing or not. Description Indicates that a graph is presently running. Return true if PlayableGraph.Play or has been called on the graph. Returns false if PlayableGraph.Stop has been calle...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_8f098c498e02
unity_docs
editor
What are the parameters of `iOS.Xcode.PBXProject.UpdateBuildProperty` in Unity?
Description Adds and removes values from a build property in all build configurations for the specified target(s). ```csharp using UnityEditor; using System.IO; using UnityEditor.Callbacks; using UnityEditor.iOS.Xcode;public class Sample_UpdateBuildProperty { [PostProcessBuild] public static void OnPostproces...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_70e0abcb02ec
unity_docs
scripting
What is `Rendering.SubMeshDescriptor.ctor` in Unity? Explain its purpose and usage.
SubMeshDescriptor Constructor Declaration public SubMeshDescriptor (int indexStart , int indexCount , MeshTopology topology ); Parameters Parameter Description indexStart Initial value for indexStart field. indexCount Initial value for indexCount field. topology Initial value for topology field...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_beb58cd295ab
unity_docs
scripting
What is `Presets.PresetSelector` in Unity? Explain its purpose and usage.
PresetSelector class in UnityEditor.Presets / Inherits from: EditorWindow Description This class implements a modal window that selects a Preset asset from the Project. Static Methods Method Description DrawPresetButton Draw a Preset button that opens the default PresetSelector using the targets array. Sh...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_51a6fe26ff67
unity_docs
scripting
What is `XR.XRMeshSubsystem.GenerateMeshAsync` in Unity? Explain its purpose and usage.
XRMeshSubsystem.GenerateMeshAsync Declaration public void GenerateMeshAsync ( XR.MeshId meshId , Mesh mesh , MeshCollider meshCollider , XR.MeshVertexAttributes attributes , Action<MeshGenerationResult> onMeshGenerationComplete ); Parameters Parameter Description meshId The MeshId of the mesh yo...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_792b7d7fd098
unity_docs
scripting
What is `PlayerLoop.PreLateUpdate` in Unity? Explain its purpose and usage.
PreLateUpdate struct in UnityEngine.PlayerLoop / Implemented in: UnityEngine.CoreModule Description Update phase in the native player loop. This is the C# representation of an update phase in the native player loop. It can only be used to identify the update phase in native.
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_2b6cebc2112a
unity_docs
scripting
What is `AndroidJNI.IsSameObject` in Unity? Explain its purpose and usage.
AndroidJNI.IsSameObject Declaration public static bool IsSameObject (IntPtr obj1 , IntPtr obj2 ); Description Tests whether two references refer to the same Java object. Additional resources: Java Native Interface Specification (Oracle)
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_c81bdf8f225a
unity_docs
physics
What is `TerrainTools.PaintContext.ApplyDelayedActions` in Unity? Explain its purpose and usage.
PaintContext.ApplyDelayedActions Declaration public static void ApplyDelayedActions (); Description Flushes the delayed actions created by PaintContext heightmap and alphamap modifications. Expensive updates that would cause performance issues during painting and sculpting are deferred until the user finishes ...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_man_31545655dccd
unity_docs
rendering
Explain 'Texture type and shape settings reference' in Unity.
Note: Some of the less commonly used properties are hidden by default. Expand the Advanced section in the Inspector window to view these properties. ## Texture Type Use the Texture Type property to select the type of Texture you want to create from the source image file. The other properties in the Texture Import set...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
gh_b4d70b8046f1
github
scripting
Write a Unity C# MonoBehaviour script called Mono Behaviour Tests
```csharp namespace AncientLightStudios.Nanoject.Tests { using System.Collections.Generic; using MonoBehaviours; using NUnit.Framework; using UnityEngine; [TestFixture] public class MonoBehaviourTests { private DependencyContext _context; private List<GameObject> _dispose; ...
You are a senior Unity engineer. Answer questions about Unity scripting, XR/VR development, and game systems with working code examples.
local_sr_6dd9f863dfe3
unity_docs
scripting
What is `UIElements.Rotate` in Unity? Explain its purpose and usage.
Rotate struct in UnityEngine.UIElements / Implemented in: UnityEngine.UIElementsModule Description Provides rotation information for visual elements that rotates around the TransformOrigin . Positive values represent clockwise rotation. Properties Property Description angle The angle applied by the rot...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_man_8c6e4ec81704
unity_docs
input
Explain 'iOS input overview' in Unity.
Unity uses the Input class to access input on all mobile devices. ## iOS keyboard iOS devices include a touchscreen keyboard. When you select editable UI elements such as Input Fields , Unity automatically activates the iOS touchscreen keyboard and handles input from it. For information on how to manually activate an...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_8d88dab0ce80
unity_docs
rendering
What is `LightTransport.RadeonRaysWorld.GetIntegrationContext` in Unity? Explain its purpose and usage.
RadeonRaysWorld.GetIntegrationContext Declaration public LightTransport.IntegrationContext GetIntegrationContext (); Returns IntegrationContext The current Integration context. Description Get the Integration context. Get the current integration context set on the world.
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_a29944edc98e
unity_docs
editor
What is `EditorBuildSettings.globalScenes` in Unity? Explain its purpose and usage.
EditorBuildSettings.globalScenes public static EditorBuildSettingsScene[] globalScenes ; Description The list of scenes used by all platform profiles and build profiles that do not override global scenes. Additional resources: BuildProfile.overrideGlobalScenes , Platform profile .
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
gh_6910d9d9a9ea_doc_34
github
scripting
What does `OnRectTransformRemovedAsObservable` do in this Unity script? Explain its purpose and signature.
Callback that is sent if an associated RectTransform is removed. Signature: ```csharp public static IObservable<Unit> OnRectTransformRemovedAsObservable(this Component component) ```
You are an expert Unity game developer. Provide clear, accurate, and practical answers about Unity development.
local_sr_0e751394a6f1
unity_docs
editor
What is `EditorUtility.SetDirty` in Unity? Explain its purpose and usage.
EditorUtility.SetDirty Declaration public static void SetDirty ( Object target ); Parameters Parameter Description target The object to mark as dirty. Description Marks target object as dirty. You can use SetDirty when you want to modify an object without creating an undo entry, but still ensure the ...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_a12aca63a1bb
unity_docs
scripting
What is `Unity.IntegerTime.DiscreteTimeTimeExtensions.Max` in Unity? Explain its purpose and usage.
DiscreteTimeTimeExtensions.Max Declaration public static Unity.IntegerTime.DiscreteTime Max ( Unity.IntegerTime.DiscreteTime lhs , Unity.IntegerTime.DiscreteTime rhs ); Parameters Parameter Description lhs The first operand. rhs The second operand. Returns DiscreteTime The maximum of the two spec...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
gh_f522b91ce703_doc_3
github
scripting
What does `this member` do in this Unity script? Explain its purpose and signature.
Represents an object which can receive four arguments as part of its initialization process.-derived classes that implement this interface can be instantiated with their dependency using the function.-derived classes that implement this interface can be added to a with their dependency using the function.If the class ...
You are an experienced Unity developer specializing in C# scripting, XR/VR development, and performance optimization.
gh_fe6faf1191bb
github
scripting
Write a Unity C# MonoBehaviour script called Own Test8
```csharp using System.Collections; using UnityEngine; public class OwnTest8 : MonoBehaviourExtended, ITest { [OwnComponent(Optional = true)] private Inventory inv; private void Start() { if (!Test()) { Debug.LogError("Test failed: " + this); } } public bo...
You are an expert Unity game developer. Provide clear, accurate, and practical answers about Unity development.
local_sr_11d89d153fc0
unity_docs
scripting
What is `VideoClipImporter.deinterlaceMode` in Unity? Explain its purpose and usage.
VideoClipImporter.deinterlaceMode public VideoDeinterlaceMode deinterlaceMode ; Description Images are deinterlaced during transcode. This tells the importer how to interpret fields in the source, if any.
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_man_1cbac634b0ac
unity_docs
rendering
Explain 'Custom data Surface Shader example in the Built-In Render Pipeline' in Unity.
Using a vertex modifier function, it is also possible to compute custom data in a vertex Shader , which then will be passed to the Surface Shader function per-pixel. The same compilation directive vertex:functionName is used, but the function should take two parameters: inout appdata_full and out Input . You can fill i...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_5dcc3ce2eefb
unity_docs
rendering
What is `ShaderUtil.GetCurrentCustomEditor` in Unity? Explain its purpose and usage.
ShaderUtil.GetCurrentCustomEditor Declaration public static string GetCurrentCustomEditor ( Shader shader ); Parameters Parameter Description shader The shader to obtain the custom editor. Returns string The current custom editor full class name. Description Gets the current custom editor for the sh...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_man_d85a4912aa33
unity_docs
rendering
In Unity's 'Control scaling with Dynamic Resolution', what is 'Example' and how does it work?
This example script demonstrates basic use of the API. Add it to a Camera in your Scene, and check Allow Dynamic Resolution in the Camera settings. You also need to open the Player settings (menu: Edit > Project Settings , then select the Player category) and check the Enable Frame Timing Stats checkbox. For more infor...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.