Forum Discussion
o0netquik0o
4 years agoRising Ace
"Trampsz;c-2224226" wrote:"Trampsz;c-2160787" wrote:
Hi all
I'm using the Wavy script (in the SoO pack) Wavy 0.5.5
You have probably noticed for some time now it calculates the "bases in range" incorrectly.
As you can see from the screenshot, the rectangles show all the bases in my range that I can attack - 17 in total, but Wavy counts only 14.
https://prnt.sc/uxpzrs
It's been an issue that i have lived with for a long time but I just wondered if anyone had developed a fix?
Thanks
Tramps
PS I do have another script active that shows the correct bases in range when you simulate a move (perhaps its "the movement" script), but this only shows the number of bases at a simulated location and not when you simply click on your current position.
Sorry for the long delay in coming back to this series of posts on this subject @o0netquik0o thanks for all your input, I didn't get any notifications so was unaware there was any replies.
I think the recent reply specifically posted by @Chertosa (thank you!) in this separate link finally answered this question for me. https://forums.ea.com/en/commandandconquer/discussion/275439/wavy
Essentially it seems the FG can only attack a radius of 10 fields whereas a player base can attack 10.5 fields. Therefore as Wavy relates to FG attacking a player base (ie the number of FG attack waves we can expect) then it should be calculated using 10 fields.
I have a suspicion that Wavy in the SOO pack may still be calculating wrong as in a recent gameplay, according to Wavy I was in a 2 wave area (20+ bases) but I only received 1 attack, so perhaps it is using 10.5 fields in the formula instead of 10.
well as already said wavy use ClientLib.Data.MainData.GetInstance().get_Server().get_MaxAttackDistance() that is 10.5 (while 0.5.5 was using 10). This was a fix introduced if remember right because some people (like you) blamed about incorrect waves. Now in the code wavy actually use "floored" value max distance (10) to scan min and max but it use "squared" not floored value (10.5*10.5=110,25) @nefrontheone @iguanaworld if I revert the fix the original issue will come up again. From https://forums.ea.com/en/commandandconquer/discussion/comment/2223718/#Comment_2223718 i can't be sure. maybe it's a floor/round difference only between players and fg. Maybe leaving the maxattackdistance form server we can try to see what results we get using floored squared value or squaring floored value (110 vs 100). In game code i can't locate fg attack function