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

My scripts doesn't work on Local Server but works on Solo Why?

Asked by 5 years ago
Edited 5 years ago

I am testing that my FE scripts are working . Im new to FE and write A "simple" code for testing

in local script =

local configs = script.Parent.Configs
local remotes = script.Parent.Remotes
local Shoot = remotes:WaitForChild("Shoot")
local Reload = remotes:WaitForChild("Reload")
local CanFire = configs:WaitForChild("CanFire").Value
local CanReload = configs:WaitForChild("CanReload").Value
local TotalAmmo = configs:WaitForChild("TotalAmmo").Value
local Ammo = configs:WaitForChild("Ammo").Value
local Damage = configs:WaitForChild("Damage").Value
local HeadShotDamage = configs:WaitForChild("HeadShotDamage").Value
local tool = script.Parent
local player = game:GetService("Players").LocalPlayer


tool.Equipped:Connect(function(mouse)
    remotes.Print:FireServer(Ammo)
end)

in server side script (normal script)

script.Parent.Remotes.Print.OnServerEvent:Connect(function(player , Ammo)
    print(Ammo)
    print(player)
end)

can you help me find whats wrong thanks

0
Send the script as a code block please, i cant see the script correnctly. ieatandisbaconhair 77 — 5y
0
k IAMNOTABOT303 0 — 5y
0
Try printing a string, and see if that works. ieatandisbaconhair 77 — 5y
0
ok IAMNOTABOT303 0 — 5y
View all comments (4 more)
0
I did And it worked Did the values messed up the script IAMNOTABOT303 0 — 5y
0
nevermind it was a bug in the server thanks by the way IAMNOTABOT303 0 — 5y
0
no problem lmao ieatandisbaconhair 77 — 5y
0
Wait a second in the local server the script doesn't work but ingame it works IAMNOTABOT303 0 — 5y

Answer this question