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
0answers
19 views

Unity 4.6: sprite image automatically splits to single sprites when clicking

I'm viewing Unity tutorial. As in this tutorial, I see when author clicks to sprite image, they will automatically divide to each frame as below: But in my Unity, I just can view this: So. My ...
0
votes
0answers
83 views

Most efficient way to achieve the following 2D heat wave background effect?

In Unity, what would be the most efficient way to achieve the following heat wave background effect Super Metroid - SNES (skip to 34m 5s for those on mobile) http://youtu.be/yB317FOcU0Y?t=34m5s ...
0
votes
2answers
63 views

How to make instantiated objects not on top of each other?

I randomly instantiate game objects, to create a dynamic "sky map". But some planets appear on top of another ones. I'm trying to solve this problem with Collision detection and Colliders, but it ...
-1
votes
2answers
69 views

Where to start developing a 2D puzzle game [closed]

I would like to start developing a 2D puzzle games, much like sudoku for example. I would like to publish it on Facebook and on gaming websites, like miniclip, agame, kongregate. The game should have ...
-1
votes
2answers
75 views

Rotating an object continously with OnMouseDown

I have a script that works but it does not do what I want it to do. My script makes an object rotate on when another is clicked. However, I want the object to continuously rotate until I click on the ...
0
votes
0answers
15 views

Rotating an object continously in UNITY with onclick [duplicate]

I have a script that works but it does not do what I want it to do. My script makes an object rotate on when another is clicked. However, I want the object to continuously rotate until I click on the ...
2
votes
1answer
76 views

Unintended sliding blocks Unity (5) physics

A game I'm working on right now relies on the Unity physics system for collisions, gravity etc. This all works well except for one strange thing. When an explosive is placed on a stone cube, it'll ...
4
votes
1answer
66 views

Is there a way to check android version running the game using Unity3D?

I want to separate code to run only on android 4.4 or higher. If it's lower, I do not want to run this code. What should I do?
18
votes
3answers
2k views

Should independent game developers target older hardware?

A developer I work with tells me that indie developers should target hardware that is around six or more years old (at max settings). I get the idea that one should allow everyone that wants to play ...
1
vote
0answers
50 views

How can I get shadows to appear correctly when using a custom projection matrix?

As mentioned in this thread, I'm using a custom projection matrix in Unity. Unfortunately, this breaks the default shadow system in Unity. Thus, I was wondering if anyone knew how to possibly ...
2
votes
1answer
32 views

Interfacing with bill/note acceptors in unity

What ways are there to interface a unity game with a bill acceptor/validator? Usually this type of devices are connecting to a computer using a serial port and communicate over ccTalk protocol. But ...
1
vote
1answer
50 views

Play vs. PlayOneShot

For Unity AudioSource objects, what is the difference between the Play and PlayOneShot methods, besides their method signatures? Is it simply that PlayOneShot won't stop an already playing sound from ...
0
votes
0answers
42 views

How can I handle ball interaction with lanes in a pinball game?

In a pinball game, how can I handle collision or constraints on the ball for convincing movement on those highway rails/tracks? I assume using physics and a mesh collider would not work, even when ...
1
vote
1answer
43 views

Importing code from unityscripts

To encourage code reuse- i want to import methods and classes defined in my core unityscripts to be imported into other unityscripts. How do i go about this? Note: An answer here seems too ...
1
vote
0answers
21 views

Unity 3d Animation Flickering

We are using 3d bus model for our game in Unity 3d.Animation works perfectly fine on Samsung s3 but some kind of texture flickering occurs on Nexus device.Please help us out how to solve this problem. ...
2
votes
0answers
61 views

Basic Node Based Pathfinding

I am new to pathfinding but i have read and watched through some articles, blogs and videos about Pathfinding. Since those that i have read and watched from are mainly for RTS Games, Grid Based ...
1
vote
1answer
35 views

How to write testable MonoBehaviour and test scripts in Unity?

I had problems with decoupled scripts and exposing interfaces in Unity, and these answers helped me a lot. But now, since I don't have hard-coded references in my scripts, I wanted to write unit tests ...
1
vote
1answer
30 views

Unity polymorphism in editor through a list

So I have an ItemDatabase class which basically only has a list of Item public class ItemDatabase : MonoBehaviour { public List<Item> Items = new List<Item>(); } The Item class ...
1
vote
1answer
21 views

Detecting a 3 x 3 grid and extracting its coordinates using Kinect

I'm interested in creating a DDR (dance dance revolution) game using unity3D and Kinect. However I need to do this without actually using a pressure sensor pad, just a mat with grids and numbers on ...
0
votes
1answer
50 views

Can Java be used for developing games for Android in Unity3D [duplicate]

I only know Java Programming Language and no other. Can I develop games for Android in Unity3D using Java?
0
votes
1answer
76 views

StartCoroutine inside TriggerOnEnter2D isn't working

I am new to this, but I need help with a CSharp script. I need to collide with the desired object, pass the game to be 1.6 in TimeScale. After passing 8 seconds in the game, change back to 1 ...
1
vote
1answer
31 views

Lists of concrete types show up in inspector, but not lists of interfaces

In one of my custom C# classes in Unity, I need to expose a List of objects in the inspector, and they need to conform to a specific interface. Below are two lines from my class definition. Card is a ...
1
vote
0answers
16 views

Unity Javascript GUI.Button shows up twice

Hi I have created a simple menu in Unity but I wanted to create my own style for colour/fonts. However for some reason it prints each button twice to the screen, once with my custom style, and once ...
0
votes
0answers
25 views

Unity 5 Animator controls - What are their Unity 4 correspondent?

I am following a tutorial that is made with Unity 5, but claims to be compatible with Unity 4.6 I am working with the Animator panel, and I was wondering where could I find certain controls on the ...
0
votes
1answer
41 views

How to reference the right object in Unity

So, I'm developing this small 2D project where I have a sphere that detects if objects get close to it from three different directions. I have successfully found a way to detect if an object ...
0
votes
1answer
24 views

Animator Panel in Unity - Where is “Entry”?

I am following a tutorial on Unity, and I saw a screenshot like the following: When I reproduced the steps of the tutorial, I realized that the green "Entry" box was not present on my screen. I ...
0
votes
0answers
49 views

Generating a NavMesh / Point Graph for 2D Procedural Platformer Levels

I am trying to create an algorithm which handles a NavMesh / Point Graph Generation for 2D Procedural Platforms Level in Unity3D. The reason why I say NavMesh / Point Graph is I don't know which one ...
0
votes
1answer
51 views

Controlling roll rotation when travelling along bezier curves [Unity3D]

I am currently working on implementing a curve implementation for use in Unity which includes an editor: The aim is to get an object to follow the path represented by the curve at a constant ...
0
votes
1answer
28 views

Getting distance between point of an object and another object in Unity

First, I'd like to apologize because this is a very basic and repetitive question, but I am completely new to game development. I understand that I can find a distance between two objects using: ...
0
votes
2answers
86 views

Realistically drivable car

I want my car to be realistically drivable (like in real life...) Unfortunately all I did so far is Rotate the whole vehicle using A and D; and AddForce in forward-backward direction using W and S ...
0
votes
1answer
18 views

Maya keyframe animation to unity

Sorry guys! I am super new to this, and I'm trying to teach myself Unity. I have a very small knowledge of Maya from a 3d modeling course I took a year ago in college, and have made a very simple ...
0
votes
1answer
19 views

Unity joystick input acting strange

After setting up my joystick axes in Unity and sweeping them around I find that the Y-axis jumps to the opposite direction in certain positions. So, when I press up on the joystick, the input will ...
1
vote
3answers
67 views

unity destroy enemy when jumping on it

I am creating a 2D platformer using Unity3D, I want to have the player destroy enemies when it jumps/falls over them (just from the top). But I have been having problems trying to implement this. I ...
0
votes
0answers
22 views

What variables change the number of lightmaps

I need to know what changes the lightmap size for example what changes the lightmap from being 2*1024*1024 to 4*1024*1024 , having larger textures or having larger quads(having more models) or having ...
0
votes
0answers
45 views

How can I make several 2D objects move in complex pre-defined patterns?

I will be making my mobile 2D game in Unity and the objects in the game will have complicated movement. For example, there will be lots of squares (around 10-15 tiny squares) in the middle of the ...
0
votes
1answer
43 views

Are lightmaps also considered textures?

I want my game to support phones with max texture size of 1024 so my texture atlases are 1024. My question is: are lightmaps also considered textures and their max size must be 1024? Or they can have ...
0
votes
2answers
46 views

Checking if object passed between two other objects

I have a three objects (strikers), lets say red, green and blue. When I apply force to the green object I want to check if it has passed between red and blue or not. See the image below for an ...
1
vote
2answers
47 views

How can I create a precise touch in Unity

Is there a way so that I can touch an object precisely? I have these aerial cars and there pretty tiny like 32 by 32 and it's hard to touch them using a raycast. I thought I'd spawn an object with a ...
0
votes
1answer
71 views

Unity 4.6 UI button AddListener sets the same callback to all items in List

I have this method that is looping through a list and sets values on the current item in the list. Everything works fine the lists values are correct exept the AddListener. All listeners on the ...
0
votes
1answer
50 views

Position GameObject sprite where I tap on the screen

I can't do one of the simplest things. When the player taps the screen, I want to put my sprite in that place. public class Controller : MonoBehaviour { public GameObject ball; // A GameObject ...
0
votes
1answer
48 views

Unity3D - How do I make so when user moves the camera it doesn't go beyond the scene borders?

How do i make so when i move my camera, it doesn't go beyond the border of the canvas while playing. This is the script i use to make the camera move: if (Input.touchCount > 0 && ...
14
votes
6answers
1k views

How can I avoid tight script coupling in Unity?

Some time ago I started working with Unity and I still struggle with the issue of tightly coupled scripts. How can I structure my code to avoid this problem? For example: I want to have health and ...
1
vote
1answer
94 views

Is there any way of creating primitive 2D shapes in unity?

I have read the whole unity manual and watched the videos on sprites but I have a question. Is there any way of creating primitive 2D shapes in unity? (I will be assigning trigger colliders to these ...
0
votes
1answer
61 views

Find closest point on NavMesh if current target unreachable

I have a mock environment set up with a cube that has a specified "Not Walkable" layer. I'm using NavMeshAgent and NavMeshPath to set destinations of the player. The way I'm setting paths is by ...
0
votes
1answer
20 views

Fb.Feed dialog closes before saving

I'm having trouble with the Facebook UnitySDK when I use the FB.Feed() method for posting on user's timeline. The share dialog closes before the post is completed, Right after i press the "Post" ...
1
vote
2answers
62 views

Camera.WorldToScreenPoint not working with perspective

transform.position = Camera.main.WorldToScreenPoint( new Vector3( origin.position.x, origin.position.y, origin.position.z ) ); I have this code on a Unity 4.6 UI object. The origin is some transform ...
1
vote
1answer
34 views

NavMeshAgent.CalculatePath - how to use properly?

I seriously can't figure out how to use this function, and the documentation doesn't help at all. Here's the documentation code: public class ExampleClass : MonoBehaviour { public Transform target; ...
1
vote
1answer
65 views

OnMouseUpAsButton not always called

I'm working on a 2D implementation of Free Cell in Unity 4.6.1, and I'm having trouble getting my click-detection code working consistently. The code below should be called every time a card is ...
-1
votes
1answer
87 views

Can one sell the game made in unity free version? [duplicate]

I'm just getting into it and soon my first project will be done. Can I sell it afterwards?
5
votes
4answers
410 views

Difference between Update method and FixedUpdate in Unity?

i am starting to learn Unity3d and one of the confusion i get is difference between Update() and FixedUpdate(). I am following Lynda Unity 2D game development tutorial there, the instructor uses ...