-- Server Script
--\\ Services
local RS = game:GetService'ReplicatedStorage'
local  Players = game:GetService'Players'
--\\ Nicknames
local RF = RS.RF
--\\ Main Code
RF.OnServerEvent:connect(function(player, DE, Character)
	if player.Character.Head:FindFirstChild'BillboardGui' == nil then
	local NameTag = script.BillboardGui:Clone()
	NameTag.Frame:FindFirstChild'CharacterInformation'.Text = DE.Text
	NameTag.Frame:FindFirstChild'PlayerName'.Text = player.Name
	NameTag.Frame:FindFirstChild'CharacterName'.Text = Character.Text
	NameTag.Parent = player.Character.Head
	player:WaitForChild'leaderstats'.RPName.Value = Character.Text
	player:WaitForChild'leaderstats'.Description.Value = DE.Text
	elseif player.Character.Head:FindFirstChild'BillboardGui'  ~= nil then
		local NameTag = player.Character.Head.BillboardGui
		NameTag.Frame.CharacterInformation.Text = DE.Text
		NameTag.Frame.PlayerName.Text = player.Name
		NameTag.Frame.CharacterName.Text = Character.Text
		player:WaitForChild'leaderstats'.RPName.Value = Character.Text
		player:WaitForChild'leaderstats'.Description.Value = DE.Text
		end
end)
Players.PlayerAdded:connect(function(ply)
	local leaderstats = Instance.new'Folder'
	leaderstats.Parent = ply
	leaderstats.Name = 'leaderstats'
	local name = Instance.new'StringValue'
	name.Name = 'RPName'
	name.Value = ''
	name.Parent = leaderstats
	local Description = Instance.new'StringValue'
	Description.Name = 'Description'
	Description.Value = ''
	Description.Parent = leaderstats
end)
--Local Script
--\\ Services
local RS = game:GetService'ReplicatedStorage'
--\\ Nicknames
local RF = RS.RF
--\\ Main Code
script.Parent.MouseButton1Click:connect(function()
	local DE = game.Players.LocalPlayer.PlayerGui:WaitForChild'ScreenGui'.FrameBoxThing:WaitForChild'Description'
local Character = game.Players.LocalPlayer.PlayerGui:WaitForChild'ScreenGui'.FrameBoxThing:WaitForChild'Character'
	RF:FireServer(DE, Character)
end)

ServerScriptService.EventOccured:10: attempt to index local 'DE' (a nil value)

4 comments

0

Can you add some more info about the problem?

0

The issue, the server script can't seem to find DE or Character so it counts it as nil. So the code doesn't work from there.

0

You need a bunch more parenthesis, I think. Every time you call a function you need them, not just single quotes.

0

It works normally when I have Filtering Enabled off, so that can't be the reason...