Player only colliding & attacking with last spawned NPC, not current collision

So my issue is when the player attacks any object in the Enemy Layer with the Enemy Tag, it will properly do damage and knockback the enemy collided with…but when the player attacks an object in the Enemy Layer with the NPC Tag, it will only ever attack the last spawned NPC, not the one collided with. Im not sure how to go about fixing this or making the collision smoother.
ExampleVideo

Here is the Attack function…it is called when the player pushes the attack button. Let me know if you need any other code for context!

 void Attack()
    {
        #region Attack and Attack Combo
        if (!attacking && attackCombo == 1 && comboAttack == false && falling == false)
        {
            attacking = true;
            knockbackDamage = Random.Range(250, 300);
            knockupDamage = Random.Range(200, 250);
            attackTime = attackCooldown;
            animator.SetBool("isAttacking", true);
            animator.SetInteger("attackCombo", 0);
            Collider2D[] enemiesToDamage = Physics2D.OverlapCircleAll(attackPos.position, attackRange, whatIsEnemies);
            foreach (Collider2D enemy in enemiesToDamage)
            {
                objCollided = enemy.gameObject;
                if (enemy.gameObject.CompareTag("Enemy"))
                {
                    if(enemy.gameObject.GetComponent<EnemyBehaviour>().dead == false)
                    {
                        canHitEnemy = true;
                        attackSwipe01.SetActive(true);
                        objCollided.GetComponent<EnemyBehaviour>().TakeDamage(attackDamage);
                        objCollided.GetComponent<EnemyBehaviour>().KnockBack(knockbackDamage, knockupDamage * 2);
                        Debug.Log("PLAYER hit " + enemy.name + " AND DID " + attackDamage + " damage!" + " Enemy has " + objCollided.GetComponent<EnemyBehaviour>().currentHealth + " health remaining!");
                    }
                    if(enemy.gameObject.GetComponent<EnemyBehaviour>().dead == true && canHitEnemy)
                    {
                        PlayerData.PlayerXP += 1;
                        canHitEnemy = false;
                    }
                }
                if(enemy.gameObject.CompareTag("NPC"))
                {
                    objCollided.GetComponent<NPC_Control>().KnockBack(knockbackDamage, knockupDamage * 2);
                    Debug.Log("Player Hit " + enemy.name);
                }
                
            }
            
        }

Solved it! I accidentally set the rb on the NPC controller script to static, so it was only affecting one object.