How can I use the same script for multiple gameobjects?

So I have a problem. When I put a value in the inspector to give xp points for my player the xp gain is not the good value it give one of value what I put in one of other scripts. I don’t know if you understand what I mean because my english is not perfect but I esper you can help me.

using UnityEngine;

public class TakeToEat : MonoBehaviour
{
    private Collider2D foodCol;
    private Vector2 initPos;
    private bool canMove = false;
    public int foodPrize;
    public float xpGain;
    void Start()
    {
        foodCol = GetComponent<Collider2D>();
        initPos = transform.position;
    }

    void Update()
    {
        if(Input.touchCount > 0)
        {
            Touch touch = Input.GetTouch(0);
            Vector2 touchPosition = Camera.main.ScreenToWorldPoint(touch.position);
            Collider2D touchedCollider = Physics2D.OverlapPoint(touchPosition);

            if(touch.phase == TouchPhase.Began)
            {
                if (foodCol == touchedCollider)
                {
                    canMove = true;
                    TouchAndCuddle.instance.canCuddle = false;
                }
            }

            if(touch.phase == TouchPhase.Moved)
            {
                if (canMove)
                {
                    gameObject.transform.position = touchPosition;
                }
            }

            if (touch.phase == TouchPhase.Ended)
            {
                if (TouchAndCuddle.instance.canEat)
                {
                    XpBar.instance.AddXp(xpGain);
                    Debug.Log(xpGain);
                }
                canMove = false;
                transform.position = initPos;
                TouchAndCuddle.instance.canEat = false;
                TouchAndCuddle.instance.canCuddle = true;
            }
        }
    }
}

Give multiple Objects the same Script… could you explain your issue?