Scripting Helpers is winding down operations and is now read-only. More info→
Ad
Log in to vote
0

How to set the Ray direction correctly? [Help pls]

Asked by 4 years ago
Edited 4 years ago

When testing weapons, the beam does not work properly. Either it's going the wrong way, or it's stuck in the blocks. p.s.sorry for my english, i use translate

script.Parent.RemoteEvent.OnServerEvent:connect(function(plr,Pos)

    local ray = Ray.new(Stvol.Position , Pos)
    local hit,position = workspace:FindPartOnRayWithIgnoreList(ray, {TOOL, beam, Stvol, TOOL.Handle}, false, true)

    if hit then
        hit.BrickColor = BrickColor.new("White")
    end

    script.Shot:Play()
0
what is Pos equal to? botw_legend 502 — 4y

Answer this question