Closed BobDotCom closed 1 year ago
Known bug: this prevents launching a/a weapons right now
Known bug: this prevents launching a/a weapons right now
Implementing #448 may result in a somewhat simple fix for this, though implementing it could be more work than figuring a fix with the current system.
if masterMode = A/G and releaseMode = CCRP:
run ccrpAutoRel
else
don't run ccrpAutoRel```
Two things to note:
Otherwise, it should work now.
Needs testing, but otherwise ready to merge.
There is already code to blink the FPM for CCIP, I think it would be better if you modify that instead of adding new code inside the code. Why did you do it inside, you don't want the bank angle indicator to blink also, or?
Is this tested with dropping pairs and/or rippling?
Instead of checking all bomb types in firecontrol, its better to test if the weapon is in the CCIP_CCRP vector. That vector is a new addition I just committed.
Not sure why the agm154 is in that list though..
Maybe we do that because we do not have side-by-side / tandem impact modelled, so we just allow dual release instead
I did not think my commit, would trigger conflicts, sorry. I did it to prepare for this PR.
Also the line print("tgt not found");
Could be changed to printDebug("CCRP: tgt not found");
Is this tested with dropping pairs and/or rippling?
Ripple tested and working, @BobDotCom mentioned a pair release the other day so presumably that works too.
There is already code to blink the FPM for CCIP, I think it would be better if you modify that instead of adding new code inside the code. Why did you do it inside, you don't want the bank angle indicator to blink also, or?
Moved the logic to that check.
Is this tested with dropping pairs and/or rippling?
Yes
Instead of checking all bomb types in firecontrol, its better to test if the weapon is in the CCIP_CCRP vector. That vector is a new addition I just committed.
Done
Also the line
print("tgt not found");
Could be changed toprintDebug("CCRP: tgt not found");
That line should pretty much never be called, only when the missile loses lock mid-function. I updated it though.
Ready to merge
Description
This PR implements automatic release of A/G weapons in CCRP mode. Weapons can now be dropped as they would be IRL. Pickle button (WPN REL) is pressed and held a few seconds prior to the calculated bombing solution, and the computer will automatically release the bombs when ready.
Demonstration
You can see when the trigger is pressed/released in the nasal console.
https://youtu.be/JX2pNDZjxMs
TODO List
payload/armament/distCCRP
instead off16/hud/distCCRP