the purpose of calling scan() in onScannedRobot()

Kent Tong <[email protected]> Tue, 28 Nov 2023 01:05:52 -0800 (PST)
Newsgroups gmane.comp.java.robocode
Message-ID <[email protected]>
------=_Part_167044_909537415.1701162352250
Content-Type: multipart/alternative; 
	boundary="----=_Part_167045_425097019.1701162352250"

------=_Part_167045_425097019.1701162352250
Content-Type: text/plain; charset="UTF-8"

Hi,

I understand that calling scan() in onScannedRobot() will restart the event 
handler if a robot is indeed detected, but the event handler seems to be 
called in the next turn instead of immediately as stated by the api doc.

This issue aside, my primary question is with the purpose of calling scan() 
in onScannedRobot(). Is it to prevent the movement in run()? 

Many thanks in advance

-- 
You received this message because you are subscribed to the Google Groups "Robocode" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [email protected].
To view this discussion on the web visit https://groups.google.com/d/msgid/robocode/f1a59bd3-5751-4e0c-a203-07574611c16an%40googlegroups.com.

------=_Part_167045_425097019.1701162352250
Content-Type: text/html; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable

Hi,<div><br /></div><div>I understand that calling scan() in=C2=A0onScanned=
Robot() will restart the event handler if a robot is indeed detected, but t=
he event handler seems to be called in the next turn instead of immediately=
 as stated by the api doc.</div><div><br /></div><div>This issue aside, my =
primary question is with the purpose of calling scan() in onScannedRobot().=
 Is it to prevent the movement in run()?=C2=A0</div><div><br /></div><div>M=
any thanks in advance</div>

<p></p>

-- <br />
You received this message because you are subscribed to the Google Groups &=
quot;Robocode&quot; group.<br />
To unsubscribe from this group and stop receiving emails from it, send an e=
mail to <a href=3D"mailto:[email protected]">robocode+u=
[email protected]</a>.<br />
To view this discussion on the web visit <a href=3D"https://groups.google.c=
om/d/msgid/robocode/f1a59bd3-5751-4e0c-a203-07574611c16an%40googlegroups.co=
m?utm_medium=3Demail&utm_source=3Dfooter">https://groups.google.com/d/msgid=
/robocode/f1a59bd3-5751-4e0c-a203-07574611c16an%40googlegroups.com</a>.<br =
/>

------=_Part_167045_425097019.1701162352250--

------=_Part_167044_909537415.1701162352250--