Ghosting effect on sprites?

Im trying to make a little effect that leaves behind a trail of “ghosts” of whatever sprite i apply this method to, and so far it works, but only with the object to ghost being hardcoded into the script. the way it works is by having the object use Instantiate() to create an object called ghostfab, a prefab which copies the sprite at a lower opacity and self destruct after a bit using its own script. I need a way to pass in the object that instantiates ghostfab as a parent, or somehow make ghostfab able to find out what instantiated it, so that i can use this on any object i wish, without having to code a different version of this for each object.

Examples below, and thanks in advance.

within the Update function of BallScript:Instantiate(ghostfab);

the ghostscript:

public class GhostScript : MonoBehaviour
{
 
    SpriteRenderer sprite;
    float timer = 0.12f;
    public GameObject WhatIGhost;
    // Start is called before the first frame update
    void Start()
    {

        WhatIGhost = GameObject.Find("ball");

        //get the renderer of this sprite
        sprite = GetComponent<SpriteRenderer>();

        //get the object to ghost's sprite
        sprite.sprite = WhatIGhost.GetComponent<SpriteRenderer>().sprite;

        //set the position to match the object to ghost
        transform.position = WhatIGhost.transform.position;

        //set the scale to match the object to ghost
        transform.localScale = WhatIGhost.transform.localScale;

        //set transparency
        sprite.color = new Vector4(50, 50, 50, 0.2f);
    }

    // Update is called once per frame
    void Update()
    {
        timer -= Time.deltaTime;

        if(timer <= 0)
        {
            Destroy(gameObject);
        }
    }
}

the result: https://i.gyazo.com/d869fc71985a144f58e9b20c39f81811.gif

Okay, so i believe i’ve gotten it to work SOMEWHAT, by modifyng the code so that the parent object instantiates like so: Instantiate(ghostfab, transform); in the hierarchy, this shows ghostfab being a child object of the intended parent, next i changed the ghost’s script so that WhatIGhost is set to transform.root.gameObject. It almost works, except the child sprite shows as giant, for some reason.

example: https://i.gyazo.com/1b47fb14809d8a22465d75f325e7c185.gif

an interesting effect, certainly, but not what i want.

just a quick bump for visibility

been at it for a few days now, still cant figure out why its gigantic, or what can be done about it.