hello im rewriting my fps game i did last year, in the previous version i had a problem when not aiming down sights the bullets trajectory would just go whitout being on the center, the solution at the time was making the bullet come out of the center of the screen which was really weird,
this time i want to make it so the actual viewmodel aims at the center of the screen depending on distance, the theory i want to try this time is raycasting and aiming the gun at the position the ray hit, yes ive tried cframe.lookat but the viewmodel would just go out of control and spin
ive searched many times on the dev forum and couldnt really find anything that could help me