This is not a request! I'm just simply asking how to extend my current script.
I have people in a match, and if one player dies/gets killed I want it to print who killed the player.
game:GetService('Players').PlayerAdded:connect(function(player) player.CharacterAdded:connect(function(character) character:WaitForChild("Humanoid").Died:connect(function() print(player.Name .. " has died!") end) end) end)
Usually, weapons shoot parts holding a value, to recognize where did it come from. It can be a string with the player's name or an object value leading to the player, so if the 'bullet' kills the victim, it can find the killer and give him the KO score, for example. If you are talking about melee weapons, it's even easier, since the tool is a child of the character.