Jump to content

kineticPull

Members
  • Posts

    29
  • Joined

  • Last visited

Posts posted by kineticPull

  1. I'm having a bit of an issue with the modules: after assembling my base on minmus (1 ponderosa, 3 chuckwagons) I left for the space center, came back, and the whole structure was thrown into the air. This seemed to happen whenever the structure was loaded into physics. I am going to test this with KJR later and see what happens. Thx.

    Edit: KJR still launches the base into the air, but it doesn't shake it like in stock.

  2. So I need an xxx_map, an xxx_height (greyscale), and an xxx_normal. If this works thank you very much. Last thing, how do I add Oceans?

    EDIT: Didn't work. Added height maps, but they still are tilted

    Here's my RSS config for my innermost planet:

     Femia 
    {
    SSBump = GameData/Kopernicus/Textures/Femia_normal.png
    useSphericalSSM = false
    PQS
    {
    Femia
    {
    Add
    {
    PQSMod_VertexColorMapBlend
    {
    vertexColorMap = GameData/Kopernicus/Textures/Femia_map.png
    blend = 1.0
    order = 9999993
    }
    }
    }
    }
    }

  3. So, its finally in a goodish enough state to post.

    I present my replication of the Boeing CST-100 Spacecraft

    Javascript is disabled. View full album

    As you can see, very unfinished, especially the textures; however, a preliminary download is below.

    Download:https://www.dropbox.com/s/k1pu4qvnn0gaqs6/CST-100.zip?dl=0

    For those willing to help me, I could use a good texturing tutorial that starts with UV mapping.

  4. That would be the easy way out. I'm trying to learn how to code C# in KSP, and i'm asking for help on the things I'm completely stuck on.

    but I figured it out.


    using UnityEngine;

    namespace BASIK_Life_Support
    {
    public class LifeSupport : PartModule
    {

    public PartResource oxygen = null;


    public void Update(ProtoCrewMember member)
    {

    PartResourceList prl = part.Resources;

    foreach (PartResource wanted_resource in prl)
    {
    if (wanted_resource.resourceName == "Oxygen")
    {
    oxygen = wanted_resource;
    }
    }

    if ( oxygen.amount <= 0)
    {
    part.RemoveCrewmember(member);
    member.seat = null;
    member.rosterStatus = ProtoCrewMember.RosterStatus.Dead;
    }

    else
    {
    oxygen.amount -= (0.2 * part.protoModuleCrew.Count);
    }
    }
    }
    }

    I hope it works


  5. using UnityEngine;

    namespace OceanExpansion
    {
    public class OceanCrash : PartModule
    {

    [KSPField]
    public float HSplashTolerance;

    [KSPField]
    public float VSplashTolerance;

    [KSPField]
    public double VSplash;

    public double vertical;


    public void OnStart()
    {

    if (vertical <= VSplash)
    {
    if (vessel.PQSAltitude() <= 0)
    {
    part.crashTolerance = HSplashTolerance;
    }
    else
    {
    part.crashTolerance = VSplashTolerance;
    }
    }
    else
    {
    part.crashTolerance = VSplashTolerance;
    }
    vertical = vessel.verticalSpeed;

    }






    public void OnLoad()
    {
    vertical = vessel.verticalSpeed;
    if (vertical <= VSplash)
    {
    if (vessel.PQSAltitude() <= 0)
    {
    part.crashTolerance = HSplashTolerance;
    }
    else
    {
    part.crashTolerance = VSplashTolerance;
    }
    }
    else
    {
    if (vertical > VSplash)
    {
    part.crashTolerance = VSplashTolerance;
    }
    }


    }

    public void OnSave()
    {
    vertical = vessel.verticalSpeed;
    if (vertical <= VSplash)
    {
    if (vessel.PQSAltitude() <= 0)
    {
    part.crashTolerance = HSplashTolerance;
    }
    else
    {
    part.crashTolerance = VSplashTolerance;
    }
    }
    else
    {
    if (vertical > VSplash)
    {
    part.crashTolerance = VSplashTolerance;
    }
    }


    }


    public void Update()
    {
    if (vertical <= VSplash)
    {
    if (vessel.PQSAltitude() <= 0)
    {
    part.crashTolerance = HSplashTolerance;
    }
    else
    {
    part.crashTolerance = VSplashTolerance;
    }
    }
    else
    {
    if (vertical > VSplash)
    {
    part.crashTolerance = VSplashTolerance;
    }
    }

    vertical = vessel.verticalSpeed;

    }

    }


    }

    Here's my current code. It runs fine in ksp, and the part (KORD drop pod) does what it is supposed to. It has a 1000 crash tolerance over water, and a 14 over land. my current problem is making a vertical speed of >14 m/s over water destroy the pod, where a >14 m/s horizontal speed over water will not.

  6. Thanks. I just got started with this plugin developing yesterday, so I don't really know what I'm doing.

    Also, I tried using vessel.VerticalSpeed to have the part only survive high velocity landings if the they were horizontal. Here's what I have.


    if (vessel.verticalSpeed <= VSplashTolerance)
    {
    if (vessel.PQSAltitude() <= 0)
    part.crashTolerance = HSplashTolerance;

    else
    part.crashTolerance = VSplashTolerance;
    }

    The part survived all water landings no matter how fast.

    I might have a page in Add on Development tomorrow...

  7. Thanks everybody!

    here's what I have now. When I used public override void, it said "no suitable method to override"

     using UnityEngine;

    namespace OceanExpansion
    {
    public class OceanCrash : PartModule
    {

    bool aboveWater = false;


    public void OnStart()
    {
    if (vessel.PQSAltitude() <= 0)
    part.crashTolerance = 1000;

    else
    part.crashTolerance = 14;


    do
    {
    if (vessel.PQSAltitude() <= 0)
    part.crashTolerance = 1000;
    if (vessel.PQSAltitude() <= 0)
    aboveWater = true;
    } while (aboveWater == false);

    do
    {
    if (vessel.PQSAltitude() >= 0)
    part.crashTolerance = 14;
    if (vessel.PQSAltitude() >= 0)
    aboveWater = false;
    } while (aboveWater == true);
    }






    public void OnLoad()
    {
    if (vessel.PQSAltitude() <= 0)
    part.crashTolerance = 1000;
    else
    part.crashTolerance = 14;


    do
    {
    if (vessel.PQSAltitude() <= 0)
    part.crashTolerance = 1000;
    if (vessel.PQSAltitude() <= 0)
    aboveWater = true;
    } while (aboveWater == false);

    do
    {
    if (vessel.PQSAltitude() >= 0)
    part.crashTolerance = 14;
    if (vessel.PQSAltitude() >= 0)
    aboveWater = false;
    } while (aboveWater == true);
    }

    public void OnSave()
    {
    if (vessel.PQSAltitude() <= 0)
    part.crashTolerance = 1000;
    else
    part.crashTolerance = 14;

    do
    {
    if (vessel.PQSAltitude() <= 0)
    part.crashTolerance = 1000;
    if (vessel.PQSAltitude() <= 0)
    aboveWater = true;
    } while (aboveWater == false);

    do
    {
    if (vessel.PQSAltitude() >= 0)
    part.crashTolerance = 14;
    if (vessel.PQSAltitude() >= 0)
    aboveWater = false;
    } while (aboveWater == true);
    }


    public void overWater()
    {
    do
    {
    if (vessel.PQSAltitude() <= 0)
    part.crashTolerance = 1000;
    if (vessel.PQSAltitude() <= 0)
    aboveWater = true;
    } while (aboveWater == false);

    do
    {
    if (vessel.PQSAltitude() >= 0)
    part.crashTolerance = 14;
    if (vessel.PQSAltitude() >= 0)
    aboveWater = false;
    } while (aboveWater == true);

    }

    }


    }

    Still goes boom when it hits the water.

  8. So I want to make it so that when I hit the ocean at a speed less than 1000 m/s (Debug speed) my part survives, but when I hit the land, it doesn't survive if it is greater than 14 m/s here is my code

     using UnityEngine;

    namespace OceanExpansion
    {
    public class OceanCrash : PartModule
    {


    public void OnStart(Vessel.Situations state)
    {
    if (state == Vessel.Situations.SPLASHED)
    part.crashTolerance = 1000;
    else
    part.crashTolerance = 6;
    }




    public void OnLoad(Vessel.Situations state)
    {
    if (state == Vessel.Situations.SPLASHED)
    part.crashTolerance = 1000;
    else
    part.crashTolerance = 6;
    }

    public void OnSave(Vessel.Situations state)
    {
    if (state == Vessel.Situations.SPLASHED)
    part.crashTolerance = 1000;
    else
    part.crashTolerance = 6;
    }


    }
    }

    What am I doing wrong?

×
×
  • Create New...