protected virtual void Start()
    {
        gridMapReference = GameObject.FindObjectOfType <GameMapController>();
        lookDirection    = inicialLookDirection;
//		  gridPosition = initialGridPosition;
        gridPosition       = new Vector2((int)transform.position.x, (int)transform.position.y);   //troquei a linha de cima por esta
        transform.position = new Vector3(gridPosition.x, gridPosition.y, locationDepth);
    }
    protected virtual void Start() {
        gridMapReference = GameObject.FindObjectOfType<GameMapController>();
		LookDirection = inicialLookDirection;
        animatorReference = GetComponent<Animator>();
//		  gridPosition = initialGridPosition;
		gridPosition = new Vector2((int)transform.position.x, (int)transform.position.y); //troquei a linha de cima por esta
        transform.position = new Vector3(gridPosition.x,gridPosition.y,-locationDepth);
    }
 void OnGUI()
 {
     activeMap = (GameMapController)FindObjectOfType(typeof(GameMapController));
     if (activeMap)
     {
         displayMapEditorWindow();
     }
     else
     {
         displayNewMapWindow();
     }
 }
Exemplo n.º 4
0
    public override void OnInspectorGUI()
    {
        DrawDefaultInspector();

        GameMapController mapController = (GameMapController)target;

        if (GUILayout.Button("generate"))
        {
            mapController.generateObjects();
        }

        if (GUILayout.Button("clear"))
        {
            mapController.clearGameObjectsInEditor();
        }
    }
Exemplo n.º 5
0
    /********************************************************************/

    void Start()
    {
        mapController = GetComponent <GameMapController>();
    }
Exemplo n.º 6
0
 private void Awake()
 {
     gameMapController = GameObject.Find("Main Camera").GetComponent <GameMapController>();
 }
Exemplo n.º 7
0
        void Start()
        {
            GameMapController gameMapController = new GameMapController();

            gameMapController.CreateStatic();
        }
Exemplo n.º 8
0
 void Start()
 {
     gameMapController = GameObject.Find("Main Camera").GetComponent <GameMapController>();
 }
Exemplo n.º 9
0
 private void Awake()
 {
     gameMapController = gameObject.GetComponent <GameMapController>();
 }
Exemplo n.º 10
0
 private void Awake()
 {
     gameMapController = GameObject.Find("Main Camera").GetComponent <GameMapController>();
     moveLight         = GameObject.Find("Directional Light").GetComponent <MoveLight>();
     antController     = GameObject.Find("Ant").GetComponent <AntMovingController>();
 }