|
| 26 Oct 2013 06:38 PM |
how you make a gun with right click aim with fieldOfView of 60 I have the gun, but this part killed me
0--<-----< |
|
|
| Report Abuse |
|
|
| |
|
|
| 26 Oct 2013 06:42 PM |
You script it, that's how.
http://wiki.roblox.com/index.php/Absolute_beginner%27s_guide_to_scripting http://wiki.roblox.com/index.php/Camera http://wiki.roblox.com/index.php/Touched http://wiki.roblox.com/index.php/Mouse
Wiki Profile: http://wiki.roblox.com/index.php/User:Nelson |
|
|
| Report Abuse |
|
|
|
| 26 Oct 2013 06:44 PM |
My zoom in script puts me in crouch here
Tool = script.Parent welds = {} sh = {} arms = nil torso = nil f = nil function Crouch(ison) if arms == nil and torso == nil then arms = {Tool.Parent:FindFirstChild("Left Leg"), Tool.Parent:FindFirstChild("Right Leg")} torso = Tool.Parent:FindFirstChild("Torso") human = Tool.Parent:FindFirstChild("Humanoid") end if arms ~= nil and torso ~= nil and human ~= nil then sh = {torso:FindFirstChild("Left Hip"), torso:FindFirstChild("Right Hip")} if sh ~= nil then local yes = true if yes then yes = false if ison == 1 then human.WalkSpeed = 8 sh[1].Part1 = nil sh[2].Part1 = nil local weld1 = Instance.new("Weld") weld1.Part0 = torso weld1.Parent = torso weld1.Part1 = arms[1] weld1.C1 = CFrame.new(-0.5,0.495,.8) * CFrame.fromEulerAnglesXYZ(math.rad(10),-.2,0) arms[1].Name = "LDave" arms[1].CanCollide = true welds[1] = weld1 ------------------------------------------- local weld2 = Instance.new("Weld") weld2.Part0 = torso weld2.Parent = torso weld2.Part1 = arms[2] weld2.C1 = CFrame.new(0.5,0.495,.8) * CFrame.fromEulerAnglesXYZ(math.rad(80),.2,0) arms[2].Name = "RDave" arms[2].CanCollide = true welds[2] = weld2 --------------------------------- local force = Instance.new("BodyForce") force.Parent = torso f = force wait(0.01) elseif ison == 0 then if arms then human.WalkSpeed = 16 sh[1].Part1 = arms[1] sh[2].Part1 = arms[2] f.Parent = nil arms[2].Name = "Right Leg" arms[1].Name = "Left Leg" welds[1].Parent = nil welds[2].Parent = nil end end -- end else print("sh") end else print("arms") end end function Key(key) if key then key = string.lower(key) if (key=="c") then if script.crouching.Value == 1 then script.crouching.Value = 0 elseif script.crouching.Value == 0 then script.crouching.Value = 1 end Crouch(script.crouching.Value) end end end function Equip(mouse) mouse.KeyDown:connect(Key) end function Unequip(mouse) if script.crouching.Value ~= 0 then script.crouching.Value = 0 Crouch(script.crouching.Value) end end Tool.Equipped:connect(Equip) Tool.Unequipped:connect(Unequip) |
|
|
| Report Abuse |
|
|
cntkillme
|
  |
| Joined: 07 Apr 2008 |
| Total Posts: 44956 |
|
|
| 26 Oct 2013 06:46 PM |
"My zoom in script puts me in crouch here" Then it's obviously not yours |
|
|
| Report Abuse |
|
|
|
| 26 Oct 2013 06:46 PM |
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ Yus. Also, tl;dr
Wiki Profile: http://wiki.roblox.com/index.php/User:Nelson |
|
|
| Report Abuse |
|
|
|
| 26 Oct 2013 06:53 PM |
| no I just put my crouch script trying to leak the Right click zoom from you guys! |
|
|
| Report Abuse |
|
|
| |
|