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

Local script, to a normal script WITH filtering enabled. help me!?

Asked by 8 years ago
game.Players.LocalPlayer.CanLoadCharacterAppearance = false
game.Players.LocalPlayer.Character:WaitForChild("Head")

wait() --keep to fix errors!11!

local cam = game.Workspace.CurrentCamera
cam.CameraSubject=game.Workspace.Map.CameraPart
cam.CameraType = "Scriptable"
cam.CoordinateFrame= game.Workspace.Map.CameraPart.CFrame


for i,v in pairs(game.Players.LocalPlayer.Character:GetChildren()) do
    if game.Players.LocalPlayer.PlayingBool.Value == false then
    v:Destroy()
    end
end

game.Players.LocalPlayer.PlayingBool.Changed:connect(function()
    if game.Players.LocalPlayer.PlayingBool.Value == true then
    if game.Players.LocalPlayer.SpawnedBool.Value == false then
        game.Players.LocalPlayer:LoadCharacter()
        game.Players.LocalPlayer.SpawnedBool.Value = true
        game.Players.LocalPlayer.Character.Head:WaitForChild("face"):Destroy()
        game.Players.LocalPlayer.Character:WaitForChild("Humanoid").WalkSpeed =0

        local newColors = game.ReplicatedStorage.GameFolder.LoadoutFolder.BodyColors:Clone()
        newColors.Parent = game.Players.LocalPlayer.Character
        newColors.TorsoColor = game.Players.LocalPlayer.TeamColor

        local Handle = game.ReplicatedStorage.GameFolder.LoadoutFolder.Handle:Clone()
        Handle.Parent = game.Players.LocalPlayer.Character
        Handle.CFrame = game.Players.LocalPlayer.Character.Head.CFrame
        Handle.BrickColor = game.Players.LocalPlayer.TeamColor

        local w = Instance.new("ManualWeld", Handle) 
        w.Part0 = Handle
        w.Part1 = game.Players.LocalPlayer.Character.Head

        game.Players.LocalPlayer.PlayerGui.WelcomeGui.Frame.Visible = false 
        game.Players.LocalPlayer.Character:WaitForChild("Humanoid").WalkSpeed =20
        game.Workspace.CurrentCamera:Destroy()
        wait()
        game.Workspace.CurrentCamera.CameraSubject = game.Players.LocalPlayer.Character.Humanoid
        game.Workspace.CurrentCamera.CameraType = "Custom"
        cam.CoordinateFrame= game.Players.LocalPlayer.Character.Torso.CFrame

        for i,v in pairs(game.ReplicatedStorage.GameFolder.WeaponFolder:GetChildren()) do
            if v.WeaponNumber.Value == game.Players.LocalPlayer.WeaponNumber.Value then
                local weapon = v:Clone()
                weapon.Parent = game.Players.LocalPlayer.Backpack
            end
        end
    end
end
end)

Ok this is a local script in StarterGui, I want to make it a normal script, filtering enabled is active. Can someone help me port this, and make it function with filtering enabled.

0
What do you mean by "Make it a normal script"? BlueTaslem 18071 — 8y
0
You're going to love/hate RemoteEvents for the next few hours Pyrondon 2089 — 8y
0
lol ConnorVIII 448 — 8y
0
You're using CurrentCamera and LocalPlayer in this script. It does not make sense to make this a Script object. What do you want to do? Be able to command this script from a script? "Porting" it is not what you want to do. BlueTaslem 18071 — 8y
0
I can just changed LocalPlayer to PlayerAdded? ConnorVIII 448 — 8y

Answer this question