raptop changed the topic of #principia to: READ THE FAQ: http://goo.gl/gMZF9H; The current version is Fréchet. We currently target 1.5.1, 1.6.1, and 1.7.x. <scott_manley> anyone that doubts the wisdom of retrograde bop needs to get the hell out | https://xkcd.com/323/ | <egg> calculating the influence of lamont on Pluto is a bit silly… | <egg> also 4e16 m * 2^-52 is uncomfortably large
<discord-_>
Got. — Mmmh...
<discord-_>
Got. — For repetitive calls it would be nice if the API was mostly static methods and properties, so they can be wrapped in static delegates, allowing to almost eliminate the performance hit of reflection.
<discord-_>
egg. — yes but then you would get annoying coupling of the API with the lifecycle of the plugin so no
<discord-_>
egg. — you don’t have to do reflection if you don’t want to : you can also build against the Principia DLL and write actual calls
<discord-_>
egg. — (and as long as we don’t move that around that should be compatible across versions)
<discord-_>
Got. — > you would get annoying coupling of the API with the lifecycle of the plugin so no
<discord-_>
Got. — Well, if the underlying fields/properties are changing, the mod calling them will break anyway, no ?
<discord-_>
egg. — no I mean there is the Plugin in C++
<discord-_>
egg. — that is an object that gets reconstructed (mostly on scene changes), and we definitely do not want to keep a static reference to it
<discord-_>
Got. — But you call have a static API class (in the C# plugin), with static API properties/methods that have whatever implementation is adequate to plug into the C++ instance, no ?
<discord-_>
egg. — you want slow? because that is going to be slow
<discord-_>
egg. — because then you need to find the KSP plugin adapter scenario module at *every call*
<discord-_>
egg. — (that is what Principia.Get() does)
<discord-_>
egg. — to figure out what the pointer to the current C++ Plugin is
<discord-_>
Got. — Can't the scenario do it once when needed, setting a single static field reference ?
<discord-_>
egg. — no
<discord-_>
egg. — because it is not static
<discord-_>
egg. — you can do that, because you know your lifecycle
<discord-_>
egg. — and the scenario is definitely not going to start doing things for the external interface, that is very backward
<discord-_>
egg. — I would recommend seeing if you actually have performance issues that come from that before asking my to redesign what I spent the whole week-end doing
<discord-_>
egg. — If you don’t want to do reflection, again, building against the DLL is an option, that will generate code that just calls the thing
<discord-_>
Got. — mkay, well, not arging, just trying to understand why it's like that 🙂
<discord-_>
Got. — mkay, well, not arguing, just trying to understand why it's like that 🙂 (edited)
<discord-_>
egg. — (and then you can probably do cleverness to isolate the right bits so you don’t actually depend on us)
<discord-_>
egg. — (or you could even call directly into the C++ DLL, but you are going to have Fun)
<discord-_>
egg. — (and you still need to reflect to get the plugin pointer)
<discord-_>
egg. — I would recommend seeing if you actually have performance issues that come from that before asking me to redesign what I spent the whole week-end doing (edited)
<discord-_>
Got. — Yep I guess interfacing properly with the C++ dll isn't trivial
<discord-_>
egg. — well, now have a reasonably reliable way to do that
<discord-_>
egg. — but that took a while, and it is not exactly simple
<discord-_>
egg. — the interface is specified using protocol buffers, and we have a code generator that generates a C++ header and a C# file with matching imports, as well as C# marshalers and interface types and both languages
<discord-_>
egg. — @Got as for delegates, you should be able to create a delegate even from an instance method (encapsulating the instance); it is OK to keep using the same instance of principia.ksp_plugin_adapter.ExternalInterface() as long as there are no intervening scene changes, because it uses the KSP ScenarioModule it found
<discord-_>
egg. — @Got as for delegates, you should be able to create a delegate even from an instance method (encapsulating the instance); it is OK to keep using the same instance of principia.ksp_plugin_adapter.ExternalInterface as long as there are no intervening scene changes, because it uses the KSP ScenarioModule it found (edited)
<discord-_>
egg. — (so if you are a ScenarioModule yourself, or a PartModule, just wrap things in a delegate all you want, as long as you make that delegate an instance member and not static)
<discord-_>
Kobymaru. — So I can report: Principia still mostly playable despite 2519, with one exception:
<discord-_>
Kobymaru. — suborbital spaceplanes on reentry. Those twitches make it very very ... interesting.
<discord-_>
Got. — Ok, yep, doesn't have to be static, if the reference only change on scene changes that's fine
<discord-_>
egg. — well, we don’t guarantee that the underlying Plugin pointer doesn’t change (though I don’t think it does), but the PluginAdapter ScenarioModule lives like a ScenarioModule and that is what the ExternalInterface calls into
<discord-_>
egg. — I could modernize that type check, if (module is PrincipiaPluginAdapter adapter) { return new ExternalInterface(adapter); } ...
<discord-_>
egg. — the only reason why ExternalInterface exists is that you cannot do reflection with out parameters, and the interface has out parameters because otherwise we would need lots of interchange types
<discord-_>
egg. — (otherwise we could just say « go fetch the plugin_ of the adapter ScenarioModule, and pass that to the interface functions that we generate », but the only way you could call those would be to build against Principia
<discord-_>
egg. — (otherwise we could just say « go fetch the plugin_ of the adapter ScenarioModule, and pass that to the interface functions that we generate », but the only way you could call those would be to build against Principia) (edited)
<discord-_>
egg. — which is possible, faster, and gives you typesafety, but probably makes it tricky to ensure that you don’t have a hard dependency on us
<discord-_>
Got. — I'm not sure it's really possible directly, within the same assembly.
<discord-_>
Got. — The best solution that I can think of is to have a separate principia<>myPlugin assembly, in another (renamed) dll that you load manually from your main plugin if principia is installed.
<discord-_>
Got. — Depend on the use case, but in the end it's probably cleaner that way than trough reflection.
<discord-_>
Got. — I'm not sure it's really possible directly, within the same assembly (while still handling the case where Principia isn't present)
<discord-_>
Got. — The best solution that I can think of is to have a separate principia<>myPlugin assembly, in another (renamed) dll that you load manually from your main plugin if principia is installed.
<discord-_>
Got. — Depend on the use case, but in the end it's probably cleaner that way than trough reflection. (edited)
<discord-_>
egg. — yeah it all heavily depends on the use case and on how heavily you tie into Principia
<discord-_>
egg. — there is not that big of an API to warrant coupling yourself tightly to it at this point
<discord-_>
egg. — (and if you want to be really tied into Principia maybe you should be in Principia, that is how you are going to get proper performance anyway :D)
<discord-_>
egg. — I think for most use cases reflection should do the job (but it is ugly of course), and `dynamic` is a nicer way to write the same thing (but it does not seem to work)
<discord-_>
Got. — Yep, the KSP redistributed NET framework is lacking many "optional" (from the Unity POV) .NET assemblies
<discord-_>
Got. — And unfortunately redistributing the unity provided facade dlls with a plugin doesn't always work, as by doing so they are loaded trough the KSP plugin loader.
<discord-_>
Got. — Since it try to resolve dependencies immediately, that can fail badly.
<discord-_>
Got. — I added System.IO.Compression n Kerbalism 4.0, so fare so good, but doing it for more "nested" framework dlls that have multiple dependencies usually fails.
<discord-_>
egg. — yeah that does not sound very viable
<discord-_>
egg. — so reflection seems to be the way to go
<discord-_>
egg. — (or building against our DLL)
egg|laptop|egg has quit [Remote host closed the connection]
Mike` has quit [Ping timeout: 378 seconds]
Mike` has joined #principia
Mike` has quit [Ping timeout: 190 seconds]
Mike` has joined #principia
<discord-_>
Profiremu23. — I got a problem, i try to get to the moon in the first time with principia, but i have no idea how to get it
<discord-_>
Profiremu23. — @egg I got a problem, i try to get to the moon in the first time with principia, but i have no idea how to get it (edited)
<discord-_>
Myshiko. — Now, to get to The Moon, one need to learn how to deal with inclinations.
<discord-_>
Myshiko. — There are 2 cases: if you are starting from Cape of Canaveral or closer to equator, then you need to wait for the appropriate time of day to launch.
<discord-_>
Myshiko. — If you are starting from something like Baykonur, you might want to wait for an appropriate day of the month to get your launch closer to optimal
<discord-_>
Profiremu23. — So is the same with normal physics?
<discord-_>
Myshiko. — Define “same”. It’s not the same, but patched conics IS an approximation.
<discord-_>
Profiremu23. — Hmmm
<discord-_>
Myshiko. — So, if you know how to get to the Moon in patched conics world optimally, you can start with that as first approximation and then see if fine tuning make life better.
<discord-_>
Myshiko. — Launch site inclination has the biggest practical impact in the Earth-Moon travel planning.
<discord-_>
Myshiko. — But it’s also true in the patches conics world.
<discord-_>
Profiremu23. — Okay
<discord-_>
Profiremu23. — thanks for the tips
<discord-_>
Myshiko. — Well, all I can say - launch at the day and time when you would hit the moon burning mostly prograde :).
<discord-_>
Myshiko. — Well, all I can say - launch at the day and time when you would hit the moon burning mostly prograde :). Some coasting might be fine 🙂 (edited)
<discord-_>
Myshiko. — Moon moves, so aim for the point where moon will be approximately 3 days from launch 🙂
<discord-_>
Myshiko. — Mule around 3250+ delta/v to LEO (3500 delta v should be plenty), and good bucket of RCS for fine trajectory correction. Moon is a big target, hard to miss 🙂
<discord-_>
Damien. — @Profiremu23 @Myshiko when using principia, you may not be able to launch directly into plane with the moon because unlike with stock physics, the moon isn't at a fixed 28.5° inclination.
<discord-_>
Damien. —
<discord-_>
Damien. — In principia, as in real life the moon's orbit precesses between 18.5° and 28.5° and back again over an 18.5° year cycle.
<discord-_>
Damien. — @Profiremu23 @Myshiko when using principia, depending on your launch site you may not be able to launch directly into plane with the moon because unlike with stock physics, the moon isn't at a fixed 28.5° inclination.
<discord-_>
Damien. —
<discord-_>
Damien. — In principia, as in real life the moon's orbit precesses between 18.5° and 28.5° and back again over an 18.5° year cycle. (edited)
<discord-_>
Damien. — @Profiremu23 @Myshiko when using principia, depending on your launch site you may not be able to launch directly into plane with the moon because unlike with stock physics, the moon isn't at a fixed 28.5° inclination.
<discord-_>
Damien. —
<discord-_>
Damien. — In principia, as in real life the moon's orbit precesses between 18.5° and 28.5° and back again over an 18.5 year cycle. (edited)
<discord-_>
Damien. — You may need to use direct ascent or an an/dn transfer
<discord-_>
Kobymaru. — yeah that "trans-lunar injection" pic is unrealistically kind with aligned orbital planes
<discord-_>
Kobymaru. — so if you are in baikonur for example, you you can do the exact same transfer but only when the moon is 3 days away from the AN or DN between the moons orbital plane and whatever your launch plane will be
<discord-_>
Kobymaru. — so if you are in baikonur for example, you you can do the exact same transfer but only when the moon is 3 days away from the AN or DN between the moons orbital plane and whatever your orbital plane will be (edited)
<discord-_>
Kobymaru. — 3 days is: 360° * 3/28 = 38°
<discord-_>
Kobymaru. — or if you want to get real crazy, you can do it soviet style - just into a polar orbit at the right time and then do the TLI from polar
<discord-_>
Kobymaru. — but that's "advanced" stuff, because getting the time of day right for such a launch is a bit tricky
<discord-_>
Butcher. — I do polar launches, using a kos script for timing. You need to hit the window to within about a minute either way to get close.
<discord-_>
Kobymaru. — how do you work out the time?
<discord-_>
Kobymaru. — and inclination
<discord-_>
Butcher. — Estimate flight time, work out when to launch to based on the moon being the right number of degrees of long ahead of the launch site, calculate required orbit such that it crosses the orbit of the moon as closely as possible, calc new flight time for new orbit, repeat.
<discord-_>
Butcher. — Inclination is done by varying the SMA of the orbit to adjust where it intercepts the moon's orbit.
<discord-_>
Butcher. — The problem is that everything depends on everything else - launch time (i.e. lead angle) depends on flight time, which depends on orbit, which depends on lead angle, etc.
<discord-_>
Butcher. — So I'm not sure there's a nice closed form, hence I just iterate until it's close enough.
<discord-_>
Butcher. — It'll also do North or South launches, though picking the "wrong" one leads to very high required dV as you end up with a hyperbolic orbit.
<discord-_>
Myshiko. — Honestly, many of you are over complicating Moon transfers. Even from the Baykonur. Ideal Moon transfer is hard. However, the moon transfer that does not suck can simply be extrapolated after 10-20 launches. And “not suck” means about +300 delta v from ideal.
<discord-_>
Myshiko. — Just try launching at the different times and see how well can you fly by the moon from the launch time and date.
<discord-_>
Myshiko. — See how delta v changes
<discord-_>
Myshiko. — Assuming you are launching from the fixed site, you will quickly “draw your pork chop chart”
<discord-_>
Myshiko. — Assuming you are launching from the fixed site, you will quickly “draw your pork chop chart” for the injection (edited)
<discord-_>
Myshiko. — And you will also see, what really makes a big, and what makes a small impact on the total delta v. From Cape, Moon precession is not that bad most of the time. And when you feel it’s bad, one can always time the launch to a specific day of the month.
<discord-_>
Myshiko. — Same for “minutes accuracy”. For purists - yes, seconds are ideal. For eye-ballers - actually, if you don’t do polar launch to the moon and burn East, but on a appropriate day and time, your launch time can be as accurate as +/-30 min, and you are fine.
<discord-_>
Myshiko. — Aka delta v cost is not prohibitive
<discord-_>
Myshiko. — Same for “minutes accuracy”. For purists - yes, seconds are ideal. For eye-ballers - actually, if you don’t do polar launch to the moon and burn East, but on a appropriate day and time, your launch time can be as accurate as +/-30 min, and you are still fine. (edited)
<discord-_>
Myshiko. — Polar launches is what makes more sense for interplanetary launches.
<discord-_>
Butcher. — 10-20? Mine will hit the moon in 1-2 launches. Who wants to sim 20 times?
<discord-_>
Butcher. — And minutes matter for Polar launches, bot for Easterly.
<discord-_>
Butcher. — And minutes matter for Polar launches, not for Easterly, obviously. 🙄 (edited)
egg|laptop|egg has joined #principia
<discord-_>
Myshiko. — 10-20 launches to learn how to hit the moon, once person figures it out.
<discord-_>
Myshiko. — 10-20 launches to learn how to hit the moon, once person figures it out it’s 1 launch - 1 success. (edited)
<discord-_>
Ampersand. — Easterly launch with maneuver nodes and some design advice from this server can probably allow a player to succeed on the first flight
<discord-_>
Myshiko. — For me it usually requires 0.5 launches now for the moon - I do both impactor and flyby in one launch.
<discord-_>
Ampersand. — That's the usual procedure for people who aren't sufficiently oogabooga to also complete orbit in that launch
<discord-_>
Ampersand. — (lunar orbit, that is)
<discord-_>
Myshiko. — Orbit in the same launch does require a bit more. But it’s harder to do with unguided stages.
<discord-_>
Myshiko. — While flyby and impactor with unguided last stage is perfectly fine.
<discord-_>
Myshiko. — This also open the question about orbiting burn
<discord-_>
Kobymaru. — > That's the usual procedure for people who aren't sufficiently oogabooga to also complete orbit in that launch
<discord-_>
Kobymaru. — @Ampersand how the hell would you insert into orbit without avionics
<discord-_>
Ampersand. — Spin stabilization, luck, and sep motors
<discord-_>
Ampersand. — That's LPG's trick, I certainly don't have the chops to pull it off
<discord-_>
Kobymaru. — that doesn't actually sound practical
<discord-_>
Ampersand. — You can also, very theoretically, achieve lunar landing with no guidance after TLI, but it's a pain
<discord-_>
Kobymaru. — unless you do speedruns and are willing to revert 50 times for one launch
<discord-_>
Ampersand. — And if principia's wierd SOI change behavior hasn't been fixed, impossible in these physics
<discord-_>
Ampersand. — I think part of the idea of the unguided lunar orbit trick is to spin the probe so that the motor will face different directions over time, and then wait until you're close to lunar periapse and the motor is pointed roughly the right direction, then fire
<discord-_>
Kobymaru. — Honestly, that just sounds like cheese to me
<discord-_>
Ampersand. — yes
<discord-_>
Myshiko. — Some RCS can also time the spin
<discord-_>
egg. — > And if principia's wierd SOI change behavior hasn't been fixed, impossible in these physics
<discord-_>
egg. — This has been fixed
<discord-_>
Ampersand. — Nice!
<discord-_>
egg. — that was the whole rotation thing
<discord-_>
Myshiko. — If spin is slow, burn RCS when it’s in the right direction
<discord-_>
egg. — took us a year :-p
<discord-_>
Ampersand. — I continue to be extremely impressed with your skills
<discord-_>
Ampersand. — I haven't played with it, but Principia is a remarkable piece of software
<discord-_>
Damien. — anyone got any documentation on altering inclinations of libration orbits? I find them really hard to adjust because every orientation seems to make changes in the same plane
<discord-_>
Damien. — anyone got any documentation on altering inclinations of libration orbits? I find them really hard to adjust because burns in every orientation seems to make changes in the same plane (edited)
<discord-_>
Damien. — anyone got any documentation on altering inclinations of libration orbits? I find them really hard to adjust because burns in every orientation seem to make changes in the same plane (edited)
egg|cell|egg has quit [Ping timeout: 189 seconds]
<discord-_>
Myshiko. — With newest Principia, I wonder if Джанибеков effect can be used practically for unguided stages. That flipping looks handy for reversing where engines point
<discord-_>
Damien. — that's some big brain thinking
<discord-_>
Ampersand. — Somebody proposed using it to achieve semi-complete attitude control while only having roll thrusters
<discord-_>
Acer_Saccharum. — you'd definitely need to write custom control laws to use such a system though
<discord-_>
Pteropodidae. — > how the hell would you insert into orbit without avionics
<discord-_>
Pteropodidae. — If you really want to spend a lot of time you could go for a ballistic capture too
<discord-_>
Pteropodidae. — Although said orbit might be a bit weakly bound
<discord-_>
Damien. — that's literally what I'm doing right now
<discord-_>
Pteropodidae. — Can't help but think of a treble clef every time I see that particular type of transfer
<discord-_>
Damien. — the burn cost me roughly what a normal hohmann transfer would, but the capture is free
<discord-_>
Damien. — what I'm trying to wrap my head around though, is making my capture orbit end up a polar one
<discord-_>
Damien. — I've done it before but it was pure luck
<discord-_>
Damien. — btw I'm playing on JNSQ instead of RSS at the moment so a normal inner resonance low energy transfer wasn't working due to minmus being inside mun's orbit
<discord-_>
Damien. — so this swing out to EL1 (or 2) was my only option
<discord-_>
Damien. — without any TCMs along the way, I'll capture into this orbit
<discord-_>
Damien. — but it's a scansat so ideally I want to end up polar, but spending as little to do so as possible
<discord-_>
Damien. — I was hoping there was something I could do while I'm still in near EL1 but I've not found anything. I'll probably have to capture into an elliptical orbit and do it at Ap
UmbralRaptor has joined #principia
<discord-_>
Damien. — I could try and capture into a mun L-point orbit and do something from there but that'd take some experimentation
UmbralRaptop has quit [Ping timeout: 204 seconds]
<discord-_>
Damien. — @Pteropodidae if you want to play with low energy transfers and Lagrange point orbits, make sure you fit a really weak engine
<discord-_>
Damien. — Throttle restricted rcs is perfect
<discord-_>
Damien. — Burns are often fractions of a m/s
<discord-_>
Pteropodidae. — I've only messed with low energy transfers/ballistic captures once or twice IIRC, but I think I did end up using RCS
<discord-_>
Pteropodidae. — Don't remember if I had limited the thrust on them
<discord-_>
Pteropodidae. — But yeah, I definitely remember things being *very* sensitive
<discord-_>
egg. — 𝄞 transfer
<discord-_>
Sir Mortimer. — Trololo
<discord-_>
Damien. — @egg you got any papers that mention transferring from a flat halo orbit to an inclined one?
<discord-_>
Pteropodidae. — Don't think I've messed with Lagrange point orbits, now that I think about it
<discord-_>
Pteropodidae. — Are they useful for any RP-1 contracts yet?
<discord-_>
Damien. — it's a shame that some experiments that are said to be observing earth, can't be done in EL1, because it's classed as being in a solar orbit by KSP, not high above earth
<discord-_>
DRVeyl. — The ~~tyrrany~~ joy of SoIs.
<discord-_>
DRVeyl. — SM might fix that with some of his Kerbalism contracts reworking.
* discord-_
egg. — whistles a counter-melody to @Sir Mortimer’s whistling_
<discord-_>
DRVeyl. — (I have a "do science without being in the SoI" idea on the uber-back-burner also.)
<discord-_>
Damien. — yeah I know the contracts he's working on will help in that regard which is really cool
<discord-_>
Damien. — can't wait
<discord-_>
Damien. — 44sci for a sun geiger counter scan while doing my transfer. nice, I'll take it
<discord-_>
egg. — _whistles a counter-melody to @Sir Mortimer’s whistling 𝄾 𝅘𝅥 𝅘𝅥𝅮 𝅘𝅥_ (edited)
<discord-_>
Sir Mortimer. — SoI is only relevant when contracts relate to a specific location on the surface
egg|laptop|egg_ has joined #principia
egg|laptop|egg has quit [Ping timeout: 190 seconds]
Jesin has quit [Quit: Leaving]
Jesin has joined #principia
<discord-_>
Pteropodidae. — > 𝄾 𝅘𝅥 𝅘𝅥𝅮 𝅘𝅥
<discord-_>
Pteropodidae. — Curse my seemingly incomplete default font
egg|cell|egg has joined #principia
<discord-_>
smartdummies. — Science without having to get in the SoI? You mean I will be able to get science from Phobos and Demios?
<discord-_>
DRVeyl. — Is the thought. Not getting any time at the moment because, well, it's *only* applicable to folks who are playing both Principia and Kerbalism.
<discord-_>
DRVeyl. — (No Principia, then just get into Deimos/Phobos SoI and you can safely stay there. No Kerbalism, then you get all the science instantaneously so you don't need to -stay- anywhere.)
<discord-_>
Damien. — realistically the experiments would have max ranges from the target or that'd be silly
<discord-_>
Damien. — but an experiment in a following orbit, or a libration point that is technically in a solar orbit but is close enough to see the target, should be able to get science
<discord-_>
Damien. — but an experiment in a following orbit (or a libration point) that is technically in a solar orbit but is close enough to see the target, should be able to get science (edited)
UmbralRaptor has quit [Remote host closed the connection]
<discord-_>
DRVeyl. — Yes, that'd be the idea, and range limit would pretty much have to get applied. The issue is more "worth the effort to make yet?" 🙂
egg|laptop|egg_ has quit [Read error: Connection reset by peer]
Mike` has quit [Ping timeout: 190 seconds]
Mike` has joined #principia
egg|laptop|egg has joined #principia
<discord-_>
Pteropodidae. — Maybe some kind of falloff?
<discord-_>
Pteropodidae. — You can get a little science from far away if you try really really hard, but the rates improve significantly if you get closer
<discord-_>
Pteropodidae. — I guess that's just another way to implement a range limit, really
<discord-_>
DRVeyl. — It is just a softer limit, yeah.
<discord-_>
smartdummies. — This would be HUGE for me personally and if you get this in I would be eternally grateful. But I do understand that most players do not have both Principia and Kerbalism. I think that most do not have Principia, but I initially got it when it included axial tilt as going to Jupiter in the orbits of the Gallilain moons should not be getting you into biomes other than the equatorial xone
<discord-_>
Damien. — Kerbalism and principia go together perfectly. They're amazing mods.
<discord-_>
Damien. — I've just unlocked the solar wind collector experiment in my jnsq career so I'm going to give principialism a run tomorrow by attempting to recreate the genesis mission