Hi, so I have a beam that stretches out from top to bottom of my screen. I want to have follow my player around when i activate it. And so after doing some research, a lot of people suggested i create it as a child. This is the code I used:
player = (GameObject.Find(“ShotSpawn”)).transform;
transform.parent = player;
and so, i managed to get the object to follow me as i move my player object around… but everytime I hit other objects with this beam it acts as if it’s my player, and it makes me take damage as if these objects were hitting my player directly, even though it’s only hitting my beam/projectile. So my question is,
is there another way to “clamp” this beam of mine to my character to make it move left and right along with my character?