Пример #1
0
        public override bool CanUse(Player player, Vector2Int target)
        {
            Tilemap    tilemap  = TilemapManager.Instance.groundTilemap;
            Vector3Int position = new Vector3Int(target.x, target.y, 0);
            TileBase   tile     = tilemap.GetTile(position);

            return((soilType.Contains(tile) || wetSoilType.Contains(tile)) && seedItem != null &&
                   !CropManager.Instance.HasCrop(target) && player.Stamina >= staminaCost);
        }