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_1ba0e000a6b0 | unity_docs | scripting | What is `Pool.IObjectPool_1` in Unity? Explain its purpose and usage. | IObjectPool<T0>
interface in
UnityEngine.Pool
Description
Interface for ObjectPools.
Additional resources:
ObjectPool<T0>
,
LinkedPool<T0>
.
Properties
Property
Description
CountInactive
The total amount of items currently in the pool.
Public Methods
Method
Description
Clear
Removes all pooled items. If... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_man_6037824520a3 | unity_docs | scripting | In Unity's 'Create TreeView with IMGUI', what is 'Important classes and methods' and how does it work? | The most important classes aside from the TreeView itself are TreeViewItem and
TreeViewState
.
TreeViewState
(
TreeViewState
) contains state information that is changed when interacting with TreeView fields in the Editor, such as selection state, expanded state, navigation state, and scroll state.
TreeViewState
is the... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_a9c11e4a4f06 | unity_docs | math | What is `Mathf.Asin` in Unity? Explain its purpose and usage. | Mathf.Asin
Declaration
public static float
Asin
(float
f
);
Description
Returns the arc-sine of
f
- the angle in radians whose sine is
f
.
```csharp
using UnityEngine;public class ScriptExample : MonoBehaviour
{
void Start()
{
print(Mathf.Asin(0.5f));
}
}
``` | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_3cf77a5e6878 | unity_docs | scripting | What is `Search.QueryEngine.ctor` in Unity? Explain its purpose and usage. | QueryEngine Constructor
Declaration
public
QueryEngine
();
Declaration
public
QueryEngine
(bool
validateFilters
);
Declaration
public
QueryEngine
(
Search.QueryValidationOptions
validationOptions
);
Parameters
Parameter
Description
validateFilters
Indicates if the engine must validate filters when ... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_man_20ce8d6bfe77 | unity_docs | networking | In Unity's 'Collecting performance data on an iOS device', what is 'Enabling remote profiling' and how does it work? | To enable remote profiling, follow these steps:
Connect the device to your WiFi network. The Profiler uses a local WiFi network to send profiling data from your device to the Unity Editor.
Attach your device to your computer via cable.
Open the
Build Profiles
window (menu:
File > Build Profiles
).
Enable the
Developmen... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_6c092813dea6 | unity_docs | scripting | What is `UIElements.StylePropertyName.IsNullOrEmpty` in Unity? Explain its purpose and usage. | StylePropertyName.IsNullOrEmpty
Declaration
public static bool
IsNullOrEmpty
(
UIElements.StylePropertyName
propertyName
);
Parameters
Parameter
Description
propertyName
StylePropertyName you want to check.
Returns
bool
True if propertyName is invalid. False otherwise.
Description
Checks if the Sty... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_be5da9ce2ba7 | unity_docs | editor | Give me an overview of the `SettingsProviderAttribute` class in Unity. | SettingsProviderAttribute
class in
UnityEditor
Description
Attribute used to register a new
SettingsProvider
. Use this attribute to decorate a function that returns an instance of a
SettingsProvider
. If the function returns null, no SettingsProvider appears in the Settings window.
```csharp
using System.IO;
u... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_e240b6f1a5d1 | unity_docs | ui | What is `UIElements.VisualElementExtensions.LocalToWorld` in Unity? Explain its purpose and usage. | VisualElementExtensions.LocalToWorld
Declaration
public static
Vector2
LocalToWorld
(
UIElements.VisualElement
ele
,
Vector2
p
);
Parameters
Parameter
Description
ele
The element to use as a reference for the local space.
p
The point to transform, in local space.
Returns
Vector2
A point in the wo... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_ab120ada556a | unity_docs | physics | What is `Toolbars.EditorToolbarDropdownToggle.ctor` in Unity? Explain its purpose and usage. | EditorToolbarDropdownToggle Constructor
Declaration
public
EditorToolbarDropdownToggle
();
Declaration
public
EditorToolbarDropdownToggle
(
Unity.Android.Gradle.Manifest.Action
dropdownClickEvent
);
Declaration
public
EditorToolbarDropdownToggle
(string
text
,
Unity.Android.Gradle.Manifest.Action
dropd... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_c54dc0ec3257 | unity_docs | scripting | What is `Tilemaps.Tilemap.SwapTile` in Unity? Explain its purpose and usage. | Tilemap.SwapTile
Declaration
public void
SwapTile
(
Tilemaps.TileBase
changeTile
,
Tilemaps.TileBase
newTile
);
Parameters
Parameter
Description
changeTile
Tile to swap.
newTile
Tile to swap to.
Description
Swaps all existing
Tile
s of
changeTile
to
newTile
and refreshes all the swapped
Tile
s.... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
gh_af1f727cefc0 | github | scripting | Write a Unity Editor script for State Switcher Editor | ```csharp
using System;
using UnityEditor;
using UnityEngine;
namespace UIStateSwitcher.Editor
{
[CustomEditor(typeof(StateSwitcher))]
public class StateSwitcherEditor : UnityEditor.Editor
{
private int selectedIndex;
public override void OnInspectorGUI()
{
... | You are a senior Unity engineer. Answer questions about Unity scripting, XR/VR development, and game systems with working code examples. |
local_sr_8c17e85ffce0 | unity_docs | scripting | Show me a Unity C# example demonstrating `Grid.GetCellCenterWorld`. | s.
Description
Get the logical center coordinate of a grid cell in world space.
In a rectangular grid layout, a call to
GridLayout.CellToWorld
with
Vector3Int
parameter, returns a
Vector3
coordinate that represents the bottom-left of the cell. This is mathematically correct, but when for example instantiatin... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_man_9b8eca27df67 | unity_docs | scripting | In Unity's 'Managed memory introduction', what is 'Clean and dirty pages' and how does it work? | When a page enters physical memory, the operating system keeps track of whether your application has modified it and assigns the page one of the following types:
Page type Description Performance impact Clean Contains data that has been read from a file and hasn’t been changed. For example, a game’s executable code, re... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_man_eeda0df3c031 | unity_docs | rendering | Explain 'Control how much memory shaders use' in Unity. | In your built application, Unity stores several ‘chunks’ of compressed shader variant data. Each chunk contains multiple shader variants. When Unity loads a scene at runtime, it loads all the scene’s chunks into CPU memory and decompresses them.
To reduce memory usage on platforms that have limited memory, you can limi... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_ab1a42cd380c | unity_docs | math | What is `AudioSource.GetSpectrumData` in Unity? Explain its purpose and usage. | AudioSource.GetSpectrumData
Declaration
public void
GetSpectrumData
(float[]
samples
,
int
channel
,
FFTWindow
window
);
Parameters
Parameter
Description
samples
The array to populate with frequency domain representations of audio samples. The array length must be a power of 2 (such as 128, 256, 512). A... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_7c638a46a7ab | unity_docs | editor | What is `EditorGUILayout.MaskField` in Unity? Explain its purpose and usage. | EditorGUILayout.MaskField
Declaration
public static int
MaskField
(
GUIContent
label
,
int
mask
,
string[]
displayedOptions
,
GUIStyle
style
,
params GUILayoutOption[]
options
);
Declaration
public static int
MaskField
(string
label
,
int
mask
,
string[]
displayedOptions
,
GUIStyle
style
,
params G... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_aeb36de56704 | unity_docs | rendering | What is `Material.SetOverrideTag` in Unity? Explain its purpose and usage. | Material.SetOverrideTag
Declaration
public void
SetOverrideTag
(string
tag
,
string
val
);
Parameters
Parameter
Description
tag
Name of the tag to set.
val
Name of the value to set. Empty string to clear the override flag.
Description
Sets an override tag/value on the material.
Will set a tag/value on... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
gh_6bdb2e16b792_doc_0 | github | scripting | What does `this member` do in this Unity script? Explain its purpose and signature. | An object that allows users to edit objects when using the Unity inspector.
Signature:
```csharp
public sealed class EditableOrderedDictionary_string_Texture2D : EditableEntry<OrderedDictionary_string_Texture2D>
``` | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
gh_6910d9d9a9ea_doc_14 | github | scripting | What does `OnMouseDragAsObservable` do in this Unity script? Explain its purpose and signature. | OnMouseDrag is called when the user has clicked on a GUIElement or Collider and is still holding down the mouse.
Signature:
```csharp
public static IObservable<Unit> OnMouseDragAsObservable(this Component component)
``` | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
gh_a326a9e5b629_doc_1 | github | scripting | What does `CodeBlock` do in this Unity script? Explain its purpose and signature. | A block of code that can be passed around as a value to be executedas many times as desired by the function it is passed to.CodeBlock setDone = () => _done = true;CodeBlock doRandomStuff = () => { DoSomeRandomStuff(); Player.Instance.transform.position = Vector3.zero; _done = true;};void ExecuteTwice([CanBeNul... | You are an expert Unity game developer. Provide clear, accurate, and practical answers about Unity development. |
local_sr_3ef71d44d5de | unity_docs | scripting | What is `Vector3Int.ctor` in Unity? Explain its purpose and usage. | Vector3Int Constructor
Declaration
public
Vector3Int
(int
x
,
int
y
,
int
z
);
Parameters
Parameter
Description
x
The X component of the Vector3Int.
y
The Y component of the Vector3Int.
z
The Z component of the Vector3Int.
Description
Initializes and returns an instance of a new Vector3Int with x, y,... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_8d0016dfe398 | unity_docs | editor | What are the parameters of `EditorGUI.BeginDisabledGroup` in Unity? | Description Create a group of controls that can be disabled. If disabled is true, the controls inside the group will be disabled.
If false, the enabled/disabled state will not be changed. Note: The use of DisabledScope is usually preferred over EditorGUI.BeginDisabledGroup()/EditorGUI.EndDisabledGroup(), as it provides... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_man_fc16754f6c2f | unity_docs | scripting | In Unity's 'The GameObject class', what is 'Active status' and how does it work? | GameObjects are active by default, but can be deactivated, which turns off all components attached to the GameObject. This generally means it will become invisible, and not receive any of the normal callbacks or events such as Update or
FixedUpdate
.
The GameObject’s active status is represented by the checkbox to the ... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
gh_eb0bd599c28d | github | scripting | Write a Unity C# MonoBehaviour script called Unity Singleton | ```csharp
using System.Collections;
using System.Collections.Generic;
using UnityEngine;
using UnityEngine.SceneManagement;
using UnityEngine.Assertions;
/// <summary>
/// This is an example of a Singleton.
/// It's creation was inspired by Richard Fine's talk:
/// "Unite 2016 - Overthrowing the MonoBehaviour Tyrann... | You are an experienced Unity developer specializing in C# scripting, XR/VR development, and performance optimization. |
local_sr_b4e61eb5b46e | unity_docs | performance | What is `Profiling.HierarchyFrameDataView.ItemContainsRawFrameDataViewIndex` in Unity? Explain its purpose and usage. | HierarchyFrameDataView.ItemContainsRawFrameDataViewIndex
Declaration
public bool
ItemContainsRawFrameDataViewIndex
(int
id
,
int
sampleIndex
);
Parameters
Parameter
Description
id
Hierarchy item identifier.
sampleIndex
The particular profiler sample index that should be checked if it is represented by thi... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_39d577b07ef0 | unity_docs | rendering | What is `TerrainTools.MaterialIndex` in Unity? Explain its purpose and usage. | MaterialIndex
enumeration
Description
The index at which you should place the material tools in the Terrain Tools overlay.
Properties
Property
Description
PaintTexture
The index at which you should place the Paint Texture material tool in the Terrain Tools overlay. | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_680814128db7 | unity_docs | scripting | What is `Experimental.GraphView.Port.OnCustomStyleResolved` in Unity? Explain its purpose and usage. | Experimental
: this API is experimental and might be changed or removed in the future.
Port.OnCustomStyleResolved
Declaration
protected void
OnCustomStyleResolved
(
UIElements.ICustomStyle
styles
);
Description
Called when the custom style properties are resolved. | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_man_1cc55254a14c | unity_docs | rendering | Explain 'Billboard asset reference' in Unity. | Explore the properties in the Billboard asset.
Property Description Width
The width of the billboard.
Height
The height of the billboard.
Bottom
The amount to offset the billboard at the bottom.
Images
The texture coordinates that represent the billboard images in the texture atlas.
Vertices
The vertex data of the bill... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_759e42f15971 | unity_docs | physics | Show me a Unity C# example demonstrating `Joint.massScale`. | s and inertia is fundamentally nonphysical and momentum won't be conserved.
The following script is useful to adjust the mass and inertia scaling in order to get the same corrective velocity out of the solver. Attach it to the ragdoll's root, or to a limb that is over-stretched during the gameplay and it will find all ... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
gh_6b945cbccb82_doc_0 | github | scripting | What does `this member` do in this Unity script? Explain its purpose and signature. | Behavior that provides events for when the system gesture starts and ends and when themenu palm pinch gesture occurs while hand tracking is in use.See Meta Hand Tracking Aim.
Signature:
```csharp
public class MetaSystemGestureDetector : MonoBehaviour
``` | You are a knowledgeable Unity developer. Explain Unity concepts clearly and provide practical, tested code examples. |
gh_5a202ebea1c7 | github | scripting | Write a Unity C# MonoBehaviour script called Inventory | ```csharp
using System.Collections;
using System.Collections.Generic;
using UnityEngine;
public interface IInventory { }
public class Inventory : MonoBehaviour, IInventory
{
// Start is called before the first frame update
void Start()
{
}
// Update is called once per frame
void Update()
... | You are a knowledgeable Unity developer. Explain Unity concepts clearly and provide practical, tested code examples. |
local_sr_ded146c9680b | unity_docs | scripting | What is `TerrainLayerUtility.TilingSettingsUI` in Unity? Explain its purpose and usage. | TerrainLayerUtility.TilingSettingsUI
Declaration
public static void
TilingSettingsUI
(
TerrainLayer
terrainLayer
);
Declaration
public static void
TilingSettingsUI
(
SerializedProperty
tileSize
,
SerializedProperty
tileOffset
);
Parameters
Parameter
Description
terrainLayer
The terrain layer that c... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_a39aaee3a628 | unity_docs | editor | What are the parameters of `Callbacks.RunBeforeClassAttribute.ctor` in Unity? | Description Add this attribute to a callback method to mark that this callback must be run before any callbacks that are part of the specified class. To define dependencies for a callback, use the following attributes: RunAfterClassAttribute , RunBeforeClassAttribute RunAfterAssemblyAttribute , RunBeforeAssemblyAttribu... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_man_e8455f431c76 | unity_docs | audio | In Unity's 'Introduction to the Audio Source component', what is 'Configure your audio source' and how does it work? | You can configure the audio source to play the clip as 2D, 3D, or as a mixture (
SpatialBlend
). The audio can be spread out between speakers (stereo to 7.1) (
Spread
) and morphed between 3D and 2D (
SpatialBlend
).
If you set SpatialBlend to
0.0f
, then Unity will treat the audio clip as a 2D sound. If you set it to
... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_bdd3a7df5d9c | unity_docs | rendering | What is `TextureImporterSettings.spriteMode` in Unity? Explain its purpose and usage. | TextureImporterSettings.spriteMode
public int
spriteMode
;
Description
Sprite texture import mode.
This value corresponds to the SpriteImportMode enum as follows:
None = 0, Single = 1, Manual = 2.
Additional resources:
SpriteImportMode
enum. | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_94d61cbc51d4 | unity_docs | xr | What is `XR.InputDevices.GetDeviceAtXRNode` in Unity? Explain its purpose and usage. | InputDevices.GetDeviceAtXRNode
Declaration
public static
XR.InputDevice
GetDeviceAtXRNode
(
XR.XRNode
node
);
Parameters
Parameter
Description
node
The XRNode that owns the requested device.
Returns
InputDevice
An
InputDevice
at this [[XR.XRNode].
Description
Gets the input device at a given
XR... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_e600150d86fe | unity_docs | rendering | What is `Rendering.CommandBuffer.SetGlobalTexture` in Unity? Explain its purpose and usage. | CommandBuffer.SetGlobalTexture
Declaration
public void
SetGlobalTexture
(string
name
,
Rendering.RenderTargetIdentifier
value
);
Declaration
public void
SetGlobalTexture
(int
nameID
,
Rendering.RenderTargetIdentifier
value
);
Declaration
public void
SetGlobalTexture
(string
name
,
Rendering.RenderT... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_e5e5e102776d | unity_docs | rendering | What is `Rendering.CommandBuffer.SetGlobalBuffer` in Unity? Explain its purpose and usage. | CommandBuffer.SetGlobalBuffer
Declaration
public void
SetGlobalBuffer
(string
name
,
ComputeBuffer
value
);
Declaration
public void
SetGlobalBuffer
(int
nameID
,
ComputeBuffer
value
);
Declaration
public void
SetGlobalBuffer
(string
name
,
GraphicsBuffer
value
);
Declaration
public void
SetGl... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_d2792c1bca06 | unity_docs | scripting | What is `Rendering.SphericalHarmonicsL2.operator_add` in Unity? Explain its purpose and usage. | SphericalHarmonicsL2.operator +
public static
Rendering.SphericalHarmonicsL2
operator +
(
Rendering.SphericalHarmonicsL2
lhs
,
Rendering.SphericalHarmonicsL2
rhs
);
Description
Adds two spherical harmonics. | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_8e5f8820a8ee | unity_docs | editor | What are the parameters of `GradientUsageAttribute.ctor` in Unity? | Description Attribute for gradient fields. Used to configure the GUI for the Gradient Editor. ```csharp
using UnityEngine;public class ExampleScript : MonoBehaviour
{
// Inspector editor for this gradient
// allows to setup regular low dynamic range
// colors.
public Gradient defaultGradient; // Insp... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
gh_8918b878b81d | github | scripting | Write a Unity C# XR/VR script for Plane Configuration Manager | ```csharp
using System.Collections;
using UnityEngine;
using UnityEngine.XR.ARFoundation;
using UnityEngine.XR.ARSubsystems;
using UnityEngine.XR.MagicLeap;
using UnityEngine.XR.Management;
using UnityEngine.XR.OpenXR.Features.MagicLeapSupport;
public class PlaneConfigurationManager : MonoBehaviour
{
[Se... | You are an expert Unity game developer. Provide clear, accurate, and practical answers about Unity development. |
local_sr_897759b7b0f3 | unity_docs | physics | Show me a Unity C# example demonstrating `OverlapSphereCommand`. | array size accordingly to store all hits. Use
QueryParameters
to control hit flags.
QueryParameters.hitBackfaces
and
QueryParameters.hitMultipleFaces
flags are not supported and won’t have any impact on overlap results.
Note: Only BatchQuery.ExecuteOverlapSphere is logged into the profiler. Query count informatio... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_3a91ef3d6429 | unity_docs | scripting | Show me a Unity C# example demonstrating `ObjectPreview`. | ObjectPreview
class in
UnityEditor
Description
Base Class to derive from when creating Custom Previews.
You specify which type is the preview for by using the CustomPreview attribute derived from
ObjectPreview
.
Below you can see an small example that will display the name of the object being inspected. The prev... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_404233ab2a02 | unity_docs | scripting | What is `UIElements.TabView.reorderable` in Unity? Explain its purpose and usage. | TabView.reorderable
public bool
reorderable
;
Description
A property that adds dragging support to tabs.
The default value is
false
.
Set this value to
true
to allow the user to reorder tabs in the tab view. | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_0774132af07a | unity_docs | scripting | What is `UIElements.ToolbarSpacer` in Unity? Explain its purpose and usage. | ToolbarSpacer
class in
UnityEditor.UIElements
/
Inherits from:
UIElements.VisualElement
Description
A toolbar spacer of static size. For more information, refer to
UXML element ToolbarSpacer
.
Static Properties
Property
Description
flexibleSpacerVariantUssClassName
USS class name of elements of this ty... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_f479dd7a8603 | unity_docs | scripting | What is `AndroidJavaObject` in Unity? Explain its purpose and usage. | AndroidJavaObject
class in
UnityEngine
/
Implemented in:
UnityEngine.AndroidJNIModule
Description
AndroidJavaObject is the Unity representation of a generic instance of java.lang.Object.
It can be used as type-less interface to an instance of any Java class.
Note
: this API can be used from custom thread, but ... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_d00f1c2497b4 | unity_docs | math | What is `Rendering.CommandBuffer.SetComputeTextureParam` in Unity? Explain its purpose and usage. | CommandBuffer.SetComputeTextureParam
Declaration
public void
SetComputeTextureParam
(
ComputeShader
computeShader
,
int
kernelIndex
,
string
name
,
Rendering.RenderTargetIdentifier
rt
);
Declaration
public void
SetComputeTextureParam
(
ComputeShader
computeShader
,
int
kernelIndex
,
int
nameID
,
Rend... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_289588d009fc | unity_docs | scripting | What is `UIElements.BackgroundPosition.ctor` in Unity? Explain its purpose and usage. | BackgroundPosition Constructor
Declaration
public
BackgroundPosition
(
UIElements.BackgroundPositionKeyword
keyword
);
Description
Initialize from single position type
Declaration
public
BackgroundPosition
(
UIElements.BackgroundPositionKeyword
keyword
,
UIElements.Length
offset
);
Description
I... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_man_4eadf4d2464c | unity_docs | scripting | In Unity's 'The Debug class', what is 'Logging errors, warnings and messages' and how does it work? | Unity sometimes logs errors, warnings, and messages to the Console window. The Debug class provides you with the ability to do exactly the same from your own code, as shown in the following example:
```
Debug.Log("This is a log message.");
Debug.LogWarning("This is a warning message!");
Debug.LogError("This is an error... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_man_1969bf11b6ed | unity_docs | ui | Explain 'Grid and Snap toolbar overlay' in Unity. | Use the
Grid and Snap
overlay to modify how the Scene grid looks, how GameObjects snap to the grid, and how GameObjects move incrementally.
The settings on the
Grid and Snap
overlay are global to all
Scene views
.
From the
Grid and Snap
overlay, you can select the dropdown arrows next to the
Toggle grid visibility and ... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_man_c6f69f47679d | unity_docs | scripting | In Unity's 'Rotation and orientation in Unity', what is 'Euler angles' and how does it work? | In the Transform coordinate, Unity displays rotation with the vector property
Transform.eulerAngles
X, Y, and Z. Unlike a normal vector, these values actually represent the angle (in degrees) of rotation about the X, Y, and Z axes.
Euler angle rotations perform three separate rotations around the three axes. Unity perf... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_0e929c8fd72c | unity_docs | physics | Give me an overview of the `WheelCollider` class in Unity. | WheelCollider
class in
UnityEngine
/
Inherits from:
Collider
/
Implemented in:
UnityEngine.VehiclesModule
Description
A special collider for vehicle wheels.
Wheel collider is used to model vehicle wheels. It simulates a spring and damper suspension setup,
and uses a slip based tire friction model to calculat... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_0cd948ec1d16 | unity_docs | rendering | What is `StereoRenderingPath.SinglePass` in Unity? Explain its purpose and usage. | StereoRenderingPath.SinglePass
Description
Single pass VR rendering ( via double-wide render texture ).
This is a faster rendering path for VR compared to the
StereoRenderingPath.MultiPass
.
The speed is achieved by traversing the Scene graph only once while issuing two draw calls for each render node.
The main re... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_bfc861278e85 | unity_docs | xr | What is `XR.XRSettings.occlusionMaskScale` in Unity? Explain its purpose and usage. | XRSettings.occlusionMaskScale
public static float
occlusionMaskScale
;
Description
A scale applied to the standard occulsion mask for each platform.
Occlusion masks are used to increase performance by not rendering to pixels that cannot be seen through the XR headset. Some post-processing effects require data f... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_d0f6898c2b5d | unity_docs | animation | What is `Animations.BoundProperty.CompareTo` in Unity? Explain its purpose and usage. | BoundProperty.CompareTo
Declaration
public int
CompareTo
(
Animations.BoundProperty
other
);
Parameters
Parameter
Description
other
The BoundProperty to compare.
Returns
int
Returns zero if the Index values for the two BoundProperty objects match. Otherwise, this method returns the difference between th... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_301431e55df5 | unity_docs | editor | Show me a Unity C# example demonstrating `EditorGUI.EnumPopup`. | bled
Method called for each Enum value displayed. The specified method should return true if the option can be selected, false otherwise.
Returns
Enum
The enum option that has been selected by the user.
Description
Makes an enum popup selection field.
Takes the currently selected enum value as a parameter and... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_cc294418759a | unity_docs | editor | What is `GameObjectUtility.SetStaticEditorFlags` in Unity? Explain its purpose and usage. | GameObjectUtility.SetStaticEditorFlags
Declaration
public static void
SetStaticEditorFlags
(
GameObject
go
,
StaticEditorFlags
flags
);
Parameters
Parameter
Description
go
The GameObject whose Static Editor Flags you want to set.
flags
The StaticEditorFlags to set on the GameObject.
Description
Sets ... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_da2c7a767f13 | unity_docs | math | What is `EditorPrefs.SetBool` in Unity? Explain its purpose and usage. | EditorPrefs.SetBool
Declaration
public static void
SetBool
(string
key
,
bool
value
);
Description
Sets the value of the preference identified by
key
.
Round rotations/positions and remember the active option.
```csharp
using UnityEngine;
using UnityEditor;public class EditorPrefsBoolExample : EditorWindow
... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_8f32198cf32f | unity_docs | editor | What is `Handles.DrawSolidDisc` in Unity? Explain its purpose and usage. | Handles.DrawSolidDisc
Declaration
public static void
DrawSolidDisc
(
Vector3
center
,
Vector3
normal
,
float
radius
);
Parameters
Parameter
Description
center
The center of the disc.
normal
The normal of the disc.
radius
The radius of the disc.
Note:
Use HandleUtility.GetHandleSize where you might ... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_5b82e80ace32 | unity_docs | scripting | What is `XR.XRInputSubsystem` in Unity? Explain its purpose and usage. | XRInputSubsystem
class in
UnityEngine.XR
/
Inherits from:
IntegratedSubsystem
/
Implemented in:
UnityEngine.XRModule
Description
XRInputSubsystem
Instance is used to enable and disable the inputs coming from a specific plugin.
Starting up an XRInputSubsystem
Instance will cause that plugin to start feeding in... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_b9f0eca238bc | unity_docs | scripting | What is `SystemInfo.deviceModel` in Unity? Explain its purpose and usage. | SystemInfo.deviceModel
public static string
deviceModel
;
Description
The model of the device (Read Only).
Exact format of model name is operating system dependent.
Windows:
"Model (Manufacturer)" (e.g.
Latitude 7480 (Dell Inc.)
)
macOS:
"HardwareModelIdentifier" (e.g.
MacBookPro18,1
or
iMac21,1
)
Linu... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_3f53605e4995 | unity_docs | scripting | What is `ObjectChangeEventStream.GetChangeGameObjectParentEvent` in Unity? Explain its purpose and usage. | ObjectChangeEventStream.GetChangeGameObjectParentEvent
Declaration
public void
GetChangeGameObjectParentEvent
(int
eventIdx
,
out
ChangeGameObjectParentEventArgs
data
);
Parameters
Parameter
Description
eventIdx
The index of the event to get the data for.
data
The data associated with the event.
Descri... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_3166526c8c18 | unity_docs | rendering | Give me an overview of the `AdditionalCanvasShaderChannels` class in Unity. | AdditionalCanvasShaderChannels
enumeration
Description
Enum mask of possible shader channel properties that can also be included when the
Canvas
mesh is created.
Properties
Property
Description
None
No additional shader parameters are needed.
TexCoord1
Include UV1 on the mesh vertices.
TexCoord2
Include UV2... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_man_dc75d7134643 | unity_docs | scripting | In Unity's 'Reserved folder name reference', what is 'Hidden assets' and how does it work? | During the import process, Unity ignores the following files and folders in the Assets folder and its subfolders:
Hidden folders.
Files and folders which start with
.
, except for those under StreamingAssets where this pattern is not ignored.
Files and folders which end with
~
.
Files and folders named
cvs
.
Files with... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_00288945caf3 | unity_docs | ui | What is `UIElements.ClickEvent` in Unity? Explain its purpose and usage. | ClickEvent
class in
UnityEngine.UIElements
/
Inherits from:
UIElements.PointerEventBase_1
/
Implemented in:
UnityEngine.UIElementsModule
Description
This event is sent when the left mouse button is clicked.
A click consists of a mouse down event followed by a mouse up event on the same VisualElement.
The... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_929abc59374f | unity_docs | physics | Give me an overview of the `ParticleSystemColliderQueryMode` class in Unity. | ParticleSystemColliderQueryMode
enumeration
Description
Whether collider information is available when using the [[ParticleSystem::GetTriggerParticles]] method.
Properties
Property
Description
Disabled
[[ParticleSystem::GetTriggerParticles]] does not return any information about which colliders each particle is... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_46b57ce01af5 | unity_docs | math | What is `SpriteMetaData.pivot` in Unity? Explain its purpose and usage. | SpriteMetaData.pivot
public
Vector2
pivot
;
Description
The pivot point of the Sprite, relative to its bounding rectangle.
The pivot point is usually specified in (x, y) values within a range of (0-1). For example: The upper left of the rectangle is (0,0); the bottom right of the rectangle is (1,1), and the c... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_2150f2996d8e | unity_docs | editor | Show me a Unity C# example demonstrating `AssetImporter.SetAssetBundleNameAndVariant`. | AssetImporter.SetAssetBundleNameAndVariant
Declaration
public void
SetAssetBundleNameAndVariant
(string
assetBundleName
,
string
assetBundleVariant
);
Parameters
Parameter
Description
assetBundleName
AssetBundle name.
assetBundleVariant
AssetBundle variant.
Description
Set the AssetBundle name and varia... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_7c242ee9208b | unity_docs | scripting | What is `SearchService.ObjectSelectorSearch.RegisterEngine` in Unity? Explain its purpose and usage. | ObjectSelectorSearch.RegisterEngine
Declaration
public static void
RegisterEngine
(
SearchService.IObjectSelectorEngine
engine
);
Parameters
Parameter
Description
engine
The ObjectSelector search engine to register.
Description
Registers an ObjectSelector search engine dynamically.
If you set a dynamical... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_afe189f13ebd | unity_docs | rendering | Show me a Unity C# example demonstrating `ImageConversion.EncodeNativeArrayToEXR`. | e controlled using the passed in flags.
The encoded EXR data will only contain an alpha channel when the passed-in format has one. For single-channel red textures (
R8
,
R16
,
RFloat
and
RHalf
), the encoded data will be in grayscale mode.
The native array that this function returns is allocated with the persis... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_1912db69b258 | unity_docs | performance | What is `Unity.Jobs.IJobForExtensions.ScheduleParallelByRef` in Unity? Explain its purpose and usage. | IJobForExtensions.ScheduleParallelByRef
Declaration
public static
Unity.Jobs.JobHandle
ScheduleParallelByRef
(ref T
jobData
,
int
arrayLength
,
int
innerloopBatchCount
,
Unity.Jobs.JobHandle
dependency
);
Parameters
Parameter
Description
jobData
The job and data to schedule.
arrayLength
The number o... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_06804ba3441c | unity_docs | scripting | What is `Search.SearchResult.GetHashCode` in Unity? Explain its purpose and usage. | SearchResult.GetHashCode
Declaration
public int
GetHashCode
();
Returns
int
HashCode of the SearchResult.
Description
Computes the hash code for this SearchResult from its index property. | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_man_07314fe817fe | unity_docs | scripting | In Unity's 'Edit prefab assets', what is 'Open in isolation' and how does it work? | To open a prefab asset and edit it in isolation, perform one of the following actions:
Double-click the prefab asset in the
Project window
.
Select a prefab asset in the Project window. Select Open in the top right of the Inspector window.
Unity then opens the prefab asset in isolation in prefab editing mode. | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_c25b2dd41a0f | unity_docs | physics | What is `Rendering.RenderPipelineGraphicsSettingsEditorUtility` in Unity? Explain its purpose and usage. | RenderPipelineGraphicsSettingsEditorUtility
class in
UnityEditor.Rendering
Description
Helper class that contains a utility function on
IRenderPipelineGraphicsSettings
for Editor.
Static Methods
Method
Description
ForEachFieldOfType
Iterate on each fields of the IRenderPipelineGraphicsSettings of type T and ... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_90d6ba1c5b16 | unity_docs | scripting | What is `ParticleSystem.NoiseModule.strengthMultiplier` in Unity? Explain its purpose and usage. | ParticleSystem.NoiseModule.strengthMultiplier
public float
strengthMultiplier
;
Description
Strength multiplier.
Changing this property is more efficient than accessing the entire curve, if you only want to change the overall strength multiplier.
Additional resources:
ParticleSystem.NoiseModule.strength
.
``... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_11be00d69331 | unity_docs | scripting | What is `Experimental.Rendering.GraphicsFormat.R16G16_SNorm` in Unity? Explain its purpose and usage. | Experimental
: this API is experimental and might be changed or removed in the future.
GraphicsFormat.R16G16_SNorm
Description
A two-component, 32-bit signed normalized format that has a 16-bit R component in bytes 0..1, and a 16-bit G component in bytes 2..3. | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_17e57e5579ab | unity_docs | rendering | Show me a Unity C# example demonstrating `LineRenderer.numCapVertices`. | LineRenderer.numCapVertices
public int
numCapVertices
;
Description
Set this to a value greater than 0, to get rounded corners on each end of the line. The default is 0.
The value controls how many vertices are added to each end, where a higher value will give a smoother result.
```csharp
using UnityEngine;
u... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_430f0305c5df | unity_docs | scripting | Give me an overview of the `LightmapParameters` class in Unity. | LightmapParameters
class in
UnityEditor
/
Inherits from:
Object
Description
Configures how Unity bakes lighting and can be assigned to a
LightingSettings
instance or asset.
Note that Unity's built-in Lightmap Parameters Assets are read-only.
Additional resources:
LightmapParameters.SetLightmapParametersFor... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_41e0eece4594 | unity_docs | rendering | What is `SystemInfo.hasDynamicUniformArrayIndexingInFragmentShaders` in Unity? Explain its purpose and usage. | SystemInfo.hasDynamicUniformArrayIndexingInFragmentShaders
public static bool
hasDynamicUniformArrayIndexingInFragmentShaders
;
Description
Returns true when the GPU has native support for indexing uniform arrays in fragment shaders without restrictions.
This is true for all currently supported GPUs. | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_61f8c7ac331a | unity_docs | ui | What is `EditorWindow.ShowUtility` in Unity? Explain its purpose and usage. | EditorWindow.ShowUtility
Declaration
public void
ShowUtility
();
Description
Show the EditorWindow as a floating utility window.
When the utility window loses focus it remains on top of the new active window. This means
the
EditorWindow.ShowUtility
window is never hidden by the Unity editor. It is, however, n... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_d7513a617a4e | unity_docs | physics | What is `Search.ISearchView.Refresh` in Unity? Explain its purpose and usage. | ISearchView.Refresh
Declaration
public void
Refresh
(
Search.RefreshFlags
reason
);
Parameters
Parameter
Description
reason
The refresh flags give some additional context and reasons why the view needs to be updated.
Description
Triggers a refresh of the search view and refetches all the search items from... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_f29fb867a0a1 | unity_docs | scripting | What is `Experimental.GraphView.Dragger.RegisterCallbacksOnTarget` in Unity? Explain its purpose and usage. | Experimental
: this API is experimental and might be changed or removed in the future.
Dragger.RegisterCallbacksOnTarget
Declaration
protected void
RegisterCallbacksOnTarget
();
Description
Called to register click event callbacks on the target element. | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_1c0dd050d920 | unity_docs | scripting | What is `Unity.Collections.LowLevel.Unsafe.UnsafeUtility.ReleaseGCObject` in Unity? Explain its purpose and usage. | UnsafeUtility.ReleaseGCObject
Declaration
public static void
ReleaseGCObject
(ulong
gcHandle
);
Parameters
Parameter
Description
gcHandle
The handle associated with the pinned object.
Description
Releases a GC handle obtained from
UnsafeUtility.PinGCObjectAndGetAddress
or
UnsafeUtility.PinGCArrayAndGetD... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_7aefd87b62a7 | unity_docs | scripting | Show me a Unity C# example demonstrating `Application.lowMemory`. | UWP
:
MemoryManager.AppMemoryUsageIncreased (AppMemoryUsageLevel == OverLimit)
Note:
For UWP, this event does not occur on desktop and only works on memory constrained devices, such as HoloLens. The
OverLimit
threshold specified by the OS in this case is so high that it's not reasonably possible to reach it and tr... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_dd6137f3dd0c | unity_docs | editor | What is `EditorAnalyticsSessionInfo.sessionCount` in Unity? Explain its purpose and usage. | EditorAnalyticsSessionInfo.sessionCount
public static long
sessionCount
;
Description
The number of Editor sessions that have occurred since the current instance of the Unity Editor was installed. | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_e5e02f08d53a | unity_docs | rendering | What is `UIElements.ITextElementExperimentalFeatures.SetRenderedText` in Unity? Explain its purpose and usage. | Experimental
: this API is experimental and might be changed or removed in the future.
ITextElementExperimentalFeatures.SetRenderedText
Declaration
public void
SetRenderedText
(string
renderedText
);
Description
Setting this property will override the displayed text while preserving the original text value.
... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_a06739e8ce43 | unity_docs | physics | What is `HingeJoint.useMotor` in Unity? Explain its purpose and usage. | HingeJoint.useMotor
public bool
useMotor
;
Description
Enables the joint's
motor
. Disabled by default.
Additional resources:
JointMotor
Enabling the motor
overrides
the
spring
, given the spring was enabled. If the motor is again disabled the spring will be restored. | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
gh_7d06c08effcd | github | scripting | Write a Unity Editor script for Field Search Settings Editor | ```csharp
using FieldSearch.EditorScriptGeneration.Editor;
using UnityEditor;
using UnityEngine;
namespace FieldSearch.Settings.Editor
{
/// <summary>
/// Custom editor for <see cref="FieldSearchSettings"/>
/// </summary>
[CustomEditor(typeof(FieldSearchSettings), true)]
public class FieldSearchSe... | You are an expert Unity game developer. Provide clear, accurate, and practical answers about Unity development. |
local_sr_2dfd1a4c1912 | unity_docs | rendering | What is `Camera.ResetTransparencySortSettings` in Unity? Explain its purpose and usage. | Camera.ResetTransparencySortSettings
Declaration
public void
ResetTransparencySortSettings
();
Description
Resets this Camera's transparency sort settings to the default. Default transparency settings are taken from
GraphicsSettings
instead of directly from this Camera.
The rendering pipeline will, by defaul... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_cb6339579600 | unity_docs | physics | Give me an overview of the `JointDrive` class in Unity. | JointDrive
struct in
UnityEngine
/
Implemented in:
UnityEngine.PhysicsModule
Description
How the joint's movement will behave along its local X axis.
Properties
Property
Description
maximumForce
Amount of force applied to push the object toward the defined direction.
positionDamper
Resistance strength again... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_435e04b0d086 | unity_docs | editor | What is `iOS.Xcode.PBXProject.AddRemotePackageReferenceAtBranch` in Unity? Explain its purpose and usage. | PBXProject.AddRemotePackageReferenceAtBranch
Declaration
public string
AddRemotePackageReferenceAtBranch
(string
url
,
string
branch
);
Parameters
Parameter
Description
url
The URL of the repository.
branch
The name of the branch in the repository.
Returns
string
Returns the GUID of the remote package... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_98851b36261b | unity_docs | scripting | What is `ModelImporterHumanoidOversampling` in Unity? Explain its purpose and usage. | ModelImporterHumanoidOversampling
enumeration
Description
Humanoid Oversampling available multipliers.
Properties
Property
Description
X1
Default Humanoid Oversampling multiplier = 1 which is equivalent to no oversampling.
X2
Humanoid Oversampling samples at 2 times the sampling rate found in the imported file... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_79cdad565fea | unity_docs | physics | Show me a Unity C# example demonstrating `PhysicsScene.Raycast`. | rMask
, to filter out any Colliders you aren't interested in generating collisions with.
Specifying
queryTriggerInteraction
allows you to control whether or not Trigger colliders generate a hit, or whether to use the global
Physics.queriesHitTriggers
setting.
This example creates a simple Raycast, projecting forwar... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_5a9086bd19e4 | unity_docs | rendering | What is `GL.GetGPUProjectionMatrix` in Unity? Explain its purpose and usage. | GL.GetGPUProjectionMatrix
Declaration
public static
Matrix4x4
GetGPUProjectionMatrix
(
Matrix4x4
proj
,
bool
renderIntoTexture
);
Parameters
Parameter
Description
proj
Source projection matrix.
renderIntoTexture
Will this projection be used for rendering into a RenderTexture?
Returns
Matrix4x4
Adju... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_eebc4a0bd1cf | unity_docs | scripting | Show me a Unity C# example demonstrating `Vector3.Dot`. | Vector3
rhs
);
Description
Dot Product of two vectors.
The dot product is a float value equal to the magnitudes of the two vectors multiplied together
and then multiplied by the cosine of the angle between them.
For
normalized
vectors Dot returns 1 if they point in exactly the same direction,
-1 if they point ... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_18c0ab6b321f | unity_docs | scripting | Show me a Unity C# example demonstrating `GUI.matrix`. | GUI.matrix
public static
Matrix4x4
matrix
;
Description
The GUI transform matrix.
```csharp
using UnityEngine;
using System.Collections;public class ExampleClass : MonoBehaviour
{
void Example()
{
print(GUI.matrix);
}
}
``` | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_dfccec20ee0c | unity_docs | rendering | What is `ShaderUtil.UpdateShaderAsset` in Unity? Explain its purpose and usage. | ShaderUtil.UpdateShaderAsset
Declaration
public static void
UpdateShaderAsset
(
AssetImporters.AssetImportContext
context
,
Shader
shader
,
string
source
,
bool
compileInitialShaderVariants
);
Declaration
public static void
UpdateShaderAsset
(
Shader
shader
,
string
source
,
bool
compileInitialShaderV... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_c26023175edc | unity_docs | math | What is `UIElements.PointerEventBase_1.deltaPosition` in Unity? Explain its purpose and usage. | PointerEventBase<T0>.deltaPosition
public
Vector3
deltaPosition
;
Description
Gets the difference between the pointer's position during the previous mouse event and its position during the
current mouse event. | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_b91cc71aec4d | unity_docs | scripting | What is `UIElements.BaseVerticalCollectionView.ScrollToItemById` in Unity? Explain its purpose and usage. | BaseVerticalCollectionView.ScrollToItemById
Declaration
public void
ScrollToItemById
(int
id
);
Parameters
Parameter
Description
id
Item id to scroll to.
Description
Scrolls to a specific item id and makes it visible. | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_b62368526966 | unity_docs | scripting | What is `Unity.Android.Gradle.Manifest.GrantUriPermission` in Unity? Explain its purpose and usage. | GrantUriPermission
class in
Unity.Android.Gradle.Manifest
/
Inherits from:
Unity.Android.Gradle.Manifest.BaseElement
Description
The C# definition of the
<grant-uri-permission>
Android Manifest element.
For more information about the element, see Android's documentation:
GrantUriPermission element
Propert... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.