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_man_3f7fb5c782b3 | unity_docs | rendering | In Unity's 'Mesh index data', what is 'Winding order' and how does it work? | The order of the vertices in each group in the index array is called the
winding order
. Unity uses winding order to determine whether a face is front-facing or back-facing, and in turn whether it should render a face or cull it (exclude it from rendering). By default, Unity renders front-facing polygons and culls back... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_65f262724b2e | unity_docs | editor | Show me a Unity C# example demonstrating `Profiling.Recorder`. | Recorder
class in
UnityEngine.Profiling
/
Implemented in:
UnityEngine.CoreModule
Description
Records profiling data produced by a specific Sampler.
Recorder accumulates elapsed time of every Begin/End pair during a frame.
Once enabled it sums delta time between Begin and End samples produced by a Sampler.
Use
... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_d8b95f38bfb7 | unity_docs | scripting | What is `MPE.ChannelService.Start` in Unity? Explain its purpose and usage. | ChannelService.Start
Declaration
public static void
Start
();
Description
Starts the ChannelService. After you start the ChannelService it listens to connection at the URL provided by: <ChannelService Address>:<ChannelServicePort>/<channelName>, for example, 127.0.0.1:9976/events. See
ChannelService.GetAddress
... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_8e6453f46b3c | unity_docs | editor | What is `Profiling.FrameDataView.GetMarkers` in Unity? Explain its purpose and usage. | FrameDataView.GetMarkers
Declaration
public void
GetMarkers
(List<MarkerInfo>
markerInfoList
);
Parameters
Parameter
Description
markerInfoList
List filled with marker descriptors.
Description
Gets all available markers for the current profiling session.
Use to retrieve all marker identifiers together wit... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_5653ff1c36d6 | unity_docs | math | What is `Experimental.GraphView.RectUtils.IntersectsSegment` in Unity? Explain its purpose and usage. | Experimental
: this API is experimental and might be changed or removed in the future.
RectUtils.IntersectsSegment
Declaration
public static bool
IntersectsSegment
(
Rect
rect
,
Vector2
p1
,
Vector2
p2
);
Parameters
Parameter
Description
rect
Rectangle to check.
p1
Line segment point 1.
p2
Line s... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_man_cdea92241895 | unity_docs | rendering | Explain 'Assembly definition and packages' in Unity. | You must associate scripts inside a package to an assembly definition file (.asmdef
). Assembly definition files are the Unity equivalent to a C# project in the .NET ecosystem. You must set explicit references in the assembly definition file to other assemblies (whether in the same package or in external packages). Ref... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
gh_36b8b9ff13ba_doc_9 | github | scripting | What does `EstimateTotalBytes` do in this Unity script? Explain its purpose and signature. | Estimate total RAM needed to load all files. Returns bytes.
Signature:
```csharp
public static long EstimateTotalBytes(IReadOnlyList<string> files)
``` | You are a knowledgeable Unity developer. Explain Unity concepts clearly and provide practical, tested code examples. |
local_sr_10837252d33e | unity_docs | editor | What is `BuildAssetBundleOptions.DisableWriteTypeTree` in Unity? Explain its purpose and usage. | BuildAssetBundleOptions.DisableWriteTypeTree
Description
Do not include type information within the AssetBundle.
Specifying this flag will make an AssetBundle susceptible to script or Unity version changes, but will make the file smaller and a bit faster to load.
This flag affects only AssetBundles for platforms th... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_9b8649cada28 | unity_docs | rendering | What is `ParticleSystem.ShapeModule.randomPositionAmount` in Unity? Explain its purpose and usage. | ParticleSystem.ShapeModule.randomPositionAmount
public float
randomPositionAmount
;
Description
Randomizes the starting position of particles.
A higher value applies more randomization to the particle positions.
Additional resources:
ParticleSystem.ShapeModule.shapeType
. | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
gh_1508d8be65e1 | github | scripting | Write a Unity C# XR/VR script for Climb Teleport Destination Indicator | ```csharp
using UnityEngine.XR.Interaction.Toolkit.Locomotion.Climbing;
using UnityEngine.XR.Interaction.Toolkit.Locomotion.Teleportation;
using UnityEngine.XR.Interaction.Toolkit.Utilities;
namespace UnityEngine.XR.Interaction.Toolkit.Samples.StarterAssets
{
/// <summary>
/// Affordance component used in conj... | You are an experienced Unity developer specializing in C# scripting, XR/VR development, and performance optimization. |
local_sr_34008862ea6e | unity_docs | editor | What is `EditorGUILayout.ObjectField` in Unity? Explain its purpose and usage. | EditorGUILayout.ObjectField
Declaration
public static Object
ObjectField
(
Object
obj
,
Type
objType
,
bool
allowSceneObjects
,
params GUILayoutOption[]
options
);
Declaration
public static Object
ObjectField
(string
label
,
Object
obj
,
Type
objType
,
bool
allowSceneObjects
,
params GUILayoutOption[]... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_2f9e4205d9c7 | unity_docs | animation | What is `Animations.PropertySceneHandle.GetInt` in Unity? Explain its purpose and usage. | PropertySceneHandle.GetInt
Declaration
public int
GetInt
(
Animations.AnimationStream
stream
);
Parameters
Parameter
Description
stream
The
AnimationStream
managing this handle.
Returns
int
The integer property value.
Description
Gets the integer property value from an object in the Scene.
If the... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_58a8d2538329 | unity_docs | editor | What are the parameters of `Search.SearchIndexer.ctor` in Unity? | Description Creates a new default SearchIndexer. ```csharp
using UnityEditor;
using UnityEditor.Search;
using UnityEngine;
static class Example_SearchIndexer
{
[MenuItem("Examples/SearchIndexer/Class")]
public static void Run()
{
// Create a search indexer
using var searchIndexer = new Sear... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_92f876304620 | unity_docs | ui | What is `TerrainTools.TerrainPaintToolWithOverlaysBase.HasBrushAttributes` in Unity? Explain its purpose and usage. | TerrainPaintToolWithOverlaysBase.HasBrushAttributes
public bool
HasBrushAttributes
;
Description
True if the Terrain Tool has brush attributes, false otherwise.
Returns a boolean indicating whether the Terrain Tool should display an overlay containing sliders for brush attributes such as brush size and strength... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_edebb1525684 | unity_docs | rendering | Show me a Unity C# example demonstrating `Search.SearchProvider.name`. | SearchProvider.name
public string
name
;
Description
Unique ID of the search provider.
```csharp
using System;
using System.Collections.Generic;
using System.Globalization;
using System.Linq;
using UnityEditor;
using UnityEditor.Search;
using UnityEngine;
static class SearchProvider_name
{
internal static str... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_c32c779f1908 | unity_docs | rendering | What is `LightTransport.ReferenceContext.DestroyBuffer` in Unity? Explain its purpose and usage. | ReferenceContext.DestroyBuffer
Declaration
public void
DestroyBuffer
(
LightTransport.BufferID
id
);
Parameters
Parameter
Description
id
ID of the buffer to destroy.
Description
Destroy the buffer with the given ID. | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_man_178b4bd9bfdc | unity_docs | physics | In Unity's 'Optimize performance of moving elements at runtime', what is 'Best practices for moving elements' and how does it work? | The most performance-efficient way to move elements is to use the
style.translate
property. This property adjusts an element’s position dynamically without recalculating the layout. Unlike other positioning methods,
style.translate
operates at the transform stage. It minimizes the computational overhead and improves re... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
gh_8c21f425961f | github | scripting | Write a Unity C# script called Editable Timed Flag Attribute | ```csharp
// Copyright (c) Mixed Reality Toolkit Contributors
// Licensed under the BSD 3-Clause
using UnityEngine;
namespace MixedReality.Toolkit
{
/// <summary>
/// Attribute to enable an inspector checkbox for
/// toggling the state at edit-time. Mostly used for Toggle state.
/// </summary>
pub... | You are an experienced Unity developer specializing in C# scripting, XR/VR development, and performance optimization. |
local_sr_6d85368ae83b | unity_docs | performance | What is `Unity.Profiling.LowLevel.ProfilerMarkerDataType` in Unity? Explain its purpose and usage. | ProfilerMarkerDataType
enumeration
Description
Options for the Profiler metadata type.
Used as a value of
ProfilerMarkerData.Type
field.
Properties
Property
Description
InstanceId
Indicates that ProfilerMarkerData.Ptr points to a value of type int that represents an instance ID of Unity Object.
Int32
Indica... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_bbdcd53069cf | unity_docs | editor | Show me a Unity C# example demonstrating `EditorGUIUtility.GetFlowLayoutedRects`. | tyle
Style for the items.
horizontalSpacing
Extra horizontal spacing between successive items.
verticalSpacing
Extra vertical spacing between item rows.
items
Strings to layout.
Returns
List<Rect>
List of rectangles for the passed items.
Description
Layout list of string items left to right, top to botto... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_06fe4e7e5f64 | unity_docs | scripting | What is `UIElements.TransitionEndEvent` in Unity? Explain its purpose and usage. | TransitionEndEvent
class in
UnityEngine.UIElements
/
Inherits from:
UIElements.TransitionEventBase_1
/
Implemented in:
UnityEngine.UIElementsModule
Description
Event sent at the completion of the transition. In the case where a transition is removed before completion then the event will not fire.
Inherited... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_ff620e205165 | unity_docs | audio | Give me an overview of the `AudioSampleRateSetting` class in Unity. | AudioSampleRateSetting
enumeration
Description
The sample rate setting used within the AudioImporter. This defines the sample rate conversion of audio on import.
Properties
Property
Description
PreserveSampleRate
Do not change the sample rate of the imported audio file. The sample rate will be preserved for the... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_6de5ca29a9b5 | unity_docs | scripting | Show me a Unity C# example demonstrating `ParticleSystem.ColorOverLifetimeModule.color`. | ParticleSystem.ColorOverLifetimeModule.color
public
ParticleSystem.MinMaxGradient
color
;
Description
The gradient that controls the particle colors.
Additional resources:
MinMaxGradient
.
```csharp
using UnityEngine;
using System.Collections;[RequireComponent(typeof(ParticleSystem))]
public class ExampleC... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_cae8a685cf73 | unity_docs | scripting | Give me an overview of the `MonoScript` class in Unity. | MonoScript
class in
UnityEditor
/
Inherits from:
TextAsset
Description
Representation of Script assets.
This class represents C# files stored in the project.
Public Methods
Method
Description
GetClass
Returns the System.Type object of the class implemented by this script.
Static Methods
Method
Descriptio... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_647375e18f25 | unity_docs | physics | Show me a Unity C# example demonstrating `UIElements.BaseVerticalCollectionView.itemsSourceChanged`. | ged
event.
For selection changes, listen to the
BaseVerticalCollectionView.selectionChanged
event.
Additional resources:
BaseListViewController.itemsAdded
,
BaseListViewController.itemsRemoved
The following example illustrates that the
itemsSourceChanged
event is only triggered when the
itemsSource
pro... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_f2fda0f10d6b | unity_docs | ui | What is `UIElements.BindingExtensions.Bind` in Unity? Explain its purpose and usage. | BindingExtensions.Bind
Declaration
public static void
Bind
(
UIElements.VisualElement
element
,
SerializedObject
obj
);
Parameters
Parameter
Description
element
Root VisualElement containing IBindable fields.
obj
Data object.
Description
Binds a SerializedObject to fields in the element hierarchy.
... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_18f296267e0a | unity_docs | scripting | What is `Experimental.GraphView.Scope.SetScopePositionOnly` in Unity? Explain its purpose and usage. | Experimental
: this API is experimental and might be changed or removed in the future.
Scope.SetScopePositionOnly
Declaration
protected void
SetScopePositionOnly
(
Rect
newPos
);
Description
Change the position of the scope but does not move its elements. | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_man_5a3ab06adea0 | unity_docs | scripting | In Unity's 'API updater', what is 'Logging' and how does it work? | The API updater logs changes it makes to any assemblies to the
Editor log
. To control how much information is logged, set the UNITY_APIUPDATER_LOG_THRESHOLD environment variable to the desired log threshold and start Unity. For example:
On Windows:
```
c:> set UNITY_APIUPDATER_LOG_THRESHOLD=Debug
c:> \path\to\unity\Un... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_man_4154715b7756 | unity_docs | xr | In Unity's 'Choose and configure XR provider plug-ins', what is 'Configure provider plug-in settings' and how does it work? | For each enabled plug-in provider, you can configure provider-specific settings as follows:
In the
XR Plug-in Management menu
, select the name of the provider plug-in.
If present, select the tab for the platform build target. For example, to configure settings for Android devices, click the tab with the Android icon
.... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_64ca559233a6 | unity_docs | scripting | What is `Search.QueryNodeType` in Unity? Explain its purpose and usage. | QueryNodeType
enumeration
Description
Options for representing the query node types.
Properties
Property
Description
And
And node.
Or
Or node.
Filter
Filter node.
Search
Word search node.
Not
Negation node.
NestedQuery
Nested query node.
Where
Where enumerator node.
FilterIn
Filter with nested query node... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
gh_7f3f71336c8e | github | scripting | Write a Unity C# MonoBehaviour script called Singleton | ```csharp
using System;
using UnityEngine;
namespace E
{
/// <summary>
/// Makes <see cref="MonoBehaviour"/> singleton.
/// <para>See also:
/// <seealso cref="SingletonAttribute"/></para>
/// </summary>
/// <typeparam name="T">MonoBehaviour</typeparam>
public abstract class Singleton<T> : M... | You are an expert Unity game developer. Provide clear, accurate, and practical answers about Unity development. |
local_sr_83ef5718b520 | unity_docs | xr | What is `Texture.totalTextureMemory` in Unity? Explain its purpose and usage. | Texture.totalTextureMemory
public static ulong
totalTextureMemory
;
Description
The total amount of Texture memory that Unity would use if it loads all Textures at mipmap level 0.
This is a theoretical value that does not take into account any input from the streaming system or any other input, for example when ... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_aff18798edfd | unity_docs | editor | What are the parameters of `EditorGUILayout.RenderingLayerMaskField` in Unity? | Returns RenderingLayerMask The Rendering Layer selected by the User. Description Makes a layer selection field. Declaration public static uint RenderingLayerMaskField (string label ,
uint layers ,
params GUILayoutOption[] options ); Declaration public static uint RenderingLayerMaskField (string label ,
uint layers , GU... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_adf1358e27b2 | unity_docs | editor | What is `VersionControl.VersionControlManager.activeVersionControlObject` in Unity? Explain its purpose and usage. | VersionControlManager.activeVersionControlObject
public static
VersionControl.VersionControlObject
activeVersionControlObject
;
Description
The
VersionControlObject
representing active VCS.
If there is no currently active
VersionControlObject
, this property returns
null
.
```csharp
using UnityEditor;
us... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_67ec4ace54fa | unity_docs | scripting | What is `UIElements.TransformOrigin` in Unity? Explain its purpose and usage. | TransformOrigin
struct in
UnityEngine.UIElements
/
Implemented in:
UnityEngine.UIElementsModule
Description
Represents the point of origin where the transformations (
Scale
,
Translate
, and
Rotate
) are applied.
By default, transform-origin is set in percentages relative to the element's size.
For examp... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_9975e8854e5b | unity_docs | input | What is `UIElements.PointerEventBase_1.isPrimary` in Unity? Explain its purpose and usage. | PointerEventBase<T0>.isPrimary
public bool
isPrimary
;
Description
Gets a boolean value that indicates whether the pointer is a primary pointer. True means the pointer is a primary
pointer. False means it isn't.
A primary pointer is a pointer that manipulates the mouse cursor. The mouse pointer is always a... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_f4f8cc672af4 | unity_docs | physics | What is `ParticleSystem.ExternalForcesModule` in Unity? Explain its purpose and usage. | ExternalForcesModule
struct in
UnityEngine
/
Implemented in:
UnityEngine.ParticleSystemModule
Description
Script interface for the ExternalForcesModule of a Particle System.
Additional resources:
ParticleSystem
,
ParticleSystem.externalForces
.
Properties
Property
Description
enabled
Specifies whether th... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
gh_60672ab9cbb2 | github | scripting | Write a Unity Editor script for Ginjector Editor | ```csharp
#if UNITY_EDITOR
using UnityEngine;
using UnityEditor;
using GrimTools.Runtime;
namespace GrimTools.Editor
{
[CustomEditor(typeof(Ginjector))]
public class GinjectorEditor : UnityEditor.Editor
{
public override void OnInspectorGUI()
{
DrawDefaultInspector();
... | You are an experienced Unity developer specializing in C# scripting, XR/VR development, and performance optimization. |
local_sr_d5a052733940 | unity_docs | scripting | Show me a Unity C# example demonstrating `AddComponentMenu`. | AddComponentMenu
class in
UnityEngine
/
Implemented in:
UnityEngine.CoreModule
Description
The AddComponentMenu attribute allows you to place a script anywhere in the "Component" menu, instead of just the "Component->Scripts" menu.
You can use this to organize the Component menu better and improve the workflow ... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_man_2e7d69980dd2 | unity_docs | rendering | Explain 'Write a shader for a Custom Render Texture' in Unity. | To update a Custom
Render Texture
manually, you can write a specialized Custom Render Texture
shader
.
To help you write your Custom Render Texture shaders, here are two example frameworks that contain utility functions and built-in helper variables.
The following shader example fills the texture with a color multiplie... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_26b3ba90638c | unity_docs | math | Show me a Unity C# example demonstrating `Tilemaps.Tilemap.GetTilesRangeNonAlloc`. | on's value is higher than the ending position's value, then the method begins with the Cell at the starting position but iterates in the opposite direction of the usual method, ending when it reaches the Cell at the ending position.
If the size of the arrays passed in as parameters are less than the number of Tiles wit... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_7b3ed5a229f5 | unity_docs | scripting | What is `GenericMenu.MenuFunction2` in Unity? Explain its purpose and usage. | GenericMenu.MenuFunction2
Declaration
public delegate void
MenuFunction2
(object
userData
);
Parameters
Parameter
Description
userData
The data to pass through to the callback function.
Description
Callback function with user data, called when a menu item is selected.
Additional resources:
GenericMenu
, ... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_man_6b2bbfc8bcc9 | unity_docs | rendering | In Unity's 'Upgrade to Unity 2022 LTS', what is 'Page Outline' and how does it work? | Articulation Drive forceLimit property now accepts force input instead of impulse
Change to generated lightmap UVs
Change to GradientField in the UI Toolkit
UI Toolkit Numeric and Compound fields are available at runtime
The Physical Keys option in Input Manager is enabled by default
Added support for BatchRendererGrou... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_68a16ea323de | unity_docs | rendering | What is `Rendering.CullingSplit.cascadeBlendCullingFactor` in Unity? Explain its purpose and usage. | CullingSplit.cascadeBlendCullingFactor
public float
cascadeBlendCullingFactor
;
Description
Cascade blend culling factor.
Multiply the radius of the culling sphere by this factor. Valid range: 0–1. The value comes from
ShadowSplitData
. | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_man_296ccec72585 | unity_docs | scripting | Explain 'Introduction to programming in Unity' in Unity. | Unity is customizable and extensible by design and almost everything is scriptable to some extent. Many items you can configure through the various
Editor views
have a corresponding public C# class representation that you can interact with in code.
You can use Editor APIs to customize and extend the Editor authoring to... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_man_d2da5e0ecf82 | unity_docs | ui | In Unity's 'Generate 2D visual content', what is 'Use the Vector API' and how does it work? | To use the Vector API, access the Painter2D object from the MeshGenerationContext and generate paths with it. You can then use Stroke to draw lines or Fill to draw shapes.
To build paths, you issue commands that move a kind of “virtual pen.” For example, to generate the
same quad in the Mesh API example
, move the “pen... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_45fd7c63f8f4 | unity_docs | editor | What is `EditorGUIUtility.ShowObjectPicker` in Unity? Explain its purpose and usage. | EditorGUIUtility.ShowObjectPicker
Declaration
public static void
ShowObjectPicker
(
Object
obj
,
bool
allowSceneObjects
,
string
searchFilter
,
int
controlID
);
Parameters
Parameter
Description
obj
The object to be selected by default.
allowSceneObjects
Is selection of Scene objects allowed, or should ... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_man_3481726a39e8 | unity_docs | scripting | Explain 'Code examples: Call Java/Kotlin code from C# scripts' in Unity. | Unity provides high-level APIs such as AndroidJavaObject ,
AndroidJavaClass
,
AndroidJavaProxy
, and AndroidApplication that allow you to interact with Java/Kotlin code from C#
scripts
.
The following code examples demonstrate how to use these APIs.
## Example 1: Get the hash code for a Java string
The following code... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_8d457717d9aa | unity_docs | editor | What is `EditorGUILayout.Toggle` in Unity? Explain its purpose and usage. | EditorGUILayout.Toggle
Declaration
public static bool
Toggle
(bool
value
,
params GUILayoutOption[]
options
);
Declaration
public static bool
Toggle
(string
label
,
bool
value
,
params GUILayoutOption[]
options
);
Declaration
public static bool
Toggle
(
GUIContent
label
,
bool
value
,
params GUILayou... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_man_b2a6d8800095 | unity_docs | rendering | Explain 'Normal map texturing shader example in the Built-In Render Pipeline' in Unity. | Often
Normal Maps
are used to create additional detail on objects, without creating additional geometry. Let’s see how to make a shader that reflects the environment, with a normal map texture.
Now the math is starting to get
really involved
, so we’ll do it in a few steps. In the shader above, the reflection
direction... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_d6deb4e9db40 | unity_docs | ui | What is `EventType.MouseUp` in Unity? Explain its purpose and usage. | EventType.MouseUp
Description
Mouse button was released.
This event gets sent when any mouse button is released. Use
Event.button
to determine which button was pressed down.
Additional resources:
EventType
,
Event.Use
. | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_815e2aa7bf64 | unity_docs | math | What are the parameters of `Mesh.SetSubMesh` in Unity? | Description Sets the information about a sub-mesh of the Mesh. Note that SetSubMesh , SubMeshDescriptor , and SetIndexBufferData are designed for advanced users aiming for maximum performance, because they operate on the underlying mesh data structures that primarily work on raw index buffers, vertex buffers and mesh s... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_man_29157205752e | unity_docs | input | Show me a Unity code example for 'LongField'. | nsure that the entered data meets certain requirements.
Note
: To align a LongField 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 LongField
You can create a LongField with UI Builder, UXML, and C#.
To create... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_aa2c38ede78c | unity_docs | rendering | What is `WebCamTexture.GetPixels` in Unity? Explain its purpose and usage. | WebCamTexture.GetPixels
Declaration
public Color[]
GetPixels
();
Returns
Color[]
An array that contains the pixel colors.
Description
Gets the pixel color data for a mipmap level as
Color
structs.
This method gets pixel data from the texture in CPU memory.
Texture.isReadable
must be
true
.
The array ... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_bfb6e15eee50 | unity_docs | animation | What is `Animations.AnimatorController.AddLayer` in Unity? Explain its purpose and usage. | AnimatorController.AddLayer
Declaration
public void
AddLayer
(string
name
);
Declaration
public void
AddLayer
(
Animations.AnimatorControllerLayer
layer
);
Parameters
Parameter
Description
name
The name of the Layer.
layer
The layer to add.
Description
Utility function to add a layer to the control... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_a1027ebe2b37 | unity_docs | ui | What is `Connect.ProjectBindDrawer` in Unity? Explain its purpose and usage. | ProjectBindDrawer
class in
UnityEditor.Connect
Implements interfaces:
IProjectEditorDrawer
Description
A container that fetches the UIElements that draw the Project Binding UI, and subscribes to its events.
Constructors
Constructor
Description
ProjectBindDrawer
The default constructor for the Drawer that subs... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_6d86e520082f | unity_docs | math | What is `Mesh.GetVertexAttributeFormat` in Unity? Explain its purpose and usage. | Mesh.GetVertexAttributeFormat
Declaration
public
Rendering.VertexAttributeFormat
GetVertexAttributeFormat
(
Rendering.VertexAttribute
attr
);
Parameters
Parameter
Description
attr
Vertex data attribute to check for.
Returns
VertexAttributeFormat
Format of the data attribute.
Description
Get forma... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_256adf6165fa | unity_docs | physics | What is `PhysicsVisualizationSettings.MeshColliderType` in Unity? Explain its purpose and usage. | MeshColliderType
enumeration
Description
Is a MeshCollider convex.
Properties
Property
Description
Convex
Corresponds to MeshCollider.convex is true.
NonConvex
Corresponds to MeshCollider.convex is false. | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_daa075b2d0a6 | unity_docs | scripting | What are the parameters of `Rendering.AsyncGPUReadback.RequestIntoNativeSlice` in Unity? | Returns AsyncGPUReadbackRequest Returns an AsyncGPUReadbackRequest that you can use to determine when the data is available. Otherwise, returns a request with an error. Description Retrieves data asynchronously from a GPU Texture resource. If the return value is a request with an error, calling AsyncGPUReadbackRequest.... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_man_97917c54f7a8 | unity_docs | editor | In Unity's 'Create and manage overlay configurations', what is 'Save an overlay configuration' and how does it work? | Saved overlay presets are available in any Unity project on your computer.
Overlay configurations are also saved when you save your
Editor layout
.
To save your overlay configuration as a preset:
In the Scene view, press the ` key to display the Overlays menu.
In the dropdown in the Overlays menu, select
Save Preset
.
... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_8e80fcbbb3e7 | unity_docs | scripting | What is `ChangeGameObjectOrComponentPropertiesEventArgs.ctor` in Unity? Explain its purpose and usage. | ChangeGameObjectOrComponentPropertiesEventArgs Constructor
Declaration
public
ChangeGameObjectOrComponentPropertiesEventArgs
(int
instanceId
,
SceneManagement.Scene
scene
);
Parameters
Parameter
Description
instanceId
The instance ID of the modified
GameObject
or
Component
.
scene
The
Scene
that co... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_38e876a0b80d | unity_docs | scripting | What is `Device.Application.SetStackTraceLogType` in Unity? Explain its purpose and usage. | Application.SetStackTraceLogType
Declaration
public static void
SetStackTraceLogType
(
LogType
logType
,
StackTraceLogType
stackTraceType
);
Description
This has the same functionality as
Application.SetStackTraceLogType
. At the moment, the Device Simulator doesn't support simulation of this method. | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_e6b123a462a6 | unity_docs | rendering | What is `TerrainTools.PaintContext.GatherHoles` in Unity? Explain its purpose and usage. | PaintContext.GatherHoles
Declaration
public void
GatherHoles
();
Description
Gathers the Terrain holes information into
sourceRenderTexture
.
This function collects the Terrain holes data from all Terrain tiles in the Paint Context, and saves the information in
sourceRenderTexture
.
This function is called ... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_man_c4bde4ef3f04 | unity_docs | scripting | In Unity's 'MultiColumnTreeView', what is 'Refresh the collection view' and how does it work? | To refresh the collection view, you can call either
RefreshItems
/
RefreshItem or Rebuild
.
In general, call the RefreshItems or RefreshItem method—these methods only refresh the collection view and are less expensive. If you call Rebuild , the collection view is completely rebuilt, which can be expensive.
However, you... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_ce19191b6fbe | unity_docs | input | What is `Experimental.GraphView.SelectionDropper.OnMouseUp` in Unity? Explain its purpose and usage. | Experimental
: this API is experimental and might be changed or removed in the future.
SelectionDropper.OnMouseUp
Declaration
protected void
OnMouseUp
(
UIElements.MouseUpEvent
e
);
Parameters
Parameter
Description
e
The event.
Description
Called on mouse up event. | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_a96b9ba20347 | unity_docs | scripting | What is `SystemInfo.supportsMultisampledBackBuffer` in Unity? Explain its purpose and usage. | SystemInfo.supportsMultisampledBackBuffer
public static bool
supportsMultisampledBackBuffer
;
Returns
bool
true
if a multi-sampled back buffer is supported.
Description
A boolean property that indicates whether multi-sampled back buffer is supported (
true
if supported,
false
if not supported).
Multi-s... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_6fe974da2c98 | unity_docs | scripting | What is `MinAttribute` in Unity? Explain its purpose and usage. | MinAttribute
class in
UnityEngine
/
Inherits from:
PropertyAttribute
/
Implemented in:
UnityEngine.CoreModule
Description
Attribute used to make a float or int variable in a script be restricted to a specific minimum value.
Properties
Property
Description
min
The minimum allowed value.
Constructors
Const... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_398f4576bd42 | unity_docs | scripting | What is `ModelImporterNormalSmoothingSource.PreferSmoothingGroups` in Unity? Explain its purpose and usage. | ModelImporterNormalSmoothingSource.PreferSmoothingGroups
Description
Use smoothing groups if they are present in the Model file, otherwise use angle (default).
Additional resources:
ModelImporter.normalSmoothingSource
. | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_338a15f34e9f | unity_docs | physics | What is `UnityEngine.Physics2DModule` in Unity? Explain its purpose and usage. | UnityEngine.Physics2DModule
Description
The Physics2d module implements 2D physics in Unity.
Classes
Class
Description
AnchoredJoint2D
Parent class for all joints that have anchor points.
AreaEffector2D
Applies forces within an area.
BoxCollider2D
Collider for 2D physics representing an axis-aligned rectangle.... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_25b0704d4575 | unity_docs | rendering | What is `Rendering.EditorCameraUtils.GetRenderersHiddenResultBits` in Unity? Explain its purpose and usage. | EditorCameraUtils.GetRenderersHiddenResultBits
Declaration
public static void
GetRenderersHiddenResultBits
(ReadOnlySpan<int>
rendererIDs
,
Span<ulong>
resultBits
);
Parameters
Parameter
Description
rendererIDs
The span of renderer
instance IDs
to check.
resultBits
The span of visibility statuses the me... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_92c02e5e64c4 | unity_docs | audio | Show me a Unity C# example demonstrating `AudioChorusFilter.wetMix2`. | AudioChorusFilter.wetMix2
public float
wetMix2
;
Description
Volume of 2nd chorus tap. This tap is 90 degrees out of phase of the first tap. 0.0 to 1.0. Default = 0.5.
```csharp
using UnityEngine;[RequireComponent(typeof(AudioSource))]
[RequireComponent(typeof(AudioChorusFilter))]
public class Example : MonoBe... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_man_0c3500cc6cd9 | unity_docs | scripting | In Unity's 'Introduction to the camera view', what is 'The view frustum' and how does it work? | The word frustum refers to a solid shape that looks like a pyramid with the top cut off parallel to the base. This is the shape of the region that can be seen and rendered by a perspective camera. The following thought experiment should help to explain why this is the case.
Imagine holding a straight rod (a broom handl... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_a8e6f6695f69 | unity_docs | editor | What is `PlayerSettings.WSA.packageName` in Unity? Explain its purpose and usage. | PlayerSettings.WSA.packageName
public static string
packageName
;
Description
The name of the Universal Windows Platform application package to install on the device.
In the Editor, Unity displays this under
Packaging
in
UWP Player Settings
. | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_man_19dd64f70071 | unity_docs | physics | Explain 'Adjust Rigidbody component solver iterations' in Unity. | Adjust solver iteration counts for individual Rigidbody components to improve simulation results.
If a specific Rigidbody component in your scene requires higher simulation accuracy or stability, such as preventing jittering in stacks or ensure joint stability, adjust its solver iteration count individually. Increasing... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_d6e7fcfd587b | unity_docs | math | What are the parameters of `Vector4.ToString` in Unity? | Description Returns a formatted string for this vector. Defaults to two digits displayed (format="F2"). For more information, see Microsoft's documentation on Standard numeric format strings . ```csharp
using UnityEngine;public class Example : MonoBehaviour
{
void Start()
{
Vector4 vector = new Vector4(... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_388352517258 | unity_docs | rendering | What are the parameters of `Experimental.Rendering.GraphicsStateCollection.GetGraphicsStatesForVariant` in Unity? | Description Populate given list with graphics states associated with input shader variant. ```csharp
using System.Collections.Generic;
using UnityEngine;
using UnityEngine.Experimental.Rendering;public class GetGraphicsStatesExample : MonoBehaviour
{
public GraphicsStateCollection graphicsStateCollection; void S... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_3ca6bd5677a1 | unity_docs | scripting | What is `PlayerSettings.Android.androidVulkanAllowFilterList` in Unity? Explain its purpose and usage. | PlayerSettings.Android.androidVulkanAllowFilterList
public static AndroidDeviceFilterData[]
androidVulkanAllowFilterList
;
Description
Specifies a list of
AndroidDeviceFilterData
parameters to allow Android devices to always use Vulkan API when running Unity applications.
Each parameter value in each
Androi... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_a6f681601231 | unity_docs | scripting | Show me a Unity C# example demonstrating `ParticleSystem.sizeBySpeed`. | ParticleSystem.sizeBySpeed
public
ParticleSystem.SizeBySpeedModule
sizeBySpeed
;
Description
Script interface for the SizeBySpeedModule of a Particle System.
This module controls the size of particles based on their speeds.
Particle System modules do not need to be reassigned back to the system; they are int... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_bb4225b5ecc5 | unity_docs | scripting | Show me a Unity C# example demonstrating `UIElements.ProgressBar`. | ProgressBar
class in
UnityEngine.UIElements
/
Inherits from:
UIElements.AbstractProgressBar
/
Implemented in:
UnityEngine.UIElementsModule
Description
A control that displays the progress between a lower and upper bound value. For more information, refer to
UXML element ProgressBar
.
```csharp
public Prog... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_87e68a133112 | unity_docs | rendering | Show me a Unity C# example demonstrating `Graphics.DrawMeshInstancedIndirect`. | per instance, instance count, start index location, base vertex location, start instance location.
Unity only needs the submeshIndex argument if submeshes within the mesh have different topologies (e.g. Triangles and Lines). Otherwise, all the information about which submesh to draw comes from the bufferWithArgs argume... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_e79b47765e42 | unity_docs | scripting | What is `Build.Content.ObjectIdentifier.operator_lt` in Unity? Explain its purpose and usage. | ObjectIdentifier.operator <
public static bool
operator <
(
Build.Content.ObjectIdentifier
a
,
Build.Content.ObjectIdentifier
b
);
Description
Returns true if the first ObjectIdentifier is less than the second ObjectIdentifier.
Internal use only. See
ObjectIdentifier
. | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_98e1c4bcf4e2 | unity_docs | scripting | What is `Experimental.GraphView.ContentDragger.RegisterCallbacksOnTarget` in Unity? Explain its purpose and usage. | Experimental
: this API is experimental and might be changed or removed in the future.
ContentDragger.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_e38663a49911 | unity_docs | physics | What is `PlayerSettings.Android.forceInternetPermission` in Unity? Explain its purpose and usage. | PlayerSettings.Android.forceInternetPermission
public static bool
forceInternetPermission
;
Description
Force internet permission flag.
```csharp
using UnityEngine;
using UnityEditor;
using UnityEditor.Build;public class ForceInternetPermissionSample : MonoBehaviour
{
[MenuItem("Build/ForceInternetPermission ... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_574decfaece6 | unity_docs | rendering | What is `ParticleSystem.RotationOverLifetimeModule.y` in Unity? Explain its purpose and usage. | ParticleSystem.RotationOverLifetimeModule.y
public
ParticleSystem.MinMaxCurve
y
;
Description
Rotation over lifetime curve for the y-axis.
Additional resources:
MinMaxCurve
.
```csharp
using UnityEngine;
using System.Collections;[RequireComponent(typeof(ParticleSystem))]
public class ExampleClass : MonoBeh... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_c7e5d349e3e8 | unity_docs | physics | What is `MPE.RoleProviderAttribute` in Unity? Explain its purpose and usage. | RoleProviderAttribute
class in
UnityEditor.MPE
Description
An attribute used to decorate function that defines how a slave process can interact with a main instance of Unity.
Properties
Property
Description
eventType
The event that the process triggered.
level
The process level (either master or slave) that t... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_man_f59ca6856cfc | unity_docs | rendering | Explain 'Reflections' in Unity. | Techniques and resources for using Reflection Probes to capture and display reflections on
GameObjects
.
Page Description Reflection Probes
Understand how Unity bakes a spherical view of a scene into a Reflection Probe, then uses it to quickly calculate reflections on GameObjects.
Types of Reflection Probe
Compare the ... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_c5169646c021 | unity_docs | scripting | Give me an overview of the `AnimationCullingType` class in Unity. | AnimationCullingType
enumeration
Description
This enum controlls culling of Animation component.
When culling is enabled, Unity might stop animating if it thinks that the results of the animation won't be visible to the user.
This could save you some performance if you have things animating outside of the viewport... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_0046fd9ac890 | unity_docs | scripting | What is `Experimental.GraphView.Capabilities` in Unity? Explain its purpose and usage. | Capabilities
enumeration
Description
Capabilities used by Manipulators to easily determine valid actions on a GraphElement.
Properties
Property
Description
Selectable
The GraphElement is selectable.
Collapsible
The GraphElement can be collapsed.
Resizable
The GraphElement is resizable.
Movable
The GraphEleme... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_5cbe0e6adb07 | unity_docs | rendering | What is `ParticleSystem.ShapeModule.arcSpeed` in Unity? Explain its purpose and usage. | ParticleSystem.ShapeModule.arcSpeed
public
ParticleSystem.MinMaxCurve
arcSpeed
;
Description
In animated modes, this determines how quickly the particle emission position moves around the arc.
The value is specified in terms of the number of complete 360 degree rotations. A value of 2 would mean that the par... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_803b1826c6a2 | unity_docs | editor | Show me a Unity C# example demonstrating `AssetDatabase.RemoveAssetBundleName`. | AssetDatabase.RemoveAssetBundleName
Declaration
public static bool
RemoveAssetBundleName
(string
assetBundleName
,
bool
forceRemove
);
Parameters
Parameter
Description
assetBundleName
The AssetBundle name you want to remove.
forceRemove
Flag to indicate if you want to remove the AssetBundle name even it's... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_ecbe4222826b | unity_docs | ui | What is `UIElements.ToggleButtonGroupState.operator_ne` in Unity? Explain its purpose and usage. | ToggleButtonGroupState.operator !=
public static bool
operator !=
(
UIElements.ToggleButtonGroupState
lhs
,
UIElements.ToggleButtonGroupState
rhs
);
Parameters
Parameter
Description
lhs
The first option set to be compared against.
rhs
The second option set to be compared against.
Returns
bool
True ... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_27a7ed38ee24 | unity_docs | scripting | What are the parameters of `Search.IPropertyDatabaseView.TryLoad` in Unity? | Returns bool True if the record is found and is valid, false otherwise. Description Loads a single property, already deseriazed into an object. ```
// Load the value already deserialized.
using (var view = propertyDatabase.GetView())
{
var colorRecordKey = view.CreateRecordKey("path/to/my/asset", "m_Color");
if... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_cb80afe2cf19 | unity_docs | scripting | What are the parameters of `LightTransport.IDeviceContext.ReadBuffer` in Unity? | Description Asynchronously copies data from a device buffer to host memory. Initiates an asynchronous transfer of data from device memory to host memory. The method returns immediately after enqueuing the operation. Use Flush to ensure the operation begins executing, then use Wait or IsCompleted with the provided event... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_0f7aaec8b83c | unity_docs | rendering | What is `Experimental.Rendering.GraphicsStateCollection.AddVariant` in Unity? Explain its purpose and usage. | Experimental
: this API is experimental and might be changed or removed in the future.
GraphicsStateCollection.AddVariant
Declaration
public bool
AddVariant
(
Shader
shader
,
Rendering.PassIdentifier
passId
,
LocalKeyword[]
keywords
);
Parameters
Parameter
Description
shader
Shader used in the variant.... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_3394ccfda1cb | unity_docs | rendering | What is `QualitySettings.streamingMipmapsAddAllCameras` in Unity? Explain its purpose and usage. | QualitySettings.streamingMipmapsAddAllCameras
public static bool
streamingMipmapsAddAllCameras
;
Description
Process all enabled Cameras for texture streaming (rather than just those with StreamingController components).
Set to True to process all enabled Cameras for texture streaming. This is a quick way to s... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_fcceade6130a | unity_docs | physics | What is `OverlapCapsuleCommand.ctor` in Unity? Explain its purpose and usage. | OverlapCapsuleCommand Constructor
Declaration
public
OverlapCapsuleCommand
(
Vector3
point0
,
Vector3
point1
,
float
radius
,
QueryParameters
queryParameters
);
Parameters
Parameter
Description
point0
The center of the sphere at the
start
of the capsule.
point1
The center of the sphere at the
en... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_man_c7bb09dfeb7a | unity_docs | rendering | Explain 'Configure mipmap streaming' in Unity. | ## Set which cameras use mipmap streaming
By default, all cameras in your scene use mipmap streaming when you enable it.
## Disable mipmap streaming on a single camera
Follow these steps:
Select a camera in your scene.
In the Inspector window, select
Add Component
>
Streaming Controller
.
Disable the
Streaming Contr... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_4361edb2c659 | unity_docs | rendering | What is `Resources.Load` in Unity? Explain its purpose and usage. | Resources.Load
Description
Loads the asset of the requested type stored at
path
in a
Resources
folder.
This method returns the asset at
path
if it can be found, otherwise it returns null.
Note that the
path
is case insensitive and must not contain a file extension. All asset names and paths in Unity use fo... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_84b9199a1975 | unity_docs | math | What is `BoundsInt.ToString` in Unity? Explain its purpose and usage. | BoundsInt.ToString
Declaration
public string
ToString
();
Declaration
public string
ToString
(string
format
);
Declaration
public string
ToString
(string
format
,
IFormatProvider
formatProvider
);
Parameters
Parameter
Description
format
A numeric format string.
formatProvider
An object that speci... | You are a Unity game development assistant. Help developers understand Unity APIs, best practices, and solve implementation challenges. |
local_sr_93081fdcd5e6 | unity_docs | scripting | What is `SceneManagement.StageHandle.FindComponentOfType` in Unity? Explain its purpose and usage. | StageHandle.FindComponentOfType
Declaration
public T
FindComponentOfType
();
Returns
T
This returns the object that matches the specified type. It returns null if no object matches the type.
Description
Returns the first active loaded object of the given type. | 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.