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_fdaf42471dd6
unity_docs
rendering
Give me an overview of the `ParticleSystemStopBehavior` class in Unity.
ParticleSystemStopBehavior enumeration Description The behavior to apply when calling Stop . Properties Property Description StopEmittingAndClear Stops Particle System emitting and removes all existing emitted particles. StopEmitting Stops Particle System emitting any further particles. All existing particles...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_17fea4f1bf0d
unity_docs
scripting
Show me a Unity C# example demonstrating `Animator.ResetTrigger`.
Parameters Parameter Description name The parameter name. id The parameter ID. Description Resets the value of the given trigger parameter. Use this to reset a Trigger parameter in an Animator Controller that could still be active. Make sure to create a parameter in the Animator Controller with the same name...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_68271a22fd3f
unity_docs
math
What is `Vector2Int.Min` in Unity? Explain its purpose and usage.
Vector2Int.Min Declaration public static Vector2Int Min ( Vector2Int lhs , Vector2Int rhs ); Description Returns a vector that is made from the smallest components of two vectors. Additional resources: Max function.
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_ff0eeb677c57
unity_docs
scripting
What is `SystemInfo.graphicsDeviceName` in Unity? Explain its purpose and usage.
SystemInfo.graphicsDeviceName public static string graphicsDeviceName ; Description The name of the graphics device (Read Only). This is the name of user's graphics card, as reported by the graphics driver. ```csharp using UnityEngine;public class Example : MonoBehaviour { void Start() { // Prints using the...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_1543668dcf21
unity_docs
physics
What is `PhysicsScene2D.BoxCast` in Unity? Explain its purpose and usage.
PhysicsScene2D.BoxCast Declaration public RaycastHit2D BoxCast ( Vector2 origin , Vector2 size , float angle , Vector2 direction , float distance , int layerMask = Physics2D.DefaultRaycastLayers); Declaration public RaycastHit2D BoxCast ( Vector2 origin , Vector2 size , float angle , Vecto...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_man_1a4128638c3a
unity_docs
editor
In Unity's 'Refreshing the Asset Database', what is 'Refresh process' and how does it work?
Unity performs the following steps during an Asset Database refresh: Check if any files in the Assets and Packages folders have been added, modified, or deleted since the last check and update the Asset Database accordingly. Import and compile code-related files such as .dll, .asmdef, .asmref, .rsp, and .cs files. Relo...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_8369a3ccea15
unity_docs
xr
What is `XR.XRDisplaySubsystem.ReprojectionMode` in Unity? Explain its purpose and usage.
ReprojectionMode enumeration Description The kind of reprojection the app requests to stabilize its holographic rendering relative to the user's head motion. Properties Property Description Unspecified Does not specify the type of reprojection mode to use. PositionAndOrientation Stabilizes the image for change...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
gh_fa38bfeb0a52
github
scripting
Write a Unity C# script called Ring Buffer
```csharp using System.Collections; using System.Collections.Generic; using UnityEngine; public class RingBuffer<T> { T[] backingValues; public int Count { get; private set; } private int frontIndex = 0; public RingBuffer(int bufferSize) { backingValues = new T[bufferSize]; Coun...
You are an expert Unity game developer. Provide clear, accurate, and practical answers about Unity development.
local_man_22c93be18efc
unity_docs
physics
Explain 'Select a broad phase pruning algorithm' in Unity.
Select the most efficient broad phase pruning algorithm. In the Unity Editor, you can select these algorithms for broad phase collision detection: Sweep and Prune (SAP): Projects Axis-Aligned Bounding Boxes (AABBs) onto axes. While generally efficient, SAP can generate false positives in large, flat worlds with many co...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
gh_103347a59c12_doc_11
github
scripting
What does `this member` do in this Unity script? Explain its purpose and signature.
Stores the used to select the number of degrees to rotate for snap turning. Signature: ```csharp public Dropdown snapTurnAmountDropdown ```
You are a knowledgeable Unity developer. Explain Unity concepts clearly and provide practical, tested code examples.
local_sr_15ea424c321f
unity_docs
scripting
What is `RenderParams.instanceID` in Unity? Explain its purpose and usage.
RenderParams.instanceID public int instanceID ; Description The instance ID of the GameObject that issues the draw. Provide an instanceID to make a rendered GameObject pickable in the scene view when you click on it. The default value is 0, which means that you can't pick or outline the procedural GameObject in ...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_4a7c3a858d26
unity_docs
math
What is `AsyncInstantiateOperation_1.Result` in Unity? Explain its purpose and usage.
AsyncInstantiateOperation<T0>.Result public T[] Result ; Description If isDone is true, then Result contains instantiated objects of type T. The size of the array is the same as the 'count' argument for the InstantiateAsync method call.
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_45d1db5f015c
unity_docs
rendering
What are the parameters of `LightTransport.IDeviceContext.CreateBuffer` in Unity?
Returns BufferID Unique identifier for the newly created buffer. Description Allocates a new buffer on the device with the specified element count and stride. Creates a buffer that can store the specified number of elements, each with the given stride (size in bytes). The actual memory allocation may occur in CPU memor...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_man_31a4f63e0c1c
unity_docs
rendering
Explain 'Branch in a shader via built-in macros' in Unity.
Resources for adding a condition in a shader based on the platform, shader model, Unity Version, or shader pass. Page Description Branch based on platform or graphics API Use SHADER_API macros to make shader behaviour conditional on the platform or graphics API. Branch based on shader model Use SHADER_TARGET to make sh...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_4aa563694ccd
unity_docs
physics
What is `PlayerSettings.useFlipModelSwapchain` in Unity? Explain its purpose and usage.
PlayerSettings.useFlipModelSwapchain public static bool useFlipModelSwapchain ; Description Use DXGI flip model swap chain for D3D11. Direct3D 11 supports two presentation modes: Windows 7-style BitBlt and the modern flip models. The BitBlt model has historically been the only way to present the Direct3D swap ...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_98835722e9a2
unity_docs
scripting
What is `Android.AndroidAssetPackError.InsufficientStorage` in Unity? Explain its purpose and usage.
AndroidAssetPackError.InsufficientStorage Description Indicates that there is not enough storage space on the device to download the Android asset pack. Additional resources: AndroidAssetPacks.DownloadAssetPackAsync , AndroidAssetPacks.GetAssetPackStateAsync .
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_32167d74551b
unity_docs
ui
What is `UIElements.BaseListView.showAddRemoveFooter` in Unity? Explain its purpose and usage.
BaseListView.showAddRemoveFooter public bool showAddRemoveFooter ; Description This property controls whether a footer will be added to the list view. The default value is false . When this property is set to true , Unity adds a footer under the scroll view. This footer contains two buttons: A "+" butt...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_e75dc9c0a23d
unity_docs
ui
What is `UIElements.VisualElement.EnableInClassList` in Unity? Explain its purpose and usage.
VisualElement.EnableInClassList Declaration public void EnableInClassList (string className , bool enable ); Parameters Parameter Description className The name of the class to enable or disable. enable A boolean flag that adds or removes the class name from the class list. If true, EnableInClassList adds...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_0fdd0253b4bb
unity_docs
audio
Show me a Unity C# example demonstrating `AudioChorusFilter.dryMix`.
AudioChorusFilter.dryMix public float dryMix ; Description Volume of original signal to pass to output. 0.0 to 1.0. Default = 0.5. ```csharp using UnityEngine;[RequireComponent(typeof(AudioSource))] [RequireComponent(typeof(AudioChorusFilter))] public class Example : MonoBehaviour { void Start() { GetCompon...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
gh_784a8fdadf8b
github
scripting
Write a Unity C# script called Config Params
```csharp using System; using System.Runtime.InteropServices; using UnityEngine; namespace Wrld { /// <summary> /// These are parameters required during initialization and construction of the map. /// They are only used for startup. Please use the [API endpoints]({{ site.baseurl }}/docs/api) to in...
You are a senior Unity engineer. Answer questions about Unity scripting, XR/VR development, and game systems with working code examples.
local_sr_2fca5bf5f36f
unity_docs
scripting
What is `Rendering.UVChannelFlags` in Unity? Explain its purpose and usage.
UVChannelFlags enumeration Description A flag representing each UV channel. Properties Property Description UV0 First UV channel. UV1 Second UV channel. UV2 Third UV channel. UV3 Fourth UV channel.
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_man_f27bdb6e5b29
unity_docs
ui
Explain 'Toggle' in Unity.
A Toggle includes an image and a label. Just like other standard UI Toolkit controls, such as a Button , a Toggle has a Clickable manipulator attached to it that registers to MouseUpEvent and PointerUpEvent . When one of those events triggers the manipulator, the Toggle’s value changes from true to false or from false ...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_2316b22db149
unity_docs
rendering
What is `TerrainData.holesTexture` in Unity? Explain its purpose and usage.
TerrainData.holesTexture public Texture holesTexture ; Description Returns the Terrain holes Texture. An uncompressed Terrain holes Texture is a RenderTexture in the Editor and at runtime. A compressed Terrain holes Texture is a Texture2D at runtime only. You might use an uncompressed Terrain holes Texture as...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_man_b3120c9ef55b
unity_docs
rendering
Explain 'Asynchronous shader compilation in the Editor' in Unity.
Resources for compiling shader variants in the background, and using placeholder shaders in the meantime. Page Description Introduction to asynchronous shader compilation Learn about how asynchronous shader compilation works, and exceptions. Enable or disable asynchronous shader compilation Enable or disable asynchrono...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_fcb54b762f91
unity_docs
scripting
Show me a Unity C# example demonstrating `Vector3.Max`.
Vector3.Max Declaration public static Vector3 Max ( Vector3 lhs , Vector3 rhs ); Description Returns a vector that is made from the largest components of two vectors. Additional resources: Min function. ```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_ac4045825be9
unity_docs
scripting
What is `RigidbodyConstraints.None` in Unity? Explain its purpose and usage.
RigidbodyConstraints.None Description No constraints. ```csharp //This example shows how RigidbodyConstraints is used to freeze the position and rotation of a Rigidbody in the z axis at start-up. //It also shows what happens when these constraints are removed, when you press the space key //Attach this to a GameObj...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_f90542798e44
unity_docs
ui
What is `GUISkin.horizontalScrollbarRightButton` in Unity? Explain its purpose and usage.
GUISkin.horizontalScrollbarRightButton public GUIStyle horizontalScrollbarRightButton ; Description Style used by default for the right button on GUI.HorizontalScrollbar controls. ```csharp using UnityEngine;public class Example : MonoBehaviour { // Modifies only the horizontal scrollbar // left button o...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_man_a92231b14252
unity_docs
animation
Explain 'State Machine Transitions' in Unity.
State Machine Transitions exist to help you simplify large or complex State Machines. They allow you to have a higher level of abstraction over the state machine logic. Each view in the animator window has an Entry and Exit node. These are used during State Machine Transitions. The Entry node is used when transitioning...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_2ce0594f1612
unity_docs
rendering
What is `Rendering.RayTracingInstanceCullingTest.allowTransparentMaterials` in Unity? Explain its purpose and usage.
RayTracingInstanceCullingTest.allowTransparentMaterials public bool allowTransparentMaterials ; Description Whether to allow Renderers that use transparent Materials. Use RayTracingInstanceCullingConfig.transparentMaterialConfig to define when a Material is considered alpha tested. If this value is false and ...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_457126652c4a
unity_docs
math
What is `HandleUtility.CalcLineTranslation` in Unity? Explain its purpose and usage.
HandleUtility.CalcLineTranslation Declaration public static float CalcLineTranslation ( Vector2 src , Vector2 dest , Vector3 srcPosition , Vector3 constraintDir ); Parameters Parameter Description src The source point of the drag. dest The destination point of the drag. srcPosition The 3D posit...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_man_1446feda981b
unity_docs
physics
Show me a Unity code example for 'Measure performance with the built-in profiler'.
lt-in profiler for iOS to provide insight on how the application is running. Every 30 frames, the built-in profiler emits console messages from the application running on the device to help determine if it’s CPU or GPU-bound. If your application is CPU-bound, you can determine whether script code or garbage collection ...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_man_b60e3322bb8b
unity_docs
physics
Explain 'Physics 2D reference' in Unity.
The following Project settings manage the global settings for Physics 2D, which define the limits on the accuracy of the physics simulation of 2D GameObjects in the Unity physics system. A more accurate simulation requires more processing overhead, and these settings allow you to adjust the trade-off between accuracy a...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_bbbe8bdf16a4
unity_docs
scripting
What is `Terrain.treeDistance` in Unity? Explain its purpose and usage.
Terrain.treeDistance public float treeDistance ; Description The maximum distance at which trees are rendered. The higher this is, the further the distance trees can be seen and the slower it will run. Additional resources: Terrain.treeBillboardDistance . ```csharp using UnityEngine;public class Example : Mon...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_92f40f7486ab
unity_docs
animation
What is `UIElements.Experimental.ValueAnimation_1.Recycle` in Unity? Explain its purpose and usage.
Experimental : this API is experimental and might be changed or removed in the future. ValueAnimation<T0>.Recycle Declaration public void Recycle (); Description Returns this animation object into its object pool. Keeping a reference to the animation object afterwards could lead to unspecified behaviour.
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_88b3d6c6f42d
unity_docs
editor
Show me a Unity C# example demonstrating `PlayerSettings.iOS.buildNumber`.
PlayerSettings.iOS.buildNumber public static string buildNumber ; Description The build number of the bundle It is saved to the 'CFBundleVersion' field in the built app's info.plist file. ```csharp using UnityEngine; using UnityEditor;public class BuildNumberExample { // This example will create a Menu Item...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_eb642860c48d
unity_docs
scripting
What is `Tools` in Unity? Explain its purpose and usage.
Tools class in UnityEditor / Inherits from: ScriptableObject Description Class used to manipulate the tools used in Unity's Scene View. Static Properties Property Description current The tool that is currently selected for the Scene View. handlePosition The position of the tool handle in world space. handl...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_3963de09921b
unity_docs
math
What is `TerrainLayer.normalScale` in Unity? Explain its purpose and usage.
TerrainLayer.normalScale public float normalScale ; Description A float value that scales the normal vector. The minimum value is 0, the maximum value is 1. Specifying a value of 0 neutrializes the normal vector ((0,0,1) in the tangent space). Specifying a value greater than 1 exaggerates the normal further fr...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_074424552f79
unity_docs
rendering
What is `EditorUtility.CopySerializedManagedFieldsOnly` in Unity? Explain its purpose and usage.
EditorUtility.CopySerializedManagedFieldsOnly Declaration public static void CopySerializedManagedFieldsOnly (object source , object dest ); Parameters Parameter Description source The object to copy data from. dest The object to copy data to. Description Copies the serializable fields from one managed ...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_249d1fc88d6c
unity_docs
rendering
Give me an overview of the `RenderTextureReadWrite` class in Unity.
RenderTextureReadWrite enumeration Description Color space conversion mode of a RenderTexture . When using Gamma color space , no conversions are done of any kind, and this setting is not used. When Linear color space is used, then by default non-HDR render textures are considered to contain sRGB data (i.e. "reg...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_fcdc5008f1f9
unity_docs
rendering
What is `Rendering.TierSettings.reflectionProbeBoxProjection` in Unity? Explain its purpose and usage.
TierSettings.reflectionProbeBoxProjection public bool reflectionProbeBoxProjection ; Description Whether to use Reflection Probes Box Projection. Enabling or disabling this setting will add or remove the UNITY_SPECCUBE_BOX_PROJECTION shader compiler define.
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
gh_8f482dccdc87_doc_0
github
scripting
What does `this member` do in this Unity script? Explain its purpose and signature.
Singleton container that is not destroyed on scene change Signature: ```csharp public static GameObject GlobalSingletonsContainer ```
You are an expert Unity game developer. Provide clear, accurate, and practical answers about Unity development.
local_sr_0bfc865cae38
unity_docs
rendering
What is `Texture2D.ClearRequestedMipmapLevel` in Unity? Explain its purpose and usage.
Texture2D.ClearRequestedMipmapLevel Declaration public void ClearRequestedMipmapLevel (); Description Resets the requestedMipmapLevel field. Resetting the requestedMipmapLevel allows the mipmap streaming system to start choosing which mipmap should be loaded based on the position of cameras.
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_70fe0fb5a1a6
unity_docs
math
Show me a Unity C# example demonstrating `Tilemaps.Tilemap.SetTransformMatrix`.
lic void SetTransformMatrix ( Vector3Int position , Matrix4x4 transform ); Parameters Parameter Description position Position of the Tile on the Tilemap . transform The transform matrix. Description Sets the transform matrix of a Tile given the XYZ coordinates of a cell in the Tilemap . Note that ...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_80029d1629be
unity_docs
scripting
Show me a Unity C# example demonstrating `Vector2.Scale`.
Vector2.Scale Declaration public static Vector2 Scale ( Vector2 a , Vector2 b ); Description Multiplies two vectors component-wise. Every component in the result is a component of a multiplied by the same component of b . ```csharp using UnityEngine;public class Example : MonoBehaviour { void Start(...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_c932d2a85dd8
unity_docs
editor
Show me a Unity C# example demonstrating `PlayerSettings.Android.reportGooglePlayAppDependencies`.
PlayerSettings.Android.reportGooglePlayAppDependencies public static bool reportGooglePlayAppDependencies ; Description Indicates whether to track application dependencies for Google Play Store verification. ```csharp using UnityEngine; using UnityEditor; using UnityEditor.Build;public class ReportGooglePlayAp...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_man_07ca87a5d43f
unity_docs
input
In Unity's 'UnsignedIntegerField', what is 'Create an UnsignedIntegerField' and how does it work?
You can create an UnsignedIntegerField with UI Builder, UXML, or C#. The following C# code creates an UnsignedIntegerField: ``` var unsignedIntegerField = new UnsignedIntegerField(); ```
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_man_73e2fc525c3f
unity_docs
performance
In Unity's 'Web build settings', what is 'Web build settings reference' and how does it work?
The following table gives an overview of the Web build settings. Property Description Client Browser Type Select the browser client that you want your application to launch at runtime. For example, if you choose System Default, then your application launches the default browser, and removes the Path to Client Browser s...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_8628c36e1946
unity_docs
scripting
Show me a Unity C# example demonstrating `PrimitiveType.Quad`.
PrimitiveType.Quad Description A quad primitive. Additional resources: GameObject.CreatePrimitive . ```csharp using UnityEngine; using System.Collections;// Creates a quad primitivepublic class ExampleClass : MonoBehaviour { void Start() { GameObject quad = GameObject.CreatePrimitive(PrimitiveType.Quad); } } ...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_ffe7434ed5be
unity_docs
xr
What is `ResourcesAPI.Load` in Unity? Explain its purpose and usage.
ResourcesAPI.Load Declaration protected Object Load (string path , Type systemTypeInstance ); Parameters Parameter Description path Path to the target resource to load. systemTypeInstance The requested asset's Type. Returns Object The requested asset returned as an Object. Description Override for...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_man_6946a322cf1b
unity_docs
animation
Explain 'Unity Asset Store' in Unity.
The Unity Asset Store contains a library of free and commercial assets that Unity Technologies and members of the community create. A wide variety of assets are available, including textures, models, animations, entire project examples, tutorials, and extensions for the Unity Editor. Topic Description Introduction to t...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_32c4ddb83241
unity_docs
scripting
What is `VersionControl.Provider.Lock` in Unity? Explain its purpose and usage.
Provider.Lock Declaration public static VersionControl.Task Lock ( VersionControl.AssetList assets , bool locked ); Declaration public static VersionControl.Task Lock ( VersionControl.Asset asset , bool locked ); Parameters Parameter Description asset Asset to lock/unlock. assets List of asset...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_a0d53af94a44
unity_docs
math
What is `Rendering.RayTracingInstanceCullingFlags.EnableLODCulling` in Unity? Explain its purpose and usage.
RayTracingInstanceCullingFlags.EnableLODCulling Description Causes RayTracingAccelerationStructure.CullInstances to perform LOD culling. The parameters used for LOD culling are specified in RayTracingInstanceCullingConfig.lodParameters . LOD cross fading is not not supported currently. Additional resources: LOD...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_515e9b6f310c
unity_docs
editor
What are the parameters of `AssetModificationProcessor.MakeEditable` in Unity?
Returns void Returns true if all files have been made editable. Description Unity calls this method when one or more files need to be opened for editing. It must be static if implemented. Additional resources: AssetDatabase.MakeEditable . ```csharp using System.Collections.Generic; using UnityEngine;class CustomAssetMo...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_c2292bf23cd7
unity_docs
scripting
What is `Categorization.CategoryInfoAttribute.Name` in Unity? Explain its purpose and usage.
CategoryInfoAttribute.Name public string Name ; Description The name to use for this category. If Name is not specified, the element name will be used. This can falback on type name if no ElementInfoAttribute specifying Name.
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_bcd2681ecc94
unity_docs
rendering
What is `CameraProjectionCache.ScreenToGUIPoint` in Unity? Explain its purpose and usage.
CameraProjectionCache.ScreenToGUIPoint Declaration public Vector2 ScreenToGUIPoint ( Vector2 screenPoint ); Parameters Parameter Description screenPoint A point in screen space. Returns Vector2 screenPoint converted to GUI space relative to the cached camera viewport. Description Converts a point ...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_b898f785b3a2
unity_docs
scripting
Show me a Unity C# example demonstrating `Projector.aspectRatio`.
Projector.aspectRatio public float aspectRatio ; Description The aspect ratio of the projection. This is projection width divided by height. An aspect ratio of 1.0 makes the projection square; a ratio of 2.0 makes it twice as wide than high. Additional resources: projector component . ```csharp using UnityEn...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_22f12411d7d3
unity_docs
editor
Show me a Unity C# example demonstrating `Experimental.Rendering.ScriptableBakedReflectionSystemSettings.system`.
the future. ScriptableBakedReflectionSystemSettings.system public static Experimental.Rendering.IScriptableBakedReflectionSystem system ; Description The currently active ScriptableBakedReflectionSystem, see IScriptableBakedReflectionSystem . Set this property in a class with InitializeOnLoadAttribute or ...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_f487ad5a0bd2
unity_docs
performance
What are the parameters of `Profiling.Profiler.EmitSessionMetaData` in Unity?
Description Write metadata associated with the whole Profiler session capture. Use EmitSessionMetaData to write arbitrary binary data that should be available for all frames of this session. Data must contain only blittable types. If the information you want to store in the Profiler meta data might change from frame to...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_man_76f0c04aace1
unity_docs
rendering
Explain 'Asset Pipeline preferences reference' in Unity.
Contains preferences for how Unity imports and caches assets. To open the preferences, go to Edit > Preferences > Asset Pipeline (macOS: Unity > Settings > Asset Pipeline ). Property Function Auto Refresh Enable this setting to import Assets automatically as they change. Import Worker Count % Set a percentage of availa...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_e5d3fdd467bf
unity_docs
scripting
What is `DetailInstanceTransform` in Unity? Explain its purpose and usage.
DetailInstanceTransform struct in UnityEngine / Implemented in: UnityEngine.TerrainModule Description Describes the transform of a Terrain detail object. Additional resources: TerrainData.ComputeDetailInstanceTransforms . Properties Property Description posX The X coordinate of the detail object in the Ter...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_c81190c4f6e3
unity_docs
rendering
What is `Build.Reporting.BuildFile.role` in Unity? Explain its purpose and usage.
BuildFile.role public string role ; Description The role the file plays in the build output. Use this field to understand what purpose a file serves within the built player. Common roles for files are captured by the members of the CommonRoles class.
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_469c28337072
unity_docs
editor
What is `Android.AndroidProjectFilesModifierContext` in Unity? Explain its purpose and usage.
AndroidProjectFilesModifierContext class in UnityEditor.Android Description Represents a container that specifies additional dependencies and additional outputs for AndroidProjectFilesModifier . ```csharp using System.IO; using Unity.Android.Gradle; using UnityEditor; using UnityEditor.Android; using UnityEngine...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_1b6eca6b490a
unity_docs
scripting
What is `Search.ISearchQuery.GetSearchTable` in Unity? Explain its purpose and usage.
ISearchQuery.GetSearchTable Declaration public Search.SearchTable GetSearchTable (); Returns SearchTable Search table configuration. Description Returns the query search table configuration if any.
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_914f9875c8aa
unity_docs
scripting
What is `Selection` in Unity? Explain its purpose and usage.
Selection class in UnityEditor Description Access to the selection in the editor. Static Properties Property Description activeContext Returns the current context object, as was set via SetActiveObjectWithContext. activeGameObject Returns the active game object. (The one shown in the inspector). activeInstan...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_man_961b2a20be06
unity_docs
scripting
In Unity's 'Branch group reference', what is 'Geometry' and how does it work?
Property Function LOD Multiplier The tree root node sets the level of detail (LOD) for the whole tree. Use the LOD Multiplier to give the branch group a higher or lower LOD. Geometry Mode Type of geometry for this branch group: Branch Only, Branch + Fronds, Fronds Only. Branch Material Material for the branch bark. Bre...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_fd70bf604f4f
unity_docs
editor
What is `SceneView.SupportsStageHandling` in Unity? Explain its purpose and usage.
SceneView.SupportsStageHandling Declaration protected bool SupportsStageHandling (); Returns bool True if the Scene view automatically reacts to stage changes. Description Override this method to control whether the Scene view should change when you switch from one stage to another stage. By default, the ...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_man_af30360605d3
unity_docs
physics
Show me a Unity code example for 'Search settings and preferences'.
Use the Settings search provider to find settings in the Project Settings and Preferences windows. ## Query syntax Provider token: set: Query example: Searches for all light-related settings and preferences. ``` set: light ``` ## Provider filters The Settings provider has additional filters in the visual query buil...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_d6ea736a9ac5
unity_docs
scripting
What is `Search.QueryEngine_1.skipUnknownFilters` in Unity? Explain its purpose and usage.
QueryEngine<T0>.skipUnknownFilters public bool skipUnknownFilters ; Description Boolean. Indicates if unknown filters should be skipped. If true, unknown filters are skipped. If false and validateFilters is true, unknown filters will generate errors if no default filter handler is provided. See QueryValidati...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_man_0dbb8dd564ce
unity_docs
editor
In Unity's 'Search logs', what is 'Actions' and how does it work?
The context menu for the Logs search provider includes the following actions: Action Description Copy to clipboard Copies the log message to the clipboard. This is the default double-click action. To change the default action, refer to Preferences . Open Opens the log file in your operating system’s file browser.
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_man_9cbd0a5e25f5
unity_docs
ui
In Unity's 'Selector lists', what is 'Example' and how does it work?
The following two USS snippets have the same effect. ``` #container2 { background-color: pink; border-radius: 10px; } Button { background-color: pink; border-radius: 10px; } ``` ``` #container2, Button { background-color: pink; border-radius: 10px; } ```
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_man_7cbf77b20203
unity_docs
rendering
In Unity's 'CameraEvent and LightEvent events order reference for the Built-In Render Pipeline', what is 'Deferred rendering path' and how does it work?
BeforeGBuffer : Unity renders opaque geometry AfterGBuffer : Unity resolves depth. BeforeReflections : Unity renders default reflections, and Reflection Probe reflections. AfterReflections : Unity copies reflections to the Emissive channel of the G-buffer. BeforeLighting : Unity renders shadows. See LightEvent order of...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_025933b0cabb
unity_docs
scripting
What is `DragAndDrop.ProjectBrowserDropHandler` in Unity? Explain its purpose and usage.
DragAndDrop.ProjectBrowserDropHandler Declaration public delegate DragAndDropVisualMode ProjectBrowserDropHandler (int dragInstanceId , string dropUponPath , bool perform ); Parameters Parameter Description dragInstanceId ID of the dragged asset that is dropped into the Project browser window. dropUponP...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_d85631f27e03
unity_docs
scripting
Show me a Unity C# example demonstrating `Vector3.one`.
Vector3.one public static Vector3 one ; Description Shorthand for writing Vector3(1, 1, 1) . ```csharp using UnityEngine; using System.Collections;public class ExampleClass : MonoBehaviour { void Example() { transform.position = Vector3.one; } } ```
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_00b7ec84926c
unity_docs
ui
What is `UIElements.MouseManipulator.CanStopManipulation` in Unity? Explain its purpose and usage.
MouseManipulator.CanStopManipulation Declaration protected bool CanStopManipulation ( UIElements.IMouseEvent e ); Parameters Parameter Description e MouseEvent to validate. Returns bool True if MouseEvent uses the current activator button. False otherwise. Description Checks whether the MouseEvent ...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_abcf7ea9d85c
unity_docs
rendering
What is `Unity.Profiling.ProfilerCategory` in Unity? Explain its purpose and usage.
ProfilerCategory struct in Unity.Profiling / Implemented in: UnityEngine.CoreModule Description Use to specify category for instrumentation Profiler markers. ```csharp using Unity.Profiling;public class MySystemClass { static readonly ProfilerMarker s_SimulatePerfMarker = new ProfilerMarker(ProfilerCategory.Ai...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_c987804a76c9
unity_docs
scripting
What is `Experimental.Rendering.GraphicsFormat.RGB_PVRTC_4Bpp_SRGB` in Unity? Explain its purpose and usage.
Experimental : this API is experimental and might be changed or removed in the future. GraphicsFormat.RGB_PVRTC_4Bpp_SRGB Description A three-component, PVRTC compressed format where each 64-bit compressed texel block encodes a 4×4 rectangle of unsigned normalized RGB texel data with sRGB nonlinear encoding. This f...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_20ce1bc7d4f5
unity_docs
editor
Show me a Unity C# example demonstrating `VersionControl.Provider.Incoming`.
Provider.Incoming Declaration public static VersionControl.Task Incoming (); Description Starts a task that queries the version control server for incoming changes. The task returns the incoming changesets which then can be accessed through the task's Task.changeSets property once it has been completed. ``...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_a0b2e471a701
unity_docs
math
What is `Vector2Int.FloorToInt` in Unity? Explain its purpose and usage.
Vector2Int.FloorToInt Declaration public static Vector2Int FloorToInt ( Vector2 v ); Description Converts a Vector2 to a Vector2Int by doing a Floor to each value. As there is a conversion of float to integer, there is a loss of precision.
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_2f48a3c64adf
unity_docs
audio
What is `AudioSpatialExperience` in Unity? Explain its purpose and usage.
AudioSpatialExperience enumeration Description Defines the types of audio spatialization experience available in player and audio settings. The AudioSpatializationExperience setting is only supported on visionOS. Additional resources: AudioSettings.audioSpatializationExperience Properties Property Descript...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_cf9bc6d5cecf
unity_docs
scripting
What is `AI.NavMeshAgent.angularSpeed` in Unity? Explain its purpose and usage.
NavMeshAgent.angularSpeed public float angularSpeed ; Description Maximum turning speed in (deg/s) while following a path. This is the maximum rate at which the agent can turn as it rounds the "corner" defined by a waypoint. The actual turning circle is also influenced by the speed of the agent on approach and ...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
gh_7c27c0227c48
github
scripting
Write a Unity C# script called Time Counter
```csharp using System; using System.Collections; using UnityEngine; namespace THEBADDEST.Coroutines { public class TimeCounter : CoroutineDelay { private string resultString; private Coroutine coroutine; private bool isPlaying = true; private int incr = 0; private int ...
You are a knowledgeable Unity developer. Explain Unity concepts clearly and provide practical, tested code examples.
local_sr_8275b0ef7cbc
unity_docs
scripting
What is `GameObject.GetComponent` in Unity? Explain its purpose and usage.
GameObject.GetComponent Declaration public T GetComponent (); Returns T A reference to a component of the specified type, returned as an object of type T . If no component is found, returns null . Description Retrieves a reference to a component of the specified type, by providing the component type as ...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_man_f3f57e3b38e5
unity_docs
xr
Explain 'Unity Accelerator Prometheus metrics reference' in Unity.
Each Unity Accelerator hosts Prometheus metric reports as /metrics , which you can query from the local network. The following is a full list of metrics that you can access: Metric Description process_resident_memory_bytes The amount of memory used by the cache server. uta_agent_sys_cpu_percent The amount of CPU used b...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_b97edde447a1
unity_docs
scripting
What is `Rendering.RenderPipelineAsset` in Unity? Explain its purpose and usage.
RenderPipelineAsset class in UnityEngine.Rendering / Inherits from: ScriptableObject / Implemented in: UnityEngine.CoreModule Description An asset that produces a specific IRenderPipeline. Default implementation of IRenderPipelineAsset. This manages the lifecylces of inherited types, as well as ensures that c...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_f8e144dff619
unity_docs
editor
What is `IMGUI.Controls.TreeView` in Unity? Explain its purpose and usage.
TreeView class in UnityEditor.IMGUI.Controls Description The TreeView is an IMGUI control that lets you create tree views, list views and multi-column tables for Editor tools. It is customizable with regards to row content rendering, dragging logic, selection logic, searching, sorting and renaming of items. To en...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_9dab84368e4b
unity_docs
scripting
What is `Progress.GetStartDateTime` in Unity? Explain its purpose and usage.
Progress.GetStartDateTime Declaration public static long GetStartDateTime (int id ); Parameters Parameter Description id The progress indicator's unique ID. Returns long The progress indicator's start timestamp. Description Gets the timestamp of when the progress indicator started.
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_48eaa8c39cbe
unity_docs
scripting
Show me a Unity C# example demonstrating `QualitySettings.activeQualityLevelChanged`.
QualitySettings.activeQualityLevelChanged Parameters Parameter Description value If the current Quality level is being changed this callback will be raised. Description Delegate that you can use to invoke custom code when Unity changes the current Quality Level. Parameters are the previous Quality Level and t...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_man_8b63b952d7d0
unity_docs
audio
In Unity's 'Tracker Modules', what is 'Benefits of Using Tracker Modules' and how does it work?
Tracker module files differ from mainstream PCM formats (.aif ,.wav ,.mp3 , and.ogg ) in that they can be very small without a corresponding loss of sound quality. A single sound sample can be modified in pitch and volume (and can have other effects applied), so it essentially acts as an “instrument” which can play a t...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_man_1dad1c9abbbe
unity_docs
rendering
In Unity's 'Customizing native memory allocators', what is 'Using command line arguments' and how does it work?
You can use command line arguments to set the size of each allocator. To find the name of the allocator parameters you want to change, check the list of allocator settings the Editor and players print when they start up. For example, to change the block size of the main heap allocators, use the following: -memorysetup-...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_26d2fe4e9984
unity_docs
animation
What is `AnimationEvent.time` in Unity? Explain its purpose and usage.
AnimationEvent.time public float time ; Description The time at which the event will be fired off. The AnimationEvent obtains the clip length from its attached clip. The time property determines when the event is processed. For example, if the clip length is 2s and time is set to 1.5f, then the function i...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_5041c69ea8a5
unity_docs
scripting
Show me a Unity C# example demonstrating `Light`.
/ Implemented in: UnityEngine.CoreModule Description Script interface for light components . Use this to control all aspects of Unity's lights. The properties are an exact match for the values shown in the Inspector. For more information about shadow maps, refer to Shadow Mapping . Usually lights are just c...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_88f25b5f1188
unity_docs
audio
Show me a Unity C# example demonstrating `AudioSource.Pause`.
AudioSource.Pause Declaration public void Pause (); Description Pauses playing the clip . Additional resources: Play , Stop functions. ```csharp // Allow a song to be chosen and played. If can be paused, and the song played further. // Two songs are supported.using System.Collections; using System.Collect...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
gh_1724f442d80c_doc_16
github
scripting
What does `ChangeBasis` do in this Unity script? Explain its purpose and signature.
Given a TrTransform, returns that transform as a mat4 in another basis.The new basis is specified by the payload.This changes both axes and units. Signature: ```csharp public static Matrix4x4 ChangeBasis( TrTransform xfInput, SceneStatePayload payload) ```
You are a senior Unity engineer. Answer questions about Unity scripting, XR/VR development, and game systems with working code examples.
local_sr_ec1bdf02bf63
unity_docs
scripting
Give me an overview of the `TileBaseEditor` class in Unity.
TileBaseEditor class in UnityEditor / Inherits from: Editor Description Default editor for TileBase assets. Constructors Constructor Description TileBaseEditor Default editor for TileBase assets. Public Methods Method Description RenderStaticPreview Creates a texture preview for rendering the TileBase ...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_e598ba39ca96
unity_docs
scripting
What is `UIElements.Experimental.StyleValues.paddingLeft` in Unity? Explain its purpose and usage.
Experimental : this API is experimental and might be changed or removed in the future. StyleValues.paddingLeft public float paddingLeft ; Description Space reserved for the left edge of the padding during the layout phase.
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_22bf0b46c723
unity_docs
rendering
What is `Light.AddCommandBuffer` in Unity? Explain its purpose and usage.
Light.AddCommandBuffer Declaration public void AddCommandBuffer ( Rendering.LightEvent evt , Rendering.CommandBuffer buffer ); Declaration public void AddCommandBuffer ( Rendering.LightEvent evt , Rendering.CommandBuffer buffer , Rendering.ShadowMapPass shadowPassMask ); Parameters Parameter D...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_4394e834afaf
unity_docs
scripting
What is `AnimationWindow` in Unity? Explain its purpose and usage.
AnimationWindow class in UnityEditor / Inherits from: EditorWindow Implements interfaces: IHasCustomMenu Description Use the AnimationWindow class to select and edit Animation clips. The Animation window will update when selecting Animation clips in the Project window or game objects with Animation players (su...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_1af3cdd601b3
unity_docs
ui
What is `UIElements.ListView.destroyItem` in Unity? Explain its purpose and usage.
ListView.destroyItem public Action<VisualElement> destroyItem ; Description Callback invoked when a VisualElement created via makeItem is no longer needed and will be destroyed. The method called by this callback receives the VisualElement that will be destroyed from the pool.
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_ce2153b68293
unity_docs
scripting
What is `Android.AndroidAssetPackError.ApiNotAvailable` in Unity? Explain its purpose and usage.
AndroidAssetPackError.ApiNotAvailable Description Indicates that the Asset Delivery API is not available. One possible cause of this is that the PlayCore version you added to the project is too old. Additional resources: AndroidAssetPacks.DownloadAssetPackAsync , AndroidAssetPacks.GetAssetPackStateAsync .
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_2b1b1e68ce03
unity_docs
scripting
Show me a Unity C# example demonstrating `TextMesh.anchor`.
TextMesh.anchor public TextAnchor anchor ; Description Which point of the text shares the position of the Transform. ```csharp using UnityEngine;public class Example : MonoBehaviour { void Start() { GetComponent<TextMesh>().anchor = TextAnchor.MiddleCenter; } } ```
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.