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_0f968b18d727
unity_docs
scripting
Show me a Unity C# example demonstrating `Windows.CrashReporting.crashReportFolder`.
rtFolder ; Description Contains the path to the crash report folder on Windows. Crash reports are stored in the following location: %TMP%\CompanyName\ProductName\Crashes Crash reports are assigned a unique path on startup allowing you to determine in advance where a crash report will be stored if one occurs. Addit...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_ba5ebe63aca0
unity_docs
xr
What is `WWWForm.data` in Unity? Explain its purpose and usage.
WWWForm.data public byte[] data ; Description (Read Only) The raw data to pass as the POST request body when sending the form. Usually, you just pass the WWWForm object directly to the WWW constructor, but you will need this variable if you want to change the request headers sent to the web server. Additional r...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_faaa2403721a
unity_docs
editor
What are the parameters of `Profiling.FrameDataView.GetCounterValuePtr` in Unity?
Returns void* Returns unsafe pointer to the counter value. Description Gets unsafe pointer to the last value of a counter marker in the frame. Use to retrieve a pointer to the last data sample of a marker with MarkerFlags.Counter flag. ```csharp using UnityEditor.Profiling;class Example { static unsafe bool TryExtr...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_ccd951813117
unity_docs
editor
What is `EditorGUI.DelayedTextField` in Unity? Explain its purpose and usage.
EditorGUI.DelayedTextField Declaration public static string DelayedTextField ( Rect position , string text , GUIStyle style = EditorStyles.textField); Declaration public static string DelayedTextField ( Rect position , string label , string text , GUIStyle style = EditorStyles.textField); Decla...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_1e272647fddd
unity_docs
xr
What is `Unity.IO.LowLevel.Unsafe.FileStatus` in Unity? Explain its purpose and usage.
FileStatus enumeration Description The possible statuses of a FileHandle . Additional resources: FileHandle.Status , AsyncReadManager.OpenFileAsync Properties Property Description Closed The file has been closed. Pending The asynchronous operation to open the file is still in progress. Open The file is op...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_man_e2e2831bc0c0
unity_docs
rendering
In Unity's 'Enable shadows', what is 'Configure shadows' and how does it work?
To configure shadows for your whole project or a specific scene, refer to the following: Lighting window reference Graphics settings Universal Render Pipeline (URP) asset reference Universal Renderer asset
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_df89789df9bc
unity_docs
animation
What is `AnimatorClipInfo.clip` in Unity? Explain its purpose and usage.
AnimatorClipInfo.clip public AnimationClip clip ; Description Returns the animation clip played by the Animator. ```csharp //Create a GameObject and attach an Animator component (Click the Add Component button in the Inspector of the GameObject and go to Miscellaneous>Animator). Set up the Animator how you wo...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_3d7777812a9c
unity_docs
scripting
Show me a Unity C# example demonstrating `GUIStyle.normal`.
GUIStyle.normal public GUIStyleState normal ; Description Rendering settings for when the component is displayed normally. ```csharp using UnityEngine;public class Example : MonoBehaviour { // Prints the text color that button is using. void OnGUI() { Debug.Log(GUI.skin.button.normal.textColor); } } ```
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_8280e188ae84
unity_docs
scripting
What is `Experimental.Rendering.GraphicsFormat.RGBA_ASTC10X10_UNorm` in Unity? Explain its purpose and usage.
Experimental : this API is experimental and might be changed or removed in the future. GraphicsFormat.RGBA_ASTC10X10_UNorm Description A four-component, ASTC compressed format where each 128-bit compressed texel block encodes a 10×10 rectangle of unsigned normalized RGBA texel data.
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_man_4c6bfe854782
unity_docs
scripting
Show me a Unity code example for 'MultiColumnListView'.
used to display tabular or grid-like data with multiple columns. It allows you to present data in a structured format, where each row represents an item or entry, and each column represents a specific attribute or property of that item. ## Create a MultiColumnListView You can create a MultiColumnListView with UXML an...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_96349d7672d6
unity_docs
rendering
What is `LightingSettings.environmentSampleCount` in Unity? Explain its purpose and usage.
LightingSettings.environmentSampleCount public int environmentSampleCount ; Description Specifies the number of samples the Progressive Lightmapper uses when sampling indirect lighting from the skybox. (Editor only). Indirect lighting only uses 1 environment sample per bounce per indirect sample. However, this...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_02dcb38a8bd8
unity_docs
performance
What is `Profiling.Recorder.elapsedNanoseconds` in Unity? Explain its purpose and usage.
Recorder.elapsedNanoseconds public long elapsedNanoseconds ; Description Accumulated time of Begin/End pairs for the previous frame in nanoseconds. (Read Only) Long-lasting operations (for example, on a preloading thread) might not end within a single frame. In this case, elapsedNanoseconds is calculated unti...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_man_90cbd02f89ed
unity_docs
physics
Explain 'Layer-based collision detection' in Unity.
Layer-based collision detection is a way to make a GameObject collide with another GameObject that’s set up on a specific layer or layers. The Layer Collision Matrix defines which GameObjects can collide with which Layers. To open the Layer Collision Matrix go to Edit > Project Settings > Physics . In the image, the La...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_man_f959a73a9aef
unity_docs
rendering
In Unity's 'Memory Profiler module reference', what is 'Chart categories' and how does it work?
The Memory Profiler module’s chart has categories that display detailed information on where your application spends memory. Chart Description Total Used Memory The total memory your application used. Texture Memory How much memory the Textures in your application used. Mesh Memory How much memory the Meshes in your ap...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_afe9c7a701f2
unity_docs
animation
What is `Animations.AnimationSceneHandleUtility.ReadInts` in Unity? Explain its purpose and usage.
AnimationSceneHandleUtility.ReadInts Declaration public static void ReadInts ( Animations.AnimationStream stream , NativeArray<PropertySceneHandle> handles , NativeArray<int> buffer ); Parameters Parameter Description stream The animation stream. handles The PropertySceneHandle array to read from. buff...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_b64af3b3e6f3
unity_docs
rendering
What is `ScaleMode` in Unity? Explain its purpose and usage.
ScaleMode enumeration Description Scaling mode to draw textures with. Properties Property Description StretchToFill Stretches the texture to fill the complete rectangle passed in to GUI.DrawTexture. ScaleAndCrop Scales the texture, maintaining aspect ratio, so it completely covers the position rectangle passed...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_4b30e135ddcd
unity_docs
scripting
Give me an overview of the `Camera` class in Unity.
Camera class in UnityEngine / Inherits from: Behaviour / Implemented in: UnityEngine.CoreModule Description A Camera is a device through which the player views the world. A screen space point is defined in pixels. The bottom-left of the screen is (0,0); the right-top is ( pixelWidth , pixelHeight ). The z po...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_7992833a8031
unity_docs
ui
What is `UIElements.MinMaxSlider.movableUssClassName` in Unity? Explain its purpose and usage.
MinMaxSlider.movableUssClassName public static string movableUssClassName ; Description USS class name of the element that is currently controlled by NavigationMoveEvent . When a NavigationSubmitEvent is received the slider cycles through the elements in the following order: 1. Minimum thumb. 2. Maximum thu...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_565244b8f944
unity_docs
scripting
What is `Vector4.operator_multiply` in Unity? Explain its purpose and usage.
Vector4.operator * public static Vector4 operator * ( Vector4 a , float d ); Description Multiplies a vector by a number. Multiplies each component of a by a number d . ```csharp using UnityEngine;public class Example : MonoBehaviour { void Start() { // make the vector twice longer: prints (2.0,4.0,...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_4c5af32793c1
unity_docs
rendering
What is `TextureMipmapLimitSettings` in Unity? Explain its purpose and usage.
TextureMipmapLimitSettings struct in UnityEngine / Implemented in: UnityEngine.CoreModule Description Structure that represents texture mipmap limit settings. This code example illustrates how to modify TextureMipmapLimitSettings from script. ```csharp #if UNITY_EDITOR using UnityEngine; using UnityEditor;pu...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_c3cb06ae41f6
unity_docs
rendering
What is `Experimental.Rendering.GraphicsFormatUtility.GetTextureFormat` in Unity? Explain its purpose and usage.
Experimental : this API is experimental and might be changed or removed in the future. GraphicsFormatUtility.GetTextureFormat Declaration public static TextureFormat GetTextureFormat ( Experimental.Rendering.GraphicsFormat format ); Description Translates GraphicsFormat into TextureFormat.
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_c65341e6db80
unity_docs
scripting
What is `SceneTemplate.SceneTemplateService.newSceneTemplateInstantiating` in Unity? Explain its purpose and usage.
SceneTemplateService.newSceneTemplateInstantiating Parameters Parameter Description value A user-defined handler that is called before a Scene template is instantiated. Description Events fired before a Scene template is instantiated.
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_0be595699552
unity_docs
rendering
Show me a Unity C# example demonstrating `ColorUtility.TryParseHtmlString`.
red, cyan, blue, darkblue, lightblue, purple, yellow, lime, fuchsia, white, silver, grey, black, orange, brown, maroon, green, olive, navy, teal, aqua, magenta.. The following example creates a custom PropertyDrawer that allows the user to input html colors. This property drawer can be shown in the inspector when a co...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_3b18e1f070eb
unity_docs
rendering
Show me a Unity C# example demonstrating `ShaderKeywordFilter.FilterAttribute`.
nly apply to the build if they're attached to a serialized data field that's part of the type tree of a RenderPipelineAsset referenced by QualitySettings . The attributes give you control over which shader keywords Unity uses to build shader variants, based on render pipeline settings. For example, by default the fo...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_man_04dcb265c389
unity_docs
rendering
Show me a Unity code example for 'Control material properties in the Inspector window'.
omEditorForRenderPipeline block, the render pipeline specific one overrides the CustomEditor one. ## Create a custom editor class for a shader asset To define a custom editor for shader assets that represent a given Shader object , you create a script that inherits from the ShaderGUI class. Place your script in a fol...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_c0ac24cf88e9
unity_docs
physics
What is `Terrain.CreateTerrainGameObject` in Unity? Explain its purpose and usage.
Terrain.CreateTerrainGameObject Declaration public static GameObject CreateTerrainGameObject ( TerrainData assignTerrain ); Description Creates a Terrain including collider from TerrainData .
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_3123a8bd506f
unity_docs
scripting
What is `AudioConfiguration.dspBufferSize` in Unity? Explain its purpose and usage.
AudioConfiguration.dspBufferSize public int dspBufferSize ; Description The length of the DSP buffer in samples determining the latency of sounds by the audio output device. This buffer size only accounts for the size of a single DSP buffer. It doesn't include additional latency caused by multiple DSP buffers o...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_b7c1967ca87e
unity_docs
scripting
What is `UIElements.BaseTreeView.ExpandItem` in Unity? Explain its purpose and usage.
BaseTreeView.ExpandItem Declaration public void ExpandItem (int id , bool expandAllChildren , bool refresh ); Parameters Parameter Description id The TreeView item identifier. expandAllChildren When true, all children will also get expanded. This is false by default. refresh Whether to refresh items or...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_5c30b701da21
unity_docs
scripting
What is `RenderingLayerMask.GetDefinedRenderingLayersCombinedMaskValue` in Unity? Explain its purpose and usage.
RenderingLayerMask.GetDefinedRenderingLayersCombinedMaskValue Declaration public static uint GetDefinedRenderingLayersCombinedMaskValue (); Returns uint Current Rendering Layers mask for all defined Rendering Layers. Description Returns value that represents all defined Rendering Layers in the Tags and La...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_man_ac51aa9cf0f3
unity_docs
rendering
Explain 'Custom textures' in Unity.
Resources for importing, converting, and loading textures so that you can use them in shaders and materials. Page Description Get started with textures Learn about texture types, GPU texture formats , and mipmaps. Import a texture Import an image or movie file as a Texture asset. Texture arrays Resources for creating a...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_5cfda52549fc
unity_docs
input
What is `QualitySettings.maxQueuedFrames` in Unity? Explain its purpose and usage.
QualitySettings.maxQueuedFrames public static int maxQueuedFrames ; Description Maximum number of frames queued up by graphics driver. Graphics drivers queue up frames that are yet to be rendered, especially when the CPU has lesser processes to execute than the graphics card, this queue can grow large. In suc...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_75ed22fd6f31
unity_docs
math
Show me a Unity C# example demonstrating `Camera.CalculateFrustumCorners`.
Description Given viewport coordinates, calculates the view space vectors pointing to the four frustum corners at the specified camera depth. The order of the corners is lower left, upper left, upper right, lower right. CalculateFrustumCorners can be used to efficiently calculate the world space position of a pixel ...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_man_023606861822
unity_docs
rendering
In Unity's 'Using Streaming Virtual Texturing in Shader Graph', what is 'Shader Graph compatibility' and how does it work?
You must assign all texture slots of the Virtual Texture Property in Shader Graph. SVT copies each unique combination of textures you assign to a Virtual Texture Property to a unique section of the streaming virtual texture. Therefore, if you use many different combinations of textures in a Virtual Texture Property, it...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_1f6fb0347f12
unity_docs
scripting
Show me a Unity C# example demonstrating `Transform.eulerAngles`.
le demonstrates the rotation of a GameObject using eulerAngles based on the Input of the user. The example shows that we never rely on reading the Quanternion.eulerAngles to increment the rotation, instead we set it using our Vector3 currentEulerAngles. All rotational changes happen in the currentEulerAngles variable, ...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_69bb96ec41f6
unity_docs
rendering
What is `Rendering.DrawingSettings.SetShaderPassName` in Unity? Explain its purpose and usage.
DrawingSettings.SetShaderPassName Declaration public void SetShaderPassName (int index , Rendering.ShaderTagId shaderPassName ); Parameters Parameter Description index Index of the shader pass to use. shaderPassName Name of the shader pass. Description Set the name of the shader pass.
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_851f845f14b4
unity_docs
scripting
Show me a Unity C# example demonstrating `IMGUI.Controls.JointAngularLimitHandle`.
ols Description A class for a compound handle to edit multiaxial angular motion limits in the Scene view. JointAngularLimitHandle in the Scene View. The shapes rendered by the DrawHandle method assume that angular limits are applied first along the x-axis, then the y-axis, and finally the z-axis. The following co...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_0ae1129134ba
unity_docs
physics
What is `SliderJoint2D.angle` in Unity? Explain its purpose and usage.
SliderJoint2D.angle public float angle ; Description The angle of the line in space (in degrees). The line along which the joint can slide is specified by its world angle and optionally by endpoint limits along its length. Additional resources: limits .
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_man_196a5e101590
unity_docs
editor
Explain 'Cache location reference' in Unity.
If you need to investigate build problems, then it can be useful to understand where Unity stores the caches and metadata files related to a Player build. File location Description Library/Bee Contains most cached build content. Library/BuildPlayerData Contains TypeDB files that record the schema of each C# type in you...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_man_eea18b1175e4
unity_docs
rendering
Explain 'Choosing a render pipeline' in Unity.
Resources for comparing the different render pipelines in Unity and choosing the right one for your project. Page Description Choose a render pipeline Compare the Universal Render Pipeline (URP), the High Definition Render Pipeline (HDRP), and the Built-In Render Pipeline. Render pipeline feature comparison reference E...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_21ca4f93bef3
unity_docs
physics
Give me an overview of the `ColliderDistance2D` class in Unity.
ColliderDistance2D struct in UnityEngine / Implemented in: UnityEngine.Physics2DModule Description Represents the separation or overlap of two Collider2D . The ColliderDistance2D primarily defines a point on the exterior of each Collider2D along with the distance between those two points. The distance ...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_22b2381cbb1f
unity_docs
rendering
What is `Rendering.BuiltinRenderTextureType.ResolvedDepth` in Unity? Explain its purpose and usage.
BuiltinRenderTextureType.ResolvedDepth Description Resolved depth buffer from deferred. The resolved depth buffer contains depth written when filling G-buffers as well as depth from forward rendered objects if there's an active shadowed directional light, or if the camera has requested a depth texture. Additional r...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_man_ab18cf25cc33
unity_docs
physics
In Unity's 'Articulation Body component reference', what is 'Properties' and how does it work?
An Articulation Body allows you to define in one single component the properties that you would similarly define through a RigidBody and a regular Joint in a classic configuration. That said, these properties depend on the GameObject position in the hierarchy: For the root GameObject of the articulation, you can only s...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_ed34fd069f5f
unity_docs
rendering
Give me an overview of the `TextureImporterPlatformSettings` class in Unity.
TextureImporterPlatformSettings class in UnityEditor Description Stores platform specifics settings of a TextureImporter . Additional resources: TextureImporter. Properties Property Description allowsAlphaSplitting Allows Alpha splitting on the imported texture when needed (for example ETC1 compression for t...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_a17add74d895
unity_docs
scripting
What is `UIElements.MouseCaptureOutEvent` in Unity? Explain its purpose and usage.
MouseCaptureOutEvent class in UnityEngine.UIElements / Inherits from: UIElements.MouseCaptureEventBase_1 / Implemented in: UnityEngine.UIElementsModule Description Event sent before a handler stops capturing the mouse. Inherited Members Properties Property Description bubbles Returns whether this event...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_22aafb0579a1
unity_docs
scripting
What is `GameObject.scene` in Unity? Explain its purpose and usage.
GameObject.scene public SceneManagement.Scene scene ; Description The Scene that contains the GameObject. ```csharp //Output the name of the Scene this GameObject belongs tousing UnityEngine; using UnityEngine.SceneManagement;public class Example : MonoBehaviour { void Start() { Scene scene = gameObject.s...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_829b981dc8be
unity_docs
math
What is `Mathf.Round` in Unity? Explain its purpose and usage.
Mathf.Round Declaration public static float Round (float f ); Description Returns f rounded to the nearest integer. If the number ends in .5 so it is halfway between two integers, one of which is even and the other odd, the even number is returned. ```csharp using UnityEngine; using System.Collections;publ...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_f5226f4a27fd
unity_docs
scripting
What is `Unity.Android.Gradle.PropertyString` in Unity? Explain its purpose and usage.
PropertyString class in Unity.Android.Gradle / Inherits from: Unity.Android.Gradle.Property_1 Description String property type. Inherited Members Public Methods Method Description AddElementDependencies Adds a list of dependencies by ID to this element. AddElementDependency Adds a dependency to this element....
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
gh_6e46ad405037
github
scripting
Write a Unity C# script called Tool Config
```csharp using System; using UnityEngine; namespace CurvePickerTool { [Serializable] public class ToolConfig { public bool m_CanInsertSwatch; public bool m_CanRemoveSwatch; public bool CanRemoveSwatch => m_CanRemoveSwatch; public bool CanInsertSwatch => m_CanInser...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_0174c4242c4f
unity_docs
scripting
What is `DelayedAttribute` in Unity? Explain its purpose and usage.
DelayedAttribute class in UnityEngine / Inherits from: PropertyAttribute / Implemented in: UnityEngine.CoreModule Description Attribute used to make a float, int, or string variable in a script be delayed. When this attribute is used, the float, int, or text field will not return a new value until the user ha...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_a42afcf5702f
unity_docs
editor
Show me a Unity C# example demonstrating `PrefabUtility.GetCorrespondingObjectFromSource`.
you supply the instance of GameObject C as the componentOrGameObject parameter to GetCorrespondingObjectFromSource , then the method returns the object C from the asset Prefab A. For more information about source objects, refer to Introduction to prefabs . The following example adds a menu item to the Editor, which...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_be763ac6785e
unity_docs
scripting
What is `UIElements.SearchFieldBase_2.FieldIsEmpty` in Unity? Explain its purpose and usage.
SearchFieldBase<T0,T1>.FieldIsEmpty Declaration protected bool FieldIsEmpty (T fieldValue ); Parameters Parameter Description fieldValue The value to check. Returns bool True if the parameter is empty. That meaning depends on the type of T. Description Tells if the field is empty. That meaning depen...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_467df54b1b2c
unity_docs
scripting
What is `IExposedPropertyTable.ClearReferenceValue` in Unity? Explain its purpose and usage.
IExposedPropertyTable.ClearReferenceValue Declaration public void ClearReferenceValue ( PropertyName id ); Parameters Parameter Description id Identifier of the ExposedReference. Description Remove a value for the given reference.
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_71eff412eb72
unity_docs
performance
What is `Experimental.Rendering.ExternalGPUProfiler.BeginGPUCapture` in Unity? Explain its purpose and usage.
Experimental : this API is experimental and might be changed or removed in the future. ExternalGPUProfiler.BeginGPUCapture Declaration public static void BeginGPUCapture (); Description Begins the current GPU frame capture in the external GPU profiler.
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_be1b6417b501
unity_docs
scripting
What is `GUIStyle.CalcMinMaxWidth` in Unity? Explain its purpose and usage.
GUIStyle.CalcMinMaxWidth Declaration public void CalcMinMaxWidth ( GUIContent content , out float minWidth , out float maxWidth ); Description Calculate the minimum and maximum widths for this style rendered with content . Used by GUILayout to handle word-wrapping elements correctly.
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_800e1c5fddba
unity_docs
rendering
What is `Shader.GetPropertyAttributes` in Unity? Explain its purpose and usage.
Shader.GetPropertyAttributes Declaration public string[] GetPropertyAttributes (int propertyIndex ); Parameters Parameter Description propertyIndex The index of the shader property. Description Returns an array of strings containing attributes of the shader property at the specified index. Attributes are...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_9d6dec2e751b
unity_docs
rendering
Give me an overview of the `CameraClearFlags` class in Unity.
CameraClearFlags enumeration Description Values for Camera.clearFlags, determining what to clear when rendering a Camera . Additional resources: camera component . Properties Property Description Skybox Clear with the skybox. SolidColor Clear with a background color. Depth Clear only the depth buffer. Not...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_bd5b1644b63f
unity_docs
rendering
What is `Rendering.LoadStoreActionDebugModeSettings` in Unity? Explain its purpose and usage.
LoadStoreActionDebugModeSettings class in UnityEngine.Rendering / Implemented in: UnityEngine.CoreModule Description Whether to show undefined areas of the display that might cause rendering problems in your built application. If you create a RenderTexture , it might have undefined ('invalidated') pixels. Rend...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_daa1dd58f0b6
unity_docs
editor
What is `IMGUI.Controls.BoxBoundsHandle` in Unity? Explain its purpose and usage.
BoxBoundsHandle class in UnityEditor.IMGUI.Controls / Inherits from: IMGUI.Controls.PrimitiveBoundsHandle Description A compound handle to edit a box-shaped bounding volume in the Scene view. 2D and 3D BoxBoundsHandle in the Scene View. Additional resources: PrimitiveBoundsHandle . Properties Property Desc...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_e27ea5afe63a
unity_docs
math
What is `Vector4.Normalize` in Unity? Explain its purpose and usage.
Vector4.Normalize Declaration public void Normalize (); Description Makes this vector have a magnitude of 1. When normalized, a vector keeps the same direction but its length is 1.0. Note that this function will change the current vector. If you want to keep the current vector unchanged, use normalized vari...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_9397b0b208a2
unity_docs
physics
Give me an overview of the `ArticulationDrive` class in Unity.
ArticulationDrive struct in UnityEngine / Implemented in: UnityEngine.PhysicsModule Description Drive applies forces and torques to the connected bodies. Drive moves the body along one degree of freedom, be it a linear motion along a particular axis or a rotational motion around a particular axis. The drive wil...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_6ead6a3d0e0b
unity_docs
rendering
What is `Mesh.tangents` in Unity? Explain its purpose and usage.
Mesh.tangents public Vector4[] tangents ; Description The tangents of the Mesh. Tangents are mostly used in bump-mapped Shaders. A tangent is a unit-length vector that follows Mesh surface along horizontal (U) texture direction. Tangents in Unity are represented as Vector4 , with x,y,z components defining t...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_67dd0820e876
unity_docs
physics
What is `ShortcutManagement.ShortcutAttribute.ctor` in Unity? Explain its purpose and usage.
ShortcutAttribute Constructor Declaration public ShortcutAttribute (string id , Type context = null); Declaration public ShortcutAttribute (string id , Type context , KeyCode defaultKeyCode , ShortcutManagement.ShortcutModifiers defaultShortcutModifiers = None); Declaration public ShortcutAttribu...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_man_54031b3ccda2
unity_docs
scripting
Explain 'UI Toolkit Debugger' in Unity.
The UI Toolkit Debugger is a tool that you can use to inspect and debug your UI elements in real-time. It provides a visual representation of your UI hierarchy. You use it to examine the state and properties of each UI element. When you open the UI Toolkit Debugger, it displays a window that shows a live view of your U...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_585182a14000
unity_docs
math
What is `Mathf.Floor` in Unity? Explain its purpose and usage.
Mathf.Floor Declaration public static float Floor (float f ); Description Returns the largest integer smaller than or equal to f . ```csharp using UnityEngine; using System.Collections;public class ExampleClass : MonoBehaviour { void Example() { Debug.Log(Mathf.Floor(10.0F)); // Prints 10 Debug.Log(Mathf...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
gh_69871e5133e7
github
scripting
Write a Unity C# script called Main Controller
```csharp using RMC.Core.Architectures.Umvcs.Controller; using RMC.Core.Architectures.Umvcs.Model.Data.Types; using RMC.Core.Architectures.Umvcs.Samples.MyBouncyBallExample.Umvcs.Controller.Commands; using RMC.Core.Architectures.Umvcs.Samples.MyBouncyBallExample.Umvcs.Model; using RMC.Core.Architectures.Umvcs.Samples....
You are a senior Unity engineer. Answer questions about Unity scripting, XR/VR development, and game systems with working code examples.
local_sr_2ff35ff38ae8
unity_docs
scripting
What is `Search.SearchViewState.ctor` in Unity? Explain its purpose and usage.
SearchViewState Constructor Declaration public SearchViewState ( Search.SearchContext context ); Declaration public SearchViewState ( Search.SearchContext context , Search.SearchViewFlags flags ); Parameters Parameter Description context Initial search context. flags Initial search view flags. D...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
gh_2396b5707e39
github
scripting
Write a Unity C# script called Update Job Data
```csharp using System; using Unity.Collections; using UnityEngine; namespace Gilzoide.UpdateManager.Jobs.Internal { public class UpdateJobData<TData, TDataProvider> : IDisposable where TData : struct where TDataProvider : IInitialJobDataProvider<TData> { public UnsafeNativeList<TData> ...
You are an experienced Unity developer specializing in C# scripting, XR/VR development, and performance optimization.
local_sr_6131fc84f049
unity_docs
scripting
What is `LightProbes.SetPositionsSelf` in Unity? Explain its purpose and usage.
LightProbes.SetPositionsSelf Declaration public bool SetPositionsSelf (Vector3[] positions , bool checkForDuplicatePositions ); Parameters Parameter Description checkForDuplicatePositions Whether to check for duplicate light probe positions at the cost of performance. positions The positions to set. Retu...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_c79f138cdb88
unity_docs
scripting
What is `UIElements.PointerEventBase_1.shiftKey` in Unity? Explain its purpose and usage.
PointerEventBase<T0>.shiftKey public bool shiftKey ; Description Gets a boolean value that indicates whether the Shift key is pressed. True means the Shift key is pressed. False means it isn't.
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_6224639f6123
unity_docs
rendering
Show me a Unity C# example demonstrating `ParticleSystemRenderer.trailMaterial`.
ParticleSystemRenderer.trailMaterial public Material trailMaterial ; Description Set the Material that the TrailModule uses to attach trails to particles. Additional resources: ParticleSystem.trails . ```csharp using UnityEngine; using System.Collections;[RequireComponent(typeof(ParticleSystem))] public cla...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_3b99c7dcd0d4
unity_docs
scripting
What are the parameters of `Undo.RegisterCreatedObjectUndo` in Unity?
Description Registers an undo operation to undo the creation of an object. This method registers the creation of an object to the undo stack so that users can undo a create object action. Use this method each time you define an action that creates an object, for example, inside a custom Editor or menu item. Unity updat...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_d1557184a929
unity_docs
scripting
What is `Screen.height` in Unity? Explain its purpose and usage.
Screen.height public static int height ; Description The current height of the screen window in pixels (Read Only). This is the actual height of the Player window. In full-screen mode, it reflects the current resolution. Note : When accessed from the Editor events, such as ContextMenu methods, inspector enabl...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_efbabbd359fa
unity_docs
scripting
What is `Experimental.Rendering.GraphicsFormat.R_BC4_UNorm` in Unity? Explain its purpose and usage.
Experimental : this API is experimental and might be changed or removed in the future. GraphicsFormat.R_BC4_UNorm Description A one-component, block-compressed format where each 64-bit compressed texel block encodes a 4×4 rectangle of unsigned normalized red texel data.
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_6b556a33dd08
unity_docs
scripting
What is `ReflectionProbe.ReflectionProbeEvent.ReflectionProbeAdded` in Unity? Explain its purpose and usage.
ReflectionProbe.ReflectionProbeEvent.ReflectionProbeAdded Description An event that occurs when a Reflection Probe component is added to a Scene or enabled in a Scene. Additional resources: ReflectionProbe .
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_aea2acf03252
unity_docs
scripting
What is `SystemLanguage.Slovenian` in Unity? Explain its purpose and usage.
SystemLanguage.Slovenian Description Slovenian. ```csharp using UnityEngine;public class Example : MonoBehaviour { void Start() { //This checks if your computer's operating system is in the Slovenian language if (Application.systemLanguage == SystemLanguage.Slovenian) { //Outputs into console that the system ...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_504d139f9f43
unity_docs
scripting
What is `UIElements.NavigationEventBase_1.shiftKey` in Unity? Explain its purpose and usage.
NavigationEventBase<T0>.shiftKey public bool shiftKey ; Description Gets a boolean value that indicates whether the Shift key is pressed. True means the Shift key is pressed. False means it isn't.
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_7fa232a7c771
unity_docs
physics
What is `Rigidbody2D.SlideMovement.surfaceSlideAngle` in Unity? Explain its purpose and usage.
Rigidbody2D.SlideMovement.surfaceSlideAngle public float surfaceSlideAngle ; Description When the velocity movement causes a contact with a Collider2D , a slide maybe occur if the surface angle is less than this angle. Use this angle threshold to control whether slippage will occur on surface slopes above the ...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_man_428217dfad4f
unity_docs
rendering
In Unity's 'Background Tasks window reference', what is 'View task status' and how does it work?
Background tasks can have the following statuses: Status Description Icon Active The task is running and reports progress as percent complete, or estimated time remaining. None Indeterminate The task is running and reports progress, but cannot determine how close it is to being complete. None Finished The task finished...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_30cfcbf828ca
unity_docs
rendering
What is `LightTransport.ReferenceContext.GetNativeArray` in Unity? Explain its purpose and usage.
ReferenceContext.GetNativeArray Declaration public NativeArray<byte> GetNativeArray ( LightTransport.BufferID id ); Parameters Parameter Description id ID of the buffer to get the underlying NativeArray from. Returns NativeArray<byte> The NativeArray of bytes for a given BufferID . Description Get ...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_man_6d3c17860a15
unity_docs
rendering
Explain 'Android build settings reference' in Unity.
Use the Android build settings to configure and build your application for Android platform. The Android build settings are part of the Platform Settings section of the Build Profiles window . Property Description Texture Compression The texture compression format to use for the build. The options are: Use Player Setti...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_a713f48be740
unity_docs
editor
What is `AssetDatabase.CopyAssets` in Unity? Explain its purpose and usage.
AssetDatabase.CopyAssets Declaration public static bool CopyAssets (string[] paths , string[] newPaths ); Parameters Parameter Description paths Filesystem paths of the source assets. newPaths Filesystem paths of the new assets to create. Returns bool Returns true if the copy operation is successful o...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_man_bc9406f34eff
unity_docs
rendering
Explain 'Build your application for Android' in Unity.
Refer to the following instructions on how to build your Unity application for Android and considerations to be aware of when you do. For information on the build process for Android and the tools Unity uses, refer to How Unity builds Android applications . Instead of building your application, you can also export the ...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_3856c9cb87fb
unity_docs
input
Show me a Unity C# example demonstrating `Input.anyKey`.
Input.anyKey public static bool anyKey ; Description Is any key or mouse button currently held down? (Read Only) Note : This API is part of the legacy Input Manager. The recommended best practice is that you don't use this API in new projects. For new projects, use the Input System package. To learn more about ...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_man_0c7618225f48
unity_docs
rendering
In Unity's 'IMGUI Basics', what is 'Type' and how does it work?
Type is the Control Type , and is declared by calling a function in Unity’s GUI class or the GUILayout class , which is discussed at length in the Layout Modes section of the Guide. For example, GUI.Label() will create a non-interactive label. All the different control types are explained later, in the Controls section...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_man_f265281992d3
unity_docs
scripting
In Unity's 'Place Light Probes with the Editor', what is 'Choosing Light Probe positions' and how does it work?
Unlike lightmaps , which usually have a continuous resolution across the surface of an object, the resolution of the Light Probe information depends on how closely packed you choose to position the Light Probes. To optimise the amount of data that Light Probes store, and the amount of computation done while the game is...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_a799fbf3b3e6
unity_docs
editor
What are the parameters of `EditorWindow.GetWindowWithRect` in Unity?
Description Returns the first EditorWindow of type t which is currently on the screen. If there is none, creates and shows new window at the position rect and returns the instance of it. Create an empty 100x150px window at the upper left corner of the screen. ```csharp using UnityEngine; using UnityEditor; // Create a...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_man_fde903114187
unity_docs
rendering
Explain 'How Unity compiles branching shaders' in Unity.
When you use a keyword, you can choose how Unity compiles the shader code. The options are: Dynamic branching: Unity keeps branching code in one compiled shader program. Shader variants: Unity compiles a separate shader program called a shader variant for each branch. This is a form of static branching, and can help mi...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_716da1e9b0e6
unity_docs
editor
Show me a Unity C# example demonstrating `MonoImporter.GetAllRuntimeMonoScripts`.
MonoImporter.GetAllRuntimeMonoScripts Declaration public static MonoScript[] GetAllRuntimeMonoScripts (); Returns MonoScript[] Returns an array of scripts. Description Gets an array of scripts that will be available at runtime. Additional resources: AssetDatabase.FindAssets . ```csharp using UnityEngine...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_1437b7d59635
unity_docs
scripting
What is `Progress.Item.ClearRemainingTime` in Unity? Explain its purpose and usage.
Progress.Item.ClearRemainingTime Declaration public void ClearRemainingTime (); Description Resets the computation of the progress indicator's remaining time. If the remaining time was set manually, it reverts to its default state where it is computed automatically. Additional resources: Progress.ClearRemainin...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_55778631c546
unity_docs
scripting
What is `Networking.UnityWebRequest.PostWwwForm` in Unity? Explain its purpose and usage.
UnityWebRequest.PostWwwForm Declaration public static Networking.UnityWebRequest PostWwwForm (string uri , string form ); Declaration public static Networking.UnityWebRequest PostWwwForm (Uri uri , string form ); Parameters Parameter Description uri The target URI to which form data will be transm...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_61352a81f9ec
unity_docs
rendering
What is `Rendering.CameraProperties` in Unity? Explain its purpose and usage.
CameraProperties struct in UnityEngine.Rendering / Implemented in: UnityEngine.CoreModule Description Camera related properties in CullingParameters. Typical use case is to compute culling parameters from Camera data, see CullingResults.GetCullingParameters. Public Methods Method Description GetCameraCull...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
gh_22c48f0f93d7_doc_4
github
scripting
What does `UnregisterSynchronization` do in this Unity script? Explain its purpose and signature.
Unregister from job data synchronization.Unregistering job provider objects is O(1).Unregistering an object that wasn't registered is a no-op. Signature: ```csharp public void UnregisterSynchronization(TDataProvider provider) ```
You are a senior Unity engineer. Answer questions about Unity scripting, XR/VR development, and game systems with working code examples.
local_sr_d8da8a8bc8b8
unity_docs
scripting
What are the parameters of `Physics.ContactModifyEvent` in Unity?
Description Subscribe to this event to be able to customize the collision response for contact pairs. Each subscriber to this event gets invoked with a physics scene and a native array of contact pairs to process. Each contact pair has modifiable data, like impulses and contact normals that can be changed in order to c...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_714614f6ab7b
unity_docs
rendering
Show me a Unity C# example demonstrating `Mesh.GetVertexBuffer`.
eBuffer.SetBuffer, Material.SetBuffer and similar methods. GetVertexBufferStride , GetVertexAttributeOffset and related methods can be used to query the exact mesh vertex data layout and format, so that the compute shader can access it properly. If you modify the CPU copy of the data, this can cause the GPU vertex ...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_74395a486813
unity_docs
scripting
What is `UIElements.ValidateCommandEvent` in Unity? Explain its purpose and usage.
ValidateCommandEvent class in UnityEngine.UIElements / Inherits from: UIElements.CommandEventBase_1 / Implemented in: UnityEngine.UIElementsModule Description This event is sent by the Editor while it determines whether the command will be handled by an element in the panel. See also: Command Events . ...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_90410dc23e24
unity_docs
scripting
What is `MonoBehaviour.didAwake` in Unity? Explain its purpose and usage.
MonoBehaviour.didAwake public bool didAwake ; Description Returns a boolean value which represents if Awake was called. ```csharp using UnityEngine;public class NewBehaviourScript : MonoBehaviour { void Awake() { // Code is within Awake, therefore will print 'true', as Awake was called. Debug.Log(this.didA...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_b065418321cc
unity_docs
scripting
What is `ParticleSystem.trails` in Unity? Explain its purpose and usage.
ParticleSystem.trails public ParticleSystem.TrailModule trails ; Description Script interface for the TrailsModule of a Particle System. This module adds trails to your particles. Trails can either be left in the wake of particles as they move, or can connect each particle in the system together. Particle Sy...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
gh_38a1071e82e8_doc_12
github
scripting
What does `RandomizeSpawnOption` do in this Unity script? Explain its purpose and signature.
Sets this behavior to select a random object from each time it spawns. Signature: ```csharp public void RandomizeSpawnOption() ```
You are an expert Unity game developer. Provide clear, accurate, and practical answers about Unity development.
local_sr_5dbb20d82a36
unity_docs
scripting
What is `Unity.Android.Gradle.Manifest.Category.AttributesContainer` in Unity? Explain its purpose and usage.
AttributesContainer class in Unity.Android.Gradle.Manifest / Inherits from: Unity.Android.Gradle.Manifest.BaseAttributesContainer Description The attributes container for the <category> element. Properties Property Description Name The C# definition of the android:name Android Manifest attribute. Inheri...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_5a9202cac91e
unity_docs
ui
What is `GUILayout.HorizontalScope` in Unity? Explain its purpose and usage.
HorizontalScope class in UnityEngine / Implemented in: UnityEngine.IMGUIModule Description Disposable helper class for managing BeginHorizontal / EndHorizontal . All controls rendered inside this element will be placed horizontally next to each other. The using statement means BeginHorizontal and EndHor...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.