Jump to content

Corbald

Members
  • Posts

    51
  • Joined

  • Last visited

Everything posted by Corbald

  1. Same issue, same joystick. Can't post logs right now, but I will later if it's needed.
  2. You might try forking around with the 'Docked' / 'Undocked' modes for the attachment. KAS is NOT based on 'normal' stock behavior and random forces/glitches/errors/unplanned disassembly should be expected, from my experience. For example, the winches/harpoons I used to secure my very vertical bases on Minmus *pulse* with heat and occasionally explode... violently.
  3. The option you're looking for is 'Link.' You'll get the green tube out of the Kerbal's back, just walk/float over to the other connector and 'Link' again. Viola! I suggest having a few connectors inside KAS storage for each mission. You'll inevitably forget to put one on something and regret it later! Put a wrench in there too, then you can hit 'Tab' to open the Kerb's inventory, drag the wrench/drill across to slot 1. Now, when you want to attach the connector, press 1, then press 2 (the slot for the connector) and HOLD X to attach it.
  4. 3.15 Fairing Bases still explode due to overheating, even when no overheating should be present, such as at the launchpad. Tested/Confirmed in isolation with new 1.0.4 install and only PF mod.
  5. Mod works great! Found that Asperagus staging takes a bit of setup, but I had success with checking the engine's status for "Flame-Out!" which works great. On another note, I can't get the stock panel to show up. I tried updating the KSPAPIExtensions.dll, which fixed the out of date error, but didn't make the panel button show up. I just bound the Action to the breaks, for the time being, but a button would be nice!
  6. Stuck on the moon, getting her first good sleep since getting the room next to Bill at KSC! She (audaciously!) decided to try a hybrid rocket/SSO/spaceplane concept with only entry parts and the danged thing made it to the Munar surface... albeit without a drop of fuel left for a return trip... We're letting her cool her heels up there for a bit... Even Jeb says she's way more badass than he is! (I think he's scared of her!!)
  7. Fel, Aqua, you two are CHAMPS! Chuck Norris aspires to be like you! This should be enough for me to get something working! Fel, I should have realized that the longAscNode gobbledygook was if's. Makes sense when you run numbers through it! DOH! The Lambda wrapping function would have kept me guessing for weeks! I kept getting lost in the interior of the function's argument calls! Thanks for clearing that up, especially.
  8. Hey Aqua, thanks for the response. Looks like I need to know how AngleZero2Pi works. Hopefully someone that understands the maths can help me figure that out. Unfortunately, I can't learn from math books, as previous experience has taught me. My mind can't stay focused to that degree. I HAVE, however, primed myself with a bit of understanding from the helpful folks who air lessons on Youtube. That said, I'm not going to understand it until I put it in practice. Thus this endeavor. So, the questions remaining are: How do these work? //longAscNode_1=AngleZero2Pi(asin(hUnitVect(1)/sin(inc))); //is AngleZero2Pi a matlab function? what is this? // *** couldn't find that in the documentation, must be a custom method or from an old MATLAB version //longAscNode_2=AngleZero2Pi(pi-asin(hUnitVect(1)/sin(inc))); //longAscNode_3=AngleZero2Pi(acos(-hUnitVect(2)/sin(inc))); //longAscNode_4=AngleZero2Pi(-acos(-hUnitVect(2)/sin(inc))); And: //[val,ia,ib]=intersect(longAscNodeSet1,longAscNodeSet2); //am I finding the intersection of two vector2's? I don't know how to read this! // *** foo[a, b, c] is an array: 'foo' is the name of it, abc are the names of three elements inside the array. // *** The named elements allow direct access to array element. // *** Therefore [val,ia,ib] is an unnamed array with three elements, named val, ia and ib. //longAscNode=longAscNodeSet1(ia); //I don't know how to read this! // *** I, too, have no idea what happens here. if longAscNodeSet1 and longAscNodeSet2 are vector2's, then [val,ia,ib] should be a vector2, but it's got three elements. what the heck is 'val'? If it IS a vector 2, then longAscNodeSet1(ia) should be something like longAscNodeSet1.x, riiiight? *Later*, I found this for [val,ia,ib]=intersect(longAscNodeSet1,longAscNodeSet2): Define two vectors with values in common. A = [7 1 7 7 4]; B = [7 0 4 4 0]; Find the values common to both A and B, as well as the index vectors ia and ib, such that C = A(ia) and C = B(ib). [C,ia,ib] = intersect(A, C = 4 7 ia = 5 1 ib = 3 1 Worst case: I write a function which does this, myself. Does unity do anything like this, built in? I'll run with the assumption that it does not (since I can't find anything in their docs) and code my own, but if anyone knows a shortcut, lemme know! That just leaves AngleZero2Pi! Anyone have insight?
  9. (Mods: Is this the right place to ask this?) Hey all, I need some help! I have been working for a while on a project of my own. I have a lot of stuff that I have already done, but now it comes time to do the thing I've been dreading the most... the math of orbital dynamics and conics. I have a rudimentary understanding of how cones draw ellipses and how planets sit in the foci, but I'm trying to really wrap my mind around the math. I can't read mathematical notation and have only a high-school education. I'm ADHD and haven't been in school for 24 years. As you can imagine, this has been an uphill battle for me, the entire time! None the less, I have tackled a lot of difficult problems, including dynamic LoD, procedural generation, networking, optimization and more. In trying to make the numbers actually mean something to my idiot brain, I stumbled upon a post by none other than HarvesteR, himself (http://www.orbiter-forum.com/showthread.php?t=20580). He seems to be asking some of the same questions that I am, and seems to be at around the same stage that I am (at that moment in time). Now, we all know that he was successful in his attempts, so I think I'm on the right track. In that post, Arrowstar very kindly supplies him with a MATLAB example which spits out all the relevant data points for an orbit. I'm really hoping you guys can help me get the MATLAB gibberish to produce some real numbers, so that I can actually learn something and get my mind to visualize these concepts. I have a lot of references that I have dug up via Googling around, and I hope that if I can get this thing running, I can actually make some headway. Here's what I have: (I have commented relevant lines of code with the pertinent questions I have.) using UnityEngine; using System.Collections; public class Manager : MonoBehaviour { // Use this for initialization void Start() { GameObject[] Objects = GameObject.FindGameObjectsWithTag("Star"); //Initial 'kick' foreach (GameObject ObjectA in Objects) { ObjectA.GetComponent<Rigidbody>().AddForce(new Vector3(0, 0, 1)); //Initial 'kick' } } void ApplyGravity(Rigidbody A, Rigidbody { //This is how to get the distance vector between two objects. (I totally stole most of this function, //but I understand it now, so I'll rewrite it to suit my project, later.) Vector3 dist = B.transform.position - A.transform.position; float r = dist.magnitude; dist /= r; //This is the Newton's equation //G = 6.67 * 10^-11 N.m².kg^-2 double G = 6.674f * (10 ^ 11); float force = ((float)G * A.mass * B.mass) / (r * r); //Then, just apply the forces A.AddForce(dist * force); B.AddForce(-dist * force); //note that there are only two objects in my scene, a 'planet' with x,y,z locked, and a 'moon' //the 'moon' is the only object which will get a force, for this example, due to the constraints on the other body. //DrawOrbit(A.position, A.position + A.velocity, dist * force); //this will call the orbital calculation stuff below. } Here's the code for the function I'm having issues with void DrawOrbit(Vector3 rVect, Vector3 vVect, float muCB) { //Here begins the MATLAB code provided to HarvesteR // function [sma, ecc, inc, longAscNode, ArgPeri, TrueAnom] = getKeplerFromState(rVect,vVect,muCB) //% getKeplerFromState() returns Keplerian orbital elements when provided //% with the state (cartesian position vector, cartesian velocity vector) of //% a spacecraft or celestial body. //% //% INPUTS //% rVect - a 3x1 vector that contains the x,y,z components of the orbiting //% body's current position relative to the central body. Units: [km] //% vVect - a 3x1 vector that contains the x,y,z components of the orbiting //% body's current velocity vector relative to the central body. Units: //% [km/sec] //% muCB - the gravitational parameter of the central body. Units: km^3/s^2 //(What, of the above, goes here? //% //%OUTPUTS //% sma - semi-major axis of the orbit. Units: [km] //% ecc - eccentricity of the orbit. Units: dimensionless //% inc - inclination angle of the orbit. Units: radian //% longAscNode - Longitude of ascending node of the orbit. Units: radian //% ArgPeri - Argument of periapse of the orbit. Units: radian. //% TrueAnom - Current true anomaly of the spacecraft/body in the orbit. //% Units: radian //r=norm(rVect); //rUnitVect=rVect/r; //v=norm(vVect); float r = rVect.magnitude; //matlab 'norm' is Unity Vector3.magnitude? Vector3 rUnitVect = rVect.normalized; // rVect/r is Unity Vector3.normalized? float v = vVect.magnitude; //hVect=cross(rVect,vVect); //h=norm(hVect); //hUnitVect=hVect/h; //ThetaUnitVect=cross(hUnitVect,rUnitVect); Vector3 hVect = Vector3.Cross(rVect, vVect); float h = hVect.magnitude; Vector3 hUnitVect = hVect.normalized; Vector3 ThetaUnitVect = Vector3.Cross(hUnitVect, rUnitVect); //Energy=v^2/2 - muCB/r; //sma=-muCB/(2*Energy); float Energy = Mathf.Pow( v, 2 )/ 2 - muCB / r; //Am I doing order of operation right? float sma = -muCB / (2 * Energy); //p=h^2/muCB; //ecc=sqrt(-p/sma + 1); float p = Mathf.Pow(h, 2) / muCB; float ecc = Mathf.Sqrt(-p / sma + 1); //TrueAnom=acos((p/r - 1)/(ecc)); //if(dot(rVect,vVect)<0) // TrueAnom=-TrueAnom; //end float TrueAnom = Mathf.Acos((p / r - 1) / ecc); if (Vector3.Dot(rVect, vVect) < 0) { TrueAnom = -TrueAnom; } //inc=acos(hUnitVect(3)); float inc = Mathf.Acos(hUnitVect[2]); //Unity vectors are from 0-2, not 1-3 //longAscNode_1=AngleZero2Pi(asin(hUnitVect(1)/sin(inc))); //is AngleZero2Pi a matlab function? what is this? //longAscNode_2=AngleZero2Pi(pi-asin(hUnitVect(1)/sin(inc))); //longAscNode_3=AngleZero2Pi(acos(-hUnitVect(2)/sin(inc))); //longAscNode_4=AngleZero2Pi(-acos(-hUnitVect(2)/sin(inc))); //longAscNodeSet1=round(1000*[longAscNode_1,longAscNode_2])/1000; //is this a Mathf.Round as a vector2? //longAscNodeSet2=round(1000*[longAscNode_3,longAscNode_4])/1000; //[val,ia,ib]=intersect(longAscNodeSet1,longAscNodeSet2); //am I finding the intersection of two vector2's? I don't know how to read this! //longAscNode=longAscNodeSet1(ia); //I don't know how to read this! //Theta_1=AngleZero2Pi(asin(rUnitVect(3)/sin(inc))); //Quesion as above //Theta_2=AngleZero2Pi(pi-asin(rUnitVect(3)/sin(inc))); //Theta_3=AngleZero2Pi(acos(ThetaUnitVect(3)/sin(inc))); //Theta_4=AngleZero2Pi(-acos(ThetaUnitVect(3)/sin(inc))); //ThetaSet1=round(1000*[Theta_1,Theta_2])/1000; //Quesion as above //ThetaSet2=round(1000*[Theta_3,Theta_4])/1000; //[val,ia,ib]=intersect(ThetaSet1,ThetaSet2); //Quesion as above //Theta=ThetaSet1(ia); //Quesion as above //ArgPeri=Theta-TrueAnom; //If I could figure out the above, this might make sense! //some stuff will go here to draw the elipse/orbits. I'll tackle that later, after I make sense of the rest. } Finally, some code to apply a basic orbit, it's bad, but it's working void FixedUpdate() { //Get every object GameObject[] Objects = GameObject.FindGameObjectsWithTag("Star"); //This runs too often. Extract to Start() later to optimize. //the gravity between each couple of object is calculated foreach (GameObject ObjectA in Objects) { foreach (GameObject ObjectB in Objects) { //Objects must not self interact if (ObjectA == ObjectB) continue; ApplyGravity(ObjectA.GetComponent<Rigidbody>(), ObjectB.GetComponent<Rigidbody>()); //should store these GetComponents, they run too often. } } } } Hopefully, someone can make some sense of this. I'm really stuck here! Please note that I DO NOT intend to reuse 90% of this code, as it's not all mine. Once I can understand what's going on, I'll re-write for my project.
  10. Very nice! I'm planning a Duna mission, myself. First time working my way through the Science tree. I'm going to be landing (and ascending) the Science Lab, even though it's a beast! I'll also be landing a small, one Kerbal rover to collect data with. The rover will be able to dock with the Lab for cleaning via KAS, but I imagine that it'd be easy enough to set up something with just docking ports to do the same thing.
  11. Yup, that seems to have done it! Thanks for the quick fix! (yes; I WAS hovering over the thread ;D )
  12. Triple-Confirming the "Parts don't resize" bug. (they do if you change the shape, but not in real time) Also: No idea what all is going on here... The SRB is ON in the SPH, the exhaust is doubled and one of the clones is detached and the tweakable under "Thrust Limiter" reads "Not Found" if the buttons are clicked.... Also: Tanks seem to have no fuel, nor fuel tweakables... Update: I made a fresh install of KSP. No mods, no config changes (except graphics resolution and no AA) and all the same issues persist. It's not an inter-mod incompatibility issue.
  13. I'm officially in love with you. Plz have my green squishy babies!
  14. THANK YOU!! This has been driving me NUTS all morning! The FAR mod adding it reveals why I couldn't find a darned thing on Google... :/
  15. The tweakable menu for the AV-R8 winglet includes a toggle for "Use as sp..." What does this do?
  16. Correct. You're fed bits of functionality with each Automation tech-tree node. I like it! You get the basic readouts with the first Automation research. Ascent and Landing Guidance (and Space-Plane Guidance) with Adv. Automation. That's as far as I am, but you get the idea.
  17. Any chance a future version could include a 'Focus Node' hotkey/button?
  18. Badarse! TYVM! Note: You'll have to set MechJebModuleMenu's Enabled = True, but this time it'll STAY true ;D MJ also seems to want to inherit a planet's movement through space as part of it's calculations for retrograde. I would prefer to use retrograde on SmartASS to land, but it points me off some 45 degrees to the left on Kerbin and 10 degrees on the Mun... ?
  19. I'm having similar issues. I updated in the hope that my craft would stop spinning out of control when ascent autopilot was in charge and when at very low, downward velocity and retro is nearly straight up. Deleted old Mechjeb folder and installed latest from GitHub. now have no menu and the light on the MechJeb module is red. I believe what's happening is that I have already unlocked MechJeb in the tech-tree, but the .cfg files don't concur. Can anyone tell me which entries to edit to make it recognise I have unlocked up to 'Unmanned Tech?'
  20. SCIENCE! Is earner by right clicking the relevant part or Kerbal and clicking the relevant option. You'll know which option when you see it. SCIENCE! is then 'stored' in the pod (?) and can either be returned to the Science Center by transmitting it back via antenna/dish, or returning the pod to Kerbin and recovering the vessel. Transmitting often comes at a loss, whereas physically returning the SCIENCE! guarantees a 100% yield. Different parts will get SCIENCE! at different amounts at different locations and under different conditions. For example, Goo can return science from (but not limited to!) low atmosphere and in space. Try all the things.
  21. Also, not that I have had the chance to check yet, but I seem to remember that Kerbin has different biomes now. Might try to land in the desert or at a pole.
  22. Writers of IHRS. I would be honored!
  23. Kowbell, you hit the nail on the head. That's exactly the sort of thing I was imagining.
×
×
  • Create New...