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_03db23a84c55 | unity_docs | scripting | What is `Serialization.FormerlySerializedAsAttribute.ctor` in Unity? Explain its purpose and usage. | FormerlySerializedAsAttribute Constructor
Declaration
public
FormerlySerializedAsAttribute
(string
oldName
);
Parameters
Parameter
Description
oldName
The name of the field before renaming. | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_c6a0c08789d1 | unity_docs | performance | What is `Unity.Jobs.IJobForExtensions.Run` in Unity? Explain its purpose and usage. | IJobForExtensions.Run
Declaration
public static void
Run
(T
jobData
,
int
arrayLength
);
Parameters
Parameter
Description
jobData
The job and data to execute.
arrayLength
The number of iterations to execute the for loop over.
Description
Performs the job's Execute method immediately on the main thread.
... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_99324485db3c | unity_docs | audio | What is `Video.VideoPlayer.GetAudioSampleRate` in Unity? Explain its purpose and usage. | VideoPlayer.GetAudioSampleRate
Declaration
public uint
GetAudioSampleRate
(ushort
trackIndex
);
Parameters
Parameter
Description
trackIndex
Index of the audio track to query.
Returns
uint
The sampling rate in Hertz.
Description
Gets the audio track sampling rate in Hertz.
For URL sources, this will ... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_7ffb2858297f | unity_docs | scripting | What is `MeshTopology` in Unity? Explain its purpose and usage. | MeshTopology
enumeration
Description
Topology of
Mesh
faces.
Normally meshes are composed of triangles (three vertex indices per face), but
in some cases you might want to render complex things that are made up from lines
or points. Creating a
Mesh
with that topology and using it to render is usually the
most ... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_94f8f0cbcafd | unity_docs | editor | What is `iOS.Xcode.PBXProject.AddShellScriptBuildPhaseBeforeTargetPostprocess` in Unity? Explain its purpose and usage. | PBXProject.AddShellScriptBuildPhaseBeforeTargetPostprocess
Declaration
public string
AddShellScriptBuildPhaseBeforeTargetPostprocess
(string
targetGuid
,
string
name
,
string
shellPath
,
string
shellScript
);
Parameters
Parameter
Description
targetGuid
The GUID of the target, such as the one returned by
... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_99c3e9a93ea4 | unity_docs | input | Give me an overview of the `IntegratedSubsystem` class in Unity. | IntegratedSubsystem
class in
UnityEngine
/
Implemented in:
UnityEngine.SubsystemsModule
Implements interfaces:
ISubsystem
Description
An IntegratedSubsystem is initialized from an
IntegratedSubsystemDescriptor
for a given Subsystem (Example, Input, Environment, Display, etc.) and provides an interface to inte... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_f4782438b090 | unity_docs | scripting | What is `ParticleSystem.CustomDataModule.SetColor` in Unity? Explain its purpose and usage. | ParticleSystem.CustomDataModule.SetColor
Declaration
public void
SetColor
(
ParticleSystemCustomData
stream
,
ParticleSystem.MinMaxGradient
gradient
);
Parameters
Parameter
Description
stream
The name of the custom data stream to apply the gradient to.
gradient
The gradient to be used for generating c... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_443cf97e14e0 | unity_docs | scripting | What is `UIElements.BaseListViewController.RemoveItem` in Unity? Explain its purpose and usage. | BaseListViewController.RemoveItem
Declaration
public void
RemoveItem
(int
index
);
Parameters
Parameter
Description
index
The item index.
Description
Removes an item from the source, by index. | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_8ef3255eead6 | unity_docs | physics | What is `Rigidbody2D.AddForceAtPosition` in Unity? Explain its purpose and usage. | Rigidbody2D.AddForceAtPosition
Declaration
public void
AddForceAtPosition
(
Vector2
force
,
Vector2
position
,
ForceMode2D
mode
= ForceMode2D.Force);
Parameters
Parameter
Description
force
Components of the force in the X and Y axes.
position
Position in world space to apply the force.
mode
The m... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_46d67847d5a7 | unity_docs | rendering | What is `Renderer.sharedMaterials` in Unity? Explain its purpose and usage. | Renderer.sharedMaterials
public Material[]
sharedMaterials
;
Description
All the shared materials of this object.
This is an array of all materials used by the renderer. Unity supports multiple objects
using a single material; in this case
sharedMaterials
contains all the materials used for this.
sharedMater... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_116269664847 | unity_docs | editor | What is `AssetDatabase.InstanceIDsToGUIDs` in Unity? Explain its purpose and usage. | AssetDatabase.InstanceIDsToGUIDs
Declaration
public static void
InstanceIDsToGUIDs
(NativeArray<int>
instanceIDs
,
NativeArray<GUID>
guidsOut
);
Description
Sets a NativeArray of UnityEditor.GUIDs for every valid Instance ID that is an asset.
Both arrays must be the same length and initialised before calling.... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_7ab65dc5b7de | unity_docs | rendering | What is `Canvas.targetDisplay` in Unity? Explain its purpose and usage. | Canvas.targetDisplay
public int
targetDisplay
;
Description
For Overlay mode, display index on which the UI canvas will appear.
This setting makes a Canvas render into the specified display.
Maximum number of secondary displays (eg. monitors) supported is 8.
Additional resources:
Display
class,
Camera.target... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_4ece606f3dee | unity_docs | physics | What is `MeshCollider.convex` in Unity? Explain its purpose and usage. | MeshCollider.convex
public bool
convex
;
Description
Use a convex collider from the mesh.
This means that if you have this set to true, your mesh collider wont have holes or entrances.
Convex meshes can collide with other convex colliders and non-convex meshes.
Thus convex mesh colliders are suitable on rigidb... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_5217f2ef366e | unity_docs | editor | What is `U2D.SpriteEditorExtension.GetSpriteID` in Unity? Explain its purpose and usage. | SpriteEditorExtension.GetSpriteID
Declaration
public static GUID
GetSpriteID
(
Sprite
sprite
);
Parameters
Parameter
Description
sprite
The Sprite to query.
Returns
GUID
GUID stored in the Sprite.
Description
Gets the Sprite's GUID.
During Sprite Asset generation, you can identify which SpriteRect ... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_0def13e78b85 | unity_docs | scripting | What is `Experimental.Rendering.GraphicsStateCollection.SaveToFile` in Unity? Explain its purpose and usage. | Experimental
: this API is experimental and might be changed or removed in the future.
GraphicsStateCollection.SaveToFile
Declaration
public bool
SaveToFile
(string
filePath
);
Parameters
Parameter
Description
filePath
Output location of GraphicsStateCollection serialized data.
Returns
bool
Returns true... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_ee7964c86438 | unity_docs | audio | Show me a Unity C# example demonstrating `AudioSource.resource`. | t the
AudioResource
that plays next.
Note
: Audio resources don’t provide direct access to properties like
length
. However, if your audio resource is an
AudioClip
, you can access these properties through
AudioSource.clip
. Other types of resources might not provide direct access to these properties because the r... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_5930d87be6da | unity_docs | scripting | What is `Build.Content.ObjectIdentifier.TryGetObjectIdentifier` in Unity? Explain its purpose and usage. | ObjectIdentifier.TryGetObjectIdentifier
Declaration
public static bool
TryGetObjectIdentifier
(
Object
targetObject
,
out
Build.Content.ObjectIdentifier
objectId
);
Declaration
public static bool
TryGetObjectIdentifier
(int
instanceID
,
out
Build.Content.ObjectIdentifier
objectId
);
Description
Trie... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_0ab88fd37e81 | unity_docs | rendering | What is `LightingSettings.lightProbeSampleCountMultiplier` in Unity? Explain its purpose and usage. | LightingSettings.lightProbeSampleCountMultiplier
public float
lightProbeSampleCountMultiplier
;
Description
Specifies the number of samples to use for Light Probes relative to the number of samples for lightmap texels. (Editor only).
The default value is 4.
This value is a multiplier of
directSampleCount
,
i... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_0065efb56223 | unity_docs | animation | What is `Animations.RotationConstraint.locked` in Unity? Explain its purpose and usage. | RotationConstraint.locked
public bool
locked
;
Description
Locks the offset and rotation at rest.
In Edit mode, unlock the constraint to update its offsets. In Play mode, the constraint is always locked. | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
gh_44aa844fe5b4 | github | scripting | Write a Unity Editor script for Game Object Extensions Tests | ```csharp
using System.IO;
using Duck.HierarchyBehaviour.Tests.Behaviours;
using NUnit.Framework;
using UnityEditor;
using UnityEngine;
namespace Duck.HierarchyBehaviour.Tests
{
[TestFixture]
internal partial class GameObjectExtensionsTests
{
private const string TEST_ARGS = "test-args";
private const string P... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_505dbb60e22b | unity_docs | editor | Show me a Unity C# example demonstrating `SerializedProperty.managedReferenceId`. | lizedProperty.managedReferenceId
public long
managedReferenceId
;
Description
Id associated with a managed reference.
Available when
propertyType
is
SerializedPropertyType.ManagedReference
. If the reference is null then the Id is SerializeUtility.RefIdNull.
Additional resources:
SerializeReference
,
man... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_785ce2a84bf9 | unity_docs | physics | What is `Physics2D` in Unity? Explain its purpose and usage. | Physics2D
class in
UnityEngine
/
Implemented in:
UnityEngine.Physics2DModule
Description
Global settings and helpers for 2D physics.
Static Properties
Property
Description
AllLayers
Layer mask constant that includes all layers.
angularSleepTolerance
A Rigidbody cannot sleep if its angular velocity is above ... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_1c4cfc5a6c00 | unity_docs | rendering | What is `Rendering.RasterState.offsetUnits` in Unity? Explain its purpose and usage. | RasterState.offsetUnits
public int
offsetUnits
;
Description
Scales the minimum resolvable depth buffer value in the GPU's depth bias setting.
Corresponds to the
Offset
command in ShaderLab. For more information, see
ShaderLab command: Offset
. | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_4228490cec66 | unity_docs | editor | What is `Device.SystemInfo.batteryStatus` in Unity? Explain its purpose and usage. | SystemInfo.batteryStatus
public static
BatteryStatus
batteryStatus
;
Description
This has the same functionality as
SystemInfo.batteryStatus
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_01907a4697fa | unity_docs | rendering | What is `Camera.allCameras` in Unity? Explain its purpose and usage. | Camera.allCameras
public static Camera[]
allCameras
;
Description
Returns all enabled cameras in the Scene.
All cameras in the scene can be enabled or disabled. The
allCameras
value tells how many cameras are still enabled. If all the
cameras are disabled then a value of zero will be returned.
```csharp
u... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_7168e20d2855 | unity_docs | scripting | What is `Handles.ScaleHandle` in Unity? Explain its purpose and usage. | Handles.ScaleHandle
Declaration
public static
Vector3
ScaleHandle
(
Vector3
scale
,
Vector3
position
,
Quaternion
rotation
,
float
size
);
Parameters
Parameter
Description
scale
Scale to modify.
position
The position of the handle.
rotation
The rotation of the handle.
size
Allows you to scale... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_2514385f2328 | unity_docs | editor | Show me a Unity C# example demonstrating `EditorGUILayout.TextArea`. | GUILayout.ExpandWidth
,
GUILayout.ExpandHeight
.
Returns
string
The text entered by the user.
Description
Make a text area.
This works just like @@
GUILayout.TextArea
@@ with proper responsiveness to actions like
Select all
,
Copy
,
Paste
in the Editor.
For Undo support, see
Undo.RecordObject
.
To make... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_man_b9dfe0665ff2 | unity_docs | scripting | Show me a Unity code example for 'ColorField'. | : To align an element with other fields in an Inspector window, simply apply the.unity-base-field__aligned
USS class to it. For more information, refer to
BaseField
.
## Create a ColorField
You can create a ColorField with UI Builder, UXML, or C#. The following C# example creates a ColorField with a default color and... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_8e7948ca308d | unity_docs | scripting | What is `AndroidJNI.GetStaticStringField` in Unity? Explain its purpose and usage. | AndroidJNI.GetStaticStringField
Declaration
public static string
GetStaticStringField
(IntPtr
clazz
,
IntPtr
fieldID
);
Description
Returns the value of a static field of an object.
This is a convenience function that calls GetStaticObjectField() with the same parameters, but creates a managed string from the... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_262abb9cdd31 | unity_docs | rendering | What is `CanvasRenderer.EnableRectClipping` in Unity? Explain its purpose and usage. | CanvasRenderer.EnableRectClipping
Declaration
public void
EnableRectClipping
(
Rect
rect
);
Description
Enables rect clipping on the CanvasRendered. Geometry outside of the specified rect will be clipped (not rendered).
Additional resources:
CanvasRenderer.DisableRectClipping
. | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_5d110db8e739 | unity_docs | scripting | What is `UIElements.IFocusRing` in Unity? Explain its purpose and usage. | IFocusRing
interface in
UnityEngine.UIElements
Description
Interface for classes implementing focus rings.
Public Methods
Method
Description
GetFocusChangeDirection
Get the direction of the focus change for the given event. For example, when the Tab key is pressed, focus should be given to the element to ... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_148fab988142 | unity_docs | physics | What is `CompositeCollider2D.GetCompositedColliders` in Unity? Explain its purpose and usage. | CompositeCollider2D.GetCompositedColliders
Declaration
public int
GetCompositedColliders
(List<Collider2D>
colliders
);
Parameters
Parameter
Description
colliders
A list of Collider2D that are being composited.
Returns
int
The number of colliders returned.
Description
When any
Collider2D
is using a... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_7658c28fbbdd | unity_docs | math | What is `Vector4.Lerp` in Unity? Explain its purpose and usage. | Vector4.Lerp
Declaration
public static
Vector4
Lerp
(
Vector4
a
,
Vector4
b
,
float
t
);
Description
Linearly interpolates between two vectors.
Interpolates between
a
and
b
by amount
t
.
The parameter
t
is clamped between [0...1].
When
t
= 0 returns
a
.
When
t
= 1 returns
b
.
When
t
=... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_5f41d0a4729b | unity_docs | scripting | What is `AddComponentMenu.ctor` in Unity? Explain its purpose and usage. | AddComponentMenu Constructor
Declaration
public
AddComponentMenu
(string
menuName
);
Declaration
public
AddComponentMenu
(string
menuName
,
int
order
);
Parameters
Parameter
Description
menuName
The path to the component.
order
Where in the component menu to add the new item.
Description
Add an ite... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
gh_103347a59c12_doc_0 | github | scripting | What does `this member` do in this Unity script? Explain its purpose and signature. | Use this class to present locomotion control schemes and configuration preferences,and respond to player input in the UI to set them.
Signature:
```csharp
public class LocomotionConfigurationMenu : MonoBehaviour
``` | You are a senior Unity engineer. Answer questions about Unity scripting, XR/VR development, and game systems with working code examples. |
local_sr_e27ea66c6e86 | unity_docs | physics | What is `Gyroscope.userAcceleration` in Unity? Explain its purpose and usage. | Gyroscope.userAcceleration
public
Vector3
userAcceleration
;
Description
Returns the acceleration that the user is giving to the device.
The significance of this value is that the effect of gravity (which is also detected by the accelerometer)
has been removed to leave just the acceleration from the user's m... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_3c387e7507ec | unity_docs | scripting | What is `AvatarMask.GetHumanoidBodyPartActive` in Unity? Explain its purpose and usage. | AvatarMask.GetHumanoidBodyPartActive
Declaration
public bool
GetHumanoidBodyPartActive
(
AvatarMaskBodyPart
index
);
Parameters
Parameter
Description
index
The index of the humanoid body part.
Description
Returns true if the humanoid body part at the given index is active. | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_man_a3888b9f7388 | unity_docs | rendering | Explain 'Light Probes' in Unity. | Light Probes
provide a way to capture and use information about light that is passing through the empty space in your
scene
.
Similar to lightmaps , light probes store “baked” information about lighting in your scene. The difference is that while lightmaps store lighting information about light hitting the surfaces in ... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_dd203bdfa501 | unity_docs | editor | Show me a Unity C# example demonstrating `MouseCursor.Link`. | MouseCursor.Link
Description
Arrow with a Link badge (for assigning pointers).
```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 win... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_e344c96411da | unity_docs | scripting | What is `UIElements.MultiColumnTreeView.columnSortingChanged` in Unity? Explain its purpose and usage. | MultiColumnTreeView.columnSortingChanged
Description
If a column is clicked to change sorting, this event is raised to allow users to sort the tree view items.
For a default implementation, set sortingMode to
ColumnSortingMode.Default
. | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_fc99f059b6b6 | unity_docs | scripting | What are the parameters of `Caching.GetAllCachePaths` in Unity? | Description Returns all paths of the cache in the cache list. ```csharp
using System.IO;
using System.Collections.Generic;
using UnityEngine;public class Example : MonoBehaviour
{
void GetAllCachePathExample()
{
Directory.CreateDirectory("Cache1");
Directory.CreateDirectory("Cache2");
Di... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_199e1e7c552b | unity_docs | scripting | What is `UIElements.UxmlSerializedData.Register` in Unity? Explain its purpose and usage. | UxmlSerializedData.Register
Declaration
public static void
Register
();
Description
This is used by the code generator when a custom control is using the
UxmlElementAttribute
. You should not need to call it. | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_4a3da54538b3 | unity_docs | performance | What is `Profiling.CustomSampler.End` in Unity? Explain its purpose and usage. | CustomSampler.End
Declaration
public void
End
();
Description
End profiling a piece of code with a custom label.
This will show up in the Profiler hierarchy.
```csharp
using UnityEngine;
using UnityEngine.Profiling;public class ExampleClass : MonoBehaviour
{
CustomSampler sampler;
void Start()
{
sampler = ... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_e694d3d392b6 | unity_docs | physics | What is `HumanPoseHandler` in Unity? Explain its purpose and usage. | HumanPoseHandler
class in
UnityEngine
/
Implemented in:
UnityEngine.AnimationModule
Description
Use this class to create, read, and write the
HumanPose
for a humanoid avatar skeleton hierarchy or an avatar pose.
Constructors
Constructor
Description
HumanPoseHandler
Creates a human pose handler from an avat... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_017abaa6d8af | unity_docs | scripting | What is `Rendering.RenderPipelineGlobalSettings.TryGetFirstSettingsImplementingInterface` in Unity? Explain its purpose and usage. | RenderPipelineGlobalSettings.TryGetFirstSettingsImplementingInterface
Declaration
protected bool
TryGetFirstSettingsImplementingInterface
(out TSettingsInterfaceType
settings
);
Parameters
Parameter
Description
settings
Get the first settings for the currently active pipeline that implements
TSettingsInterf... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_7bb74262e9b6 | unity_docs | rendering | What is `GL.TexCoord` in Unity? Explain its purpose and usage. | GL.TexCoord
Declaration
public static void
TexCoord
(
Vector3
v
);
Description
Sets current texture coordinate (v.x,v.y,v.z) for all texture units.
In OpenGL this matches
glMultiTexCoord
for all texture units or
glTexCoord
when no multi-texturing is available. On other graphics APIs the same
functionality... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_b5f7cda2ff46 | unity_docs | scripting | What is `AvatarBuilder.BuildHumanAvatar` in Unity? Explain its purpose and usage. | AvatarBuilder.BuildHumanAvatar
Declaration
public static
Avatar
BuildHumanAvatar
(
GameObject
go
,
HumanDescription
humanDescription
);
Parameters
Parameter
Description
go
Root object of your transform hierachy. It must be the top most gameobject when you create the avatar.
humanDescription
Humanoid ... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
gh_e8f9e20f4f08 | github | scripting | Write a Unity C# script called Curve Picker | ```csharp
using System;
using UnityEngine;
namespace CurvePickerTool
{
[Serializable]
public class CurvePicker
{
[SerializeField] private float[] samplePoints = new float[0];
[SerializeField] private float[] sampleTimes = new float[0];
[SerializeField] private float[] sampleValues =... | You are an expert Unity game developer. Provide clear, accurate, and practical answers about Unity development. |
local_sr_c411496054a2 | unity_docs | input | Show me a Unity C# example demonstrating `Rect.Contains`. | Rect's width and height to be negative?
Returns
bool
True if the point lies within the specified rectangle.
Description
Returns true if the
x
and
y
components of
point
is a point inside this rectangle. If
allowInverse
is present and true, the width and height of the Rect are allowed to take negative val... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_60c64447afe6 | unity_docs | scripting | Show me a Unity C# example demonstrating `Animations.GameObjectRecorder.BindComponent`. | GameObjectRecorder.BindComponent
Declaration
public void
BindComponent
(
Component
component
);
Parameters
Parameter
Description
component
The component to bind.
Description
Adds bindings for all the properties of
component
.
```csharp
using UnityEngine;
using UnityEditor;
using UnityEditor.Animations;p... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_532f1a24d475 | unity_docs | ui | Show me a Unity C# example demonstrating `EditorWindow.position`. | EditorWindow.position
public
Rect
position
;
Description
The desired position of the window in screen space.
Setting this value will undock the window if it is docked.
Create an undocked editor window with position.
```csharp
// The position of the window is displayed when it is
// external from Unity.
usi... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_c6e63d2cfeec | unity_docs | scripting | Show me a Unity C# example demonstrating `Vector4.Max`. | Vector4.Max
Declaration
public static
Vector4
Max
(
Vector4
lhs
,
Vector4
rhs
);
Description
Returns a vector that is made from the largest components of two vectors.
Additional resources:
Min
function.
```csharp
using UnityEngine;public class Example : MonoBehaviour
{
void Start()
{
Vector4 a = ne... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_man_73300bb7275d | unity_docs | ui | In Unity's 'Introduction to scripting back ends', what is 'Scripting backends comparison' and how does it work? | The C#/.NET API surface available for Mono and IL2CPP is nearly identical. Both scripting back ends use the same base class library and both support the available
API compatibility levels
. However, some restrictions specific to IL2CPP and certain AOT platforms apply. For more information, refer to
IL2CPP restrictions
... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_58edc3cdf168 | unity_docs | scripting | What is `AssetImporters.ScriptedImporterEditor` in Unity? Explain its purpose and usage. | ScriptedImporterEditor
class in
UnityEditor.AssetImporters
/
Inherits from:
AssetImporters.AssetImporterEditor
Description
Default editor for source assets handled by Scripted Importers.
See
ScriptedImporter
and
AssetImporterEditor
.
Inherited Members
Properties Property Description
extraDataSerializedObj... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_210aed386c71 | unity_docs | rendering | What is `Cubemap.GetPixel` in Unity? Explain its purpose and usage. | Cubemap.GetPixel
Declaration
public
Color
GetPixel
(
CubemapFace
face
,
int
x
,
int
y
,
int
mip
= 0);
Parameters
Parameter
Description
x
The x coordinate of the pixel to get. The range is
0
through (texture width - 1).
y
The y coordinate of the pixel to get. The range is
0
through (texture heigh... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_9aef2a8a13b9 | unity_docs | editor | What is `EditorGUIUtility.currentViewWidth` in Unity? Explain its purpose and usage. | EditorGUIUtility.currentViewWidth
public static float
currentViewWidth
;
Description
The width of the GUI area for the current EditorWindow or other view. This Property should only be accessed within an OnGUI call. | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_man_8705632ba9b0 | unity_docs | scripting | Explain 'Default Scene view overlay reference' in Unity. | From the Overlays menu, you can
control which overlays are in the Scene view and manage your overlay configurations
. To display the Overlays menu in the Scene view, press the ` key. To restore the default overlay configuration, select the Default overlay configuration from the Overlays menu.
By default, the following ... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_9d2e4240771f | unity_docs | scripting | What is `Build.Content.ContentBuildInterface.GetPlayerDependenciesForObject` in Unity? Explain its purpose and usage. | ContentBuildInterface.GetPlayerDependenciesForObject
Declaration
public static ObjectIdentifier[]
GetPlayerDependenciesForObject
(
Build.Content.ObjectIdentifier
objectID
,
BuildTarget
target
,
Build.Player.TypeDB
typeDB
);
Description
Returns a list of objects referenced by an object.
Internal use only... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_man_8da411303af9 | unity_docs | rendering | Explain 'Reflective Diffuse' in Unity. | Note.
Unity 5 introduced the
Standard Shader
which replaces this
shader
.
## Reflective Properties
Note.
Unity 5 introduced the
Standard Shader
which replaces this shader.
This shader will simulate reflective surfaces such as cars, metal objects etc. It requires an environment Cubemap which will define what exactly i... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_c3f62dad8883 | unity_docs | rendering | What is `GL.Viewport` in Unity? Explain its purpose and usage. | GL.Viewport
Declaration
public static void
Viewport
(
Rect
pixelRect
);
Description
Set the rendering viewport.
All rendering is constrained to be inside the passed
pixelRect
.
If the Viewport is modified, all the rendered content inside of it gets stretched.
```csharp
using UnityEngine;public class Example... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_9c6f5f85e618 | unity_docs | math | What is `UIElements.Vector2IntField.ctor` in Unity? Explain its purpose and usage. | Vector2IntField Constructor
Declaration
public
Vector2IntField
();
Description
Initializes and returns an instance of Vector2IntField.
Declaration
public
Vector2IntField
(string
label
);
Parameters
Parameter
Description
label
The text to use as a label.
Description
Initializes and returns an inst... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_55eddaaed742 | unity_docs | scripting | What is `SpeedTreeImporter.billboardTransitionCrossFadeWidth` in Unity? Explain its purpose and usage. | SpeedTreeImporter.billboardTransitionCrossFadeWidth
public float
billboardTransitionCrossFadeWidth
;
Description
Proportion of the last 3D mesh LOD region width which is used for cross-fading to billboard tree. | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_0418d715cb3c | unity_docs | rendering | What is `Material.HasFloat` in Unity? Explain its purpose and usage. | Material.HasFloat
Declaration
public bool
HasFloat
(string
name
);
Declaration
public bool
HasFloat
(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
Returns true if the ShaderL... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
gh_3619a2f53add | github | scripting | Write a Unity C# XR/VR script for Tint Texture Generator | ```csharp
using UnityEngine;
using UnityEngine.Tilemaps;
/// <summary>
/// A helper class for tinting a Grid component
/// </summary>
[ExecuteInEditMode]
public class TintTextureGenerator : MonoBehaviour
{
/// <summary>
/// Size of the Tint map in cells
/// </summary>
public int k_TintMapSize = 256;
... | You are an experienced Unity developer specializing in C# scripting, XR/VR development, and performance optimization. |
local_sr_1b0b0e678a95 | unity_docs | scripting | What is `Experimental.Rendering.ScriptableBakedReflectionSystem.BakeAllReflectionProbes` in Unity? Explain its purpose and usage. | Experimental
: this API is experimental and might be changed or removed in the future.
ScriptableBakedReflectionSystem.BakeAllReflectionProbes
Declaration
public bool
BakeAllReflectionProbes
();
Returns
bool
True when the probe were baked, false when baking was not completed.
Description
Implement this me... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_72376ab368cc | unity_docs | scripting | What is `UIElements.StylePropertyNameCollection.GetEnumerator` in Unity? Explain its purpose and usage. | StylePropertyNameCollection.GetEnumerator
Declaration
public
UIElements.StylePropertyNameCollection.Enumerator
GetEnumerator
();
Returns
Enumerator
An enumerator that can be used to iterate through the
StylePropertyNameCollection
.
Description
Returns an enumerator that iterates through the
StylePrope... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_bc0f493d9166 | unity_docs | input | What is `UIElements.PointerLeaveEvent` in Unity? Explain its purpose and usage. | PointerLeaveEvent
class in
UnityEngine.UIElements
/
Inherits from:
UIElements.PointerEventBase_1
/
Implemented in:
UnityEngine.UIElementsModule
Description
This event is sent when a pointer exits an element and all of its descendants.
The event does not trickle down and does not bubble up.
Constructors
C... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_man_1ab1ce40a181 | unity_docs | ui | Show me a Unity code example for 'GUI Skin (IMGUI System)'. | e will be applied to all Text Field Controls.
No matter how many Text Fields you create in your script, they will all use this
Style
. Of course, you have control over changing the styles of one Text Field over the other if you wish. We’ll discuss how that is done next.
## Applying GUISkins
To apply a GUISkin to your... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_ab3fa462b93f | unity_docs | animation | What is `Animations.Axis` in Unity? Explain its purpose and usage. | Axis
enumeration
Description
Represents the axes used in 3D space.
Properties
Property
Description
None
Represents the case when no axis is specified.
X
Represents the X axis.
Y
Represents the Y axis.
Z
Represents the Z axis. | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_man_0ea64c27a569 | unity_docs | rendering | In Unity's 'Lighting', what is 'Additional resources and examples' and how does it work? | 👥
Community
:
Join the conversation on Unity Discussions for Graphics
📖
E-Book
:
Introduction to the Universal Render Pipeline for advanced creators (Unity 6 edition)
📺
Video
:
The URP 3D Sample - a short introduction
📺
Video
:
Understanding URP settings and essentials
📚
Documentation
:
Visual effects | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_efa2a6503efc | unity_docs | scripting | Show me a Unity C# example demonstrating `DragAndDrop.visualMode`. | DragAndDrop.visualMode
public static
DragAndDropVisualMode
visualMode
;
Description
The visual indication of the drag.
Default is
DragAndDropVisualMode.Link
.
```csharp
using UnityEngine;
using UnityEditor;public class Example : MonoBehaviour
{
void OnGUI()
{
EventType eventType = Event.current.type;
if... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_3393a890cba2 | unity_docs | physics | What is `PhysicsMaterial.staticFriction` in Unity? Explain its purpose and usage. | PhysicsMaterial.staticFriction
public float
staticFriction
;
Description
The friction coefficient used when an object is lying on a surface.
Must be greater than or equal to zero. Natural materials will usually have a friction coefficient between 0 (no friction at all, like slippery ice) and 1 (full friction, ... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_12235de04fc8 | unity_docs | audio | What is `Experimental.Audio.AudioSampleProvider.enableSampleFramesAvailableEvents` in Unity? Explain its purpose and usage. | Experimental
: this API is experimental and might be changed or removed in the future.
AudioSampleProvider.enableSampleFramesAvailableEvents
public bool
enableSampleFramesAvailableEvents
;
Description
Enables the
AudioSampleProvider.sampleFramesAvailable
events.
Depending on how often audio sample frames are... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_dcfaed3effe0 | unity_docs | rendering | What is `Rendering.SupportedRenderingFeatures.overridesEnableLODCrossFade` in Unity? Explain its purpose and usage. | SupportedRenderingFeatures.overridesEnableLODCrossFade
public bool
overridesEnableLODCrossFade
;
Description
Specifies whether the renderer overrides the Enable LOD Cross Fade settings in the Quality Settings Panel. If It does, the renderer does not need the built-in UI for Enable LOD Cross Fade settings. | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_ce23c07c8ff9 | unity_docs | physics | What is `PhysicsShapeGroup2D.Clear` in Unity? Explain its purpose and usage. | PhysicsShapeGroup2D.Clear
Declaration
public void
Clear
();
Description
Clears all the vertices and shapes from the PhysicsShapeGroup.
This call clears the lists used to store both vertices and shapes but retains the current shape group capacity (effectively creating an empty shape group).
```csharp
using Unit... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_762362e587c6 | unity_docs | scripting | What is `InSceneAssetUtility.CreateInSceneAssetFromAsset` in Unity? Explain its purpose and usage. | InSceneAssetUtility.CreateInSceneAssetFromAsset
Declaration
public static Object
CreateInSceneAssetFromAsset
(
Object
asset
,
GameObject
gameObjectReferencingAsset
);
Parameters
Parameter
Description
asset
The persistent asset to convert to an in-scene asset.
gameObjectReferencingAsset
The GameObject t... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_9023acdc50ec | unity_docs | editor | Show me a Unity C# example demonstrating `Search.SearchSelection.MinIndex`. | SearchSelection.MinIndex
Declaration
public int
MinIndex
();
Returns
int
Returns the lowest selected index.
Description
Lowest selected index of any item in the selection.
```csharp
using UnityEngine;
using UnityEditor;
using UnityEditor.Search;
static class Example_ISearchView_AddSelection
{
static ISe... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_man_f87c0610e758 | unity_docs | rendering | In Unity's 'Implementation details of shadow cascades', what is 'Perspective aliasing' and how does it work? | A directional light typically simulates sunlight, and a single directional light can illuminate the entire
Scene
. This means that its shadow map covers a large portion of the Scene, which can lead to a problem called perspective aliasing. Perspective aliasing means that shadow map pixels close to the Camera look enlar... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_952f9ea7e26e | unity_docs | rendering | What is `Light.shadows` in Unity? Explain its purpose and usage. | Light.shadows
public
LightShadows
shadows
;
Description
Determines if this light will cast soft or hard shadows, or not cast shadows at all.
Changing this setting can significantly affect visual quality and performance. Typically, turning shadows off boosts performance dramatically at the expense of realism ... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_1356069cca44 | unity_docs | scripting | What is `UIElements.Button` in Unity? Explain its purpose and usage. | Button
class in
UnityEngine.UIElements
/
Inherits from:
UIElements.TextElement
/
Implemented in:
UnityEngine.UIElementsModule
Description
This is a clickable button.
A Button has a text label element that can respond to pointer and mouse events.
You can add an icon to pair it with the text by assigning a... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
gh_fb052fdaeec5_doc_3 | github | scripting | What does `this member` do in this Unity script? Explain its purpose and signature. | Convert single column data by header name.
Signature:
```csharp
public static List<T> ConvertColumn<T>(string csvContent, string headerName, char cellSeparator = CSVDataHelper.CommaCharacter, bool supportCellMultiline = true)
``` | You are a senior Unity engineer. Answer questions about Unity scripting, XR/VR development, and game systems with working code examples. |
local_man_590baea1fe30 | unity_docs | rendering | In Unity's '3D texture preview reference', what is 'Slice' and how does it work? | In Slice preview mode, Unity displays a 2D slice of each of the three axes of the 3D texture. Use the X ,
Y and Z
sliders to select the slices to preview.
Control Description Ramp
Enable and disable color ramp so that Unity displays grayscale as color. If the image contains a lot of subtle details, enable Ramp to make ... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_b3af3aedc873 | unity_docs | rendering | What is `SceneManagement.Stage.GetCombinedSceneCullingMaskForCamera` in Unity? Explain its purpose and usage. | Stage.GetCombinedSceneCullingMaskForCamera
Declaration
public ulong
GetCombinedSceneCullingMaskForCamera
();
Returns
ulong
The combined Scene culling mask for this Stage. Unity uses this mask on the Scene view Camera for renderer filtering.
Description
Gets the Scene culling mask from this Stage.
Dependin... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_0b886fe9ba29 | unity_docs | rendering | What is `SceneView.size` in Unity? Explain its purpose and usage. | SceneView.size
public float
size
;
Description
The size of the Scene view measured diagonally.
Use with
pivot
,
rotation
, and
CameraSettings.fieldOfView
to calculate camera transformation.
The image above shows the math used to calculate the actual field of view. Here BC = size, and you need to find ... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_07d7e3fc7c83 | unity_docs | scripting | What is `HandleUtility.ResolvePickingCallback` in Unity? Explain its purpose and usage. | HandleUtility.ResolvePickingCallback
Declaration
public delegate Object
ResolvePickingCallback
(int
localPickingIndex
);
Parameters
Parameter
Description
localPickingIndex
The 0-based index that specifies what picking index was selected.
Description
The delegate type to return from
RenderPickingCallback
... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_579a27748471 | unity_docs | scripting | What is `DragAndDrop.HasHandler` in Unity? Explain its purpose and usage. | DragAndDrop.HasHandler
Declaration
public static bool
HasHandler
(int
dropDstId
,
Delegate
handler
);
Parameters
Parameter
Description
dropDstId
ID of the destination window.
handler
The handler of the targeted window.
Returns
bool
True if the handler is already registered.
Description
Check if th... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_a9c18f823055 | unity_docs | editor | What are the parameters of `Android.AndroidProjectFiles.GetData` in Unity? | Description Gets data that was set in the Setup method. This method is used to get data from the Unity Editor by setting it in the Setup method. If data with the the given key does not exist, Unity throws an error. Declaration public T GetData (string key ); Parameters Parameter Description key Data key. value Serializ... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_cd9a6a94c48d | unity_docs | ui | Show me a Unity C# example demonstrating `Windows.LicenseInformation.PurchaseApp`. | formation.PurchaseApp
Declaration
public static string
PurchaseApp
();
Returns
string
Purchase receipt.
Description
Attempts to purchase the app if it is in installed in trial mode.
Calling this pops up a dialog for the user asking whether they want to buy the application. If the user buys the application... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_man_4b6392ce60f9 | unity_docs | animation | In Unity's 'Introduction to the Asset Store', what is 'Asset Store package types' and how does it work? | Asset Store packages are collections of files and data from Unity projects, or elements of projects. An Asset Store package type is either a
UPM package
or an
asset package
(.unitypackage
format). When you add an Asset Store package to your project, the Unity Package Manager unpacks the package and maintains its direct... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
gh_cc9553dbce43 | github | scripting | Write a Unity C# script called Ray Ring | ```csharp
using FfalconXR.InputModule;
using FfalconXR.Native;
using RayNeo.API;
using UnityEngine;
using UnityEngine.InputSystem.XR;
namespace RayNeo
{
public class RayRing : RayInteractionBase
{
public override void SetRayInput(RayNeoInput input)
{
base.SetRayInput(input);
... | You are a senior Unity engineer. Answer questions about Unity scripting, XR/VR development, and game systems with working code examples. |
local_sr_b2ef0f20c3d1 | unity_docs | rendering | What is `Texture2DArray.allSlices` in Unity? Explain its purpose and usage. | Texture2DArray.allSlices
public static int
allSlices
;
Description
Read Only. This property is used as a parameter in some overloads of the CommandBuffer.Blit, Graphics.Blit, CommandBuffer.SetRenderTarget, and Graphics.SetRenderTarget methods to indicate that all texture array slices are bound. The value of thi... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_a6c18af9c2f5 | unity_docs | rendering | What is `LightProbes.GetInterpolatedProbe` in Unity? Explain its purpose and usage. | LightProbes.GetInterpolatedProbe
Declaration
public static void
GetInterpolatedProbe
(
Vector3
position
,
Renderer
renderer
,
out
Rendering.SphericalHarmonicsL2
probe
);
Description
Returns an interpolated probe for the given position for both real-time and baked light probes combined.
Renderer is only ... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_d409ff64188d | unity_docs | rendering | Show me a Unity C# example demonstrating `AMD.GraphicsDevice`. | agement.
GraphicsDevice
is needed to implement FSR2 outside of the built-in integration to the
HDRP Dynamic Resolution
.
Before using
GraphicsDevice
, ensure the
AMDUnityPlugin
is loaded and the device is initialized via
GraphicsDevice.CreateGraphicsDevice
.
Additional resources:
AMDUnityPlugin
,
FSR2Context
, ... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
gh_35f8fb3212ea_doc_14 | github | scripting | What does `CallbackStopRunning` do in this Unity script? Explain its purpose and signature. | Animation completion callback: unlocks animation state and fires the appropriate event.This ensures OnPress/OnUnpress events fire AFTER animations complete.True to invoke OnPress event, false to invoke OnUnpress event.
Signature:
```csharp
private void CallbackStopRunning(bool state)
``` | You are an experienced Unity developer specializing in C# scripting, XR/VR development, and performance optimization. |
local_sr_7dd43d65fc3f | unity_docs | scripting | Show me a Unity C# example demonstrating `Animation.Stop`. | Animation.Stop
Declaration
public void
Stop
();
Description
Stops all playing animations that were started with this Animation.
Stopping an animation also Rewinds it to the Start.
```csharp
using UnityEngine;public class ExampleScript : MonoBehaviour
{
Animation anim; void Start()
{
anim = GetComponent<Ani... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_f711181bc926 | unity_docs | rendering | Give me an overview of the `BillboardAsset` class in Unity. | BillboardAsset
class in
UnityEngine
/
Inherits from:
Object
/
Implemented in:
UnityEngine.CoreModule
Description
BillboardAsset describes how a billboard is rendered.
Billboards are a level-of-detail (LOD) method of drawing complicated 3D objects in a simpler manner if they are further away. Because the obje... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_90458f26e64f | unity_docs | rendering | What is `ParticleSystem.MainModule.startRotationY` in Unity? Explain its purpose and usage. | ParticleSystem.MainModule.startRotationY
public
ParticleSystem.MinMaxCurve
startRotationY
;
Description
The initial rotation of particles around the y-axis when the Particle System first spawns them.
Note that you should specify the value in radians.
Additional resources:
MinMaxCurve
.
```csharp
using Unit... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_man_be9c73ceaa21 | unity_docs | rendering | In Unity's 'Upgrade to Unity 2023.1', what is 'Render pipelines' and how does it work? | This upgrade guide describes how to upgrade to version 2023.1 of Unity’s built-in render pipeline.
To upgrade other render pipelines to version 2023.1, see:
The URP upgrade guide
The HDRP upgrade guide
To upgrade other packages, refer to the documentation for the packages you are using. | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_f8c3225d4074 | unity_docs | input | What is `Input.anyKey` in Unity? Explain its purpose and usage. | Input.anyKey
public static bool
anyKey
;
Description
Is any key or mouse button currently held down? (Read Only)
Note
: This API is part of the legacy Input Manager. The recommended best practice is that you don't use this API in new projects. For new projects, use the Input System package. To learn more about ... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_2e6095b5972f | unity_docs | performance | What is `Unity.Profiling.ProfilerRecorderOptions.GpuRecorder` in Unity? Explain its purpose and usage. | ProfilerRecorderOptions.GpuRecorder
Description
Use to indicate that ProfilerRecorder should collect GPU timing instead of CPU.
If you use
ProfilerRecorderOptions.GpuRecorder
to create the recorder, make sure you set the MarkerFlags.SampleGpu flag for the
ProfilerMarker
it is used with. | 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.