How do I uh make a KillFeed thingy? Like after I killed someone with a gun, how do I make a GUI appear saying “Killed: ‘theplayerthatIkill’”
something like the above when you killed someone
How do I uh make a KillFeed thingy? Like after I killed someone with a gun, how do I make a GUI appear saying “Killed: ‘theplayerthatIkill’”
something like the above when you killed someone
Theres not one definitive answer… It depends on the system you are using. I would recommend just firing a remote to all clients with the name after someone is killed and having a gui display that
my system is like checking if the humanoid’s health that took damage is dead after getting shot though, how should I script it to fireAll client?
you have to communicate the person who shot em
local function onRayHit(cast, result, velocity, bullet)
if not result then return end
local newDamage = Damage
local hit = result.Instance
local char = hit:FindFirstAncestorWhichIsA("Model")
if char and char:FindFirstChild("Humanoid") then
if hit.Name == "Head" then
local C = script.Blood:Clone()
hitSound:Play()
newDamage = newDamage * HeadMulti
char.Humanoid:TakeDamage(newDamage)
char.Humanoid.StateChanged:Connect(function(oldState, newState)
if newState == Enum.HumanoidStateType.Dead then
ReturnRemote:FireAllClients(hit.Parent.Name)
end
end)
C.Enabled = true
C.Parent = hit
wait(0.2)
C:Destroy()
else
local C = script.Blood:Clone()
hitSound:Play()
char.Humanoid:TakeDamage(newDamage)
char.Humanoid.StateChanged:Connect(function(oldState, newState)
if newState == Enum.HumanoidStateType.Dead then
ReturnRemote:FireAllClients(hit.Parent.Name)
end
end)
C.Enabled = true
C.Parent = hit
wait(0.2)
C:Destroy()
end
end
game:GetService("Debris"):AddItem(bullet, 0.2)
end
^^ Killed checker
OnClientEvent Script:
local Remote = game.ReplicatedStorage.a
Remote.OnClientEvent:Connect(function(player, PlayerFired)
script.Parent.TextLabel.Text = "Terminated: "… PlayerFired
script.Parent.TextLabel.Visible = true
wait(5)
script.Parent.TextLabel.Visible = false
end)
is this correct?
My suggestion: detect the bullet if the bullet hit the character and when it hit and the character’s humanoid health is lower than 0 or equal to 0 then that mean the player that shoot the gun killed that player and to find the player name you can use the character name or you can do local player = game.Players:GetPlayerFromCharacter(Humanoid)
okie thank u for deh suggestion ima try
Still doesnt work tho, the error says couldnt cast value to object