-
What do you want to achieve? I want the ray to hit where the mouse is aiming without using mouse.hit because player accessories mess with the hit position.
-
What is the issue? The ray is hitting below the mouse cursor.
When my weapon fires the ray hits below the mouse cursor for some reason.
local raycastParams = RaycastParams.new()
raycastParams.FilterType = Enum.RaycastFilterType.Blacklist
table.insert(Ignore, game.Players.LocalPlayer.Character)
raycastParams.FilterDescendantsInstances = {Ignore}
local Ray = Mouse.UnitRay
local Origin, Direction = Tool.Emitter1.Position, Ray.Direction.Unit * Tool.StatInfo.Range.Value
local RayPath = workspace:Raycast(Origin, Direction, raycastParams)