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

GetPlayerFromCharacter not working?

Asked by
Async_io 908 Moderation Voter
9 years ago
1tool = script.Parent
2handle = tool:WaitForChild('Handle')
3event = tool:WaitForChild('RemoteEvent')
4swingtime = 1
5combowindow = 1
6combo = 0
7wait(1)
8character = tool.Parent
9player = game.Players:GetPlayerfromCharacter(character)

that's the chunk of code I'm having issues with I keep getting this error:

118:17:33.809 - GetPlayerfromCharacter is not a valid member of Players
218:17:33.810 - Script 'Players.Player1.Backpack.Black.Script', Line 9
318:17:33.811 - Stack End

And I typed this script out while watching one of stickmasterluke's videos on how to make a custom sword. I checked 20 times, and it's still the same as in the video, yet he has no errors.

Answer this question