The local script works completely fine, the prints and such work. The server script print does not print. This is very confusing as this should be correct and is very important to my scripts. There are no errors or yields in the output.
--Server script
game.ReplicatedStorage.DeadBodyItemCreate.OnServerEvent:Connect(function(plr, corpse, item)
print('Recieved')
local Wcorpse = workspace:WaitForChild(corpse.." Corpse").Inventory:WaitForChild(item)
Wcorpse.Value = Wcorpse.Value - 1
local plrItem = plr.Inventory:WaitForChild(item)
plrItem.Value = plrItem.Value + 1
end)
--Local script
local item = script.Parent.Parent.Parent
local ItemName = item.Name
local amount = item.ItemCount.ItemValue
local CorpseName = item.Parent.Parent.PlayerName.Value
print(CorpseName)
game.ReplicatedStorage.DeadBodyItemCreate:FireServer(CorpseName, ItemName)
print(CorpseName.." Corpse")
all of the values are correct. The server script is inside ServerScriptService, and the local script is inside a startergui. https://imgur.com/9vbpkPo that is the picture of the local script (at the bottom)

3 comments
Try making sure nothing is yielding the script before the OnServerEvent.
Well isn't the server responsible for what happens? Meaning when the client dies, it should fire. Try "OnClientEvent"? If I'm wrong then sorry.
Did you ever solve this issue? I'm having the same problem, everything in my code is correct in syntax but it won't fire to the server. No errors in output and all of the buttons work other than the FireServer part.