Jump to content
juleshuxley

Detect the type of locking system an ammo instance uses?

Recommended Posts

getNumber ( configfile >> "CfgAmmo" >> "M_120mm_cannon_ATGM" >> "laserLock" );

I'm trying to detect when a missile uses a laser lock / ir lock/ any other types of lock Arma uses. Unfortunately the above code returns 0 for the ATGM, when it should return 1 as the ATGM definitely laser guided?

something to do with the M_120mm_cannon-ATGM having the "class SensorTemplateLaser", maybe?

Share this post


Link to post
Share on other sites

play with weaponLockSystem (cfgAmmo):

 

configfile >> "CfgAmmo" >> "M_120mm_cannon_ATGM" >> "weaponLockSystem"  // 16 = missile, not laser-guided
but

configfile >> "CfgAmmo" >> "Bo_GBU12_LGB" >> "weaponLockSystem"  // 4 = laser-guided

 

Consider "missile" (16) as generic. In this case, you can add the lock type:

configfile >> "CfgAmmo" >> "M_120mm_cannon_ATGM" >> "lockType" // 1 here, means:  Manual - beamriding guidance

 

You can work these data like I show you in the other thread.

See also: https://community.bistudio.com/wiki/Arma_3_Countermeasures

 

  • Like 1

Share this post


Link to post
Share on other sites

Right so you're saying I should have an if statement that says when weaponLockSystem is 16, check it's lockType because 16 is generic. Else, 4 means laser guided

Share this post


Link to post
Share on other sites

Please sign in to comment

You will be able to leave a comment after signing in



Sign In Now

×