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

'Backpack is not a valid member of Player' help me please?

Asked by 6 years ago

Hello !, I have a problem in a script, what I want is that when the player joins the Team a weapon appears automatically, but I get an error saying the following: 'Backpack is not a valid member of Player'.

This is the 'Script':

01print("hola")
02local Teams = game:GetService("Teams")
03 
04local team = Instance.new("Team", Teams)
05team.AutoAssignable = true
06 
07print(team.Parent, team.TeamColor)
08 
09local tool = game.ReplicatedStorage.Pistola
10tool:Clone().Parent = team
11 
12local function armas(plr)
13    for i,v in pairs(team:GetChildren())do
14        print(v)
15        local Tools = v:Clone()
View all 26 lines...

By the way I'm using a normal Script located in 'Workspace'.

I hope you help me ... Thank you!.

0
Are you using a local script or a regular script. And is FE on or off? Jexpler 63 — 6y
0
Script Regular. ¿FE? xmaanzach 28 — 6y

1 answer

Log in to vote
0
Answered by 6 years ago

plr:WaitForChild("Backpack")

0
I forgot that, thank you! xmaanzach 28 — 6y
Ad

Answer this question