-- Sub to me! https://www.youtube.com/channel/UCrG4Cnjcz1mkDopaqPGaW3A
-- My discord! https://discord.gg/6x56rTZ5c8
-- Good luck!


local mouse = game.Players.LocalPlayer:GetMouse()

function Light()
	local player = game.Players.LocalPlayer
	local playerChar = player.Character
	local playerLight = playerChar.Head:FindFirstChild("Light")

	if playerLight then
		playerLight:Destroy()
	else
		local light = Instance.new("SurfaceLight",playerChar:FindFirstChild("Head"))
		light.Name = "Light"
		light.Range = 60 -- Change lighting range / Изменение диапозона освещения
		light.Angle = 50 -- Change lighting angle / Изменение угла освещения
		light.Shadows = true
		light.Brigtness = 3 -- Change lighting brigtness / Изменение яркости освещения
	end
end

mouse.KeyDown:connect(function(key)

	key = key:lower()
	if key == "f" then
		script.FlashLightSound:Play()
		Light()
	end
end)
