Hi there, I am working on a boss fight that has an attack. I have tested the main mechanic and it seems to work just fine, I left it on with a 10 second cooldown and tested my game. The attack worked once, but after another 10 seconds it just never appeared. I added print(ββ) to my code to see if it registered the second time through, and yes it did but no attack. Then I had the idea of changing the cooldown to 1 seconds instead of 10 seconds, and the attack happened more than 2 times. I will include screenshots below to make what I am saying a bit easier.
Local script firing a remote event to do the attack
The wait(1) is the cooldown
The code that the local script is firing.
That code works fine.
What it looks in game with 1 second cooldown (after the event has been fired twice)
Then with 10 second cooldown it doesnβt work.
I have spent so long trying to find out the solution to this problem but no solution has popped up in my head, please help me answer my question.