hi
FYI this is not my code.
I decided to pitch in and help but so far nothing. The code segments:
script.BadgeAward:FireServer()
print(“FIRED SHOULD RECIEVEe”)
Not sure what the current setup is, but my guess is that the server script is parented to the ReplicatedStorage (due to the “script.Parent.BadgeAward”) in which case scripts don’t run in that container, and instead should be in the ServerScriptService
How to:
Put a RemoteEvent in the ReplicatedStorage, name it “AwardBadge”
Paste this in a local script in the PlayerScripts / PlayerGUI / Character / Wherever it will run as you need it to:
local rs = game:GetService("ReplicatedStorage")
local award_Badge_Remote = rs:WaitForChild("AwardBadge")
award_Badge_Remote:FireServer()
Paste this in a Script that's parented to the ServerScriptService
local bs = game:GetService("BadgeService")
local rs = game:GetService("ReplicatedStorage")
local award_Badge_Remote = rs:WaitForChild("AwardBadge")
local function award_Badge(plr)
bs:AwardBadge(plr.UserId,2147267810)
end
award_Badge_Remote.OnServerEvent:Connect(award_Badge)