Machine Drive Controls 1.0.1.0 - TEST BUILD

Changes
- Added folding-based raise/lower handling for implements such as the JD1600.
  Its XML uses foldMiddleAnimTime=0.17; MDC previously missed this lower path.
  Uses the native directional Foldable lowering callback and synchronizes the
  attached hitch state. Repeated commands do not restart the same motion.
- Keeps worker, running-engine and folding-power checks. Fold rejection does
  not fall through into unrelated hitch/AI operations.
- Calls Attachable lowering on the implement rather than the tractor; limits
  specialization calls to matching objects. Allows the existing AI fallback
  after a successful no-op call. Prevents cyclic attachment traversal.
- Added optional Thresher ON, Thresher OFF, Header ON, Header OFF assignments.
  They start unbound and participate in existing maintained-switch cleanup.
  Uses the game's turn-on action and existing worker protections.
  Thresher targets the combine regardless of implement selection. Header targets
  the selected attached cutter, or the only attached cutter. Missing/ambiguous
  headers do nothing; a header still coupled to its parent is rejected.
- Existing action names and default bindings are unchanged. Drive, throttle,
  lights, HUD and existing binding-cleanup implementation are unchanged.

Install
1. Close FS25. Back up your current MDC ZIP and working inputBinding.xml.
2. Rename this test ZIP to FS25_MachineDriveControls.zip when replacing MDC.
   Keep only one active MDC copy (including any unpacked folder).
3. Do not reset controls. Bind the four new optional actions under Machine
   Drive Controls. Use separate contacts/keys from existing Tool ON/OFF.
4. Enable Realistic Harvesting independent launch for separate operation;
   load/reload the save with it enabled so attached headers initialize correctly.
   MDC does not change that setting. With normal coupled behavior, thresher
   activation may also activate the header through the game's normal logic.

Test
- JD1600: with engine running, compare MDC Lower/Raise with the normal command.
  Repeat Lower while lowering/lowered and Raise while raising/raised; verify
  no reversal, full transport fold, or accidental turn-on. Try reversal in motion.
- Repeat with the previously working seeder and combine header. Check that
  raising/lowering retains tool ON/OFF state. Test engine-off and worker guards.
- Realistic Harvesting: Thresher ON alone, Header ON, Header OFF while thresher
  stays running, then Thresher OFF. Repeat ON/ON and OFF/OFF; no toggling.
  Change selected implement and repeat. Detach header and try Header ON:
  it should do nothing, without switching the combine or another implement.
- Recheck existing Tool ON/OFF, lights, RPM, T28 ISO, pickup and Super Strength.
- Save controls, quit fully, restart, and check bindings persist. Supply log.txt.

Verification
Passed Lua 5.1 syntax and mocked runtime regression tests covering folding
motion/repetition/reversal, hitch synchronization, engine/power/worker guards,
successful no-op fallback, ON/OFF preservation, cyclic attachment traversal,
independent harvesting targets, blocked/missing/ambiguous headers, release
events, native action rejection, existing Tool ON/OFF, registration/cleanup of
all 16 actions, XML/action/localization consistency, original binding defaults,
and ZIP integrity. These are not in-game FS25 tests; gameplay remains to verify.

Reference checked: GIANTS FS25 Foldable and Attachable documentation, plus
the supplied JD1600 XML and installed Realistic Harvesting source.
https://gdn.giants-software.com/documentation_scripting_fs25.php?category=78&class=674&version=script
https://gdn.giants-software.com/documentation_scripting_fs25.php?category=78&class=628&version=script
