KontrolSystem2 icon indicating copy to clipboard operation
KontrolSystem2 copied to clipboard

Request for CONSOLE tweaking

Open PhilouDS opened this issue 1 year ago • 6 comments

Hi. I wanted to know if it was possible to add method to open/close automatically the CONSOLE and to add a couple of R/W variables to change the height and the width of the CONSOLE. Thanks :)

PhilouDS avatar Feb 24 '24 10:02 PhilouDS

I wanted to keep the CONSOLE independent of the window displaying it as there is still the possibility to display it in a different manner (e.g. in kOS there was a way to connect to it via telnet).

But I added a CONSOLE_WINDOW to ksp::ui to control it the same way I recently introduced for scripted UI-windows.

So in the next release there will be:

  • CONSOLE_WINDOW.open()
  • CONSOLE_WINDOW.close()
  • CONSOLE_WINDOW.center()
  • CONSOLE_WINDOW.is_closed
  • CONSOLE_WINDOW.size
  • CONSOLE_WINDOW.min_size
  • CONSOLE_WINDOW.position

untoldwind avatar Feb 24 '24 13:02 untoldwind

Thank you very much!

PhilouDS avatar Feb 24 '24 14:02 PhilouDS

My heart skip a beat at the idea of reintroducing telnet console :) (And I have to admit ingame console appearance control is a nice touch).

lefouvert avatar Feb 24 '24 17:02 lefouvert

In 0.5.3.2 this should work:

use { Vessel } from ksp::vessel
use { CONSOLE_WINDOW } from ksp::ui

pub fn main_flight(vessel: Vessel) -> Result<Unit, string> = {
    CONSOLE.clear()

    CONSOLE_WINDOW.open()
    CONSOLE_WINDOW.center()
}

As for the telnet (or other type) console: I am still hesitant to put this into the main mod since doing networking might be frowned upon (if I remember correctly this kOS mod for KSP1 had an elaborate opt-in dialog for this). But maybe this could be done with an optional addon that has KontrolSystem2 as a dependency.

untoldwind avatar Feb 24 '24 18:02 untoldwind

I just tried inside the VAB, it's wonderful! I never used telnet with kOS so I can't say. Thanks again fr your work.

PhilouDS avatar Feb 24 '24 19:02 PhilouDS

This issue is stale because it has been open for 60 days with no activity.

github-actions[bot] avatar Apr 25 '24 02:04 github-actions[bot]

This issue was closed because it has been inactive for 14 days since being marked as stale.

github-actions[bot] avatar May 09 '24 02:05 github-actions[bot]