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_8dc281e3c20a
unity_docs
xr
What is `Rendering.AsyncGPUReadback` in Unity? Explain its purpose and usage.
AsyncGPUReadback class in UnityEngine.Rendering / Implemented in: UnityEngine.CoreModule Description Allows the asynchronous read back of GPU resources. This class is used to copy resource data from the GPU to the CPU without any stall (GPU or CPU), but adds a few frames of latency. Additional resources: Async...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_08d31070934c
unity_docs
physics
What is `PhysicsVisualizationSettings.useVariedContactColors` in Unity? Explain its purpose and usage.
PhysicsVisualizationSettings.useVariedContactColors public static bool useVariedContactColors ; Description Whether varied colors are used for PhysicsDebugWindow contact visualization. If you set this property to false, PhysicsVisualizationSettings.contactColor , PhysicsVisualizationSettings.contactImpulseC...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_man_488973e1ecc9
unity_docs
scripting
In Unity's 'Animator component', what is 'Properties' and how does it work?
Property Function Controller The animator controller attached to this character. Avatar The Avatar for this character. (If the Animator is being used to animate a humanoid character) Apply Root Motion Select whether to control the character’s position and rotation from the animation itself or from script. Update Mode T...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_05e6b671deed
unity_docs
xr
What is `Networking.DownloadHandlerAssetBundle.autoLoadAssetBundle` in Unity? Explain its purpose and usage.
DownloadHandlerAssetBundle.autoLoadAssetBundle public bool autoLoadAssetBundle ; Description If true, the AssetBundle will be loaded as part of the UnityWebRequest process. If false, the AssetBundle will be loaded on demand when accessing the DownloadHandlerAssetBundle.assetBundle property. Default: false...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_man_fe27bd36c5a4
unity_docs
rendering
In Unity's 'Lighting Settings Asset Inspector window reference', what is 'Realtime Lighting' and how does it work?
This section contains settings related to the Enlighten Realtime Global Illumination system . Property Description Realtime Global Illumination Enable this property to use the Enlighten Realtime Global Illumination system in Scenes that use this Lighting Settings Asset. Realtime Environment Lighting Enable this propert...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_43745e574f15
unity_docs
scripting
What is `ContactFilter2D.ClearDepth` in Unity? Explain its purpose and usage.
ContactFilter2D.ClearDepth Declaration public void ClearDepth (); Description Turns off depth filtering by setting useDepth to false. The associated values of minDepth and maxDepth are not changed.
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_4345833b3b99
unity_docs
editor
What is `Handles.SnapValue` in Unity? Explain its purpose and usage.
Handles.SnapValue Declaration public static float SnapValue (float value , float snap ); Parameters Parameter Description value The value to snap. snap The increment to snap to. Returns float If snapping is active , rounds value to the closest multiple of snap (snap can only be positive). Desc...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_8ef2fa4a3a4d
unity_docs
xr
What is `CachedAssetBundle` in Unity? Explain its purpose and usage.
CachedAssetBundle struct in UnityEngine / Implemented in: UnityEngine.CoreModule Description Data structure for downloading AssetBundles to a customized cache path. Additional resources: UnityWebRequestAssetBundle.GetAssetBundle for more information. Properties Property Description hash Hash128 which is use...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_ee60bf1c1550
unity_docs
scripting
What is `AndroidJNI.SetStaticIntField` in Unity? Explain its purpose and usage.
AndroidJNI.SetStaticIntField Declaration public static void SetStaticIntField (IntPtr clazz , IntPtr fieldID , int val ); Description Sets the value of a static field in the specified object. Additional resources: Java Native Interface Specification (Oracle)
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_90ad35aa8007
unity_docs
rendering
What is `FileUtil.DeleteFileOrDirectory` in Unity? Explain its purpose and usage.
FileUtil.DeleteFileOrDirectory Declaration public static bool DeleteFileOrDirectory (string path ); Description Deletes a file or a directory given a path. This function's path is relative to the project root folder but it can also accept absolute paths. All file separators should be forward ones "/" (Unix sty...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_8f8d930f9b7e
unity_docs
animation
What is `Animations.PropertyStreamHandle.SetInt` in Unity? Explain its purpose and usage.
PropertyStreamHandle.SetInt Declaration public void SetInt ( Animations.AnimationStream stream , int value ); Parameters Parameter Description stream The AnimationStream that holds the animated values. value The new integer property value. Description Sets the integer property value into a stream. I...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_man_7bf6ad4a5051
unity_docs
ui
Explain 'Selector lists' in Unity.
A selector list is a comma-separated list of selectors that share the same style rule. ## Syntax A selector list consists of multiple selectors separated by commas: ``` selector1, selector2 {...} ``` ## Example The following two USS snippets have the same effect. ``` #container2 { background-color: pink; border-r...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_9374d2c65276
unity_docs
physics
What is `MonoBehaviour.OnMouseEnter` in Unity? Explain its purpose and usage.
MonoBehaviour.OnMouseEnter() Description Called when the mouse enters the Collider . The corresponding OnMouseOver function is called while the mouse stays over the object and OnMouseExit is called when it moves away. This event is sent to all scripts attached to the Collider . This function is not called on...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_10c7556ca0e0
unity_docs
networking
What is `Android.AndroidScreenLayoutSize.Undefined` in Unity? Explain its purpose and usage.
AndroidScreenLayoutSize.Undefined Description Mirrors the Android property value SCREENLAYOUT_SIZE_UNDEFINED . For information about the property value, refer to the Android developer documentation on SCREENLAYOUT_SIZE_UNDEFINED .
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_b4767fd1883a
unity_docs
scripting
Show me a Unity C# example demonstrating `ExecuteAlways`.
heel that's not forwarded to EventType.KeyDown or EventType.KeyUp . Events forwarded to the Game view are added to a queue and aren't guaranteed to be processed immediately. OnRenderObject and the other rendering callback functions are called on every redraw of the Scene view or Game view. See Also: Appli...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_fad5d8fe1994
unity_docs
rendering
What is `Rendering.CommandBuffer.SetGlobalMatrix` in Unity? Explain its purpose and usage.
CommandBuffer.SetGlobalMatrix Declaration public void SetGlobalMatrix (string name , Matrix4x4 value ); Declaration public void SetGlobalMatrix (int nameID , Matrix4x4 value ); Description Add a "set global shader matrix property" command. When the command buffer will be executed, a global shader ma...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_056044e3b820
unity_docs
input
What is `Input.GetMouseButtonUp` in Unity? Explain its purpose and usage.
Input.GetMouseButtonUp Declaration public static bool GetMouseButtonUp (int button ); Description Returns true during the frame the user releases the given mouse button. Note : This API is part of the legacy Input Manager. The recommended best practice is that you don't use this API in new projects. For new pr...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
gh_103347a59c12_doc_4
github
scripting
What does `this member` do in this Unity script? Explain its purpose and signature.
Stores the used to enable or disable strafing (sideways movement) of continuous movement. Signature: ```csharp public Toggle enableStrafeToggle ```
You are an experienced Unity developer specializing in C# scripting, XR/VR development, and performance optimization.
local_sr_18449183e565
unity_docs
rendering
What is `GUI.ModalWindow` in Unity? Explain its purpose and usage.
GUI.ModalWindow Declaration public static Rect ModalWindow (int id , Rect clientRect , GUI.WindowFunction func , string text ); Declaration public static Rect ModalWindow (int id , Rect clientRect , GUI.WindowFunction func , Texture image ); Declaration public static Rect ModalWindow ...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_83bf0adf23e6
unity_docs
math
What is `ComputeShader.SetInts` in Unity? Explain its purpose and usage.
ComputeShader.SetInts Declaration public void SetInts (string name , params int[] values ); Declaration public void SetInts (int nameID , params int[] values ); Parameters Parameter Description name Array variable name in the shader code. nameID Property name ID, use Shader.PropertyToID to get it...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_5a15961e6455
unity_docs
animation
Give me an overview of the `HumanBodyBones` class in Unity.
HumanBodyBones enumeration Description Human Body Bones. Additional resources: Animator.GetBoneTransform . Properties Property Description Hips This is the Hips bone. LeftUpperLeg This is the Left Upper Leg bone. RightUpperLeg This is the Right Upper Leg bone. LeftLowerLeg This is the Left Knee bone. Righ...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_man_9e42bcc1a915
unity_docs
scripting
In Unity's 'HelpBox', what is 'Example' and how does it work?
The following UXML example creates a HelpBox with a warning message: ``` <UXML xmlns="UnityEngine.UIElements" xmlns:uie="UnityEditor.UIElements"> <HelpBox text="UXML Help Box" message-type="Info" name="the-uxml-help-box" /> </UXML> ``` The following C# example illustrates some of the customizable functionalities of th...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_e4418fd94734
unity_docs
scripting
What is `Handheld.SetActivityIndicatorStyle` in Unity? Explain its purpose and usage.
Handheld.SetActivityIndicatorStyle Declaration public static void SetActivityIndicatorStyle ( AndroidActivityIndicatorStyle style ); Description Sets the desired activity indicator style. Note that the change will take effect on next call to StartActivityIndicator.
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_d6f2fa8648fe
unity_docs
scripting
What is `Search.SearchUtils.CreateGroupProvider` in Unity? Explain its purpose and usage.
SearchUtils.CreateGroupProvider Declaration public static Search.SearchProvider CreateGroupProvider ( Search.SearchProvider templateProvider , string groupId , int groupPriority , bool cacheProvider ); Parameters Parameter Description templateProvider Search provider template to copy. groupId New gro...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_bb552ed3c31a
unity_docs
scripting
Show me a Unity C# example demonstrating `Application.logMessageReceived`.
Application.logMessageReceived Description Event that is fired if a log message is received. This event only ever triggers on the main thread. Use it if your handler requires accessing parts of the Unity API that are restricted to the main thread or if for other reasons your handler isn't thread-safe. ```csharp us...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_man_342c7213aad1
unity_docs
rendering
In Unity's 'Control material variant properties', what is 'Remove an override' and how does it work?
To remove an override, right-click the name of the property and select Revert . The child material reverts to inheriting the value from its parent. You can also select Revert all Overrides to remove all the overrides on the material.
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_f06eecd7b1b7
unity_docs
animation
What is `Animations.AnimatorJobExtensions.BindStreamTransform` in Unity? Explain its purpose and usage.
AnimatorJobExtensions.BindStreamTransform Declaration public static Animations.TransformStreamHandle BindStreamTransform ( Animator animator , Transform transform ); Parameters Parameter Description animator The Animator instance that calls this method. transform The Transform to bind. Returns ...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_dd5db785b0a0
unity_docs
scripting
What is `SceneManagement.Stage.OnCloseStage` in Unity? Explain its purpose and usage.
Stage.OnCloseStage Declaration protected void OnCloseStage (); Description Unity calls this method when the Stage is closed. Classes that inherit from Stage should implement cleanup logic in this method. A Stage can remain open even after another Stage becomes the active Stage. Unity only closes a Stage once it...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_b5db182a69f4
unity_docs
animation
What is `Animations.AnimationHumanStream.SetHintWeightPosition` in Unity? Explain its purpose and usage.
AnimationHumanStream.SetHintWeightPosition Declaration public void SetHintWeightPosition ( AvatarIKHint index , float value ); Parameters Parameter Description index The AvatarIKHint that is queried. value The position weight of the IK Hint. Description Sets the position weight of the IK Hint. Additio...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_man_30d2de9e0e57
unity_docs
audio
In Unity's 'Validate and upload assets to your package', what is 'Install the Asset Store Publishing Tools package' and how does it work?
Use the Asset Store Publishing Tools package to validate, upload, and preview your assets. To add it to your project: Go to the Asset Store Publishing Tools . Select Open in Unity . In the Unity Editor go to Window > Package Management > Package Manager . Select My Assets . Search for and select the Asset Store Publish...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
gh_e86ebf2b0978_doc_12
github
scripting
What does `IPoolable` do in this Unity script? Explain its purpose and signature.
Destroys all objects in the non-MonoBehaviour-based pool.The type of non-MonoBehaviour objects to destroy. Signature: ```csharp public void DestroyAllPure<T>() where T : class, IPoolable => GetPool<PurePool<T>, T>(_purePools).DestroyAll(); ```
You are an experienced Unity developer specializing in C# scripting, XR/VR development, and performance optimization.
local_sr_2c9151184881
unity_docs
scripting
What is `UIElements.TrickleDown` in Unity? Explain its purpose and usage.
TrickleDown enumeration Description Use this enum to specify during which phases the event handler is executed. Properties Property Description NoTrickleDown The event handler should be executed during the AtTarget and BubbleUp phases. TrickleDown The event handler should be executed during the AtTarg...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_e7e629731de0
unity_docs
scripting
What is `UIElements.INotifyValueChangedExtensions.UnregisterValueChangedCallback` in Unity? Explain its purpose and usage.
INotifyValueChangedExtensions.UnregisterValueChangedCallback Declaration public static bool UnregisterValueChangedCallback (INotifyValueChanged<T> control , EventCallback<ChangeEvent<T>> callback ); Description Unregisters this callback from receiving ChangeEvent_1 when the value is changed.
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
gh_2329a7941cc1_doc_9
github
scripting
What does `this member` do in this Unity script? Explain its purpose and signature.
The interactor instance that is associated with this state Signature: ```csharp public XRBaseInteractor m_Interactor; ```
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_man_5ae4ae95403b
unity_docs
physics
In Unity's 'Enable or disable asynchronous shader compilation', what is 'In an immediate scope' and how does it work?
In an immediate scope, you can use ShaderUtil.allowAsyncCompilation . To do this: Store the current state of ShaderUtil.allowAsyncCompilation in a variable. Before you call the rendering commands, set ShaderUtil.allowAsyncCompilation to false . Call the rendering commands. After calling the rendering commands, restore ...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_edc56e3b2fab
unity_docs
scripting
What is `UIElements.UxmlValueMatches` in Unity? Explain its purpose and usage.
UxmlValueMatches class in UnityEngine.UIElements / Inherits from: UIElements.UxmlTypeRestriction / Implemented in: UnityEngine.UIElementsModule Description Restricts the value of an attribute to match a regular expression. Properties Property Description regex The regular expression that should be mat...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_man_b99d33366ee5
unity_docs
audio
Explain 'Edit Animation curves' in Unity.
There are several different features and windows in the Unity Editor which use Curves to display and edit data. The methods you can use to view and manipulate curves is largely the same across all these areas, although there are some exceptions. The Animation Window uses curves to display and edit the values of animate...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_ed27aacf914c
unity_docs
editor
Show me a Unity C# example demonstrating `iOS.Xcode.PBXProject.ContainsFramework`.
d by TargetGuidByName . framework The name of the framework. The extension of the filename must be .framework . Returns bool Returns true if the given framework is a dependency of the given target. Description Checks whether the given system framework is a dependency of a target. The function assumes system...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_man_f3c67782f461
unity_docs
ui
In Unity's 'IMGUIContainer', what is 'Inherited UXML attributes' and how does it work?
This element inherits the following attributes from its base class: Name Type Description focusable boolean If false, this prevents the element from being focused. The element can only be focused if its canGrabFocus property is true. tabindex int An integer used to sort focusable elements in the focus ring. Must be gre...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_c5b743e5c168
unity_docs
rendering
What is `Random.ColorHSV` in Unity? Explain its purpose and usage.
Random.ColorHSV Declaration public static Color ColorHSV (); Declaration public static Color ColorHSV (float hueMin , float hueMax ); Declaration public static Color ColorHSV (float hueMin , float hueMax , float saturationMin , float saturationMax ); Declaration public static Color ColorHS...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_ec99f5a0958b
unity_docs
rendering
What is `Material.HasConstantBuffer` in Unity? Explain its purpose and usage.
Material.HasConstantBuffer Declaration public bool HasConstantBuffer (string name ); Declaration public bool HasConstantBuffer (int nameID ); Parameters Parameter Description nameID The name ID of the property. Use Shader.PropertyToID to get this ID. name The name of the property. Returns bool ...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_5fe532aae121
unity_docs
physics
Give me an overview of the `ModifiableMassProperties` class in Unity.
ModifiableMassProperties struct in UnityEngine / Implemented in: UnityEngine.PhysicsModule Description Mass-related modifiable properties of a contact pair. Mostly useful to make a collider appear lighter to the solver than it actually is when the bodies in this contact pair have very different mass values. Pr...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_0495f5c5bd33
unity_docs
scripting
What is `Experimental.Rendering.GraphicsFormat.A2R10G10B10_SIntPack32` in Unity? Explain its purpose and usage.
Experimental : this API is experimental and might be changed or removed in the future. GraphicsFormat.A2R10G10B10_SIntPack32 Description A four-component, 32-bit packed signed integer format that has a 2-bit A component in bits 30..31, a 10-bit R component in bits 20..29, a 10-bit G component in bits 10..19, and a ...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_d82ce4dd7e01
unity_docs
ui
What is `AssetImporters.AssetImporterEditor.ApplyButton` in Unity? Explain its purpose and usage.
AssetImporterEditor.ApplyButton Declaration protected bool ApplyButton (); Returns bool Returns true if the new settings were successfully applied. Description Implements the 'Apply' button of the inspector. The Apply button saves changes made to the setting values in your custom importer. Then, it re-imp...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_fdf5472b7a82
unity_docs
rendering
Give me an overview of the `Texture3D` class in Unity.
Texture3D class in UnityEngine / Inherits from: Texture / Implemented in: UnityEngine.CoreModule Description Class for handling 3D Textures, Use this to create 3D texture assets . 3D textures are commonly used as lookup tables by shaders, or to represent volumetric data. Typically you'd create a 3D texture,...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_7967224e4120
unity_docs
rendering
What is `Rendering.SortingSettings` in Unity? Explain its purpose and usage.
SortingSettings struct in UnityEngine.Rendering / Implemented in: UnityEngine.CoreModule Description This struct describes the methods to sort objects during rendering. Additional resources: DrawingSettings , ScriptableRenderContext.DrawRenderers. Properties Property Description cameraPosition Used to calc...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_26f5a2d7e216
unity_docs
scripting
What is `UIElements.AttachToPanelEvent` in Unity? Explain its purpose and usage.
AttachToPanelEvent class in UnityEngine.UIElements / Inherits from: UIElements.PanelChangedEventBase_1 / Implemented in: UnityEngine.UIElementsModule Description Event sent after an element is added to an element that is a descendant of a panel. Don't modify the parent of the element in your registered ca...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_8cedaaa2b4b5
unity_docs
scripting
What is `GameObject.GetComponentInChildren` in Unity? Explain its purpose and usage.
GameObject.GetComponentInChildren Declaration public T GetComponentInChildren (bool includeInactive = false); Parameters Parameter Description includeInactive Whether to include inactive child GameObjects in the search. Returns T A Component of the matching type T , otherwise null if no matching Com...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
gh_93aa55d2fe2e
github
scripting
Write a Unity C# UI script for Title View
```csharp using System.Threading; using Cysharp.Threading.Tasks; using UnityEngine; using UnityEngine.UI; namespace AntiMonoBehaviour.Views { public interface ITitleView { UniTask StartButtonClickAsync(CancellationToken cancel); } public class TitleView : UnityViewBase, ITitleView { ...
You are a knowledgeable Unity developer. Explain Unity concepts clearly and provide practical, tested code examples.
local_sr_952560340525
unity_docs
rendering
What is `ParticleSystemRenderer.BakeMesh` in Unity? Explain its purpose and usage.
ParticleSystemRenderer.BakeMesh Declaration public void BakeMesh ( Mesh mesh , ParticleSystemBakeMeshOptions options ); Declaration public void BakeMesh ( Mesh mesh , Camera camera , ParticleSystemBakeMeshOptions options ); Obsolete BakeMesh with useTransform is deprecated. Use BakeMesh with Pa...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_460ccc26f471
unity_docs
scripting
What is `ObjectChangeEventStream.Builder.PushChangeAssetObjectPropertiesEvent` in Unity? Explain its purpose and usage.
ObjectChangeEventStream.Builder.PushChangeAssetObjectPropertiesEvent Declaration public void PushChangeAssetObjectPropertiesEvent (ref ChangeAssetObjectPropertiesEventArgs data ); Parameters Parameter Description data The event data to add to the stream. Description Adds an ChangeAssetObjectPropertiesEv...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_b51e6ba31496
unity_docs
editor
What is `EditorTools.ToolManager.SetActiveTool` in Unity? Explain its purpose and usage.
ToolManager.SetActiveTool Declaration public static void SetActiveTool (); Declaration public static void SetActiveTool (Type type ); Declaration public static void SetActiveTool ( EditorTools.EditorTool tool ); Parameters Parameter Description type The EditorTool type to set as the active tool. ...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_7d7610f66ba2
unity_docs
scripting
What is `AndroidJNI.GetStaticFieldID` in Unity? Explain its purpose and usage.
AndroidJNI.GetStaticFieldID Declaration public static IntPtr GetStaticFieldID (IntPtr clazz , string name , string sig ); Description Returns the field ID for a static field of a class. Additional resources: Java Native Interface Specification (Oracle)
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_15034da26350
unity_docs
physics
What is `ControllerColliderHit.controller` in Unity? Explain its purpose and usage.
ControllerColliderHit.controller public characterController controller ; Description The controller that hit the collider. ```csharp using UnityEngine;public class Example : MonoBehaviour { //Disable collision detection on CharacterControllers we touch. void OnControllerColliderHit(ControllerColliderHit hit) ...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_bc337fd7df0c
unity_docs
scripting
Show me a Unity C# example demonstrating `Vector3.operator_multiply`.
Vector3.operator * public static Vector3 operator * ( Vector3 a , float d ); Description Multiplies a vector by a number. Multiplies each component of a by a number d . ```csharp // make the vector twice longer: prints (2.0,4.0,6.0) using UnityEngine; using System.Collections;public class ExampleClass ...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_66098013b341
unity_docs
physics
What is `Animations.AnimationScriptPlayable.SetProcessInputs` in Unity? Explain its purpose and usage.
AnimationScriptPlayable.SetProcessInputs Declaration public void SetProcessInputs (bool value ); Parameters Parameter Description value The new value for processing the inputs or not. Description Sets the new value for processing the inputs or not. In some cases, like for custom mixers, it is wanted to ha...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_9891c753ab52
unity_docs
scripting
Show me a Unity C# example demonstrating `Vector3.ctor`.
Vector3 Constructor Declaration public Vector3 (float x , float y , float z ); Description Creates a new vector with given x, y, z components. ```csharp //Attach this script to a GameObject. //Attach a Rigidbody component to the GameObject (Click Add Component button in the Inspector window and go to Physics...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_5fec36789183
unity_docs
scripting
Show me a Unity C# example demonstrating `Experimental.Rendering.ScriptableRuntimeReflectionSystemSettings.system`.
mental : this API is experimental and might be changed or removed in the future. ScriptableRuntimeReflectionSystemSettings.system public static Experimental.Rendering.IScriptableRuntimeReflectionSystem system ; Description The current scriptable runtime reflection system instance. Set this property in a meth...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
gh_4a1e04725075_doc_11
github
scripting
What does `ActionWithChangeCheck` do in this Unity script? Explain its purpose and signature.
Method to call GUI action that returns state of change Signature: ```csharp private bool ActionWithChangeCheck(Action action) ```
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_d4794e86fca9
unity_docs
rendering
What is `Search.SearchProposition` in Unity? Explain its purpose and usage.
SearchProposition struct in UnityEditor.Search Description Search propositions are used to display choices to the user to add new filters to a search query. ``` static IEnumerable<SearchProposition> EnumerateDecalPropositions(SearchContext context, SearchPropositionOptions options) { if (!options.flags.HasAny(Se...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_98aa3eda9fea
unity_docs
math
What is `IMGUI.Controls.PrimitiveBoundsHandle.DefaultMidpointHandleSizeFunction` in Unity? Explain its purpose and usage.
PrimitiveBoundsHandle.DefaultMidpointHandleSizeFunction Declaration public static float DefaultMidpointHandleSizeFunction ( Vector3 position ); Parameters Parameter Description position The current position of the handle in the space of Handles.matrix . Returns float The size to use for a handle at the...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_008c352eb077
unity_docs
scripting
What is `MPE.ChannelClient.IsConnected` in Unity? Explain its purpose and usage.
ChannelClient.IsConnected Declaration public bool IsConnected (); Returns bool Return true if connected, and false otherwise. Description Checks whether the ChannelClient connected to a ChannelService .
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_8d0bb3324b3e
unity_docs
input
What is `XR.XRInputSubsystem.GetSupportedTrackingOriginModes` in Unity? Explain its purpose and usage.
XRInputSubsystem.GetSupportedTrackingOriginModes Declaration public XR.TrackingOriginModeFlags GetSupportedTrackingOriginModes (); Returns TrackingOriginModeFlags A single series of flags that contains all supported TrackingOriginModeFlags . Description Gets all TrackingOriginModeFlags that this subsy...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_af3e86e3e59a
unity_docs
rendering
What are the parameters of `Search.SearchService.ShowPicker` in Unity?
Returns ISearchView Creates a new search window. Description Open a search item picker window. Declaration public static Search.ISearchView ShowPicker ( Search.SearchViewState viewState ); Parameters Parameter Description viewState Search view state used to open the Search Picker window. Returns ISearchView Creates a n...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_dfe253170156
unity_docs
scripting
What is `Unity.IO.LowLevel.Unsafe.FileInfoResult.FileState` in Unity? Explain its purpose and usage.
FileInfoResult.FileState public Unity.IO.LowLevel.Unsafe.FileState FileState ; Description Indicates whether the file exists or not. Possible values are FileState.Exists or FileState.Absent .
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_124ad5ff1695
unity_docs
physics
What are the parameters of `MonoBehaviour.OnTriggerEnter2D` in Unity?
Description Sent when another object enters a trigger collider attached to this object (2D physics only). Further information about the other collider is reported in the Collider2D parameter passed during the call. This message is sent to the trigger Collider2D and the Rigidbody2D (if any) that the trigger Collider2D b...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_ac34edf0398d
unity_docs
scripting
What is `SearchService.ProjectSearchContext.engineScope` in Unity? Explain its purpose and usage.
ProjectSearchContext.engineScope public SearchService.SearchEngineScope engineScope ; Description An enum that identifies the scope of the current search. This property is automatically set to SearchService.Project.EngineScope.
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_ad6661f9773c
unity_docs
xr
What is `Rendering.VirtualTexturing.Streaming` in Unity? Explain its purpose and usage.
Virtual Texturing is experimental and not ready for production use. The feature and documentation might be changed or removed in the future. Streaming class in UnityEngine.Rendering.VirtualTexturing / Implemented in: UnityEngine.VirtualTexturingModule Description Static class representing the Streaming Virtual ...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_b77a20d5394f
unity_docs
math
Show me a Unity C# example demonstrating `Mathf.Clamp01`.
Mathf.Clamp01 Declaration public static float Clamp01 (float value ); Description Clamps value between 0 and 1 and returns value. If the value is negative then zero is returned. If value is greater than one then one is returned. ```csharp using UnityEngine;public class Example : MonoBehaviour { // Set the p...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_man_44fa89ff0d8d
unity_docs
editor
Explain 'Develop for Embedded Linux' in Unity.
Find information specific to Embedded Linux development, such as plug-ins , optional features, and troubleshooting. Topic Description Autodetect plug-ins for Embedded Linux Detect plug-ins automatically for Embedded Linux. Enable optional features for Embedded Linux Enable optional features to improve your application ...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
gh_6a17979c4696_doc_0
github
scripting
What does `InvokeOnValidate` do in this Unity script? Explain its purpose and signature.
NOTE: This is also called from the . Signature: ```csharp protected override void InvokeOnValidate() ```
You are a senior Unity engineer. Answer questions about Unity scripting, XR/VR development, and game systems with working code examples.
gh_74fc56c7f25a_doc_4
github
scripting
What does `Erase` do in this Unity script? Explain its purpose and signature.
Erases Prefabs in a given position within the selected layers.The PrefabBrush overrides this to provide Prefab erasing functionality.Grid used for layout.Target of the erase operation. By default the currently selected GameObject.The coordinates of the cell to erase data from. Signature: ```csharp public override void...
You are a knowledgeable Unity developer. Explain Unity concepts clearly and provide practical, tested code examples.
local_sr_12e25b09d67d
unity_docs
scripting
Show me a Unity C# example demonstrating `Assertions.Assert.AreApproximatelyEqual`.
ximate equality check (|a-b| < tolerance ). Default tolerance is 0.00001f. Note: Every time you call the method with tolerance specified, a new instance of FloatComparer is created. For performance reasons you might want to instance your own comparer and pass it to the AreApproximatelyEqual method. If the tolera...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_e119a22ad077
unity_docs
editor
What is `ShortcutManagement.ShortcutManager.RegisterTag` in Unity? Explain its purpose and usage.
ShortcutManager.RegisterTag Declaration public static void RegisterTag (string tag ); Declaration public static void RegisterTag (Enum e ); Parameters Parameter Description tag Context string identifier. e Context enum identifier. Description Registers the tag as a custom context used to filter shor...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_f87ac5342a61
unity_docs
editor
What is `Device.SystemInfo.operatingSystem` in Unity? Explain its purpose and usage.
SystemInfo.operatingSystem public static string operatingSystem ; Description This has the same functionality as SystemInfo.operatingSystem and also mimics platform-specific behavior in the Unity Editor.
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_9d604752b7b8
unity_docs
scripting
What is `UIElements.MeshWriteData.SetNextIndex` in Unity? Explain its purpose and usage.
MeshWriteData.SetNextIndex(UInt16) Parameters Parameter Description index The value of the next index. Description Assigns the value of the next index of the allocated indices list. Used to iteratively fill the values of the allocated indices via repeated calls to this function until all values have been p...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_9c2850352346
unity_docs
scripting
Show me a Unity C# example demonstrating `VersionControl.Provider.Lock`.
. locked True to lock assets, false to unlock assets. Description Attempt to lock an asset for exclusive editing. Depending on version control system and server setup this might be an exclusive lock preventing other people from even modifing the asset (for example: Plastic SCM or Git) or it might simply prevent ot...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_bf287ce66d68
unity_docs
scripting
What is `Search.IPropertyDatabaseView.InvalidateMask` in Unity? Explain its purpose and usage.
IPropertyDatabaseView.InvalidateMask Declaration public void InvalidateMask (ulong documentKeyMask ); Parameters Parameter Description documentKeyMask A document key mask. Description Invalidate all properties stored from multiple documents that match a document key mask. This operation is slower than the...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_6c03ed1119c7
unity_docs
ui
Show me a Unity C# example demonstrating `UIElements.ToggleButtonGroupState.GetActiveOptions`.
ToggleButtonGroupState.GetActiveOptions Declaration public Span<int> GetActiveOptions (Span<int> activeOptionsIndices ); Parameters Parameter Description activeOptionsIndices A Span of type integers with the allocated size to hold the number of active indices. Description Retrieves a Span of integers cont...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_man_f33d0595f773
unity_docs
editor
In Unity's 'InspectorElement', what is 'Inherited UXML attributes' and how does it work?
This element inherits the following attributes from its base class: Name Type Description binding-path string Path of the target property to be bound. focusable boolean If false, this prevents the element from being focused. The element can only be focused if its canGrabFocus property is true. tabindex int An integer u...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_1986322ce9a0
unity_docs
scripting
What is `Search.ISearchQuery.GetProviderIds` in Unity? Explain its purpose and usage.
ISearchQuery.GetProviderIds Declaration public IEnumerable<string> GetProviderIds (); Returns IEnumerable<string> Provider ids. Description Returns the list of provider ids that search query is executed with.
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_ed5903932ecf
unity_docs
editor
Show me a Unity C# example demonstrating `MouseCursor.ResizeUpRight`.
MouseCursor.ResizeUpRight Description Resize up-right for window edges. ```csharp //Create a folder and name it “Editor” if this doesn’t already exist //Put this script in the folder//This script creates a new menu (“Examples”) and a menu item (“Mouse Cursor”). Click on this option. This displays a small window tha...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_man_4cb7e9e8696d
unity_docs
rendering
Show me a Unity code example for 'Text assets'.
on the ways you can generate text in Unity, refer to UI systems . ## Binary data Text assets can also store binary data. If you create a file with the.bytes extension, you can load it as a text asset and access it through the bytes property. For example, put a.jpeg file into the Resources folder and change the extens...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_8e66e548d04e
unity_docs
rendering
What is `AssetDatabase.GetCachedIcon` in Unity? Explain its purpose and usage.
AssetDatabase.GetCachedIcon Declaration public static Texture GetCachedIcon (string path ); Parameters Parameter Description path Path to the asset. Description Retrieves an icon for the asset at the given asset path. ```csharp using System.Collections.Generic; using UnityEditor; using UnityEngine;publi...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_cccc15919903
unity_docs
scripting
What is `Experimental.GraphView.StickyNote.fontSize` in Unity? Explain its purpose and usage.
Experimental : this API is experimental and might be changed or removed in the future. StickyNote.fontSize public Experimental.GraphView.StickyNoteFontSize fontSize ; Description The font size of the [StickyNote].
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_3bf347e59694
unity_docs
rendering
What is `AssetPostprocessor.OnAssignMaterialModel` in Unity? Explain its purpose and usage.
AssetPostprocessor.OnAssignMaterialModel(Material,Renderer) Description Feeds a source material. The returned material will be assigned to the renderer. If you return null, Unity will use its default material finding / generation method to assign a material. The sourceMaterial is generated directly from the model...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_d81dea180e5f
unity_docs
rendering
Give me an overview of the `MaterialProperty` class in Unity.
MaterialProperty class in UnityEditor Description Describes information and value of a single shader property. MaterialProperty is used with the MaterialEditor when writing custom material editors, or implementing custom MaterialPropertyDrawer classes. Additional resources: MaterialEditor , MaterialProperty...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_d701fe7f008b
unity_docs
editor
What is `Search.ObjectField.ctor` in Unity? Explain its purpose and usage.
ObjectField Constructor Declaration public ObjectField (); Declaration public ObjectField (string label ); Parameters Parameter Description label Display label if used in a property editor. Description Construct an advanced search field UITK control.
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_man_d908abee1bee
unity_docs
editor
Explain 'Manage packages in the Asset Store' in Unity.
Use the My Assets page of the Asset Store to organize the packages that you own and have downloaded. ## Use the My Assets page To access the My Assets page do one of the following: Select the My Assets folder icon in the top navigation of the Asset Store. Select your user name in the top right of the navigation, then...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_1e853b338b75
unity_docs
rendering
What is `RenderTexture.graphicsFormat` in Unity? Explain its purpose and usage.
RenderTexture.graphicsFormat public Experimental.Rendering.GraphicsFormat graphicsFormat ; Description The color format of the render texture. You can set the color format to None to achieve depth-only rendering. Additional resources: GraphicsFormat .
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_3e1b65683c97
unity_docs
rendering
What is `Material.SetPass` in Unity? Explain its purpose and usage.
Material.SetPass Declaration public bool SetPass (int pass ); Parameters Parameter Description pass Shader pass number to setup. Returns bool If false is returned, no rendering should be done. Description Activate the given pass for rendering. Pass indices start from zero and go up to (but not in...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_13ec235123ff
unity_docs
scripting
Give me an overview of the `BodyDof` class in Unity.
BodyDof enumeration Description Enumeration of all the muscles in the body. These muscles are a sub-part of a human part. Additional resources: HumanPartDof . Properties Property Description SpineFrontBack The spine front-back muscle. SpineLeftRight The spine left-right muscle. SpineRollLeftRight The spine ...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_man_6f51c873473c
unity_docs
rendering
Show me a Unity code example for 'Using Streaming Virtual Texturing in Shader Graph'.
ng . For more information, see How Streaming Virtual Texturing works . To use a Sample Virtual Texture node in the vertex stage, you first need to disable Automatic Streaming on the Sample Virtual Texture node, and then select the Lod Level mode. You must then use a script to manually request that SVT loads the tiles. ...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_d7ded0467538
unity_docs
scripting
What is `Unity.Collections.LowLevel.Unsafe.UnsafeUtility.SetLeakDetectionMode` in Unity? Explain its purpose and usage.
UnsafeUtility.SetLeakDetectionMode Declaration public static void SetLeakDetectionMode ( Unity.Collections.NativeLeakDetectionMode value ); Parameters Parameter Description value The mode of leak detection. 1 = disabled, 2 = enabled, or 3 = enabled with callstacks. Description Set the leak detection mode.
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_f7b503460596
unity_docs
input
Show me a Unity C# example demonstrating `KeyCode.Escape`.
KeyCode.Escape Description Escape key. ```csharp using UnityEngine;public class Example : MonoBehaviour { void Update() { if (Input.GetKeyDown(KeyCode.Escape)) { Debug.Log("Escape key was pressed"); } if (Input.GetKeyUp(KeyCode.Escape)) { Debug.Log("Escape key was released"); } if (Input.GetKey(KeyCode.Esc...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_2d5e32358772
unity_docs
rendering
What are the parameters of `AssetDatabase.ForceReserializeAssets` in Unity?
Description Forcibly load and re-serialize the given assets, flushing any outstanding data changes to disk. When Unity loads old data from an asset or Scene file, the data is dynamically upgraded in memory, but not written back to disk unless the user does something that explicitly dirties the object (like changing a v...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_14623d4d8163
unity_docs
editor
What is `EditorGUILayout.BeginToggleGroup` in Unity? Explain its purpose and usage.
EditorGUILayout.BeginToggleGroup Declaration public static bool BeginToggleGroup (string label , bool toggle ); Declaration public static bool BeginToggleGroup ( GUIContent label , bool toggle ); Parameters Parameter Description label Label to show above the toggled controls. toggle Enabled state o...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_0330ae3b03d7
unity_docs
input
What is `Input.touchCount` in Unity? Explain its purpose and usage.
Input.touchCount public static int touchCount ; Description Number of touches. Guaranteed not to change throughout the frame. (Read Only) Note : This API is part of the legacy Input Manager. The recommended best practice is that you don't use this API in new projects. For new projects, use the Input System pack...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_7a615c883495
unity_docs
editor
Show me a Unity C# example demonstrating `Search.QueryEngine_1.AddOperator`.
QueryEngine<T0>.AddOperator Declaration public void AddOperator (string op ); Parameters Parameter Description op The operator identifier. Description Adds a custom filter operator. ```csharp using System; using System.Collections.Generic; using System.Linq; using UnityEditor; using UnityEditor.Search; us...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.
local_sr_fa2e79024315
unity_docs
editor
What is `ShortcutManagement.ShortcutManager.UnregisterTag` in Unity? Explain its purpose and usage.
ShortcutManager.UnregisterTag Declaration public static void UnregisterTag (string tag ); Parameters Parameter Description tag Context string identifier. Description Removes a tag from the custom context list. ```csharp using UnityEditor; using UnityEditor.ShortcutManagement; using UnityEngine;public clas...
You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges.