Misbehavior with Quaternion.Slerp
Hey guys! I need some help over here. I have this script for a flying plane: private Vector3 MousePosition; public float moveSpeed = 20; void Update () { if (Input.GetMouseButton(0)) { MousePosition =...
View ArticleFixing Quadrilateral Edge Cracks
I have a procedural terrain generation system going with a quad tree LOD system. Basically I have a sphere of quadrilaterals (which are separate game objects) at different levels of "subdivision"...
View ArticleCount Objects with specific colour
Hello Unity Answers. In my scene I have 20 cubes for witch I specify a colour through java script on mouse click. Each of them have a tag "Tile". How do I filter GameObjects[] list to count objects...
View ArticlePrefab rotation not correct
Hi I have a object pool that instantiates 10 prefab enemy objects at the top of the screen. The player object, which is also a prefab, moves along the x-axis avoiding contact with the enemy objects...
View ArticleShowing Multi Mouses on Screen
Hello Guys, I've started a new project like http://team.forsvarsmakten.se/english for crossplatform. I want to know how can i show multiple cursors on one screen ? like this : ![alt text][1] [1]:...
View ArticleIs possible to force my game to run in a spesific OpenGL version?
I need to run my game in OpenGL Vr 2.0 or 1.1 . Is there a way to achieve this in Unity Editor and in my game? ps: In Unity editor itself. Running the following path instead: "C:\Program Files...
View ArticleToggle GuiTexture
Hello, I have been working an an mute/unmute button in the game. The problem is that it does not toggle correctly when pressed. When i press it apparenty it gets togggled both on and off at the same...
View ArticleAssociate a data object to Monobehaviours with generic
Hi, I can't figure out my problem. I would like to add a ***Data*** object in some of my MonoBehaviours. So, i have created an abstract class like this public abstract class DataMonoBehaviour :...
View ArticleHiding parts of mesh but only on defined objects
Hi, I need to be able to hide parts of certain meshes in the scene by putting another mesh/object in front of them. Hopefully this illustration explains what I mean: ![alt text][1] So there would be 2...
View ArticleThird person controller Tempbuffer error
Hi, I was trying to put the default Third person controller script on one of my objects, when suddenly I got this error: m_TempBuffers[i] == NULL UnityEditor.DockArea:OnGUI() It almost completely froze...
View ArticleMesh Renderer not always disabling
Hello, I am trying to disable a MeshRenderer displaying text when health on the parent object reaches 0. This seems to work when the GameController class first instantiates it and then sets its health...
View ArticleMeshCombineUtility
These errors have suddenly popped up, they are stopping me from testing and building my game, can anyone help? Internal compiler error. See the console log for more information. output...
View Articlehow to make my character Respawn?
i am creating a FPS survival game in which you kill zombies and monster an it has a pretty big map so i can“t fall down i have 100 health and when it reaches 0 i just fall down on the ground and...
View ArticleLocal scale problem
I am trying to scale object in xy by 30 over one second and then scale it down by 30 over 1 second and over and over again, but no mether what I do my script dont work. I need javascript. I cannot post...
View ArticleLoad single texture atlas for multiple sprite
Recently, I am developing sudoku game. For this, I have created multiple grid 9x9,12x12 and 15x15. For this numbers are repeated so multiple sprite renderer are created and it load same number texture...
View ArticleRaycast Rotate Help
i try to rewrite this code from sample assets because i want to raycast from the right and left side but the raycast doesn't rotate with the player // Ground Check: // Create a ray that points down...
View ArticleTwo identical if statements. Only one works. Why?
Ok so this has been bugging me for a while now. I've got two identical if statements, both in OnGUI, running one after the other. Yet only the second one works :...
View ArticleGrabbing an object from array
Ok bear with me here, I'm only a few months into programming and I'm trying to pool my first object/array. With this function I'm trying to - select a random spawn point (spawnChoice) - select the...
View ArticleMysterious behaviour of moving sphere
I'm trying to write a first simple game, as a learning exercise. So far, it's just a small ball rolling randomly on a large plane. It is more or less working. But I have a couple of questions about its...
View ArticleInstantiating NavMesh Agent SetDestination Error
**Short Version:** I'm getting this error: "SetDestination" can only be called on an active agent that has been placed on a NavMesh. EnemyAI:NewDestination(Vector3)(at../EnemyAI.cs:36) - I do have a...
View Article