Skip to content

Conversation

@adventure-gpt
Copy link

Add full MechJeb 2.15.1 IVA feature parity

This adds comprehensive IVA menu support for MechJeb 2.15.1, achieving
near-100% feature parity with MJ's IMGUI interface.

New files:

  • MechJebProxy.cs: Complete reflection-based wrapper for MJ 2.15.1

    • 367 public static methods covering all MJ autopilots
    • Ascent, landing, rendezvous, docking autopilots
    • Attitude control, thrust limiting, staging control
    • Maneuver planner operations
    • All use PascalCase field names for MJ 2.15.1 compatibility
  • MechJebRPMMenu.cs: Enhanced IVA text menu system

    • Full ascent guidance menus with all parameters
    • Landing guidance with target selection
    • Rendezvous and docking autopilot controls
    • Maneuver planner with orbit operations
    • Smart A.S.S. attitude control
    • Thrust and staging controller settings

Modified:

  • OrbitExtensions.cs: Enable orbit helper methods needed by new menus
    (SwappedOrbitalVelocityAtUT, Radius, NextApoapsisTime, etc.)

Local User added 2 commits January 20, 2026 12:25
- Update JSIMechJeb.cs field bindings to use PascalCase for MJ 2.15.1:
  - MechJebCore: target->Target, node->Node, attitude->Attitude, vesselState->VesselState
  - AbsoluteVector: latitude->Latitude, longitude->Longitude
  - ComputerModule: enabled->Enabled, users->Users
  - EditableDouble/EditableDoubleMult: val->Val property
  - ReentrySimulation.Result: outcome->Outcome, endPosition->EndPosition, endUT->EndUT

- Add MechJebModuleAscentSettings support (replaces AscentAutopilot/AscentGuidance):
  - DesiredOrbitAltitude, DesiredInclination fields
  - AscentAutopilot property access for autopilot control

- Fix FuelFlowSimulation type lookup:
  - Try MechJebLib assembly first (MJ 2.15.1 moved it there)
  - Fall back to nested type in MechJeb2 assembly

- Fix stage stats handling for List<FuelStats>:
  - Use Count property and get_Item method instead of array access

- Fix ButtonAscentGuidance/ButtonAscentGuidanceState:
  - Try MechJebModuleAscentBaseAutopilot first
  - Fall back to AscentSettings.AscentAutopilot property
  - Use MechJebModuleAscentMenu instead of AscentGuidance
  - Handle Users property with PascalCase fallback

- Fix MechJebRPM.cs:
  - Update module check from MechJebModuleAscentAutopilot to MechJebModuleAscentSettings
  - Fix Force Roll menu index (5->6) for Home button adjustment
This adds comprehensive IVA menu support for MechJeb 2.15.1, achieving
near-100% feature parity with MJ's IMGUI interface.

New files:
- MechJebProxy.cs: Complete reflection-based wrapper for MJ 2.15.1
  - 367 public static methods covering all MJ autopilots
  - Ascent, landing, rendezvous, docking autopilots
  - Attitude control, thrust limiting, staging control
  - Maneuver planner operations
  - All use PascalCase field names for MJ 2.15.1 compatibility

- MechJebRPMMenu.cs: Enhanced IVA text menu system
  - Full ascent guidance menus with all parameters
  - Landing guidance with target selection
  - Rendezvous and docking autopilot controls
  - Maneuver planner with orbit operations
  - Smart A.S.S. attitude control
  - Thrust and staging controller settings

Modified:
- OrbitExtensions.cs: Enable orbit helper methods needed by new menus
  (SwappedOrbitalVelocityAtUT, Radius, NextApoapsisTime, etc.)

This is an optional enhancement that builds on the basic MJ 2.15.1
integration. Users who only need basic functionality can use the
mechjeb-2.15.1-integration branch instead.
Local User added 2 commits January 22, 2026 14:36
- Fixed checkbox display issue: RPM interprets [text] as color tags, so
  square brackets were being stripped. Now using green color highlighting
  via isSelected property instead of checkbox characters.

- Fixed ClickProcessor alias for menu button interaction

- Fixed Advanced Transfer maneuver node creation - now checks if
  computation is finished before attempting to create nodes

- Added try-catch protection in UpdateTrackedItems to prevent exceptions
  from breaking label updates

- Disabled old MechJebRPM.csproj to prevent DLL locking issues during build

- Radio buttons (Rendezvous/Transfer, Lowest DV/ASAP) now use color
  highlighting for selection state
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant