Need help making a aimer with dots/small black circle assets

Okay Level 1-10 walk through Okay? Android Game - YouTube you can download the application that is shown in the video in the app store if you would like, not a promotion (says, most promotions) How would you implement this aimer.

Basically the dots are kept apart from each other by the distance of the one infront and behind it, then the direction from the touch position and the player are calculated to get the final position the dot should be at. I really do not know how i would write this in code, i have tried multiple ways, i am probably thinking about this completely wrong aswell. Any help would be very much appreciated. Thank you.

hello, there are 2 different parts the aimer part, thats done by code and the particle system that iis behind and i imagine you dont need help with that part. the part of the aim, not sure what part is giving you issues, but i imagine you can get the position that the objects you want to be right?
here is an example of how to do this

private void Awake()
    float distance = Vector3.Distance(target.position, transform.position);
    float frequence = 4;
    float amountOfIterations = distance / frequence;

    Vector3 direction = target.position - transform.position;

    for (int iterator = 1; iterator < amountOfIterations; iterator++)
        Transform primitive = GameObject.CreatePrimitive(PrimitiveType.Sphere).transform;

        primitive.position = transform.position + direction * frequence * iterator;

take into account, frequence is the distance each object will be spawning, in that example each 4 units. in that example i assume you already got the point towards you need your objects spawning, if you only need a direction you can ignore the amountOfIterations part and just iterate as many times as you want with that direction. i am using a sphere as an example but changin to 2d is really trivial.

the general idea would be to hold a list or array of previous positions your item has been to.
before you add a new position to your array, you just illiterate backwards replacing each other index with the one before. This gives you a constant array of the past and the oldest positions drop off your set array. Lists even have some built in features to add or remove at specific indexes but im giving you an example with an array.

once you have begun recording past positions the rest is easy. there are many ways to acheive this but
the beginning of my script example creates a preset array of spheres with transparency set accordingly. this script will create fading spheres as an object moves a given distance when attached. you could also
use time as a increment or create a time out for the trail to shorten when there is no movement but i am giving you the basic idea.

	public float spread;
	Vector3 last;

	public GameObject[] trace;

	void Start () {
		last = transform.position;
		spread = 1;
		trace = new GameObject[10];
		int i = trace.Length;

_ trace*.renderer.material = new Material(Shader.Find(“Transparent/Diffuse”));_
trace_.renderer.material.color = new Color(1,1,1, 1- (1f/trace.Length)i);

* }}*

* void Update () {*
* if (Vector3.Distance (transform.position,trace[0].transform.position) > spread) {*
*int i = trace.Length; *
* while(i>1){i–;*
_ trace*.transform.position = trace[i-1].transform.position;}
trace [0].transform.position = transform.position;}*_

* }*