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_bc3e63bb16d5
unity_docs
rendering
What is `TextureImporterPlatformSettings.resizeAlgorithm` in Unity? Explain its purpose and usage.
TextureImporterPlatformSettings.resizeAlgorithm public TextureResizeAlgorithm resizeAlgorithm ; Description For Texture to be scaled down choose resize algorithm. ( Applyed only when Texture dimension is bigger than Max Size ). Additional resources: TextureResizeAlgorithm .
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_a9ab07b3bca3
unity_docs
editor
Give me an overview of the `PauseState` class in Unity.
PauseState enumeration Description Enumeration specifying the current pause state of the Editor. Additional resources: PlayModeStateChange , EditorApplication.pauseStateChanged , EditorApplication.isPaused . Properties Property Description Paused Occurs as soon as the Editor is paused, which may occur during...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_bd68c0418da2
unity_docs
rendering
What is `Rendering.RendererListParams.tagValues` in Unity? Explain its purpose and usage.
RendererListParams.tagValues public Nullable<NativeArray<ShaderTagId>> tagValues ; Description An array of ShaderTagId structs, where the name is the value of a given SubShader Tag or Pass Tag .
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_dd1940bba1ae
unity_docs
scripting
What is `HDRDisplayBitDepth` in Unity? Explain its purpose and usage.
HDRDisplayBitDepth enumeration Description Options for the number of bits for HDR output in each color channel of swap chain buffers. Applicable when an HDR display is active. The bit count also defines the method Unity uses to render content to the display. Properties Property Description BitDepth10 Unity use...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_man_5033587556bb
unity_docs
editor
Explain 'Profiler command line arguments' in Unity.
Set how the Profiler starts from the command line. If you start your built player or the Unity Editor from the command line (such as the Command Prompt on Windows, Terminal on macOS, Linux shell, or adb for Android), you can pass command line arguments to configure some Profiler settings. For more information about sta...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_f4f4f7c1583b
unity_docs
ui
What is `UIElements.Vertex` in Unity? Explain its purpose and usage.
Vertex struct in UnityEngine.UIElements / Implemented in: UnityEngine.UIElementsModule Description Represents a vertex of geometry for drawing content of VisualElement . Static Properties Property Description nearZ A special value representing the near clipping plane. Always use this value as the verte...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_man_0dbd0190818a
unity_docs
scripting
Show me a Unity code example for 'AssetBundle caching'.
hen downloading without caching, Unity downloads the AssetBundle into a memory file then loads it. If the downloaded file is in LZMA format then Unity recompresses it into a memory file in LZ4 format and loads that instead. ## Location of the AssetBundle cache The local AssetBundle cache exists at a root folder (for ...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_063ba41858c1
unity_docs
scripting
What is `Unity.IO.LowLevel.Unsafe.AsyncReadManagerMetricsFilters` in Unity? Explain its purpose and usage.
AsyncReadManagerMetricsFilters class in Unity.IO.LowLevel.Unsafe / Implemented in: UnityEngine.CoreModule Description Defines a filter for selecting specific categories of data when summarizing AsyncReadManager metrics. Pass a filter to AsyncReadManagerMetrics.GetCurrentSummaryMetrics or AsyncReadManagerMe...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_5b14f5cb1d89
unity_docs
scripting
What is `UIElements.CommandEventBase_1.GetPooled` in Unity? Explain its purpose and usage.
CommandEventBase<T0>.GetPooled Declaration public static T GetPooled ( Event systemEvent ); Parameters Parameter Description systemEvent An IMGUI command event. Returns T An initialized event. Description Gets an event from the event pool and initializes it with the given values. Use this function ...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_cbeb2fe2bc73
unity_docs
editor
What are the parameters of `AssetDatabase.TryGetAssetFolderInfo` in Unity?
Returns bool Returns true if the given path is in a folder managed by the AssetDatabase, false otherwise. Description Get AssetDatabase specific information about a folder. This method can be used to know whether a path is tracked by the AssetDatabase. Being tracked means that files added to this folder will have a .me...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_d695c6d82d0f
unity_docs
editor
What is `InspectorOrderAttribute` in Unity? Explain its purpose and usage.
InspectorOrderAttribute class in UnityEngine / Inherits from: PropertyAttribute / Implemented in: UnityEngine.CoreModule Description Shows sorted enum values in the Inspector enum UI dropdowns i.e. EditorGUI.EnumPopup , PropertyField etc. This attribute can be applied to enum types only. Note: this attribute...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_bfd27a5dd33b
unity_docs
physics
What is `PointEffector2D.angularDrag` in Unity? Explain its purpose and usage.
PointEffector2D.angularDrag public float angularDrag ; Description The angular drag to apply to rigid-bodies. The angularDrag coefficient is applied in addition to the standard Rigidbody2D angular drag coefficient to provide additional angular drag in the effector area.
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_man_8cf94d09011a
unity_docs
ui
In Unity's 'Grid and Snap toolbar overlay', what is 'Snapping menu reference' and how does it work?
Property Description Grid Size Set the size of the grid visuals and the increment snap value to use for the Move tool . Snap to Grid Enable snapping GameObjects to the absolute position on the grid. This option only functions when your handle rotation is set to Global . Rotate Enter a increment snap value for the Rotat...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_man_5a8e8592eeca
unity_docs
physics
In Unity's 'Create and configure a trigger collider', what is 'Configure trigger collisions' and how does it work?
Make sure there is at least one dynamic collider in the collision . At least one GameObject involved in a trigger collision must have a physics body (a Rigidbody or an ArticulationBody). In most cases, trigger colliders are stationary and static (that is, they have no physics body), and the colliders that pass through ...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_04429602b36a
unity_docs
scripting
What is `ShaderInclude` in Unity? Explain its purpose and usage.
ShaderInclude class in UnityEditor / Inherits from: TextAsset Description Shader include file asset. Inherited Members Properties Property Description hideFlags Should the object be hidden, saved with the Scene or modifiable by the user? name The name of the object. bytes The raw bytes of the text asset. (R...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_f175f55566a1
unity_docs
rendering
What is `TerrainTools.TerrainPaintUtility.GetHeightBlitMaterial` in Unity? Explain its purpose and usage.
TerrainPaintUtility.GetHeightBlitMaterial Declaration public static Material GetHeightBlitMaterial (); Returns Material Built in "Hidden/TerrainEngine/HeightBlitCopy" material. Description Returns the Material to use when copying the Terrain heightmap.
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
gh_97e53f9fcc07_doc_0
github
scripting
What does `this member` do in this Unity script? Explain its purpose and signature.
A scene scoped singleton inheriting from MonoBehaviour. Scene scoped singleton is a mono behavior that can have at most a single instance in each scene in project.Class type. Signature: ```csharp public class SceneSingletonMonoBehaviour<T> : MonoBehaviour where T : SceneSingletonMonoBehaviour<T> ```
You are an experienced Unity developer specializing in C# scripting, XR/VR development, and performance optimization.
local_sr_b9e1a550750e
unity_docs
input
What is `Touch.pressure` in Unity? Explain its purpose and usage.
Touch.pressure public float pressure ; Description The current amount of pressure being applied to a touch. 1.0f is considered to be the pressure of an average touch. If Input.touchPressureSupported returns false, the value of this property will always be 1.0f.
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_4a054b4e47f8
unity_docs
rendering
What is `Texture2D.SetPixels32` in Unity? Explain its purpose and usage.
Texture2D.SetPixels32 Declaration public void SetPixels32 (Color32[] colors , int miplevel = 0); Parameters Parameter Description colors The array of pixel colours to use. This is a 2D image flattened to a 1D array. miplevel The mipmap level to write colors to. The range is 0 through the texture's T...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_0336aa78031a
unity_docs
scripting
What are the parameters of `Grid.GetCellCenterLocal` in Unity?
Returns Vector3 Center of the cell transformed into local space coordinates. Description Get the logical center coordinate of a grid cell in local space. In a rectangular grid layout, a call to GridLayout.CellToLocal with Vector3Int parameter, returns a Vector3 coordinate that represents the bottom-left of the cell. Th...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_48dce124f943
unity_docs
networking
What is `Networking.MultipartFormFileSection.sectionData` in Unity? Explain its purpose and usage.
MultipartFormFileSection.sectionData public byte[] sectionData ; Returns byte[] The raw binary data contained in this section. Will not be null or empty. Description Returns the raw binary data contained in this section. Will not return null or a zero-length array. Additional resources: [IMultipartFormSec...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_b18249e719ba
unity_docs
scripting
What is `ParticleSystem.NoiseModule.remapMultiplier` in Unity? Explain its purpose and usage.
ParticleSystem.NoiseModule.remapMultiplier public float remapMultiplier ; Description Remap multiplier. Changing this property is more efficient than accessing the entire curve, if you only want to change the overall remap multiplier. Additional resources: ParticleSystem.NoiseModule.remap . ```csharp using U...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_124eb0f92569
unity_docs
rendering
What is `Experimental.GlobalIllumination.LightMode.Mixed` in Unity? Explain its purpose and usage.
Experimental : this API is experimental and might be changed or removed in the future. LightMode.Mixed Description The light is mixed. Mixed lights are interpreted based on the global light mode setting in the lighting window.
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_man_57cfcff3b45c
unity_docs
rendering
Explain 'Mesh components reference' in Unity.
Reference for the different types of mesh component. Page Description Mesh Renderer component reference Reference for the Mesh Renderer component. Skinned Mesh Renderer component reference Reference for the Skinned Mesh Renderer component. Mesh Filter component reference Reference for the Mesh Filter component. Mesh as...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_7c5962d7018b
unity_docs
physics
What is `AssetImporters.ScriptedImporterAttribute` in Unity? Explain its purpose and usage.
ScriptedImporterAttribute class in UnityEditor.AssetImporters Description Class attribute used to register a custom asset importer derived from ScriptedImporter with Unity's Asset import pipeline. ```csharp using UnityEngine; using UnityEditor.AssetImporters;[ScriptedImporter(version: 1, ext: "sphere", AllowCac...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_cb3d86c357cc
unity_docs
editor
Show me a Unity C# example demonstrating `Search.SearchUtils`.
SearchUtils class in UnityEditor.Search Description Provides various utility functions that are used by SearchProvider . ```csharp using System; using System.Collections; using System.Globalization; using System.Linq; using UnityEditor.Search; using UnityEditor; using UnityEngine; /// <summary> /// Custom provi...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_c9d1eaa21b65
unity_docs
editor
Show me a Unity C# example demonstrating `TypeCache.GetMethodsWithAttribute`.
methods defined in this assembly. Description Retrieves an unordered collection of methods marked with the T attribute. This method provides fast access to all methods loaded from a given assembly or all Unity domain assemblies and marked with a specific attribute. Methods marked with ancestors of the specified ...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_2e7dfc64da91
unity_docs
editor
Show me a Unity C# example demonstrating `SceneTemplate.ISceneTemplatePipeline`.
ISceneTemplatePipeline interface in UnityEditor.SceneTemplate Description Derive from this interface to package a custom code sequence when a Scene template is instantiated. ISceneTemplatePipeline is instantiated once when a template is instantiated, and is notified multiple times during the instantiation sequence...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_11c66d4bc912
unity_docs
scripting
Give me an overview of the `GizmoInfo` class in Unity.
GizmoInfo class in UnityEditor Description GizmoInfo contains information about the Scene View gizmo and icon for a component type. See GizmoUtility for an example. Properties Property Description gizmoEnabled Toggle gizmo visibility in the Scene View for components of this type. hasGizmo Defines whether a...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_03cbec08309d
unity_docs
rendering
What is `ShaderVariantCollection.Add` in Unity? Explain its purpose and usage.
ShaderVariantCollection.Add Declaration public bool Add ( ShaderVariantCollection.ShaderVariant variant ); Parameters Parameter Description variant Shader variant to add. Returns bool False if already in the collection. Description Adds a new shader variant to the collection. Additional resources: ...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_e03b4e667af2
unity_docs
editor
What is `Profiling.Sampler.Get` in Unity? Explain its purpose and usage.
Sampler.Get Declaration public static Profiling.Sampler Get (string name ); Parameters Parameter Description name Profiler Sampler name. Returns Sampler Sampler object which represents specific profiler label. Description Returns Sampler object for the specific CPU Profiler label. You can use th...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_88d66d08b89a
unity_docs
rendering
Show me a Unity C# example demonstrating `AssetPostprocessor.assetImporter`.
AssetPostprocessor.assetImporter public AssetImporter assetImporter ; Description Reference to the asset importer. ```csharp using System.Collections; using System.Collections.Generic; using UnityEngine; using UnityEditor;// Set the scale of all the imported models to "globalScaleModifier" // and dont generat...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_a5d24770f04a
unity_docs
editor
What is `IMGUI.Controls.AdvancedDropdownItem` in Unity? Explain its purpose and usage.
AdvancedDropdownItem class in UnityEditor.IMGUI.Controls Description Items that build the drop-down list. Properties Property Description children The list of child items of this item. enabled True if the item is enabled. icon If set, this icon will be rendered to the left of the item name. id The unique id...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_3bc7b4bfa913
unity_docs
rendering
What is `TrailRenderer.autodestruct` in Unity? Explain its purpose and usage.
TrailRenderer.autodestruct public bool autodestruct ; Description Does the GameObject of this Trail Renderer auto destruct? When set to true , the GameObject will be destroyed when all its points have been removed.
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_50633496ff1e
unity_docs
rendering
What is `ComputeShader.enabledKeywords` in Unity? Explain its purpose and usage.
ComputeShader.enabledKeywords public LocalKeyword[] enabledKeywords ; Description An array containing the local shader keywords that are currently enabled for this compute shader. Shader keywords determine which shader variants Unity uses. For information on working with local shader keywords and global sha...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_32671394a118
unity_docs
scripting
What is `UIElements.InspectorElement.uIEDefaultVariantUssClassName` in Unity? Explain its purpose and usage.
InspectorElement.uIEDefaultVariantUssClassName public static string uIEDefaultVariantUssClassName ; Description USS class name of elements of this type, when they are displayed in UIElements default mode.
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_man_2d2c83432fb6
unity_docs
scripting
In Unity's 'Transition events', what is 'The transition’s lifecycle' and how does it work?
A transition’s lifecycle has the following stages: A VisualElement ’s property is modified when you: Add or remove a class with C# methods. For example: element.ToggleInClassList() (where element is any VisualElement ). Use USS with selectors like :hover . Manipulate the element’s style property. For example: element.s...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_14bb258b7406
unity_docs
editor
What is `Rendering.RenderPipelineGraphicsSettingsEditorUtility.ForEachFieldOfType` in Unity? Explain its purpose and usage.
RenderPipelineGraphicsSettingsEditorUtility.ForEachFieldOfType Declaration public static void ForEachFieldOfType ( Rendering.IRenderPipelineResources resource , Action<T> callback , BindingFlags flags ); Parameters Parameter Description resource The resources being inspected. callback The callback to ap...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_9680a558beae
unity_docs
editor
What is `Build.Reporting.BuildFile` in Unity? Explain its purpose and usage.
BuildFile struct in UnityEditor.Build.Reporting Description Contains information about a single file produced by the build process. Properties Property Description id The unique indentifier of the build file. path The absolute path of the file produced by the build process. role The role the file plays in th...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_7eda85a12712
unity_docs
physics
What is `EdgeCollider2D.useAdjacentEndPoint` in Unity? Explain its purpose and usage.
EdgeCollider2D.useAdjacentEndPoint public bool useAdjacentEndPoint ; Description Set this to true to use the adjacentEndPoint to form the collision normal that is used to calculate the collision response when a collision occurs at the Edge Collider's end point. Set this to false to not use the adjacentEndPoin...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_man_de11a7bf0f25
unity_docs
scripting
Explain 'Use IL2CPP with macOS' in Unity.
Describes the use of plug-ins for macOS applications using Intermediate Language To C++ (./scripting-backends-il2cpp). IL2CPP is a fully supported scripting back end that you can use as an alternative to Mono when building projects for macOS Player. When you use IL2CPP to build a project, Unity converts Intermediate La...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_man_6f3303218650
unity_docs
xr
Explain 'Scoped registry authentication' in Unity.
Some package providers and organizations host packages on private package registries that require authentication to access. If you’re a consumer or an organization member trying to access a scoped registry that requires authentication, you must configure your Package Manager user configuration file with npm authenticat...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_d48792449d6a
unity_docs
rendering
What is `TrailRenderer.shadowBias` in Unity? Explain its purpose and usage.
TrailRenderer.shadowBias public float shadowBias ; Description Apply a shadow bias to prevent self-shadowing artifacts. The specified value is the proportion of the trail width at each segment. ```csharp using UnityEngine; using System.Collections;[RequireComponent(typeof(TrailRenderer))] public class ExampleC...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_f2a52b326a71
unity_docs
rendering
What is `Texture2D.ClearMinimumMipmapLevel` in Unity? Explain its purpose and usage.
Texture2D.ClearMinimumMipmapLevel Declaration public void ClearMinimumMipmapLevel (); Description Resets the minimumMipmapLevel field. Resetting the minimumMipmapLevel allows the mipmap streaming system to select mips without a per Texture lower limit restriction.
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_923e404533b1
unity_docs
rendering
What is `Rendering.ShadowMapPass` in Unity? Explain its purpose and usage.
ShadowMapPass enumeration Description Allows precise control over which shadow map passes to execute CommandBuffer objects attached using Light.AddCommandBuffer . These flags only take effect when used with Rendering.LightEvent/BeforeShadowMapPass or Rendering.LightEvent/AfterShadowMapPass. Properties Propert...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_b9e7e5effae0
unity_docs
input
What is `TouchScreenKeyboard.text` in Unity? Explain its purpose and usage.
TouchScreenKeyboard.text public string text ; Description Returns the text displayed by the input field of the keyboard. This value can be accessed at any moment, even if user has not yet finished input process. ```csharp using UnityEngine; using System.Collections;public class ExampleClass : MonoBehaviour { ...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_6a5041e49225
unity_docs
math
Give me an overview of the `SessionState` class in Unity.
SessionState class in UnityEditor Description SessionState is a Key-Value Store intended for storing and retrieving Editor session state that should survive assembly reloading. The state information stored in SessionState is cleared when Unity exits. For storing state information that should be persistent across ...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_man_2812d310cf70
unity_docs
rendering
Explain 'Shadows' in Unity.
Shadows add a degree of depth and realism to a scene because they bring out the scale and position of objects that might otherwise look flat. In Unity, lights can cast shadows from a GameObject onto other parts of itself, or onto nearby GameObjects. Page Description Enable or disable shadows Configure settings for real...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_e76027e2245c
unity_docs
physics
Show me a Unity C# example demonstrating `Collider.isTrigger`.
Collider.isTrigger public bool isTrigger ; Description Specify if this collider is configured as a trigger. A trigger doesn't register a collision with an incoming Rigidbody . Instead, it sends OnTriggerEnter , OnTriggerExit and OnTriggerStay message when a rigidbody enters or exits the trigger volume. `...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
gh_6910d9d9a9ea_doc_6
github
scripting
What does `OnCollisionExitAsObservable` do in this Unity script? Explain its purpose and signature.
OnCollisionExit is called when this collider/rigidbody has stopped touching another rigidbody/collider. Signature: ```csharp public static IObservable<Collision> OnCollisionExitAsObservable(this Component component) ```
You are an experienced Unity developer specializing in C# scripting, XR/VR development, and performance optimization.
local_sr_d6c94732c97a
unity_docs
scripting
What is `Rendering.ReflectionProbeSortingCriteria` in Unity? Explain its purpose and usage.
ReflectionProbeSortingCriteria enumeration Description Visible reflection probes sorting options. Additional resources: CullingParameters.reflectionProbeSortingCriteria. Properties Property Description None Do not sort reflection probes. Importance Sort probes by importance. Size Sort probes from largest to ...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_e8d7bf71b11b
unity_docs
scripting
What is `AvatarMask.SetHumanoidBodyPartActive` in Unity? Explain its purpose and usage.
AvatarMask.SetHumanoidBodyPartActive Declaration public void SetHumanoidBodyPartActive ( AvatarMaskBodyPart index , bool value ); Parameters Parameter Description index The index of the humanoid body part. value Active or not. Description Sets the humanoid body part at the given index to active or not...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_621b75bcb18c
unity_docs
audio
What are the parameters of `Networking.UnityWebRequest.ctor` in Unity?
Description Creates a UnityWebRequest with the default options and no attached DownloadHandler or UploadHandler . Default method is GET . The raw constructor is useful for use cases which require detailed custom configuration of a UnityWebRequest . Most use cases will require the attachment of a DownloadHandler , an Up...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_f489ca9be023
unity_docs
rendering
What is `Editor.HasPreviewGUI` in Unity? Explain its purpose and usage.
Editor.HasPreviewGUI Declaration public bool HasPreviewGUI (); Returns bool True if this component can be Previewed in its current state. Description Override this method in subclasses if you implement OnPreviewGUI . You can also use it to disable or enable preview depending on the target asset. The defa...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_3356e4f91810
unity_docs
performance
What is `Unity.Collections.LowLevel.Unsafe.NativeContainerAttribute` in Unity? Explain its purpose and usage.
NativeContainerAttribute class in Unity.Collections.LowLevel.Unsafe / Implemented in: UnityEngine.CoreModule Description Allows you to create your own custom native container. Native containers let you create new container types, which don't allocate any GC memory and give explicit control over allocations. Th...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_7f63ca18f920
unity_docs
scripting
What is `Unity.Collections.LowLevel.Unsafe.AtomicSafetyHandle.SetStaticSafetyId` in Unity? Explain its purpose and usage.
AtomicSafetyHandle.SetStaticSafetyId Declaration public static void SetStaticSafetyId (ref Unity.Collections.LowLevel.Unsafe.AtomicSafetyHandle handle , int staticSafetyId ); Parameters Parameter Description handle The AtomicSafetyHandle to modify. staticSafetyId The static safety ID to associate with t...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_4397ad170434
unity_docs
rendering
What is `Rendering.VertexAttribute.TexCoord1` in Unity? Explain its purpose and usage.
VertexAttribute.TexCoord1 Description Additional texture coordinate. UVs usually use Vector2 format. Vector2 uses two 32-bit floats; 8 bytes in total. This vertex attribute maps to the TEXCOORD1 semantic in HLSL. This UV channel is also commonly called "UV1". It corresponds to Mesh.uv2 . Additional resources: ...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_a6cef84973e7
unity_docs
rendering
What is `TrueTypeFontImporter.characterSpacing` in Unity? Explain its purpose and usage.
TrueTypeFontImporter.characterSpacing public int characterSpacing ; Description Spacing between character images in the generated texture in pixels. This is useful if you want to render text using a shader which samples pixels outside of the character area (like an outline shader).
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_4469ff781edd
unity_docs
math
What is `Rendering.SubMeshDescriptor.vertexCount` in Unity? Explain its purpose and usage.
SubMeshDescriptor.vertexCount public int vertexCount ; Description Number of vertices used by the index buffer of this sub-mesh. Together with firstVertex , this defines the range of vertices that are possibly used by this sub-mesh. You must set the vertex count so that firstVertex+vertexCount encompasses th...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
gh_633510a078c3
github
scripting
Write a Unity Editor script for Set Default Texture Compression Step
```csharp using System; using System.Linq; using MagicLeap.SetupTool.Editor.Interfaces; using MagicLeap.SetupTool.Editor.Utilities; using UnityEditor; using UnityEngine; namespace MagicLeap.SetupTool.Editor.Setup { public class SetDefaultTextureCompressionStep : ISetupStep { //Localization private const string ...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_man_4f9abc034119
unity_docs
rendering
Explain 'Reflection Surface Shader examples in the Built-In Render Pipeline' in Unity.
Here’s a Shader that does cubemapped reflection using built-in worldRefl input. It’s very similar to built-in Reflective/Diffuse Shader: ```csharp Shader "Example/WorldRefl" { Properties { _MainTex ("Texture", 2D) = "white" {} _Cube ("Cubemap", CUBE) = "" {} } SubShader { Tags { "RenderType" = "Opaque" } CGPROGR...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_4ac02735994e
unity_docs
editor
What is `PlayerSettings.SetTemplateCustomValue` in Unity? Explain its purpose and usage.
PlayerSettings.SetTemplateCustomValue Declaration public static void SetTemplateCustomValue (string name , string value ); Parameters Parameter Description name Name of the variable. value Value of the custom template variable. Description Sets a value of a custom template variable. During the build p...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_781853cf5cb2
unity_docs
rendering
What is `ParticleSystem.ShapeModule.textureUVChannel` in Unity? Explain its purpose and usage.
ParticleSystem.ShapeModule.textureUVChannel public int textureUVChannel ; Description When using a Mesh as a source shape type, this option controls which UV channel on the Mesh to use for reading the source Texture. Additional resources: ParticleSystem.ShapeModule.texture , ParticleSystem.ShapeModule.shapeT...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_786744489073
unity_docs
rendering
What is `SpriteDrawMode.Sliced` in Unity? Explain its purpose and usage.
SpriteDrawMode.Sliced Description The SpriteRenderer will render the sprite as a 9-slice image where the corners will remain constant and the other sections will scale. When resizing a 9-sliced sprite the corners will remain unscaled while the other sections will be scaled. Note: For this method to work properly th...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_man_9e38afe2ca7d
unity_docs
editor
In Unity's 'Create a drag-and-drop UI inside a custom Editor window', what is 'Create slots and objects' and how does it work?
Next, add UI controls to your custom window: One named slots with two children named slot_row1 and slot_row2 . Each row should have two children named slot1 and slot2 . One named object at the same level as slots . object must come after slots in the Hierarchy . Style the UI controls as the following: For slot1 and slo...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_e1fd0ef3fd82
unity_docs
rendering
What is `Rendering.DepthState` in Unity? Explain its purpose and usage.
DepthState struct in UnityEngine.Rendering / Implemented in: UnityEngine.CoreModule Description Values for the depth state. Use this with RenderStateBlock and ScriptableRenderContext.DrawRenderers to override the GPU's render state. Corresponds to the ZTest and ZWrite commands in ShaderLab . Additional r...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_5bfbdfe2dbee
unity_docs
scripting
Show me a Unity C# example demonstrating `Debug.Log`.
oduced the message. Example 2 , below, illustrates how this feature works. When you run this example, first click one of the cubes it creates in the Scene. The example prints a log message to the Console . When you click on the message, Unity highlights the context object in the Hierarchy window — in this case, t...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_man_ba9a76d0d1ae
unity_docs
rendering
Explain 'Import and configure plug-ins' in Unity.
If you have a managed plug-in or a native plug-in , you can import it into Unity, then configure it. Within the Editor, a plug-in is treated as an asset, similar to a script, and you can configure it in an Inspector window. You can use the plug-in configurations to specify where a plug-in runs; which platforms and whic...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_7a3194dacb74
unity_docs
rendering
What is `LightingSettings` in Unity? Explain its purpose and usage.
LightingSettings class in UnityEngine / Inherits from: Object / Implemented in: UnityEngine.CoreModule Description An object containing settings for precomputing lighting data, that Unity can serialize as a Lighting Settings Asset . When the Unity Editor precomputes lighting data for a Scene that uses the B...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_0673e102afc8
unity_docs
math
Give me an overview of the `Plane` class in Unity.
Plane struct in UnityEngine / Implemented in: UnityEngine.CoreModule Description Representation of a plane in 3D space. A plane is an infinitely large, flat surface that exists in 3D space and divides the space into two halves known as half-spaces . It is easy to determine which of the two half-spaces a partic...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_0a436be43648
unity_docs
physics
What is `ConfigurableJoint.angularYZDrive` in Unity? Explain its purpose and usage.
ConfigurableJoint.angularYZDrive public JointDrive angularYZDrive ; Description Definition of how the joint's rotation will behave around its local Y and Z axes. Only used if Rotation Drive Mode is Swing & Twist.
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_4e1fd6d5bc58
unity_docs
rendering
What is `SystemInfo` in Unity? Explain its purpose and usage.
SystemInfo class in UnityEngine / Implemented in: UnityEngine.CoreModule Description Access system and hardware information. Use this class to figure out capabilities of the underlying platform and hardware. For example, you can check which RenderTexture formats are supported ( SupportsRenderTextureFormat ), ...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_b896e091cf77
unity_docs
rendering
Show me a Unity C# example demonstrating `ParticleSystem.SubEmittersModule.SetSubEmitterEmitProbability`.
SetSubEmitterEmitProbability Declaration public void SetSubEmitterEmitProbability (int index , float emitProbability ); Parameters Parameter Description index The index of the sub-emitter you want to modify. emitProbability The probability value. Description Sets the probability that the sub-emitter em...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_a44ac9f1a5a8
unity_docs
math
Show me a Unity C# example demonstrating `EditorTools.EditorToolAttribute`.
ute class in UnityEditor.EditorTools / Inherits from: EditorTools.ToolAttribute Description Registers an EditorTool as either a Global tool or a Component tool for a specific target type. A Global tool works on any selection. A Global tool is also always available from the top toolbar. A Component tool, lik...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_ba8d13991da0
unity_docs
animation
What is `AnimationUtility.GetDiscreteIntValue` in Unity? Explain its purpose and usage.
AnimationUtility.GetDiscreteIntValue Declaration public static bool GetDiscreteIntValue ( GameObject root , EditorCurveBinding binding , out int data ); Parameters Parameter Description root The root GameObject of the animated hierarchy. binding The binding that defines the path and the properties of ...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_3f18dc4d14a8
unity_docs
scripting
Show me a Unity C# example demonstrating `Behaviour.enabled`.
Behaviour.enabled public bool enabled ; Description Enabled Behaviours are Updated, disabled Behaviours are not. This is shown as the small checkbox in the inspector of the behaviour. ```csharp using UnityEngine; using System.Collections; using UnityEngine.UI; // Required when Using UI elements.public class Ex...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_33ca110d033a
unity_docs
animation
What is `Animations.AnimatorControllerPlayable.IsInTransition` in Unity? Explain its purpose and usage.
AnimatorControllerPlayable.IsInTransition Declaration public bool IsInTransition (int layerIndex ); Parameters Parameter Description layerIndex The layer index. Returns bool True if there is a transition on the given layer, false otherwise. Description Returns true if there is a transition on the giv...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_3b4c025429e6
unity_docs
scripting
What is `TileEditor` in Unity? Explain its purpose and usage.
TileEditor class in UnityEditor / Inherits from: TileBaseEditor Description Default editor for Tile assets. Public Methods Method Description OnInspectorGUI Draws the default Tile Inspector GUI. RenderStaticPreview Creates a texture preview for rendering the Tile asset preview. Inherited Members Propert...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_5085e530e0cd
unity_docs
editor
What is `TransformUtils` in Unity? Explain its purpose and usage.
TransformUtils class in UnityEditor Description Editor Transform Utility Class. Static Methods Method Description GetConstrainProportions Returns Constrain Proportions toggle value as it is shown in the Transform Inspector window. GetInspectorRotation Returns the rotation of a transform as it is shown in the ...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_23e440abf852
unity_docs
performance
What is `Unity.Collections.LowLevel.Unsafe.AtomicSafetyHandle.SetNestedContainer` in Unity? Explain its purpose and usage.
AtomicSafetyHandle.SetNestedContainer Declaration public static void SetNestedContainer ( Unity.Collections.LowLevel.Unsafe.AtomicSafetyHandle handle , bool isNestedContainer ); Parameters Parameter Description handle The AtomicSafetyHandle to flag. isNestedContainer Set to true to flag the container p...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_man_9ac32018ed52
unity_docs
editor
Explain 'UI Toolkit runtime examples' in Unity.
This section provides examples that demonstrate how to create and manage UI elements at runtime using the UI Toolkit. Topic Description Get started with runtime UI Use this example to get started with runtime UI. Create a list view runtime UI Use ListView to create a simple character selection screen runtime UI. Create...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_052a633db95d
unity_docs
scripting
What is `Windows.WebCam.VideoCapture.VideoCaptureResult.hResult` in Unity? Explain its purpose and usage.
VideoCapture.VideoCaptureResult.hResult public long hResult ; Description The specific Windows HRESULT code. If the operation fails, this contains the actual error code returned by the Windows API. For details on Windows HRESULT values, see Microsoft's documentation on HRESULT .
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_man_42030a0cf75f
unity_docs
ui
In Unity's 'Panel events', what is 'Unique properties' and how does it work?
originPanel : The originPanel contains data specific to the DetachFromPanelEvent . It contains the source panel that the visual element detaches from during a panel change. destinationPanel : The destinationPanel contains data specific to the AttachToPanelEvent . It provides the panel where the visual element is now at...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_00c72ef155a5
unity_docs
audio
What is `AudioSource.time` in Unity? Explain its purpose and usage.
AudioSource.time public float time ; Description Playback position in seconds. Use this property to read the current playback time or to seek to a new playback time. If the audio source is not playing , time will always return 0, regardless of any previously set or expected playback position. If you need t...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_50bf97d4112d
unity_docs
editor
Show me a Unity C# example demonstrating `SearchService.ObjectSelectorSearchEndSessionModes.CloseSelector`.
ObjectSelectorSearchEndSessionModes.CloseSelector Description The session is ending because the current object selector needs to be closed. Here is an example of an object selector engine using CloseSelector to close the currently opened selector: ```csharp using System; using UnityEditor.SearchService; using Ob...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
gh_5bdb52234eba
github
scripting
Write a Unity C# script called Overwrite Child Tests
```csharp using Duck.HierarchyBehaviour.Tests.Behaviours; using NUnit.Framework; using UnityEngine; namespace Duck.HierarchyBehaviour.Tests { [TestFixture] internal partial class GameObjectExtensionsTests { [Test] public void Expect_OverwriteChild_New_ToOverwrite() { Component original; var toReplace =...
You are an expert Unity game developer. Provide clear, accurate, and practical answers about Unity development.
local_sr_b707f3b874cb
unity_docs
scripting
What is `PrefabUtility.GetRemovedComponents` in Unity? Explain its purpose and usage.
PrefabUtility.GetRemovedComponents Declaration public static List<RemovedComponent> GetRemovedComponents ( GameObject prefabInstance ); Parameters Parameter Description prefabInstance The Prefab instance to get information about. Returns List<RemovedComponent> List of objects with information about remo...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_0c6d7f8c5737
unity_docs
rendering
What is `SkinnedMeshRenderer.forceMatrixRecalculationPerRender` in Unity? Explain its purpose and usage.
SkinnedMeshRenderer.forceMatrixRecalculationPerRender public bool forceMatrixRecalculationPerRender ; Description Forces the Skinned Mesh to recalculate its matricies when rendered This property must be set in cases where the user would like to manually render a skinned mesh multiple times within a single upda...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_efc73791dc61
unity_docs
input
What are the parameters of `Event.KeyboardEvent` in Unity?
Returns Event A new Event with EventType.KeyDown and the requested KeyCode and optional EventModifier. Description Create a keyboard event. This is useful when you need to check if a certain key has been pressed - possibly with modifiers. The syntax for the key string is a key name (same as in the Input Manager), optio...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_man_88ea88520b86
unity_docs
performance
In Unity's 'Collections', what is 'Compatible with Unity' and how does it work?
These package versions are available in Unity version 6000.0: Documentation location: State Versions available: com.unity.collections@2.7 compatible 2.7.0-exp.1 com.unity.collections@2.6 released 2.6.5
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_man_f9eb7f361c59
unity_docs
rendering
Explain 'Gizmos menu reference' in Unity.
The Scene view and the Game view both have a Gizmos menu. Click the Gizmos button in the toolbar of the Scene view or the Game view to access the Gizmos menu. ## General options Property Function 3D Icons The 3D Icons checkbox controls whether component icons (such as those for Lights and Cameras) are drawn by the Ed...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_061deb5a04e8
unity_docs
math
What is `UIElements.IntegerField.ApplyInputDeviceDelta` in Unity? Explain its purpose and usage.
IntegerField.ApplyInputDeviceDelta Declaration public void ApplyInputDeviceDelta ( Vector3 delta , UIElements.DeltaSpeed speed , int startValue ); Parameters Parameter Description delta A vector used to compute the value change. speed A multiplier for the value change. startValue The start value. D...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_13849e05d987
unity_docs
rendering
What is `CanvasRenderer.DisableRectClipping` in Unity? Explain its purpose and usage.
CanvasRenderer.DisableRectClipping Declaration public void DisableRectClipping (); Description Disables rectangle clipping for this CanvasRenderer. Additional resources: CanvasRenderer.EnableRectClipping .
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
gh_ed6bc65dc46d
github
scripting
Write a Unity C# UI script for TMP_Text Selector_A
```csharp using UnityEngine; using UnityEngine.EventSystems; using System.Collections; namespace TMPro.Examples { public class TMP_TextSelector_A : MonoBehaviour, IPointerEnterHandler, IPointerExitHandler { private TextMeshPro m_TextMeshPro; private Camera m_Camera; private bool m_...
You are a senior Unity engineer. Answer questions about Unity scripting, XR/VR development, and game systems with working code examples.
local_man_7f98ff63249e
unity_docs
scripting
In Unity's 'Focused Inspectors', what is 'Use a focused Inspector' and how does it work?
A focused Inspector window is dedicated to a single GameObject , component, or asset. It always displays the properties of the item you opened it for, even if you select something else in the scene or project. You can open as many focused Inspector windows as you want. Focused Inspector windows open in floating windows...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_7a86d569fde1
unity_docs
rendering
What is `ParticleSystem.Simulate` in Unity? Explain its purpose and usage.
ParticleSystem.Simulate Declaration public void Simulate (float t ); Declaration public void Simulate (float t , bool withChildren = true); Declaration public void Simulate (float t , bool withChildren = true, bool restart = true); Declaration public void Simulate (float t , bool withChildren...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_e19ca6a74ea1
unity_docs
physics
Show me a Unity C# example demonstrating `RaycastHit2D.transform`.
physics query, the collider refers to the specific Collider2D that was detected however transform refers to the Transform on the GameObject that the RaycastHit2D.collider is attached to. NOTE : transform is equivalent to using Collider2D.transform and is provided for convenience only. This field will be...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_6800e7fcbda5
unity_docs
math
Show me a Unity C# example demonstrating `Handles.Button`.
yle of the button. Returns bool True when the user clicks the button. Description Make a 3D Button. This button works like one drawn with GUI.Button , but it has a 3D position and is drawn by a handle function. Button Handle as a rectangle in the Scene View. Add the following script to your Assets folder as...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_man_011ae4848cec
unity_docs
xr
In Unity's 'Code sign your application', what is 'Locate the application identifier' and how does it work?
To notarize your application, Apple needs to identify it using an application identifier. There are two ways to get an application identifier: in Unity, or in the application’s information property list file . In Unity: Go to Edit > Project Settings > Player . Expand the Other Settings section Navigate to Identificatio...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_0add85103fc2
unity_docs
scripting
What is `PlayerSettings.vulkanEnablePreTransform` in Unity? Explain its purpose and usage.
PlayerSettings.vulkanEnablePreTransform public static bool vulkanEnablePreTransform ; Description Applies the display rotation during rendering. When this option is enabled, Unity rotates your content when rendering to the framebuffer. Most Android phones typically use portrait as their native display orientat...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.