I have this coroutine that waits for the player input to drop out of a while loop as well as some `if` statements that expect input as well. However the `Input.KeyCode` doesn't work in the coroutine, or rather just returns `false`, even if I press the right key...

I checked it in the normal `FixedUpdate` and there it works.

There must be a simple thing I yet don't understand about coroutines.

```
private IEnumerator TabThroughPotentialSoldiersRightCoroutine()
{
    Debug.Log("InCoroutine!");
    while (!Input.GetKeyDown(KeyCode.Return))
    {
        Debug.Log("InWhile!");
        if (Input.GetKeyDown(KeyCode.Tab))
        {
            Debug.Log("potentialAttckGroupMembers: " + potentialAttackGroupMembers.Count);
            if (potentialAttackGroupMembers.Count > 0)
            {
                attackGroupRight.Add(AI.GetClosestEnemyGameObject(potentialAttackGroupMembers, GameObject.Find("MC")));
                potentialAttackGroupMembers.Remove(AI.GetClosestEnemyGameObject(potentialAttackGroupMembers, GameObject.Find("MC")));
                Debug.Log("Add to attackGroup: " + AI.GetClosestEnemyGameObject(potentialAttackGroupMembers, GameObject.Find("MC"))); 
            }
        }

        if (Input.GetKeyDown(KeyCode.Tab) && Input.GetKeyDown(KeyCode.LeftShift))
        {
            if (attackGroupRight.Count > 0)
            {
                attackGroupRight.Remove(AI.GetClosestEnemyGameObject(attackGroupRight, GameObject.Find("MC")));
                potentialAttackGroupMembers.Add(AI.GetClosestEnemyGameObject(attackGroupRight, GameObject.Find("MC")));
                Debug.Log("Remove from atckGroup:" + AI.GetClosestEnemyGameObject(attackGroupRight, GameObject.Find("MC")));
            }
        }
        yield return new WaitForEndOfFrame();
    }
    potentialAttackGroupMembers.Clear();
}

```