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.

learn more… | top users | synonyms (1)

0
votes
1answer
44 views

Displaying Trajectory Path

How can I display trajectory path exactly as in this image? I have used void OnDrawGizmos, but that only displays trajectory in the editor and without any arrows like shown below. Trajectory with ...
4
votes
1answer
104 views

Can I use two Collision Boxes on the same GameObject?

I have two Collision Boxes on the same GameObject. I don't want the Collision Boxes to be triggers. I want the Collision Boxes on the actual GameObject, not its children. For example, if I want to ...
0
votes
2answers
7k views

Can't play animation from script in unity

I'm making a 2D sidescrolling game in Unity, and when the player shoots an obstacle, I want the obstacle animation to play and then destroy itself. I got it to destroy itself, but the animation won't ...
2
votes
1answer
168 views

masking with 3d object in unity

I have a 3d plane in my scene and some 3d objects behind that plane. So, i want to render only the part behind the 3d plane. So how should I do this, should I have to use custom shaders, plz help.
0
votes
3answers
106 views

Unable to Set Text of another Text Object

The Idea: Pressing a button in the canvas will allow the player to select a race. A script is attached to an object which is accessed though the OnClick() function of the button. The script is ...
0
votes
1answer
49 views

Unity3D - post-process unwanted on UI

I have scene rendered with a single camera using target texture (a). Second camera is used to render UI and using same target texture (a) as the first one. Third camera takes target texture (a), ...
0
votes
1answer
24 views

How to adjust the width of a LineRenderer

I wrote a code that draws a line by mouse movement. I am searching for some way to give it pencil style and head and end of the line have thinner width. As we know the LineRenderer draws the line ...
0
votes
0answers
29 views

WWW & crossdomain

i'm trying to use the WWW class to connect to a restful service located on a server. The service i'm trying to connect to is located to a specific port (8080 in my example), and my application cannot ...
0
votes
2answers
688 views

Using Appendbuffers in unity for terrain generation

Like many others I figured I would try and make the most of the monster processing power of the GPU but I'm having trouble getting the basics in place. CPU code: using UnityEngine; using ...
0
votes
1answer
20 views

Unity - Toolbox pattern is not safe

When I create a toolbox such is in this tutorial. How do I defend against breaking the pattern with multiple instances like this: gameObject.AddComponent<Toolbox>(); ...
1
vote
0answers
16 views

How to receive broadcast message in Unity?

I am trying to get the broadcasted message in overridden method of NetworkDiscovery.OnReceivedBroadcast(). For that what I had done is below: I create class which implements NetworkDiscovery where I ...
1
vote
2answers
35 views

How to dynamically create an UI text Object in Unity 5?

I have been searching for something that should be simple, but Unity 5's documentation on that is fairly outdated. What I want to achieve is to be able to create UI Text totally from script, i.e. ...
2
votes
2answers
63 views

Efficient use of pathfinding

I'm doing a post-mortem on my game project, and this problem kept bugging me as my team couldn't solve it throughout. So my game is a pure 2D top-down shooter built with Unity3D, with enemies ...
1
vote
0answers
22 views

How can i create a 2 player turn-based board game on a separate android device using unity?

im trying to make a 2 player turn-based board game, i have already made the connection between 2 device. I used photon. They both connect but i don't know how to sync them both to the game. can any ...
0
votes
1answer
39 views

Use constant force to hold something in position

This may actually be more of a Physics.SE question but since im doing this in Unity I figured I'd ask here. I am playing around with the Constant Force component and have a sphere constrained with a ...
0
votes
2answers
3k views

Play animation when click on each player with in maincamera unity3d

I have 3 gameobjects (player1, player2, player3). I attached a script "playerscript" to these game objects. In the main camera, I have added another script called "testscript". Clicking on a player ...
0
votes
1answer
129 views

Continuous Jumping Cycle

The script makes a GameObject jump using realistic gravity and reach a specific target. The GameObject jumps relative to the target, thus adjusting its trajectory. It also works while the target point ...
1
vote
3answers
145 views

Unity Click make Jump and Pause

I use Unity 5 and I have an issue with my game, when I click on the Pause button my character jumps before the game is paused. My script detects the click for jump before the pause button so for that ...
-2
votes
1answer
10 views

NavMeshAgent in unity not working

I am making a game in unity and it is throwing the error "Failed to create agent because there is no valid NavMesh" and i don't know what the problem is. using UnityEngine; using ...
0
votes
2answers
39 views

How can I mass-duplicate or “paint” Unity objects?

Let's say I have a basic map with a single box on it. I want to make many, many more of these cubes, so they can cover a large portion of the map, like this: Each box needs to be exactly one ...
0
votes
2answers
294 views

Why can't I store a value in transform.position.y?

Well I have this line of code Vector3 pos = cell.CellPosition; float light1Height = 10f; pos.y = light1Height; lightGameObject.transform.position.y = ...
0
votes
3answers
80 views

A method to create and assign a name to a GameObject (Unity)

I'm trying to create a function that takes in a name of an object in the editor and assigns this accordingly as well as the name of a sprite, rigidbody, etc. Basically what I have so far is- ...
-2
votes
1answer
62 views

Destroy object on Collision

I have a strange problem... I need a 2D projectile to destroy itself after colliding with an object. I have used all of the different ways to do this on the internet but to no avail; the object ...
0
votes
0answers
26 views

Script getting unchecked upon running

I have a script attached to a game object, with the following content, but when I press play, the tick next to the script component disappears. I cannot figure out which line in the script is ...
0
votes
0answers
25 views

AddExplosionForce issue? [duplicate]

AddExplosionForce doesn't do anything with this script, even though a RigidBody is added to each CubeParticule... What's the problem? using UnityEngine; using System.Collections; public class Force ...
0
votes
2answers
292 views

Unity PHOTON/PUN Collision Detection

I am trying to create a virtual 3D chat room based on character interaction (just like in Sims2), so I have added a collider on the "user's in-game character". The problem is that when I enable the ...
2
votes
1answer
70 views

Unity3D Pathfinder with Crossings

I'm trying to bring traffic on my street system. The main problem for me are the different lanes and crossings and to make it complete the different types of paths. I've tried a bit with the ...
3
votes
2answers
58 views

Problem with trigger

I am making a melee attack with my game, but I'm stuck in a problem related to using triggers. The enemy NPCs have a sphere collider set on trigger so I will know who is inside their range (radius of ...
0
votes
0answers
10 views

How do i integrate a android camera into a google cardboard viewing mode. For AR purposes

simply i want to have a stereoscopic view (like google cardboard) but through my camera and i want to add AR stuff in it. Is there a tutorial on this or some tips. ive tried too search for it and alas ...
0
votes
0answers
42 views

How To Create Xbox One Games for Free (Independently) [on hold]

I was wondering how to start creating video games or apps for the Xbox One without having to pay fees, etc. I've tried Unity, but can't find how to export to Xbox One. ID@Xbox is cool, but looks like ...
0
votes
1answer
18 views

Unable to open project from a scene.unity file

The tutorial I'm following has provided its project files, and I'm trying to open them in Unity. Here is the project download link. You can also go to the tutorial webpage and scroll down to download. ...
3
votes
1answer
51 views

How can I turn off the sound from another scene?

I attached music file to my first scene and thanks to following javascipt code, sound continues without stopping in other scenes. public static var object : SingletonMusic = null; function Awake() { ...
-1
votes
0answers
28 views

AddExplosionForce not working? [on hold]

AddExplosionForce doesn't do anything with this script, even though a RigidBody is added to each CubeParticule... What's the problem? using UnityEngine; using System.Collections; public class Force ...
-1
votes
2answers
18 views

NullReferenceException Error? [on hold]

I'm getting the following error when I run the code below: NullReferenceException: Object reference not set to an instance of an object GameObject Particules; void Start() { ...
0
votes
1answer
196 views

UNET start game with friend by finding their name, Android

There is a game at the google play store called Fun Run 2- Multiplayer Race. I loved its feature to find friends by writing their names, and then to play with them. Is it possible to achieve that with ...
-2
votes
1answer
33 views

How to make my “first person controller” continue to turn left or right when key is pressed in Unity 5?

I recently posted this How To Make My First Person Controller turn left and right in unity 5 but now I'm having a slight problem when I press the key that turns my camera it only does it for a little ...
0
votes
0answers
24 views

Voxel tutorial NullReferenceException: Object Reference not set to an instance of an object

I'm working my way through this voxel tutorial in Unity. I'm on part 3, and it's showing me how to create a chunk within the world. I've copied the code, but I think I am missing something. The error ...
0
votes
0answers
18 views

Unity3D - Upload a image from PC memory to WebGL app

I need user to upload his(her) avatar picture from PC to game How can I create a file dialog and upload a image to WebGL game?
-1
votes
0answers
50 views

How to implement good GUI design in Unity? [on hold]

I am new to game development in Unity. I would like to know how we can create an animated GUI similar or exactly like the one below?
0
votes
1answer
46 views

ARMv7 vs FAT in Unity Android Build Settings (release multiple valid APKs)

If I select ARMv7 instead of FAT (ARMv7+x86) in the Android Build Settings of Unity5-Free, the APK binary drops to half size. FAT => ~20MB ARM => ~10MB (Tested with an empty scene, no assets, ...
3
votes
3answers
188 views

How do you apply relativistic physics to a 4x strategy game?

I had the big idea of trying to create a hard science fiction 4x strategy game (with the obvious space setting), which is supposed to simulate a realistic way of creating interstellar societies while ...
-5
votes
1answer
43 views

Which Language for Suitable for Develop game in Unity? [on hold]

I am starting to Develop a game in Unity.I have good knowledge in Java and Android. In Unity ,only C# and JavaScript are used. I know Java,I get confused in Choose a C# or JavaScript.Give me ...
1
vote
1answer
62 views

How to remove destroyed clones out of the Hierarchy in Unity2D

I made a 2D edge collider which on contact destroys the other gameobject. When I launch the game all the other gameobjects in fact get destroyed but the clones are still listed in the Hierarchy. How ...
0
votes
0answers
42 views

Unity 5 Command not being sent

I have a client server build in Unity 5. I want to send a command from the client to the server with a GUI button click, this is for testing purposes. So on my client all I want is to click a button ...
2
votes
2answers
12k views

How to add a UI Text for keeping Score in Unity 5

My Problem is simple I want to show scores on my game. The examples on internet are good but in Unity 5 there are no GUI elements but instead these are now UI elements. I was following this example: ...
1
vote
1answer
63 views

The type or namespace name `OpenCVForUnity' could not be found

I am working on face traching in unity3D I have downloaded and imported the sample project on "FaceTracker Sample using OpenCV for Unity". But when I tried to runned the project,its showing me the ...
2
votes
2answers
84 views

Unity Ragdoll Colliders don't collide

I have a humanoid character with Ragdoll setup in Unity. However the box/capsule colliders on the various parts of the body don't collide with other static geometry. They do collide with the ground ...
0
votes
2answers
39 views

Code Logic's execution with respect to time Events

I have to show complete 24 hours cycle in Unity3d Scene. Where different kind of task will be executed in different Times. Suppose at 2pm I have to move a car, at 6pm An Aeroplane will land on ...
0
votes
1answer
313 views

Unity5 TextAsset not functioning in WebPlayer

Preface I am working on a 2D Platformer in Unity5 utilizing TileMap techniques. I have a working system to read "Room Tile Data" from JSON files with the Unity TextAsset Class and the Newtonsoft ...
0
votes
0answers
22 views

Blender to Unreal or Unity - will combining animations into one clip for a parent object to store effect workflow?

Hey so I have a gun and a set of rigged hands in blender, and I was wondering if I made a parent object for the gun, hands and everything, took all the animations respectively (such as right hand ...