#BanASync & PCall not running (remote event firing but not being received?)
1 messages · Page 1 of 1 (latest)
@livid escarp 😭have you got any clue
I need a hero
the top print.. prints
I aint spend 2hrs writing shi just for the ban to break
So, whats the issue?
alr so basically
My Client is successfully firing a RemoteEvent, but the Server's OnServerEvent listener isn't triggering the print statements inside it, even though both scripts see the same Remote object and the Admin ID check is passed.
like how is it possible my client fires an event, and the server just dont recieve it (it recieves it when i fire the same event from dif scripts like my fly one)
or wait I see it only does that when I run Server & Local instead of play
remote.OnServerEvent:Connect(function(player, command, targetName, reason)
print("SERVER RECEIVED: ", command, "TARGET: ", targetName)
if not AdminConfig[player.UserId] then
warn("User is not an admin")
return
end
local target = Players:FindFirstChild(targetName)
if not target then
warn("Target failed")
return
end
Try adding these changes
oh
hmmmm
im guessing they're warnings?
the SERVER RECEIVED thing dont run if its on a server & local test meaning its just like blocking the fireserver
let me see your local script
task.wait(1)
local ReplicatedStorage = game:GetService("ReplicatedStorage")
local remote = ReplicatedStorage:WaitForChild("AdminCommand")
local runButton = script.Parent
local playerBox = runButton:WaitForChild("Target")
local reasonBox = runButton:WaitForChild("Reason")
print("Remote Found:", remote)
print("Remote class:", remote.ClassName)
if not game:IsLoaded() then game.Loaded:Wait() end
task.wait(1)
runButton.MouseButton1Click:Connect(function()
if playerBox and reasonBox then
local targetName = playerBox.Text
local reason = reasonBox.Text
if targetName ~= "" then
remote:FireServer("Ban", targetName, reason)
print("FireServer sent to AdminHandler")
end
end
end)
I wanna try apply for s1 one day but w shi like this i aint never finna be able to do that 😭
remote:FireServer("Ban", targetName, reason)
try doing just this line
if not game:IsLoaded() then game.Loaded:Wait() end
oh
thats not how
remove that line
idk then