Search type Search syntax
Tags [tag]
Exact "words here"
Author user:1234
user:me (yours)
Score score:3 (3+)
score:0 (none)
Answers answers:3 (3+)
answers:0 (none)
isaccepted:yes
hasaccepted:no
inquestion:1234
Views views:250
Code code:"if (foo != bar)"
Sections title:apples
body:"apples oranges"
URL url:"*.example.com"
Saves in:saves
Status closed:yes
duplicate:no
migrated:no
wiki:no
Types is:question
is:answer
Exclude -[tag]
-apples
For more details on advanced search visit our help page
Results tagged with
Search options not deleted user 60302

Unity is a cross-platform game creation system that focuses on easy art pipeline process. It consists of a game engine and an integrated development environment. The game engine's scripting is built on Mono.

1 vote

Can't reference UI Image in Script

The GetComponentsInChildren() function 'Returns all components of Type type in the GameObject or any of its children. Works recursively.' If the code is executed by the parent GameObject, and it has a …
  • 4,286
1 vote

Why are my Player Input Unity Events started twice?

You may report it to the Unity team as well. …
  • 4,286
2 votes
Accepted

Can I reset the `[DisallowMultipleComponent]` attribute in child classes in Unity somehow?

I can think of a couple of ways to achieve that. You can either: Write some boilerplate code to check whether a Component is present multiple times or not at runtime (boring and error-prone). Or, you …
  • 4,286
3 votes
Accepted

Why I get indexoutofRangeException

You are declaring your class-level arrays: public int[] ResistorBand; public int[] ResistorBand2; but you aren't initialising them anywhere, like: ResistorBand = new int[7]; // This array has 7 el …
  • 4,286
1 vote

Help to compose the script correctly

Your code is excessively verbose, and this is likely to lead to unexpected behaviours when copy-pasting the same script with minor changes. You can take advantage of data structures and loop statement …
  • 4,286
0 votes
Accepted

How can I make the y extent height also to be random when instantiate new objects?

If terrain is at y = 0, you can make sure that the random y value you need is never smaller than zero by writing it like this: var y = Random.Range(0, 2*Extents.y); Although the range of values wil …
  • 4,286
1 vote
Accepted

How to make instantiated gameObject to be child of other object

As mentioned by user Zibelas, you can use the Instantiate(Object original, Transform parent) function to instantiate an object. This will immediately set parent as its parent after its creation, thus …
  • 4,286
3 votes

How to spawn the cubes on the terrain surface even if there is a hill on the terrain then sp...

You don't really need the Terrain.SampleHeight() function, since hit.point already contains the information (i.e. the position on the Terrain) you're looking for. public void SpawnThroughPlane() { …
  • 4,286
0 votes
Accepted

How can I create a custom plane with raycast?

Your question contains much code but defines your issue a bit vaguely. I hope I understood what you're trying to achieve, though. If you want to spawn objects both on the plane in the air and on the c …
  • 4,286
0 votes

How to have unity inspector variables modify each other bidirectionally and update in real time

Just as you hinted, OnValidate() is where you need to do some variable checking. If you want to update float_1 and float_2 mutually when the user changes one's value, you can check it in this editor-o …
  • 4,286
0 votes
Accepted

Unity Hub on Linux "Not enough space" download error

I'm assuming the installation directory wasn't changed (the standard directory is ~/Unity/Hub/): Create a folder named tmp in your Home directory (Bash command: mkdir ~/tmp). … The Unity Hub will open, and you'll be able to download the Editor. …
  • 4,286
0 votes
Accepted

How to keep loading screen for minimum time?

In Unity, SceneManager.LoadSceneAsync() doesn't allow you to control the exact moment to load a scene, in case you wanted to do a "Load everything, but I tell you when to move to the next scene" thing. …
  • 4,286
0 votes
1 answer
63 views

Unity Hub on Linux "Not enough space" download error

I just downloaded and installed the official Unity Hub app on my Ubuntu machine. … How can I download the Unity Editor? …
  • 4,286
3 votes
Accepted

How do you repeat a tile texture horizontally/vertically in a UI Image?

This way, you tell Unity to optimise usage of these resources for UI drawing. Setting up the Image component Select the GameObject with an Image component in it (create one if you haven't yet). …
  • 4,286
1 vote

Why are URP render settings limited in terms of rendering light sources? ( Unity )

The tradeoff here is less precision for more performance, as discussed in this Unity Forums thread by staff members. …
  • 4,286

15 30 50 per page