- Home /
This question was
closed Jan 06, 2018 at 10:04 PM by
meat5000 for the following reason:
The question is answered, right answer was accepted
Question by
SeanWink · Jan 03, 2018 at 06:30 PM ·
c#objectsload sceneobject referencetagging
can 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 = GameObject.Find ("Cube");
cube.tag= 'Player';
}
// Update is called once per frame
void Update ()
{
}
}
Trying to tag the gameobject Cube in my scene through code.
Comment
Follow this Question
Related Questions
Multiple Cars not working 1 Answer
Distribute terrain in zones 3 Answers
How can I figure if an Object was created at runtime? (for extending Json save/load) 0 Answers
Help in solving mistake in my code 1 Answer
Player hanging on objects. 0 Answers