Tag Editor is all grayed out
I'm using Unity 5.5.0xb1 on Ubuntu 16.04 My problem is that I can't edit nor create tags. So does anyone have any idea why it's happening or anyone who faced this before? Here's a screenshot below:...
View ArticleCan't tag prefab with a string
Hi, I'm trying to add a simple string tag to my prefabs: if file name suffix is "_NC", i want to add the tag "Choose". I looked online and so that all I have to do is prefab.tag, So I wrote the...
View ArticleFind closest object with a certain tag
Im trying to find the closest object from a gameobject to another gameobject with the tag "Blocks". How would I do this?
View ArticleTag an gameobject at runtime after a condition completed
Hi, I want to change tag of an gameobject at runtime after a condition completed. I use: gameObject.tag = "Myothertag"; but it doesnt work How I can do fix it? Thanks, In this example, my condition...
View ArticleHow do I pickup multiples of the same item with the same tag?
Hello, I'm very new to C#. I know the answer to this question may be obvious for most, but I'm stuck at the moment. I wrote a "PlayerHealth/Damage Script". So far, it just has one type of damage, and 4...
View ArticlenullReferenceException when comparing tag in a search for a specific parent....
below is my function i wrote to find a parent with a specific tag. its resulting in a nullReferenceException. here are the specifics of the the gameobjects and their tags. I will start with the child....
View ArticleWhy wont my raycast compareTag properly?
I have a ray that shoots out, if it hits anything it spits out a public string of the gameobject it hits and the distance to it. But to refine it, I created a Tag named "Target", tag my game object I...
View ArticleDocumenting objects/tags/code: best practice?
Hi folks, Im wondering how to best document code, tags, objects and the like - inside Unity3d. With all the dependencies and number of objects when developing a game it´s likely to become challenging...
View ArticleIs this a bug? I can't seem to fix it!
I was working in my project and I was trying to tag a GameObject when I found out that the editor for the GameObject isn't in its default state. Is this a bug? Or is there a way to return this to its...
View ArticleScreen clear using tags
I am trying to create a screen clear for my enemies but for the ones in the camera's view. The main issue is that all the solutions give me a half way result. My button Code void ScreenClear() {...
View Articlei don't know why tag option is dosen't work
in my project. i use some tags. but my new tag is maybe doesn't work. has some picture ![alt text][1] red square : '1' it sprite tag is 'Key' so, as far as i know if i checked...
View ArticleRaycast isn't working when with tag
If I add "&& Hit.collider.tag" part to my function it wouldn't work, I check if the object desired is properly tagged and it was. void Raycast() { RaycastHit2D Hit = Physics2D.Raycast...
View ArticleHow to make unity recognice tags?
I have tried once and again to make unity understand that the enemy is NOT colliding with the correct object, but, after many changes, the debug.log ("va") is still triggering even when the enemy is...
View Articlecan someone tell me whats wrong with this code?
using System.Collections; using System.Collections.Generic; using UnityEngine; public class TagAssignCube : MonoBehaviour { public GameObject cube; // Use this for initialization void Start () { cube =...
View ArticleCan't you add tags using a script instead of tagging it through the editor ?
I was working on my project and thought that it would have been great if I could. Is there any way to add a Tag to a game Object through a script?
View ArticleMultiple tags for one GameObject
Hi everyone! Basically I am trying to create an inventory system for my game. Several tags attached to one object would really help! However it seems that that's currently not possible in Unity. If so...
View ArticleSpawnable AI Controller Script to chase FPS Controller that is tagged...
Hello, I am trying to modify an AIController Script that makes an NPC "Enemy" chase after the FPSController GameObject that is tagged "Player". Ultimately, I would like to spawn the "Enemies" equipped...
View ArticleSet a Tag Multiple GameObject[]
How can i set a tag multiple GameObject[] i tried this but its not work. public GameObject[] randomSpawnes; void SetTag(string tag ){ GameObject[] randomSpawnes = GameObject.FindGameObjectsWithTag...
View ArticleMaking object switch between two tags every 3 seconds
how Can I make a script that makes an object switch between 2 tags every 3 seconds?
View ArticleGame wont restart in the build, but works great in the editor..
UnityException: GameObject has undefined tag! at (wrapper managed-to-native) UnityEngine.GameObject:get_tag () at UnityEngine.Component.get_tag () [0x00000] in :0 at PlayerCollision.OnCollisionEnter...
View Article