while i absolutely suck at vizzy i decided to make a simple auto orbit program that adapts to the current atmosphere height... however, there's a few issues.

pain
essentially, when the rocket reaches 20% of the atmosphere's height, it begins the gravity turn, and adjusts its pitch for more horizontal acceleration at 50% and 80% of the atmosphere height as well, alongside reducing throttle for lower fuel consumption (the demo craft's engine bas been XML'd to have low fuel consumption since it's just a demo).
it then checks if the apoapsis and periapsis are 2000 meters or more above the atmosphere's end, and if they aren't, it locks on prograde and applies throttle once they are (i haven't gotten to making this section fully fledged out yet, just made the basis of it)

however, the problem is that immediately after launching the program automatically skips to the final stage of the gravity turn (80% of atmo height) rather than following it from start to finish, despite me launching from only 400 meters above sea level with an atmosphere height of 112 km (yes i'm doing this on Merak from Mortan lol)...
soooooooo what am i doing wrong?

here's the craft if you want to check it out yourself


UPDATE: i improved it
less pain
it actually works now, the orbit isn't circular but that was expected, i made this purely for the auto orbit and to ensure that the final orbit will be above the atmosphere but leave everything else to the player. i also added variables to let players configure the different throttle and atmosphere height values

Tags
Vizzy

16 Comments

  • Log in to leave a comment
  • Profile image

    @Zenithspeed good to hear that ,feel free to ask me if you have any other vizzy problems

    1.6 years ago
  • Profile image
    26.8k Zenithspeed

    @RenkoUsami none of the craft's parts have problems, i have since fixed everything

    1.6 years ago
  • Profile image

    @Zenithspeed you can put the log sentence to find out which part has problems

    1.6 years ago
  • Profile image
    26.8k Zenithspeed

    @RenkoUsami what do you mean by that?

    1.6 years ago
  • Profile image

    any log ?

    1.6 years ago
  • Profile image
    26.8k Zenithspeed

    @t4zcomz @Astrolidon i improved it now

    +1 1.6 years ago
  • Profile image
    1,469 t4zcomz

    If you want to use if blocks, you need to put the whole thing in a while true loop

    1.6 years ago
  • Profile image
    2,951 Astrolidon

    Try arranging in reverse order like
    At first
    if 0.8
    Else if 0.5
    Then put
    Else if 0.2

    1.6 years ago
  • Profile image
    2,951 Astrolidon

    @t4zcomz no it can be done by if loop

    1.6 years ago
  • Profile image
    26.8k Zenithspeed

    @t4zcomz is that it?
    i'll try when i get home

    1.6 years ago
  • Profile image
    1,469 t4zcomz

    @Zenithspeed you need to use wail until blocks instead of the if blocks

    1.6 years ago
  • Profile image
    26.8k Zenithspeed

    @Astrolidon can you tell me what exactly i'm doing wrong? i'd like to do this on my own for now

    1.6 years ago
  • Profile image
    2,951 Astrolidon

    @Zenithspeed

    1.6 years ago
  • Profile image
    2,951 Astrolidon

    I am a vizzy expert for orbit , I have a vizzy that can be used to any craft to make orbit of any apo and peri apsis, if you want that i can optimize the code for your craft

    +1 1.6 years ago
  • Profile image
    2,951 Astrolidon

    First of all you are doing in wrong way

    1.6 years ago
  • Profile image
    2,951 Astrolidon

    Let me see

    1.6 years ago

1 Upvote

Log in in to upvote this post.