Late reply regarding a 10 day old issue

Hey uhm sorry but I used this script Holding Key and pressing key - #20 by Forummer
and it seems not to be working. No errors at all.
Here’s the modified one I’m using currently:

local UIS = game:GetService("UserInputService")
local RS = game:GetService("ReplicatedStorage")
local Modules = RS:WaitForChild("Modules")
local Fruit = Modules:WaitForChild("Fruit")
local FM = Fruit:WaitForChild("Devil Fruits")
local FruitModule = require(FM)
local Tool = script.Parent
local ISSummon = Tool.Moves:WaitForChild("SFX"):WaitForChild("Ice Spikes"):WaitForChild("Summon")
local ISDisappear = Tool.Moves:WaitForChild("SFX"):WaitForChild("Ice Spikes"):WaitForChild("Disappear")
local Anims = Tool.Moves:WaitForChild("Animations")
local HIS = Anims:WaitForChild("HoldIceSpikes")
local PIS = Anims:WaitForChild("PunchIceSpikes")
local Player = game.Players.LocalPlayer
local PlayerGui = Player:WaitForChild("PlayerGui")
local Character = Player.Character or Player.CharacterAdded:Wait()
local Humanoid = Character:WaitForChild("Humanoid")
local HISAnim = Humanoid:LoadAnimation(HIS)
local PISAnim = Humanoid:LoadAnimation(PIS)
local Cooldown1 = false
local Holding1 = false
local remote = RS.RemoteEvents.Fruit
local mouse = Player:GetMouse()
local Cooldown2 = false
local Holding2 = false

local function zmove()
	ISSummon:Play()
	remote:FireServer("Hie", "Spike", "Start", 3, mouse.Hit)
	task.wait(3)
	ISDisappear:Play()
end

UIS.InputBegan:Connect(function(Input, Processed)
	if Processed then
		return
	end
	if Tool.Moves.Equip.Value == true then
		local Gui = PlayerGui[Tool.Moves.Name .. " Moveset"]
		if Input.KeyCode == Enum.KeyCode.E then
			if Cooldown1 then
				if Holding1 then
					Cooldown1 = true
					Holding1 = true
					HISAnim:Play()
					Humanoid.WalkSpeed = 0
					local startTime = tick()
					repeat task.wait()
						local currTime = tick() - startTime
						local keysPressed = UIS:GetKeysPressed()
						if not table.find(keysPressed, Enum.KeyCode.E) then
							return
						end
					until currTime >= 5
					HISAnim:Stop()
					PISAnim:Play()
					PISAnim:GetMarkerReachedSignal("Ice Spikes"):Connect(function()
						zmove()
						task.wait(3)
						Cooldown1 = false
					end)
					Humanoid.WalkSpeed = 18
					Holding1 = false
				end
			end
		end
	end
end)

UIS.InputEnded:Connect(function(Input, Processed)
	if Processed then
		return
	end
	if Tool.Moves.Equip.Value == true then
		if Input.KeyCode == Enum.KeyCode.E then
			if Cooldown2 then
				if Holding2 then
					Cooldown2 = true
					Holding2 = true
					HISAnim:Stop()
					PISAnim:Play()
					PISAnim:GetMarkerReachedSignal("Ice Spikes"):Connect(function()
						Humanoid.WalkSpeed = 0
						zmove()
						task.wait(3)
						Cooldown2 = false
					end)
					Humanoid.WalkSpeed = 18
					Holding2 = false
				end
			end
		end
	end
end)

image

local UIS = game:GetService("UserInputService")
local RS = game:GetService("ReplicatedStorage")
local Modules = RS:WaitForChild("Modules")
local Fruit = Modules:WaitForChild("Fruit")
local FM = Fruit:WaitForChild("Devil Fruits")
local FruitModule = require(FM)
local Tool = script.Parent
local ISSummon = Tool.Moves:WaitForChild("SFX"):WaitForChild("Ice Spikes"):WaitForChild("Summon")
local ISDisappear = Tool.Moves:WaitForChild("SFX"):WaitForChild("Ice Spikes"):WaitForChild("Disappear")
local Anims = Tool.Moves:WaitForChild("Animations")
local HIS = Anims:WaitForChild("HoldIceSpikes")
local PIS = Anims:WaitForChild("PunchIceSpikes")
local Player = game.Players.LocalPlayer
local PlayerGui = Player:WaitForChild("PlayerGui")
local Character = Player.Character or Player.CharacterAdded:Wait()
local Humanoid = Character:WaitForChild("Humanoid")
local HISAnim = Humanoid:LoadAnimation(HIS)
local PISAnim = Humanoid:LoadAnimation(PIS)
local Cooldown1 = false
local Holding1 = false
local remote = RS.RemoteEvents.Fruit
local mouse = Player:GetMouse()
local Cooldown2 = false
local Holding2 = false

local function zmove()
	ISSummon:Play()
	remote:FireServer("Hie", "Spike", "Start", 3, mouse.Hit)
	task.wait(3)
	ISDisappear:Play()
end

UIS.InputBegan:Connect(function(Input, Processed)
	if Processed then
		return
	end
	if Tool.Moves.Equip.Value == true then
		local Gui = PlayerGui[Tool.Moves.Name .. " Moveset"]
		if Input.KeyCode == Enum.KeyCode.E then
			if Cooldown1 then
				if Holding1 then
					Cooldown1 = true
					Holding1 = true
					HISAnim:Play()
					Humanoid.WalkSpeed = 0
					local ePressCheck = false
					local startTime = tick()
					repeat task.wait()
						local currTime = tick() - startTime
						local keysPressed = UIS:GetKeysPressed()
						for _, key in ipairs(keysPressed) do
							if key.KeyCode == Enum.KeyCode.E then
								ePressCheck = true
							end
							if ePressCheck then
								ePressCheck = false
								continue
							elseif not ePressCheck then
								return
							end
						end
					until currTime >= 5
					HISAnim:Stop()
					PISAnim:Play()
					PISAnim:GetMarkerReachedSignal("Ice Spikes"):Connect(function()
						zmove()
						task.wait(3)
						Cooldown1 = false
					end)
					Humanoid.WalkSpeed = 18
					Holding1 = false
				end
			end
		end
	end
end)

UIS.InputEnded:Connect(function(Input, Processed)
	if Processed then
		return
	end
	if Tool.Moves.Equip.Value == true then
		if Input.KeyCode == Enum.KeyCode.E then
			if Cooldown2 then
				if Holding2 then
					Cooldown2 = true
					Holding2 = true
					HISAnim:Stop()
					PISAnim:Play()
					PISAnim:GetMarkerReachedSignal("Ice Spikes"):Connect(function()
						Humanoid.WalkSpeed = 0
						zmove()
						task.wait(3)
						Cooldown2 = false
					end)
					Humanoid.WalkSpeed = 18
					Holding2 = false
				end
			end
		end
	end
end)
repeat task.wait()
	local currTime = tick() - startTime
	local keysPressed = UIS:GetKeysPressed()
	for _, key in ipairs(keysPressed) do
		if key.KeyCode == Enum.KeyCode.E then
			ePressCheck = true
		end
		if ePressCheck then
			ePressCheck = false
			continue
		elseif not ePressCheck then
			return
		end
	end
until currTime >= 5

GetTouchingParts() returns an array but you need to fetch the value of the KeyCode property of each key returned in that array.

I don’t really know what you did there but it didn’t fix it. https://gyazo.com/6e502ae9b6d07863e9ab13fef18107e0
Is it me or this is the same code I sent u? and what do you mean by

GetTouchingParts() returns an array but you need to fetch the value of the KeyCode property of each key returned in that array.

this? I never used get touching parts in the localscript.

I still haven’t figured it out…

sorry again but I’m still so confused!
What do u mean fetch the value of the keycode property of each key returned in that array? You mean the gettouchingparts??

It’s been 2 days you haven’t responded I don’t mind if you dont but I’m just here waiting since I can’t fix it and I didn’t know what you meant by (I’m pretty curious too)

GetTouchingParts() returns an array but you need to fetch the value of the KeyCode property of each key returned in that array.

Edit: I thought this was private messaging.