Stack Exchange Network

Stack Exchange network consists of 175 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
2answers
49 views

Unity prefab from multiple sprites

I am making a prefab of a simple building by combining sprites. As you can see in the Hierarchy view, this simple building is composed of very many gameobjects which I created via dragging sprites ...
0
votes
0answers
23 views

How simulate day/night transition on 2d game? [duplicate]

I'm trying to create a 2d game and I want to have a day/night transition, but i'm actually new on Unity and I don't know how to do it, I'm using this code, but give me error and I really don't even ...
0
votes
1answer
17 views

Unity3D short joystick controller script acting weird

So basically there's a joystick and when the user pull the joystick up the controller moves the player forward, to the sides and backward and it's all good. the problem I'm having for example is when ...
0
votes
1answer
62 views

The character does not stand still on the moving platform

I'm trying to create a simple platforming game. I have an animated platform moving in 2 opposite directions. I use this simple code to make the character move along with the platform while he is ...
0
votes
1answer
27 views

Black screen after running emulation mode in the Unity Editor for hololens

I am having issues with black screen when running the emulation mode or simulator for Microsoft hololens. In the preview the camera shows what the user should see. I see no obvious reason to behave ...
0
votes
0answers
9 views

Unity3D - Editor.OnInspectorGUI() produces wierd null ref

I am trying to draw the inspector gui from components from a prefab to my own editor window but then this error gets produced and I have no idea how to solve it. NullReferenceException: (null) ...
0
votes
0answers
9 views

Unity - Rotating image on button made button un-useable [duplicate]

I recently started trying to teach myself Unity2D development using some tutorials and something weird was happening last night while I was working on my project. Basically I have an image that ...
0
votes
1answer
53 views

How to find 1/3 and 2/3 of the distance between two given points?

I know how to find the middle of two given points: var midpoint = (pointA + pointB)/2; where pointA and ...
-1
votes
1answer
40 views

Sonic 3 Bonus Stage - Technique Discussion

This will be my first discussion on the gamedev stack exchange, so thanks for reading. My question pertains specifically to the special/bonus stages in Sonic 3 where the game gives you a convincing ...
0
votes
0answers
32 views

Model mesh overlapping while animating in Unity but not in Blender

I made an FPS model in blender and created reload animation when I imported that model in Unity I saw that while the magazine ejecting from the rifle it overlapped some of the gun parts. Then I went ...
0
votes
1answer
38 views

Better way to handle speed able time and action in unity

I have came across a problem where i have to do some time based task(simulation) like, As the game started: After 2 mintues launch a missle. After 4 mintues star a train on track after 12 minutes ...
0
votes
0answers
54 views

How do I slice a 3D object at runtime in Unity?

I'm specifically looking for some sort of algorithm or way that can "cut" a 3 dimensional mesh with some other game object. How would I implement this?
2
votes
1answer
60 views

Closest node in A* pathfinding

For my 2D Unity game, I've implemented A* pathfinding based on waypoints. System already handles building graph from waypoints on scene (which are manually placed objects), as well as finding and ...
0
votes
1answer
71 views

Raymarching in Unity's new SRP & Post Processing V2

Hello wonderful wizards of the shader world! I've seen a few tutorials featuring the use of Raymarching via the older OnRenderImage function, however, that is no ...
0
votes
1answer
42 views

In Unity, my mesh is not rendering when huge (scale of 1400000)

Any help/tips? This is for a space game and I really want realistic measures. The user WILL get really close to the sun. Any tips with dealing this? I can see the whole "Corona" but not the big sphere ...
0
votes
0answers
21 views

How can I make in the model animation tab humanoidwalk in the preview?

This is a screenshot of the character in the hierarchy and inspector: This is the character controller settings the first animation is WALK using HumanoidWalk: This is the animation tab in the ...
1
vote
0answers
35 views

Box collider has different behavior in 2 clients

I'm new to Unity. I am making my first Game and faced with problem. I have a plane and 4 gameobject that has box collider surrounded this plane. there are a few spheres as players inside of the plane....
0
votes
1answer
44 views

Scale camera to fit screen size unity

My background and gameobjects are 2d sprites not UI images ,I want to know how to make my background scale with screen size and positions of 2d sprits on it don't change after building game (webGl) ...
11
votes
1answer
229 views

How can I make outline shader like “Life is Strange”?

I want to make sketch shader like life strange. shader has two part: 1.animated dashed line 2.noisy outline I like to know how can I make noisy outline? see outline of objects First I tried to ...
0
votes
0answers
12 views

Unity inflates poly/vertex count but I don't have any lights?

Ok I have an issue with several meshes that have a lower poly count in blender, then when I export as fbx and bring into unity, the poly/vertex count skyrockets. I read here https://forum.unity.com/...
0
votes
0answers
31 views

Set the Number of Levels at Runtime

Could anyone suggest a way that I can allow a user to set the number of levels that will be in a Unity3d game at runtime, and load them accordingly? The level design information is held in text ...
0
votes
1answer
47 views

How can I make an update patch for a Unity game on Windows?

I ran into trouble making a PC game using Unity. If I try to update my game, I can't a update the C# scripts (because AssetBundles don't include C# scripts) So I think I'll need to use a server and ...
0
votes
0answers
13 views

Inverse Kinematics with obstacle avoidance for the manipulator (arm)

I have a basic understanding of inverse kinematics, in that there's a workspace and a configuration space, and the point is to find a solution in configuration space that satisfies a workspace goal. ...
0
votes
0answers
7 views

(Unity) SetIKRotation - bone isn’t aligning with IKgoal

I'm setting the IKPosition and IKRotation of the LeftHand AvatarIKGoal to a transforms pos and rot, and the position is lining up correctly but the rotation isn't. It's strange, because in the IK goal ...
0
votes
1answer
41 views

Images disappear when camera zooms in

there is no problem when the camera is away, but as I zoom in to the game, the images disappear and I can't see the game properly. What is the reason ? enter image description here
0
votes
1answer
23 views

Unity Editor - Call a method from a ScriptableObject from its own custom Editor

I have a class like this: public class NoiseMap : ScriptableObject { public string Hello() { //... } } Now I am building its custom editor: <...
0
votes
1answer
31 views

How can the ball moving like billiard after collision with wall?

I tried ball.velocity = Vector3.forward * speed and also *=-1 when the collision is occurred(It only works for straight way. But I want the ball movement be liked in photo. How can i do it? Thank you ...
0
votes
0answers
21 views

Fail to Start android service in android studio Unity

I have written a service file in android studio like: Manifest file: ...
1
vote
0answers
24 views

Hard coded triangle in HLSL geometry shader doesn't show on screen

In Unity I'm planning on using a geometry shader for processing points into quads and can't quite figure out why I'm not getting output from my geometry shader. I've edited it down to a minimum ...
0
votes
0answers
42 views

Wrong movement with Inverse Kinematics?

I'm scripting character IK to look at object "enemy" direction. If enemy is above him, he look at enemy. The issue here is when enemy goes out of character range. Character should look forward, and he ...
1
vote
0answers
27 views

Unity Shader: Make water on terrain transparent without fading

I want to create a shader for a terrain to make the water fully transparent but not invisible or faded. In this example I would want the purple square to be seen through water but not through the ...
0
votes
1answer
58 views

A* Quad/Oc Tree path-finding vs Navigation Mesh path-finding

Main What are the differences between those path-finding algorithms. Is Navigation Mesh faster in finding the path? Is it more correct than Quad/Oc Tree? Does Navigation Mesh use Quad/Oc tree under ...
1
vote
2answers
46 views

Detect Collisions While Dragging 3D Game Object

Hello i am making a game in which i have to drag a sphere on x axis and z axis on a plane with my mouse and i have created walls from cubes so that my sphere not go anywhere else in the game but while ...
0
votes
0answers
22 views

Prefabs imported from asset bundle are not lighting properly

It only happens in my main game project. I've tested it in 2 other empty projects, both in multiple versions of unity (2018.3.0f2 and 2018.3.2f1). The strange thing is that if I look at the material, ...
0
votes
1answer
54 views

Why does the drag fail when I move too fast?

I got this code that drags a 2d sphere when i touch the screen: ...
0
votes
0answers
36 views

Unity3d getting terrain height

I am making an RTS game in unity like Total War games. As for rendering I am using Graphics draw mesh instanced method and after culling a I can easily render massive amount of soldiers on battlefield ...
2
votes
1answer
34 views

is there any method to simply ignore some files in unity build?

as im trying to build my new app on unity android specially when i want to use gradle, there is always some conflict with manifest or libraries and ..... for debug and problem exploration i need to ...
1
vote
0answers
49 views

How can I avoid jitter when working with a 2D movement system?

How can I avoid jitter in Unity? Let's suppose that I want to create a 2D movement system using a Rigidbody 2D(Dynamic), and I want make the camera follow the character (which is a pixel art sprite)....
0
votes
1answer
72 views

Loading a list of items from JSON, all entries are null

(I posted a very similar question here recently and the response I received was helpful. But I have been advised to start a new question, and here it is.) I am developing a Unity game which includes ...
0
votes
0answers
24 views

When the motion button is pressed, the shape of the character changes and always goes to the left direction

good day. When the motion button is pressed, the shape of the character changes and always goes to the left direction. Why is this happening and what is the solution? Pressing two buttons moves to ...
0
votes
1answer
27 views

Asset Bundle hashing technique question

The flow I see people discussing using is the following In your build asset bundles step, grab the hash of each bundle Store that on your server somewhere Fetch those hashes at runtime Use the ...
1
vote
1answer
35 views

Camera to the right from the character

I'm trying to create a camera like in Fortnite or Gears of War. It's focus must be to the right side from the character: But when I rotate the camera, the character slightly shivers. Lerping and ...
0
votes
1answer
29 views

Unwanted left-right rotation in run animation imported from Mixamo

A humanoid run animation I downloaded from Mixamo is working fine on their site and in Blender. When I import it into Unity it shows a strange movement: the full body is rotating left & right in ...
0
votes
0answers
32 views

Unity - Bullet spawns in wrong position in client

I am making a multiplayer game with prefab shooting, but unfortunately the prefab sometimes spawns in the wrong position when I shoot from a client. The bullet ...
0
votes
1answer
64 views

Adding text to gameobject

I'm trying to create a falling word game like z-type (code here). I have created 3 game objects and I want the words to be added as text to these game objects something like a health bar is added to ...
2
votes
1answer
55 views

UI/Menu that works with and without VR (Unity, WMR)

I'm working on an app that I want to be useable without and with VR (with a Windows Mixed Reality HMD like the Samsung Odyssey). For non-VR I'm simply using a canvas in "Screen Space - Camera" and a ...
0
votes
0answers
54 views

WHY !! CountDown not Working inside the IF Condition? [duplicate]

i need a way to make the countdown decreasing inside the if statement i am stacking in this problem for more than 3 days .. Don't suggest to me Coroutine cause it will not working in my case cause i ...
1
vote
1answer
26 views

Lightweight NON-dynamic particles in Unity

I know Unity has an advanced system for managing complex dynamic particle systems with a few thousand elements (Shuriken). Does Unity have a more lightweight way to create a very, very large (several ...
0
votes
0answers
32 views

When using Prefab Mode only one game object is adjusted while the others need to be manually selected in hierarchy window for changes

I created a bezier curve prefab using the code in the post How to create an illustrator/photoshop-like pentool for creating bezier curves in Unity. I added a few copies of the prefab to my scene. When ...
0
votes
1answer
37 views

SerializedProperty to UnityEvent in a Custom Editor

I am making a Custom Editor for a type that includes a UnityEvent property. I'm currently facing an issue in converting a SerializedProperty to get that UnityEvent. Here is how I declare the event ...