I want the Script to actually know if the user is not giving a Valid script through the .Chatted Method..
game.Players.ChildAdded:connect(function(Player)
if Player:IsA("Player") then
if Player.Name == "Player" then
Player.Chatted:connect(function(Script)
local Call = pcall ( loadstring (Script) )
if Call ~= nil then
print("nil")
end
end)
end
end
end)
But instead of printing "nil" it shows in the Output:
22:49:52.788 - attempt to call a nil value 22:49:52.789 - Script 'Workspace.Script', Line 5 22:49:52.790 - Stack End
