Exemplo n.º 1
0
        void DisableComponents()
        {
            canMove = false;
            GetComponent <Rigidbody2D>().velocity = Vector2.zero;

            TileMapMovement tileMapMovement = GetComponent <TileMapMovement>();

            tileMapMovement.lockMovement       = true;
            tileMapMovement.enabled            = false;
            GetComponent <Feeder>().enabled    = false;
            GetComponent <Harvester>().enabled = false;
            GetComponent <Animator>().enabled  = false;
        }
Exemplo n.º 2
0
 void Awake()
 {
     _behaviour       = GetComponent <BehaviourController>();
     _animator        = GetComponent <Animator>();
     _tileMapMovement = GetComponent <TileMapMovement>();
 }