Debounce isnt functioning properly

if Debounce then Debounce = not Debounce -- if debounce == true then make it false and move on.
 if OnOff == "off" then warn"MACHINE IS POWERLESS" return end -- end here if OnOff == "off". 
 ...--Code Here
 Delay(0.5,function()
  Debounce = not Debounce
 end)
else warn"DEBOUNCE REJECTED" return Debounce -- alt warning for clicks during debounce
end

Try adapting something like this into it maybe? I do think it could be wrapped into a single function. Unless I am mistaken.

1 Like