Unity is a highly cross-platform engine that focuses on easy art pipeline process and uses Mono as its scripting back end.

learn more… | top users | synonyms (1)

2
votes
1answer
75 views

Accessing the command line from in-game?

Is there a way to interact with the command line (Linux/Windows) from in-game using a game engine such as Unity or Unreal? I would like to have the user be able to jump on a console or even just ...
1
vote
1answer
80 views

Unity3D: terrain object's textures flickering on long distances

I'm making RTS project on Unity3D. I created terrain with Unity's standard Terrain tool, and added textures of grass, mood etc. on it. Then, for creating "man-made" objects of terrain (roads, ...
6
votes
0answers
140 views

Unity: Why do my normals flip during an animation?

This problem boggles my mind. I have an animation running on a face object (imported from Blender). At a few points in the animation, the normals switch direction! It causes the mesh to blink. Of ...
1
vote
2answers
268 views

(2D) Detect mouse click on object with no script attached

I'm creating a 2D project which does not have a character. So i created an empty gameobject and attached the script to it. In the script, i have declared other objects which are in the scene like ...
2
votes
1answer
38 views

How can I display Unity games in Flex?

We have tried the following methods to upload sample Unity3D build to a desktop application in Flex: HTML Loader, NavigateToURL, iFrame and resolvePath. But we only see the text content, not the 3D ...
-2
votes
1answer
56 views

Not able to destroy the prefab

In the code, everything is working smoothly, only problem I am facing is that the Destroy(fuelprefabInstance) is not getting Destroyed in OnTriggerEnter Method though the print statements are clearly ...
1
vote
1answer
66 views

Creating charging particles using Shuriken

I've been trying to create a charging effect using the Shuriken Particle system for the longest time, and I've had little to no luck with it. I've tried setting different curves for the Force over ...
1
vote
1answer
88 views

How can I calculate the visible area of my camera in world space and take zoom into account?

I am trying to get the bounds from an orthographic camera in Unity which take into account the current orthographic size (zoom). I thought that I could use the cameraToWorldMatrix to transform the ...
1
vote
2answers
121 views

How can I do something only after an animation has finished?

I'm making this 2D platform based game. Basically what I want is when the player walks into spikes (which have a "deadly" tag") it displays the animation that has the parameter of animate with the ...
0
votes
1answer
149 views

How to calculate FPS and what factors affect FPS?

In this case, FPS means Frames Per Second and that means the number of frames that graphic hardware render in one second. I'm wondering what kind of stuffs could affect FPS? So, for some tests I ...
0
votes
1answer
43 views

Destroying the instance that instantiated the prefab

What I have so far: A fuel that has Fuel script attached to it. The fuel prefab is first instantiated from another script in its Start() method. problem: The Fuel script is such that it results in ...
0
votes
1answer
74 views

The object of type GameObject has been destroyed but you are still trying to access it

I am instantiating the prefabs time to time and I want them to be destroyed with in 2 to seconds as well. But I am getting the error that says: The object of type GameObject has been destroyed but ...
0
votes
1answer
34 views

Creating a prefab

Problem: The prefab script is never executed. What I did: Created a GameObject Created a prefab Dragged GameObject over the prefab Deleted the GameObject from Scene Added the prefab script to ...
0
votes
1answer
57 views

Unity create water issue

I use daylight water in my project but by the default it has not got any waves or light tracing effects. But in some tutorials I see how the user add standard water asset and it has got beautiful ...
3
votes
1answer
64 views

Unity: White line at camera meaning

I'm a new comer to Unity. In Unity, when I click to main camera in Hierarchy view. I see 6 lines: one blue, one red, one green and three white. I know red/green/white lines for (x,y,z) location but I ...
-4
votes
1answer
81 views

Which programming languages can I use with Unity?

I am fairly familiar with Unity and I know how to work most of the features within it. But I don't know what programing languages to use for my Unity game. I have heard that it might be C#, but I am ...
2
votes
1answer
136 views

Implementing Galaga Style Enemy Behavior in Unity

I've been trying to work on a space shooter with the idea of having enemies behaving like it is shown in this video : https://www.youtube.com/watch?v=3p7u8uCR6yw In the video above, enemies fly from ...
0
votes
1answer
120 views

Unity Physics Material - Character Slides Too Much

I am currently working on a 2D platformer in Unity. I am using a prefab from the AssetStore for my character (The last paragraph contains a link to the prefab). The character has a circle collider for ...
0
votes
1answer
34 views

How do I properly import an fbx 3D model into Unity3D?

I am trying to properly import a 3D model that was made for my game in Unity3D. I was able to import the model, and I put the texture on it, but there are several other files that go unused. I think ...
3
votes
1answer
256 views

Rotating a GUI.Label relatively

Learning Unity for 2D development, I want to create a text label. So far, I have been using GUI.Label to write the text. It is above my sprite: I would like to rotate the label relatively to the ...
0
votes
1answer
62 views

Decentralized Matchmaking in Unity?

I'm making a card-playing game, similar to Magic Workstation. I've been looking into several options for networking. I have a working LAN version with the build in Unity networking, as well as Photon ...
0
votes
3answers
98 views

Minecraft Type Game Support Blocks

OK I have a game that is similar to minecraft in a sense. Players can build castles block by block. I'm using Unity3D and Photon Network for my game and I was wondering how I would handle detecting if ...
0
votes
1answer
221 views

Unity 2D, C# - Make object move diagonally by a certain angle?

I have a sprite object which I want to move in 8 directions. Left, Right, Up, Down, Left top, Right top, Left down, Right down. The view is 2D with a isometric projection. The difficulties I am ...
0
votes
2answers
97 views

How to give a Jerk Effect when the player is moving left of right

float amttomove = Input.GetAxis("Horizontal") * playerspeed * Time.deltaTime; transform.Translate (Vector3.right * amttomove); Currently, I have above script in Update function to move ...
-1
votes
1answer
53 views

Moving an object continuously when left or right key is pressed

I want the object to move continuously as long as key is pressed to left when left arrow is pressed and to right when right arrow is pressed. Instead of moving continuously it moves first time and ...
0
votes
1answer
47 views

Incosistent jump, stuttering

I've written this C# code to handle movement in my testing project. The game is supposed to be 2D, some kind of a platformer, just to get me started with Unity. However, it seems there's something odd ...
0
votes
1answer
81 views

Working with retina graphics on Unity 2D

I begun trying Unity for iOS 2D development. I am curious about how to work with retina devices. The first thing I did was create a 1136x640 solid rectangle sprite and throw it into my scene, then ...
1
vote
0answers
73 views

How to use an A* Pathfinding System across uneven environments?

I am developing a game in Unity3D. I want an enemy character to follow the player around. The problem is, my surface is uneven and full of mountains. I am using aarongranberg's pathfinding project. ...
-1
votes
2answers
93 views

how would I go on about making a movement system like mario party

main question how would i go about getting a movement system similar to the one they have on mario party only minus the dice roll things i have researched so I have been studying the uses for ...
0
votes
2answers
40 views

Monobehaviour can not find a member OfType in Unity

This is the line where I am getting above mentioned error: var listeners = FindObjectOfType<MonoBehaviour> ().OfType<iPlayerRespawnListener> (); I have already imported these libraries ...
1
vote
0answers
44 views

How to make a text of several letters animate, only with an animation

I wonder if it is possible to create an animation in a text with a single "animation". The problem is that for me to reach the desired effect I need to create an animation for each letter, as each one ...
0
votes
2answers
229 views

Is it possible to use C++ with Unity instead of C#?

The title kind of says it all. Is it possible to replace C# with C++ on a game using Unity?
1
vote
0answers
81 views

Unity Animator State Freezing

I am really new with Unity, I am making a game, but I am having some problems with the animators, my problem is that I am trying to add some animations to my menu, and also add new characters to my ...
0
votes
0answers
35 views

Text within a gameObject boundries

I am working in a little project and I want to show text within a rectangle. for that I use a sprite(rectangle) and a child that contains a TextMesh as component. The text change during runtime, and ...
-1
votes
2answers
109 views

Does Unity have a built in pathfinding system?

I know that there a lot of plugins available for pathfinding in unity but I was just wondering if unity has a built in pathfinding system ?
1
vote
3answers
164 views

How to create sprites, programatically without using prefabs?

I have different types of images for different sprites. and i am not certain that how much different sprites(images) i will have to show. So, i gotta create the sprites and apply textures ...
0
votes
1answer
152 views

What is the best type of c# timer to use with a Unity game that uses many timers simultaneously?

I am developing a stand-alone 3d game in Unity that will have anywhere from 1 to 200 timers running simultaneously. There will be a GameObject containing 1 timer. For this game timer durations will ...
2
votes
2answers
333 views

Keypress Left is called twice in Update when key is pressed only once

I have a piece of code that is changing the position of player when left key is pressed. It is inside of Update() function. I know, Update is called multiple times, but since I have an ifstatement to ...
1
vote
0answers
132 views

How to implement efficient Fog of War?

I've asked a question how to implement Fog Of War(FOW) with shaders. Well I've got this working. I use the vertex color to identify the alpha of a single vertex. I guess the most of you know what the ...
0
votes
0answers
51 views

How do I check user's unlocked achievement and leaderboard scores via GPG plugin

I need to load user's achievement and their scores from leaderboard in my game. But the Social.LoadScore() and Social.LoadAchievements() both returns a 0 size array in callback. When I checked the ...
0
votes
2answers
159 views

Set new forward directions based on camera position

I have a 3rd person camera which can rotate around the player. When I look at the back of the player and press forward, player goes forward. Then I rotate 360 around the player and "forward ...
3
votes
2answers
141 views

How can I dynamically load the correct sprite from a sprite sheet?

I am making a simple card game in unity. The game is based on a standard 52-card pack, with identical backs for unique faces. In my particular game different cards are worth different values and have ...
0
votes
0answers
32 views

Ouya build experiencing odd graphical artifacts, screen half black

I'm witnessing very odd graphical artifacts when I run my Unity game on Ouya. After the Unity splash screen, the game loads with the screen half black. This seemingly has started occurring out of ...
1
vote
0answers
58 views

Having a hard time having consecutive animations for an attack [closed]

So I've been trying to figure this out for about 8 hours now...It's driving me nuts because I am pretty sure that it is something dead simple that I am just not understanding. I had everything working ...
2
votes
2answers
268 views

How to implement Fog Of War with an shader?

Okay, I'm creating a RTS game and want to implement an AgeOfEmpires-like Fog Of War(FOW). That means a tile(or pixel) can be: 0% transparent (unexplored) 50% transparent black (explored but not in ...
0
votes
3answers
87 views

Unity, Unrealistic Sphere On Inclined Plane

So I am trying to model a ball rolling down an inclined surface in Unity based on what I am observing in real life but it is still quite off. In Unity it takes the ball about 3 seconds to travel ...
0
votes
1answer
144 views

Why do camera's aspect ratio look good on computer but not on Android devices?

I'm developing a game for Android devices and I have a script that solves the aspect-ratio problem for computer screens but not for my intended target platform. It looks perfect on computer, even when ...
0
votes
0answers
35 views

Scrolling background with changing textures

I have the 2 cubic structures that are my tracks and are scrolling basically to give effect of movement on object. In my OnBecameInvisible() method, I have changed their Tiling using mainTextureScale ...
0
votes
2answers
162 views

Material tiling and offset in unity

Ambiguity: What exactly is the difference between Tiling the material and Offset of material? Need to do: I need the material to be repeated n times on the object where I need to set the value of n ...
0
votes
0answers
30 views

Can Layer Masks Achieve This Effect

If you look at the image below you will see the player surrounded by a dotted yellow box. The dotted yellow box is also part of the player and represented a portion of the player being masked from ...