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

Character goes mad (error) when I died?!?

Asked by 5 years ago
Edited 5 years ago

So this is the last part of my FilteringEnabling script, character goes error when I died saying it was a nil value. Also goes with the Humanoid. So I found a person to try out game.Workspace:FindFirstChild(game.Players.LocalPlayer.Name) but also not works... Any ways to fix this now?

If you don't know what I mean, this is how it worked

Player used a script that is FilteredEnabled but reset because someone OOFed him, and then Player got an error because he died, and he looked Developer Console and saw that local character was a nil value for now, but before that happened it was true before.

local player = game.Players.LocalPlayer or game.Players.PlayerAdded:Wait()
local character = player.Character or game.Players.LocalPlayer.CharacterAdded:Wait() --wow noice i got oofed then wait.. what? does not work? but character will revive! what the
0
Please show all of the scripts, and copy the error, I don't have a clue what you are talking about.. AspectType 151 — 5y

1 answer

Log in to vote
0
Answered by 5 years ago

Whoa! xd

Just add a wait(1) to the top of the script.

0
it worked but when i tried to die it still got an error.. cherrythetree 130 — 5y
0
add a ypcall function into it SmhMate 4 — 5y
Ad

Answer this question