Closed xOuchx0x closed 2 months ago
Thank you for the suggestion, that we have been reviewing.
We need to see who this would work with A vs. D where D = 2,3,....,N. It also will fail where A=2 (or 1, as you note, but you can't attack 1 v 1 anyway as you need to leave a troop behind). We also need to check performance where A is in the 100,000's - which can happen with progressive cards and long games.
As this is not a direct comment on the repo, we'll close this issue and add this to the suggestions list. We will review this when we review the dice code. Thanks.
The polyinomial regression techinque that is used to generate the true random vector used for balance blitz dice rolls is significantly inaccurate over 70 troops. While I understand that SMG is looking for a comprehesive solution we know that may take some time. Given that roughly half of all attacks in ranked matches are large stacks hitting single troop territories I think a short term solution would help alot in reducing excess troop loss and excessive slidering.
Copied below is C code that runs in O(N) time. It takes an input for number of attacking troops and assumes there is only 1 defender It outputs an attack vector where the indice of the array is number of troops lost.
Note I did not make a PR since this code is not in the repository Note I also did not add the trivial solution of 1v1 which I guess is techinically a 2v1 SMG please let me know if this works, doesn't work or isn't worth the effort to update.