I tried to understand raycasting. But really its just confusing me. I really do not know how to make a ray follow the mouses position. The player needs to press and hold a key (Example: T) then point the laser via the mouse for a limited time (So they can only do this for 5 seconds). I never figured out how. Also idk how to make the ray itself deal damage to the humanoid its touching (Excluding the Player's character)

1 comment

0

Read about raycasts in a roblox API, watch tutorials how to form a raycast in different ways, when you form a raycast you can also update its position all the time.. and to make it look like a heatvision you make the raycast go out of your head, in those videos you could also find how to add a part to the raycast and make it red and neon