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

attempt to index nil with 'Character'? I need help.

Asked by 4 years ago

Here is the source: https://pastebin.com/Kfn1nhRF

Character is defined as inline 83.

local Character = Client.Character or Client.CharacterAdded:Wait()

This script is not a local script in Workspace in a part, when the part is touched it activate the script.

Please help me, I am confusion.

1
Just a note for who sees this question: Scripting Helpers have a character limit of 10k, the script is bigger than that (41k characters) Leamir 3138 — 4y
0
don't post scripts that you haven't made man... it's 1530 lines of code we ain't gonna fix that for you, nor even search for the error. Mroczusek 111 — 4y
0
the error means `Client` is nil Leamir 3138 — 4y
2
You mention as well that this is a script, not a local script. Yet, you are attempting to use LocalPlayer. That will not work. Rocketerkid 237 — 4y
0
I want to die TestGloryRare 7 — 4y

1 answer

Log in to vote
0
Answered by
HEMAN_9 70
4 years ago

The problem is in the fact that you use "Players.LocalPlayer" inside of a normal script. LocalPlayer can only be used in a local script. I'm not exactly sure what this script is for without context but one way to get the player could be through the variable that game.Players.PlayerAdded gives.

Ad

Answer this question