No error in the output

Hello developers, in my script it’s do not work. Even the warn.

Script:

1 Like

You forgot to add .Value after IsBannedValue in the if statement

I feel a little bit dumb now. I realised it when you was typing.

Please read your code thoroughly before posting, it will prevent simple issues like this

Still not working at all. Even with .Value.

How are you firing the function? Show the code that calls that function

Okay. Here it is I guess:

You’re trying to parent a folder to a string, I’m pretty sure your code expects a player instance to be given, not a string

Can you send me a fix of it? I am confused.

The fix is to give CheckBan a player instance, not a string, you gave it "achdef" as an argument, you can’t parent a folder to a string, you need to give a player instance

So I do game.Players.achdef? Or something like that?

If you aren’t in the game, it wont work, it’ll error.

Just make a PlayerAdded event and give the player instance given from the event to that function

I used WaitForChild. Now the issue is the warn wont fire.

You can just do this

game:GetService("Players").PlayerAdded:Connect(function(player)
	FBan.CheckBan(player)
end)

It’s do work:

But the output seems empty:

What is in your Checkban function code right now?

Right now it is this:

That is not where I had told you to put it…I meant for you to make a PlayerAdded event that fires the CheckBan, giving the palyer who just joined an argument, I didn’t say for you to put it here

It won’t work because it’s the player’s name, not the player. You’ll have to use :GetPlayerFromUserId, and before that :GetUserIdFromNameAsync

I fixed it but how would I put it on to a specific player?