title: Crafting System not working in unity why?
body: <p>So, I made a rudimentary crafting system but the crafting system is not working and I don't know why it doesn't work</p>
  <pre><code>public class CraftingItem: MonoBehaviour
  {
    public int RequiredItems;
    public SCItem[] Item; 
    private GameObject player;
    private GameObject playerAction;
    public GameObject FinishItem;
  
  
    public void Start(){
      player = GameObject.FindWithTag(&quot;Player&quot;);
      playerAction = GameObject.FindWithTag(&quot;ItemManager&quot;);
    }
  
    public void CheckForRequiredItems(){
      int itemsInManager = playerAction.transform.childCount;
  
      if(itemsInManager &gt; 0){
        int itemsFound = 0;
        for(int i = 0; i &lt; RequiredItems; i++){
            
            for(int z = 0; z &lt; itemsInManager; z++){
              
               if(playerAction.transform.GetChild(z).GetComponent&lt;Item&gt;() == Item[z]){
                itemsFound++;
                break;
            }
          }
        } 
        if(itemsFound &gt;= RequiredItems){
          Instantiate(FinishItem, transform.position, transform.rotation);
        } 
      }
    }
  }
  </code></pre>
  <p>unity inspector panel :<a href="https://i.stack.imgur.com/PQCoq.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/PQCoq.png" alt="enter image description here" /></a></p>
  <p>I use a scriptable object to make the item, material, and attack items easy to control. Also, this script doesn't tell an error or syntax error, and I little bit confused. can you explain why and how can i fix this?</p>