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

Why wont this work in multiplayer? [Normal Script, Placed in a tool, In starter Pack]

Asked by 9 years ago

--This is the part of the script that wont work everything else is fine (I don't know i you need the rest of the script, if so just tell me)--

mouse.Button1Down:connect(function()

local shot = script.Parent.Sound

shot:Play() 

    if ADS == false then -- Shooting script when not Aiming Down Sighs

local i = 0.9

local e = 1.4

repeat

weld2.C1 = CFrame.new(-0.6, e , 0.5) * CFrame.fromEulerAnglesXYZ(math.rad(-90),  math.rad(0), 0)

weld1.C1 = CFrame.new(1,i, 0.48) * CFrame.fromEulerAnglesXYZ(math.rad(-90), math.rad(40), 0)

i = i -0.1

e = e -0.1

wait(0.0001)    

until

   weld1.C1 == CFrame.new(1,0.5, 0.48) * CFrame.fromEulerAnglesXYZ(math.rad(-90), math.rad(40), 0)

   weld2.C1 = CFrame.new(-0.6, 1 , 0.5) * CFrame.fromEulerAnglesXYZ(math.rad(-90),  math.rad(0), 0)

end

local i = 0.5

local e = 1

repeat

weld2.C1 = CFrame.new(-0.6, e , 0.5) * CFrame.fromEulerAnglesXYZ(math.rad(-90),  math.rad(0), 0)

weld1.C1 = CFrame.new(1,i, 0.48) * CFrame.fromEulerAnglesXYZ(math.rad(-90), math.rad(40), 0)

i = i + 0.1

e = e + 0.1

wait(0.0001)    

until

   weld1.C1 == CFrame.new(1,0.9, 0.48) * CFrame.fromEulerAnglesXYZ(math.rad(-90), math.rad(40), 0)

   weld2.C1 = CFrame.new(-0.6, 1.4 , 0.5) * CFrame.fromEulerAnglesXYZ(math.rad(-90),  math.rad(0), 0)   


end)

Answer this question