How can I modify my roblox shield system to make it possible to create an NPC with a shield that can be broken but doesn't run out of time?

Client:
```
-- LocalScript inside StarterPlayerScripts or StarterCharacterScripts

local UserInputService = game:GetService("UserInputService")
local ContextActionService = game:GetService("ContextActionService")
local Players = game:GetService("Players")
local ReplicatedStorage = game:GetService("ReplicatedStorage")

local ShieldEvent = ReplicatedStorage:WaitForChild("Shield")
local ShieldBreakEvent = ReplicatedStorage:WaitForChild("ShieldBreak") -- From server to client

local player = Players.LocalPlayer
local character = player.Character or player.CharacterAdded:Wait()
local humanoid = character:WaitForChild("Humanoid")

-- Animations
local holdAnimation = script:WaitForChild("Hold") -- Animation for holding shield
local breakAnimation = script:WaitForChild("Break") -- Animation for shield breaking

local holdTrack = humanoid:LoadAnimation(holdAnimation)
local breakTrack = humanoid:LoadAnimation(breakAnimation)

-- Function to handle shield activation/deactivation
local function onShieldAction(actionName, inputState, inputObject)
	if inputState == Enum.UserInputState.Begin then
		if character:FindFirstChild("ShieldReady").Value then
			ShieldEvent:FireServer("Activate")
			holdTrack:Play()
		end
	elseif inputState == Enum.UserInputState.End then
		-- 'R' key released
		ShieldEvent:FireServer("Deactivate")
		holdTrack:Stop()
	end
end

-- Bind the action to the 'R' key
ContextActionService:BindAction("ShieldAction", onShieldAction, true, Enum.KeyCode.R)

-- Listen for ShieldBreak event from the server
ShieldBreakEvent.OnClientEvent:Connect(function()
	-- Play break animation and stop hold animation
	holdTrack:Stop()
	breakTrack:Play()
end)
```

Server:
```
-- Script inside ServerScriptService

local ReplicatedStorage = game:GetService("ReplicatedStorage")
local ShieldEvent = ReplicatedStorage:WaitForChild("Shield")
local ShieldBreakEvent = ReplicatedStorage:WaitForChild("ShieldBreak")

local ShieldModule = require(ReplicatedStorage:WaitForChild("GameModules"):WaitForChild("Shield"))

-- Table to store player's original walk speed and jump power
local playerStats = {}

-- Function to handle ShieldEvent
ShieldEvent.OnServerEvent:Connect(function(player, action)
	if action == "Activate" then
		local character = player.Character
		if character and character:FindFirstChild("ShieldReady") and character.ShieldReady.Value then
			-- Store player's walk speed and jump power if not already stored
			local humanoid = character:FindFirstChildWhichIsA("Humanoid")
			if humanoid then
				if not playerStats[player] then
					playerStats[player] = {WalkSpeed = humanoid.WalkSpeed, JumpPower = humanoid.JumpPower}
				end
				require(ReplicatedStorage:FindFirstChild("GameModules"):FindFirstChild("PlaySound")).play(
					ReplicatedStorage.GameSounds.ShieldSounds.Activate, 
					character:FindFirstChild("HumanoidRootPart")
				)
				humanoid.WalkSpeed = 0
				humanoid.JumpPower = 0
			end
			ShieldModule.Shield(player)
		end
	elseif action == "Deactivate" then
		ShieldModule.Disable(player)
	end
end)

-- Function to restore player's walk speed and jump power
local function restorePlayerStats(player)
	local character = player.Character
	if character then
		local humanoid = character:FindFirstChildWhichIsA("Humanoid")
		if humanoid and playerStats[player] then
			humanoid.WalkSpeed = playerStats[player].WalkSpeed
			humanoid.JumpPower = playerStats[player].JumpPower
			playerStats[player] = nil
		end
	end
end

-- Expose restorePlayerStats function and ShieldBreakEvent to the ShieldModule
ShieldModule.restorePlayerStats = restorePlayerStats
ShieldModule.ShieldBreakEvent = ShieldBreakEvent
```

Module:
```
-- ModuleScript inside ReplicatedStorage.GameModules.Shield

local ShieldModule = {}

local RunService = game:GetService("RunService")
local TweenService = game:GetService("TweenService")
local ReplicatedStorage = game:GetService("ReplicatedStorage")

local shieldData = {}

-- Reference to the ShieldParticles attachment (ensure the path is correct)
local shieldAttachmentTemplate = script.ParticleHold:WaitForChild("ShieldParticles")

-- Exposed from the server script
ShieldModule.ShieldBreakEvent = nil
ShieldModule.restorePlayerStats = nil

-- Function to cancel any running timers for the player
local function cancelTimers(player)
	local data = shieldData[player]
	if data then
		if data.shieldTimer then
			data.shieldTimer:Disconnect()
			data.shieldTimer = nil
		end
		if data.cooldownTimer then
			data.cooldownTimer:Disconnect()
			data.cooldownTimer = nil
		end
	end
end

function ShieldModule.Shield(player)
	local character = player.Character
	if not character or not character:FindFirstChild("Torso") then return end
	local humanoid = character:FindFirstChildWhichIsA("Humanoid")
	if not humanoid then return end

	-- Check if ShieldReady is false
	if character:FindFirstChild("ShieldReady") and not character.ShieldReady.Value then
		return
	end

	-- If ShieldActive is already true, shield is already active
	if character:FindFirstChild("ShieldActive") and character.ShieldActive.Value then
		return
	end

	-- Set ShieldActive to true
	local shieldActive = character:FindFirstChild("ShieldActive") or Instance.new("BoolValue", character)
	shieldActive.Name = "ShieldActive"
	shieldActive.Value = true

	-- Ensure ShieldReady is true
	local shieldReady = character:FindFirstChild("ShieldReady") or Instance.new("BoolValue", character)
	shieldReady.Name = "ShieldReady"
	shieldReady.Value = true

	-- Clone the ShieldParticles attachment and parent it to the character's Torso
	local shieldAttachment = shieldAttachmentTemplate:Clone()
	shieldAttachment.Parent = character:FindFirstChild("Torso")
	shieldAttachment.Name = "ShieldAttachment"

	-- Store shield data
	shieldData[player] = shieldData[player] or {}
	shieldData[player].attachment = shieldAttachment

	-- Start shield timer (3 seconds)
	local shieldStartTime = tick()
	shieldData[player].shieldStartTime = shieldStartTime

	-- Use Heartbeat to update color every frame and check duration
	local function onHeartbeat(deltaTime)
		local currentTime = tick()
		local elapsedTime = currentTime - shieldStartTime
		local data = shieldData[player]
		if not data then return end

		-- Update particle color to become more red over time
		local progress = math.clamp(elapsedTime / 3, 0, 1)
		local redColor = Color3.new(1, 0, 0) -- Red
		local startColor = Color3.new(0, 1, 0) -- Green
		local currentColor = startColor:Lerp(redColor, progress)

		-- Update color of particles and PointLight
		for _, descendant in pairs(shieldAttachment:GetDescendants()) do
			if descendant:IsA("ParticleEmitter") then
				local colorSequence = ColorSequence.new(currentColor)
				descendant.Color = colorSequence
			elseif descendant:IsA("PointLight") then
				descendant.Color = currentColor
			end
		end

		-- Check if 3 seconds have elapsed
		if elapsedTime >= 3 then
			-- Shield duration is over
			ShieldModule.DestroyShield(player, true) -- true indicates overTime
		end
	end

	shieldData[player].shieldTimer = RunService.Heartbeat:Connect(onHeartbeat)
end

function ShieldModule.DestroyShield(player, overTime)
	local data = shieldData[player]
	if not data then return end

	cancelTimers(player)

	local character = player.Character
	if not character then return end

	-- Turn off ShieldActive and ShieldReady
	local shieldActive = character:FindFirstChild("ShieldActive")
	local shieldReady = character:FindFirstChild("ShieldReady")

	if shieldActive then
		shieldActive.Value = false
	end

	if shieldReady then
		shieldReady.Value = false
	else
		shieldReady = Instance.new("BoolValue", character)
		shieldReady.Name = "ShieldReady"
		shieldReady.Value = false
	end

	-- Start cooldown timer (6 seconds if destroyed over time, else 3 seconds)
	local cooldownStartTime = tick()
	local cooldownDuration = overTime and 6 or 3

	local function onCooldownHeartbeat()
		local currentTime = tick()
		local elapsedTime = currentTime - cooldownStartTime
		if shieldReady.Value == true then
			shieldReady.Value = false -- Prevent exploiters from forcing it back on
		end
		if elapsedTime >= cooldownDuration then
			shieldReady.Value = true
			-- Destroy cooldown timer
			if data.cooldownTimer then
				data.cooldownTimer:Disconnect()
				data.cooldownTimer = nil
			end
		end
	end

	data.cooldownTimer = RunService.Heartbeat:Connect(onCooldownHeartbeat)
	require(ReplicatedStorage:FindFirstChild("GameModules"):FindFirstChild("PlaySound")).play(
		ReplicatedStorage.GameSounds.ShieldSounds.Stop, 
		character:FindFirstChild("HumanoidRootPart")
	)
	if overTime then
		local humanoid = character:FindFirstChildWhichIsA("Humanoid")
		require(ReplicatedStorage:FindFirstChild("GameModules"):FindFirstChild("PlaySound")).play(
			ReplicatedStorage.GameSounds.ShieldSounds.Break, 
			character:FindFirstChild("HumanoidRootPart")
		)
		-- Fire ShieldBreakEvent to client to play break animation
		if ShieldModule.ShieldBreakEvent then
			ShieldModule.ShieldBreakEvent:FireClient(player)
		end
	end

	-- Restore player's walk speed and jump power
	if ShieldModule.restorePlayerStats then
		ShieldModule.restorePlayerStats(player)
	end
	-- Tween light brightness over 1.5 seconds, then destroy attachment
	if data.attachment and data.attachment.Parent then
		local shieldAttachment = data.attachment
		-- Turn off particles
		for _, descendant in pairs(shieldAttachment:GetDescendants()) do
			if descendant:IsA("ParticleEmitter") then
				descendant.Enabled = false
			end
		end

		local pointLight = shieldAttachment:FindFirstChildWhichIsA("PointLight")

		if pointLight then
			local initialBrightness = pointLight.Brightness
			local targetBrightness = 0
			local tweenInfo = TweenInfo.new(1.5)
			local tween = TweenService:Create(pointLight, tweenInfo, {Brightness = targetBrightness})
			tween:Play()
		end
		task.delay(1.5, function()
			shieldAttachment:Destroy()
		end)
		data.attachment = nil
	end

	-- Clean up shieldData
	shieldData[player] = nil
end

function ShieldModule.Disable(player)
	ShieldModule.DestroyShield(player, false)
end

return ShieldModule
```