-
Notifications
You must be signed in to change notification settings - Fork 14
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Access Vessel in the VAB #127
Comments
I did some preparation to have entry points for all the different game modes, but this was mostly taken over from the original implementation for KSP1. Obviously the main focus has been on the flight-mode so far and wait for all the other parts of the game to settle down for a bit. From what I can tell, inside the VAB the vessel (as understood by ... in short: I do not think the current bindings in I'll take a look if there are some low hanging fruits that do not require a total overhaul. |
Okay, I perfectly understand that. |
I am still trying to figure out want kind of information are available in to VAB and what is specific to the flight-mode, so this is still somewhat minimal. A little test script: use { CONSOLE } from ksp::console
use { active_object_assembly_builder } from ksp::oab
pub fn main_editor() -> Result<Unit, string> = {
CONSOLE.clear()
const builder = active_object_assembly_builder()?
CONSOLE.print_line(">>> " + builder.assemblies.length.to_string())
const maybe_assembly = builder.main_assembly
if(Some(assembly) = maybe_assembly) {
for(part in assembly.parts) {
CONSOLE.print_line(part.part_name + " " + part.relative_position.to_fixed(2))
}
} else {
CONSOLE.print_line(">>> no main assembly")
}
} |
Thank you! This is already a good start, very promising! |
I have the feeling that this is not a desired behavior, considering that the time-control UI is hidden in the VAB view. |
This issue is stale because it has been open for 60 days with no activity. |
This issue was closed because it has been inactive for 14 days since being marked as stale. |
Hello.
I've written some UI scripts to use inside the VAB with the main_editor function. That works very well.
I'm wondering if it's possible to have access to the vessel, more precisely to each part of the vessel. For now, it doesn't seem possible. I wanted to compute myself the mass and the delta-v of my craft. Even the mod MicroEngineer makes mistakes sometimes.
Thanks.
The text was updated successfully, but these errors were encountered: