Ejemplo n.º 1
0
 public void PickUpBrick()
 {
     if (playerInventory.HasRoomForMoreBricks())
     {
         playerInventory.AddBrick(InputManager.brickInContact);
         playerData.bricksInInventory = playerInventory.bricksCount;
     }
 }
Ejemplo n.º 2
0
 private void OnTriggerEnter(Collider other)
 {
     if (other.gameObject.tag == "Brick" && enemyInventory.HasRoomForMoreBricks())
     {
         enemyInventory.AddBrick(other.gameObject);
         BricksOnGroundController.RemoveBrick(other.gameObject.transform);
     }
 }