Jump to content


  • Content Count

  • Joined

  • Last visited

Community Reputation

15 Good

About uscespc

  • Rank
    Bottle Rocketeer

Recent Profile Visitors

The recent visitors block is disabled and is not being shown to other users.

  1. I don't know what the max range could be, it's just a FixedJoint so whatever the limits for that are. I've tested it at 100m. As for strength I have the breaking forces set to Mathf.Infinity but it would be easy to have the strength decrease with increased distance or just set a max range for use. And for more realism FixedJoint has currentForce and currentTorque parameters you could monitor and take action when thresholds are reached. Also a ConfigurableJoint might be a better option but so many parameters and few examples on setting one up. This is just an adaptation of t
  2. I'm not much of a modeler(as you can see) or coder but I like to play at it just to see if it can be done and can I do it and this is one of my projects a Tractor Beam. It's part of the craft which is another project and not standalone and can only pick things up which is what I intended. I have no idea how well it plays with most of the stock items or other mods, this is a test setup with minimal mods; The girder is from Near Future Construction and the containers, target I created to test with.
  3. I'm working on a mod for a craft that only flies over the surface of a planet and can never reach orbit on its own. When in map view you see the orbit circle and an Ap icon for the craft when flying. Is there some way in code to disable orbit calculations or disable the map orbit display for the craft. Thanks
  4. Thank You Looking at your code gave me a clue on how to solve the land to water transition. On land I use raycasts with a PID controller to adjust power to the hover nodes and this didn't work over water. In your code I saw you use height = FlightGlobals.getAltitudeAtPos(rcTransform.position); so once I detect the transition from land to water I use this value in the PID controller Error field. Land: HForce = PIDController(TargetHeight, hit.distance) Water: HForce = PIDController(TargetHeight, height) Works great, never thought it would be this simple. Here is a
  5. I tried them all 0-32 the only ones that returned hits were 10 Scaled Scenery and 15 Local Scenery. I use 15, 10's hit info was inconsistent. Thanks for the suggestion.
  6. It's all code, I've solved the thrust, turning, hover issues it's when you are hovering over land and cross over to water, water doesn't return raycasts which I use in a PID, AddForceAtPosition construct to hover. Video2
  7. I created a hovercraft that works well on land but I'm having a problem with water. When you transition from land to water the craft maintains the attitude it had on land, this is because it's transitioning from raycast feedback to just plain addforce over water. What I would like to do is level the craft over water but I can't seem to find a way to do it. The video shows the land water transition. Just looking for some suggestions or places to look. Thanks Video
  8. I have a cube that I use: transform.Position = Vector3.up * Mathf.Cos(Time.time); in Update and it floats up and down on the Y axis just fine in the Editor . On the runway Object Inspector shows the Y axis values being changed but the cube moves left and right. DebugStuff shows the transform Y axis to be pointing up. I'm missing something , doing something wrong or just don't understand something. Any suggestions on where to start looking? Thanks
  9. Finally got one to work. In version 1 the shuttle was rigidly constrained by the shaft, version 2 uses a 4x4 hollow shaft with a 3.5x3.5 shuttle in the middle allowing for drift. As the shuttle goes up it will drift back and forth but doesn't crash the game. I'm also using this code in FixedUpdate: (have to test if removing makes a difference) part.Rigidbody.angularVelocity *= 0; vessel.angularMomentum = Vector3.zero; Here's a pic at 59.5Km (I stopped there to test stopping)
  10. The shaft is the easy part. I did it 3 ways. 1. Create it in Blender and make it 60000m high. 2. Create a 20m shaft in Blender and scale it in Unity by 3000. 3. I was able to adapt the code in linuxgurugamer's NRAP mod and created a shaft you could scale to any height. I then created a shuttle that could move up the shaft and that's where I had problems. After a point the games blows up with the following log entries: I'm not sure what is causing the problem PRE or just game mechanics. Errors Video BTW: I'm not much of a modeler or a coder. Just FY
  11. I'm using Unity 2017.1.3p1 Personal and am seeing different .anim file structures based on the following: 1. Project Settings ---> Editor ---> Asset Serialization Mode = Force Text (KSP fails to load part) 2. Project Settings ---> Editor ---> Asset Serialization Mode = Force Binary and then do Project Settings ---> Editor ---> Asset Serialization Mode = Force Text (part and animation work fine after editing) In scenario 2 I remove material from the attribute and change classID from 23 to 21 for it to work. Is this a known Unity problem, a known work around o
  • Create New...