scudState – Talk

From Bohemia Interactive Community
Jump to navigation Jump to search
mNo edit summary
 
mNo edit summary
 
(2 intermediate revisions by one other user not shown)
Line 2: Line 2:


[[User:Planck|Planck]] 11:48, 20 August 2006 (CEST)
[[User:Planck|Planck]] 11:48, 20 August 2006 (CEST)
== Return value not exact ==
When the scud is ready for launch (vertical) the scudState returned is not exactly 2 - In my case it reports 2.0021.  So checking for status using <= 2 will not work as intended, < 3 should be used instead.
--[[User:Oogieboogie|Oogieboogie]] 04:32, 8 November 2007 (CET)
Using <=2 or even <3 will also return true if scudState is 0 or 1 or indeed any value less than or equal to 2 and less than 3 respectively.
Just [[round]] the return value before testing it.
[[User:Planck|Planck]] 15:47, 8 November 2007 (CET)

Latest revision as of 16:47, 8 November 2007

According to comref, the version for this command is 1.28

Planck 11:48, 20 August 2006 (CEST)

Return value not exact

When the scud is ready for launch (vertical) the scudState returned is not exactly 2 - In my case it reports 2.0021. So checking for status using <= 2 will not work as intended, < 3 should be used instead.

--Oogieboogie 04:32, 8 November 2007 (CET)

Using <=2 or even <3 will also return true if scudState is 0 or 1 or indeed any value less than or equal to 2 and less than 3 respectively.

Just round the return value before testing it.

Planck 15:47, 8 November 2007 (CET)