Attack Cooldown can't stop reseting while in battle
CorentG opened this issue · 13 comments
Issue Description:
This is an annoying bug : it seem that the attack cooldown reset to 0 when using a special move, but it spam the reset, making the move unusable. This is especially noticable when using Pokeplayer.
What happens:
If i am a trainer and i told my pokemon to use a special move, it sometimes spam-reset (if the opponent pokemon is alive after one hit), but it's actually more noticable when using Pokeplayer (as a pokemon), as it happen everytime (if the opponent survive one hit). But it seems the bug work with any other move, as long as the pokemon is close enought to the opponent to do damage or using a move like recover. It look like it's affect only players, also.
What you expected to happen:
The cooldown properly reset, continue until it's full, and simply be able to use the special move.
Steps to reproduce:
(When trainer)
1.Try using a special move with any pokemon on a pokemon
2.If the opponent doesn't die, it will most likely start the spam thing
3.It will sometime use the move, but a lot of time were lost
...
(When Pokemon)
- Use pokeplayer to turn into a pokemon with a special move
- Use the move on any pokemon, as long as he doesn't die in one hit
- It will spam the cooldown
Affected Versions (Do not use "latest"):
- Pokecube Core:6.21.7
- Pokecube Revival (if applicable):6.11.5
- Pokecube Mobs (if applicable):2.14.12
- Minecraft: 1.12.2
- Forge:14.23.0.2509
I had this happen once, when I sent mew after a zombie, it then happened 3-4 times shortly thereafter, but not happened again since, Been trying to get it to occur again, but won't happen in testing environment...
If you can find a way to make it happen reliably, that will be very helpful.
I have never noticed this to occur, and I spam ice beam at everything, can you get a screenshot or maybe a video of the issue in action?
I will see if I can replicate this @Thutmose just give me a little bit.
I will attempt to get that happening then, it didn't happen when i tried spamming ice beam as a mew, I will try as a pikachu instead
I found what's wrong, it's because in my config file i put attackcooldown to 30, so the bug come from the fact that i have augmented the cooldown... but when i set it back to 20, it's work well.
ahh, thanks, I will set that to 30 then test
Edit: confirmed that setting it to 30 makes the bug occur immediately when using pokeplayer, I shall try to get this fixed now.
It seem also that the bug only work when another pokemon try to attack the player, or the pokemon of the player.
seems mentioning that the PR might fix the bug closed the issue... reopened it till can confirm it fixes.
I have done a fix that stopped it working in my development environment, I can try to get a release out at some point so you can test the fix.
I will try to get it uploaded in the next couple minutes, not sure when it will be approved though
it will be here whenever it is approved: https://minecraft.curseforge.com/projects/pokecube-core/files/2489045
It's work well with pokeplayer : https://youtu.be/dCQuWaHUpBwI
I was not using any keys, and it spammed.