Jump to content

Tuareg

Members
  • Posts

    370
  • Joined

  • Last visited

Posts posted by Tuareg

  1. Interesting. This would allow to test rovers and landers more easily.

    Does it allow to turn off the atmosphere, in order to negate its effects? (Sure, they will be miniscule at rover speeds, but still...)

    Very useful, I've had a number of rovers that work well on Kerbin completely fail on lower gravity worlds.

    Edit: I guess it could work to test landers too?

    sadly it cant negate atmosphere so it doesnt work for landers

  2. And an other new release from your Lunatic scientists:

    Theeeee Rover gravity manipulator!

    A module to manipulate the gravity affecting your rover

    You can choose which planet or moon settings you want to apply, turn it on and flyyyyyyyyyy.

    Sadly our scientist were not able to solve the problem of conflicting with engine electronics.

    [Moderator removed defunct website link]

    vp1w07B.jpg

    license

    source included in download

    from now on i release on [Moderator removed defunct website link] only, sry

  3. Hrmm.. can these be scaled any bigger? ( I wanna make a full scale Ender's Game style battle room!:P)

    Awesome plugin =)

    sure, in the .cfg u can find size. multiply it with the rescalefactor :) have fun

    - - - Updated - - -

    Better! Now how about an artificial gravity generator for large spacecraft? :D

    working on it for rovers :)

  4. If you want downloads, add pictures to your forum post, a description of what it is, and a link to the licence (or the embedded thing from the place you got it).

    People won't download your mod if they don't know what it is, and unfortunately they're probably not gonna go exploring the kerbal stuff link to find out

    nah, happy? :)

  5. 3 things:

    - No pics (or descriptions) no clicks

    - You spelled Anti-Gravity wrong on kerbal stuff

    - you need a license (google it)

    it has a click, more than enough i think, it has pic, description and even a video, it has license.

    i really misspelled "Anti" but kstuff dont let me to edit it

  6. Here is a new release from Lunatic Aeronautics.

    A brand new Anti-gravity room to have fun with. Enjoy! :)

    Functions:

    automatic light handling (if you add ONE any type of light-source, it will shine green when the room is free and switch to red if a vessel enters, if you add TWO, one will be green, one will be red and it will automatically switch between the lights on entering or leaving the room)

    choosing gravity settings between deep space and any planets or moons (you can fine tune it in the config)

    https://kerbalstuff.com/mod/473/Lunatic%20Aeronautics%27%20Anty-gravity%20Room

    18vRCS5.png

    license

    source included in download

    from now on i release only on kerbalstuff. sry

  7. ok, firstof, what i've got is that ksp is shifting the worldcenter to the rootpart after revert to launch but dont do it at launch. i dont know if its intended or bug but a fact. what is strange in this is that

    this.vessel.inversetransform[B]point[/B](v.vessel.transform.position)

    gives the right local coords after revert to launch but

    this.vessel.inversetransform[B]direction[/B](v.vessel.transform.position)

    doesnt. it looks like the world turned upside down around the rootpart. nvm, what i want is working with the first one, still its strange

  8. i've run into a strange thing and i wonder if its a bug

    after launching my vessel i check the position of a partmodul

    after reverting to launch if i check the position of the same part it changes and after any amount of revert to launch will give the same position

    after reverting to VAB and relaunching i get the original position again... actually the one after launching is right but why does it give a different value after reverting to launch?

    the code is simply:

    Debug.Log(v.vesselName + " - " + localPos + " - " + this.transform.position + " - " + v.findWorldCenterOfMass());

    and the output is (right image after launch left image after reverting to launch):

    zHTh16F.jpg

  9. AddForce on a kerbal seems to work fine for me. Setting vessel.transform.ridigbody.useGravity to false does not seem to do much.

    But I do see a small upwards drift that you're also seeing. So the actual downwards force that the object gets is less then the added upwards force.

    Few random ideas:

    * FlightGlobals.getCentrifugalAcc and/or FlightGlobals.getCoriolisAcc might also get applied?

    * Drag could be causing strange effects? (We know the drag model isn't that awesome)

    As cheat, you could set the velocity to zero when it's nearly zero?

    genius! thanks a lot :) i didnt think squad took the time to actually model centrifugal force but they did. my little kerbal can now levitate on kerbin \o/

  10. has it something to do with the rotation of the planet?

    no, in that case the vessel should move sideaways but it flies straight up.

    At this point, I would do a Vector3.Distance(WorldPosThisFrame,WorldPosLastFrame); in FixedUpdate and compare the distances between them. If the distances are the same (constant velocity) you are correctly canceling everything and the kerbal has no forces acting upon it.

    If the distances are different, either you are not canceling the force of gravity correctly, or there is another force acting on the kerbal.

    Also, you are running this in FixedUpdate, not Update correct? Update is for GUI stuff and on most computers runs more often then FixedUpdate where KSP exerts forces so you could be canceling gravity too often.

    D.

    yes, im now running it in fixedupdate and the velocity is increasing so it has acceleration

    If you want to stop gravity from effecting the kerbal, wouldn't the Unity "useGravity" flag be a better solution?

    http://docs.unity3d.com/ScriptReference/Rigidbody-useGravity.html

    Also, to get the current gravity that is applied to the objects, "Physics.gravity" might be a more accurate reference. And I would use the "AddForce" instead of "AddForceAtPosition" function. With the ForceMode to acceleration, so you do not need to multiply with the mass, which could also be your problem, as the mass presented to GetTotalMass might not be the same as the physics mass.

    http://docs.unity3d.com/ScriptReference/ForceMode.html


    v.transform.rigidbody.AddForce(Physics.gravity, ForceMode.Acceleration);

    as far as i know ksp doesnt use gravity, they use forces applied at CoM and this is also why i cant use addforce instead of addforceatposition. the CoM of the vessel is not the same as the center of the rigidbody. i can be wrong though

  11. it gives world coords and it does the same for other vessels too, though one fault was that i was testing it with running it in onupdate and forgot about it, that made the force so strong. now its running in onfixedupdate its a lot better still its flying straight up, doesnt matter which side of kerbin it is :(

    edit: its rigidbody has velocity so the first theory surely not true. its not the planet moves away from the still vessel

  12. Hi all.

    i try to run this code on an eva kerbal

    v.transform.rigidbody.AddForceAtPosition(-FlightGlobals.getGeeForceAtPosition(v.transform.position) * v.GetTotalMass(), v.findWorldCenterOfMass());

    v is flightglobal vessel

    the trouble is that the kerbal slowly flying upwards. what other forces are affecting a still vessel on a planetsurface?

    thanks

  13. Do you want active thrust, as in producing thrust? Or activated that when the main throttle changes, the engine responds?

    If you want the "engine responds to throttle", the bool ModuleEngines.getIgnitionState is what you are looking for.

    If you want "engine actually producing thrust", I think bool ModuleEngines.isOperational is what you want, but that needs testing.

    Hope that helps,

    D.

    i was in need of both, these are the perfect ones.

    thanks-a-lot

  14. hi

    i would have a quick question if somebody would know the answer i would be very glad.

    i have an animated engine where i want to run the animation only as long as the engine is running. while its idle the partstates.active is false, but if once i activate it it runs forever, even if it runs out of fuel or i shutdown the engine. i check the this.part.State == PartStates.ACTIVE and after once activating the engine it always true...

    from wiki: "Engines are IDLE before they are fired, ACTIVE while firing, and DEACTIVATED after running

    //out of fuel."

×
×
  • Create New...