Stack Exchange Network

Stack Exchange network consists of 174 Q&A communities including Stack Overflow, the largest, most trusted online community for developers to learn, share their knowledge, and build their careers.

Visit Stack Exchange

Questions tagged [unity]

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.

0
votes
1answer
34 views

Unity3D C# Drag object smoothly on it's x axis that's already bouncing

In my scene, I have a bouncing ball that collides with a cube. On each collision the ball returns to the same height. How can I get the ball to smoothly move along the x-axis by dragging my finger ...
0
votes
1answer
82 views

simple 2d car AI unity

I have a top down Car Game. how can I implement AI for the Cars? how the car follow the way points? I want AI cars also rotate itself along the path. I tried this solution ...
0
votes
1answer
53 views

How can I make Matrix Rain?

I want to make 3d Matrix rain like this shader that you can rotate camera.I tried to convert this shader but It have many calculations that it's expensive inside game engine.then I tried to make this ...
0
votes
1answer
51 views

Changing transform of ParticleSystem makes it not play?

Unity 2018.2.9f1, only 1 script, there is no other code. The scene is very simple (I just started). I'm working on a mobile game and I'm trying to play a particle effect at the tap location. I ...
0
votes
0answers
14 views

Smoothing random noises with different amplitudes

I have a function that returns a bounded noise. For example, let's imagine that out input range is [-1, 1]. With my method I can return a bounded/in range noise (depending on the biome we are ...
0
votes
2answers
63 views

The second double jump animation doesn't finish before the player touches the ground

I have an issue with double jump for the player my code is working but I want the second double jump animation finish(idle Animation: anim.SetBool("Jump", false)] before he touches the ground can ...
0
votes
1answer
34 views

How can I move objects in a cyclic loop?

I have number of objects I want to move them up and forward then when the last one each time in the array get to the end position move this object to the start of the array and to the start position ...
0
votes
1answer
44 views

Resize rigidbody in runtime, Box collider OnTriggerEnter not work

Scene setting: Object A: Rigidbody, kinmeatic Box collider, is trigger true. Object B: Box collider, is trigger true. Script is on Object A: ...
0
votes
0answers
24 views

How to deal with pushing objects out of collision

I am developing RTS game in unity3d. I have thousands of units running around the battlefield I can't use unity physics component for collision detection as physics API is not available for job system ...
0
votes
0answers
21 views

Does unity use reflection internally for MonoBehaviour.Invoke and the family of methods?

Does Unity use reflection for MonoBehaviour.Invoke internally? (The question is being asked, because I need to optimize some C# code for a unity project to increase performance.)
0
votes
0answers
17 views

How to Simulate Tectonic Plates using Flood Fill in Unity2d

How do I use flood fill in Unity2D to make tectonic plates? I've already wasted many hours trying to find something to help, and I couldn't find anything explaining how it was done.
0
votes
0answers
52 views

Is it possible to “trim” a prefab?

I've been making a game in Unity, and would like to be able to "trim" (or "crop") a prefab. Basically, I want to make a part of the prefab not render or collide in the scene. What I want: ...
0
votes
0answers
11 views

How to spawn a number of particles to form a circle and then animate them?

Imagine you took, say, 500 dots and randomly positioned them to form the shape of a (full) circle. Then you set each individual dot to float around aimlessly, with a limited amount of distance it can ...
0
votes
1answer
17 views

Trying to mix and mingle 3d physics with the Unity UI

I have recently created a drag drop system where I drag stuff from a UI menu and then drop it to another UI. The child of the draggable UI object is a 3d model. I have attached box collider and ...
0
votes
1answer
23 views

How to align 2 IMUs' quaternions?

Suppose I have 2 IMUs that output 2 quaternions. I place one IMU on my left hand and another one on my right hand. I put both my hands flat on the table and point it forward to the same direction. ...
1
vote
1answer
40 views

Calculating distance using Job System

I am trying to find out the distance between game objects and the player position using Job System, But I am getting an error of unsafe pointer race condition. Can anyone tell me how to access ...
0
votes
0answers
15 views

How to virtually test which Android API is supported by my Unity game?

I have Unity 5.6 and I set the Minimum API Level to 4.1 Jelly Bean. The game works fine on my Android 7.0, however, on my Android 4.4 there's a problem with the Directional Light, creating really ...
0
votes
1answer
40 views
0
votes
0answers
16 views

How to save the card collection of a player in a collectibe card game in the database? [duplicate]

So I'm creating a CCG (Collectable Card Game) and I'm using an SQL server for my account profiles (playername, password, currency, etc.). However, I now stand for the decision on how to save Collected ...
0
votes
0answers
74 views

how to check which gameobject of an array is active

1-I make a quiz game and I want to know how to make a feedback after answering question (feedback like text on button becomes red if wrong and green if correct)? 2-questions gameobjects in an array ...
-6
votes
0answers
65 views

i have a very fantastic Game idea for mobile and window… [duplicate]

I have a great idea to create play. Is there a place to hear and support my idea?     The financial returns of this idea is Excellent
0
votes
0answers
16 views

Should I place all my controller code in the EventSystem

Once upon a time, when I was working with GameMaker, I learned that I needed a single controller object in my room to hold all of the code that was not a part of any other object, and would exist ...
5
votes
2answers
147 views

Can Unity censor my content or invalidate my license for offensive content?

If I make an offensive game can they pull my license and prevent me from selling my game? Like we're talking think of the most offensive thing you can think of: you're in charge of the most efficient ...
0
votes
1answer
25 views

elements of list are changing their values

I'm making an app that's similar to an alarm, the user enters time and days, for days I'm using toggles,and storing the values of toggles states in a list which is stored in a list that contain all ...
2
votes
1answer
183 views

Random Range Without Duplicates

I have an array of gameobjects (some questions) if player hit some triggers a question from the array is displayed randomly, I want to avoid duplication of displaying questions. ...
1
vote
0answers
31 views

Avoid object from bouncing non-stop after AddForce() is applied to it

I want to implement some sort of elastic field on my light blue magnetic field when a cylinder is colliding it, it worked except the lines won't stop bouncing. I am enabling the trigger collider on ...
0
votes
1answer
19 views

How to Fetch a Frame Number from Animation Clip

I'm trying to find out how to fetch the frame number from an animation clip accurately. I don't want to get a value between 0 and 1 that shows as a percentage-as-a-decimal how much of the animation ...
-1
votes
0answers
32 views

Unity3D - Custom Inspector for a scriptable object

alt text This is what I'm trying to make in custom editor so it's like a wave of enemies data that I'm storing in next way: first int-> number of formations then select formation (one, pair, triple, ...
0
votes
0answers
41 views

Don't Render always on top Unity world space canvas UI

I have a World Space Canvas where I have a text object which is always rendering on top. I checked that it has UI/Default Shader attach. Is there any way available ...
0
votes
1answer
68 views

UI Button Click Animation

We have animation states for Normal, Highlighted, Pressed and Disabled. How to set animation when a button is clicked?(after button released not pressed)? Thanks in advance
0
votes
1answer
24 views

Smooth behaviours at high Time.timeScale

When I set the Time.timeScale in unity very high, many scripts seem to do werid things (because of the high deltaTime they use for their logic). Is there an option ...
0
votes
0answers
40 views

Unity: How can I play a sound every time a particle is emitted?

Really lost here, isn't there a way to add a sound effect to a particle-system when a particle is emitted(burn)? should i go a different path to create shots?
0
votes
1answer
50 views

Unity: Looking to achieve similar day/night cycle in 2D game

so I'm currently working on 2D game, and I was wondering if anyone around here has experience/tips in achieving this (see reference below) sort of day/night transition? I've done some reading, and ...
0
votes
0answers
19 views

Unity2D - Tilemap Challenges

At the moment, I am working on wrapping my head around what the Unity tilemap is doing programmatically. I have looked through the online documentation as well as taken a look at their official source ...
0
votes
0answers
22 views

Unity5 Boxcast/ Raycast Rotate with Parent

I started with the API Scripting reference's Physics.BoxCast example code: [https://docs.unity3d.com/ScriptReference/Physics.BoxCast.html] ...and it works great... until the game object rotates, see: ...
0
votes
0answers
18 views

Unity 2d Character hitting object with different direction

So I`am making a hacky sack game but when i kick the object hit just going up with no random direction and force. And I want my character not to hit the object when running and idle I just want the ...
0
votes
1answer
20 views

How to remove a scene after the another one has loaded

]2[]3I'm having this problem in Unity where I load a new scene, but the original is still overlapping it. How would you remove the original scene?
0
votes
1answer
42 views

How do I deactivate an object after “X” seconds?

I'm making a quiz game and I want to deactivate the question after a certain amount of time after the player clicked the correct answer button. I've tried using coroutines, but it seems like I'm doing ...
0
votes
0answers
29 views

How can I sync lip and face movement of a 3d character?

I have a 3d character controller in my Unity game. It's an asset available on asset store and goes by the name unitychan, I want the gamecontroller to make a lip sync movement (body movement not ...
0
votes
0answers
18 views

Command function is not running. And showing warning **Trying to send command for object without authority.**

I have a Capsule with script attached Player, I created a Cube as a child to the Capsule, Cube also has HandGun scripts. So when I touch the fire button it will call ...
0
votes
0answers
62 views

Design pattern/data structures for multi-level asset hierarchy streaming based on proximity?

I'm inspired by CIG's buzz about Object Container Streaming and am curious about how they implemented it. To generalize the curiosity, I am curious about how to implement the streaming of multi-level ...
0
votes
1answer
32 views

Unity3D - weird model imported from blender

Also it's important to mention that I'm using LightweightPipelineAsset for Scriptable Render Pipeline (so I can use PBR graphs) Problem is that surfaces that SHOULD be drawn they AREN'T and the ones ...
0
votes
1answer
19 views

Object pooling of different tpyes of agents (Mobile Game) in Unity

The mobile game I am developing consists of one to four players and different agents that are being spawned and act in their own way. All those Agents (Car, Animal and Powerup) derive from the same ...
-1
votes
1answer
38 views

Ludum Dare - Tips and tricks for new challenger [closed]

I plan to join on solo the 43th Ludum dare in 20 days. It will be my first LD and I would like to know if you have some tips regarding the LD in general or some software to suggest. My goal is not ...
0
votes
0answers
29 views

Unity 2D RPG NPC collision and movement

I am prototyping(that is why I'm using squares) a 2D RPG and have implemented some movement & npc dialogue system. All this is done in Unity 2018 and for the purpose of dialogue system I'm using ...
1
vote
0answers
25 views

Aligning rotation from a imu9250 to a game object

I am experimenting with interfacing unity with real world inputs, specifically I have an imu9250, connected to an arduino clone providing rotation inputs ( either quaternion or pitch/yaw/roll) to ...
0
votes
0answers
20 views

How can i manage input in a split-screen multiplayer game?

In non-online multiplayer games, you most often see a "Press A to join" screen. I'm currently trying to figure out how it would be possible to create such a system, that selects the player via ...
-1
votes
0answers
36 views

How to make a bouncing ball

How do I make a bouncing ball that reaches always the same height, falling speed always the same, and only bounces if it collides with an object, if the ball does not collide with an object(like a ...
0
votes
1answer
20 views

Why is EditorGUI.PropertyField with a custom PropertyDrawer resetting values inside OnGUI of another PropertyDrawer?

I made a PropertyDrawer for a simple class, which looks something like this: ...