Scripting HelpersARCHIVE
A little piece of Roblox history. Preserved for everyone, one question at a time.Read about the archive →
COMMUNITY QUESTION

How do i make it so when I am equipping a tool in first person the arms become visible?

Only when i am equipping a tool in first person the arms show if i'm in first person and equipping nothing then the arms do not become visible.Please respond quick.

1 comment

0

tool = script.Parent EnableArm1 = true -- Set to false if you don't want the player's right arm to appear. EnableArm2 = true -- Set to true if you don't want the player's left arm to appear. tool.Equipped:connect(function() wait() local c = game.Players.LocalPlayer.Character local colors = c:findFirstChild("Body Colors") RightArm = c:findFirstChild("Right Arm") LeftArm = c:findFirstChild(

1 answer

okay made it here is the local script put it in ur tool:wait(0.2) local player=game.Players.LocalPlayer local camera=workspace.CurrentCamera local tool=script.Parent local char=player.Character SETTINGS={

FIRST_PERSON={
	left_arm=true, --if left arm is Enabled
	right_arm=true, --If right arm is Enabled
	arm_transparency=0.4, --The transparency of the Arms
	arm_color=BrickColor.new("Really black"), --The colo(u)r of the arms, If below is set to true, This will be the BrickColor of the Arms.
	change_color=true, --Changes the colo(u)r of the arms, If false, Will set them as the Players arm colo(u)r
},

}

function FirstPerson() if (camera.focus.p - camera.CoordinateFrame.p).magnitude > 1 then return false else return true end end function Start() anim_arms=Instance.new("Model") anim_arms.Name="Arms_Model" local r,l = char:FindFirstChild("Right Arm"):clone(), char:FindFirstChild("Left Arm"):clone() if r and SETTINGS.FIRST_PERSON.right_arm then r.Transparency=SETTINGS.FIRST_PERSON.arm_transparency r.Material=Enum.Material.SmoothPlastic if SETTINGS.FIRST_PERSON.change_color then r.BrickColor=SETTINGS.FIRST_PERSON.arm_color end end if l and SETTINGS.FIRST_PERSON.left_arm then l.Transparency=SETTINGS.FIRST_PERSON.arm_transparency l.Material=Enum.Material.SmoothPlastic if SETTINGS.FIRST_PERSON.change_color then l.BrickColor=SETTINGS.FIRST_PERSON.arm_color end end local rw,lw,h = Instance.new("Weld"),Instance.new("Weld"), Instance.new("Humanoid") if rw and SETTINGS.FIRST_PERSON.right_arm then rw.Part0=r rw.Part1=char:FindFirstChild("Right Arm") rw.Parent=r r.Parent=anim_arms end if lw and SETTINGS.FIRST_PERSON.left_arm then lw.Part0=l lw.Part1=char:FindFirstChild("Left Arm") lw.Parent=l l.Parent=anim_arms end if SETTINGS.FIRST_PERSON.right_arm then if r:FindFirstChild("RightGrip")~=nil then r:FindFirstChild("RightGrip"):Destroy() end end while equipped do if FirstPerson() then if anim_arms ~= nil then anim_arms.Parent=camera end else if anim_arms ~= nil then anim_arms.Parent=nil end end wait() end end function End() anim_arms:Destroy() anim_arms=nil

end tool.Equipped:connect(function () equipped=true Start() end) tool.Unequipped:connect(function () equipped=false End() end)

This discussion is preserved as it was. New answers, comments, and votes are closed.