I have a script that logs players killed. It functions exactly like I want it to, besides one crucial detail.
I have a TextLabel that states who killed who, but it only pops up on the victim’s screen. The logging script works for the killer, but they won’t see anything until they die and get the kill message for them.
How can I make it so this shows on ALL players screens in the server? Thanks in advance.
local players = game:GetService("Players");
game:GetService("StarterGui").ResetPlayerGuiOnSpawn = false
players.PlayerAdded:Connect(function(player)
player.CharacterAdded:Connect(function(character)
local humanoid = character:WaitForChild("Humanoid");
humanoid.Died:Connect(function()
local tag = humanoid:FindFirstChildWhichIsA("ObjectValue")
if tag.Name == "damagedBy" and tag.Value then
player.PlayerGui.ScreenGui.KillUpdater.Text = (player.Name .. " was killed by " ..
tag.Value.Name)
end
end);
end);
end)