Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR LUA

luau how to make a kill brick

local killBrick = -- index your kill brick here

local function onTouched(hit)
	local humanoid = hit.Parent:FindFirstChild("Humanoid")
	if humanoid == nil then return end
	
	humanoid:TakeDamage(humanoid.MaxHealth)
    -- doesn't kill if a ForceField is guarding the Character
end

killBrick.Touched:Connect(onTouched)
 
PREVIOUS NEXT
Tagged: #luau #kill #brick
ADD COMMENT
Topic
Name
8+3 =