Approved 2022/01/17 22:43

Flight Control System

Description:

This is a flight controls script designed for use on the Draconis Expanse server to carry out certain common maneuvers such as the Flip and Burn, as well as act as a basic autopilot. Ships will have the vast majority of their thrust facing forward with the epstein drives. This script is intended use this forward thrust effectively, and make piloting expanse style ships easier and fun.

Features:

  • Flip and Burn to stop ship. This uses the forward facing epstein drives to bring the ship to a stop.
  • Flip the ship around 180 degrees.
  • Take the ship out of a gravity well using minimum thrust, and stop just outside of gravity
  • Deorbit a ship allowing gravity to pull the ship down and then bring the ship to a stop a certain distance above the surface.
  • Direct input GPS, calculates the distance and a simple ETA. After using the engage command, the script will engage autopilot and fly to the GPS
  • Multi point trips allows the user to put multiple GPS into the PB custom data, and plot a course. The after using the engage command, the script will engage autopilot and fly to the GPS sequentially.
  • Boost support, prevents the ship from coasting during trips, enabling them to make use of the Relative Top Speed mod boost feature.
  • Max burn can be set, which will determine the max percent thrust the forward facing epstein drives will be engaged by the script.
  • The script can display on the main control block screen, the programmable block screen, and an LCD with the script tag. You can set these in the custom data settings.
  • The script will avoid using forward facing RCS thrusters and only use epstein drives for forward thrust in order to save fuel.

How to use this:

  1. Put the ScriptTag ("[EFC]" by default) in the name of the control block (cockpit) and optionally in the name of an LCD.
  2. Add the script to the programmable block.
  3. Set the settings in custom data to your preferences.
  4. Use the Tune command to tune the rotation the script uses (also do this if the ship has large weight changes).
  5. Recompile the script if you change the control block, LCD, Gyros, or any of the forward thrust.

It is recommended to at least put the "off" command on the hot bar for easy access.

Custom Data Settings:

  • In custom data you can adjust the settings of the script
  • The Script_Tag is the text you need to add to the control block and optionally and LCD. You can change this to whatever you want.
  • Deorbit_Buffer is the distance above the ground you want the ship to be stopped at when using the Deorbit command. The script accounts for stopping distance.
  • GPS_Buffer is the distance from a destination GPS point you want the ship to be stopped at when using the auto pilot. The script accounts for stopping distance.
  • Max_Burn is the max percentage of thrust the script is allowed to use for the forward facing Epstein drives.
  • Max_Speed is the maximum speed in m/s the script is allowed to use for autopilot. This will automatically update when changing between high and low speed zones
  • Use_Controller_Screen enables or disables the script displaying to the primary control screen of the control block (Cockpit)
  • Use_PB_Screen, enables or disables the script displaying to the screen on the programmable block
  • Use_Boost, For autopilot, when off the thrust is shut off and the ship is allowed to coast at top speed. When on, the ship will use constant thrust in order to take advantage of the Relative Top Speed mod boost feature
  • Display_Gas_Levels, enables or disables hydrogen and oxygen gas levels being displayed.
  • Trip GPS Points:, Place a sequence of GPS points after this line, and use the plot command to set a course, then the engage command to start autopilot and follow that course.

Commands:

  • Off: Stop program, disable all overrides, reset dampners to initial state
  • Tune: Does a small rotation to tune ship rotation damping. Prevents overshooting when during rotations. [DO THIS FIRST]
  • Dampreset: Resets rotation damping to 1
  • Stop: Flip and burn to stop
  • Flip: Flip ship 180 degrees
  • Orbit: When in planet gravity, this will fly to outside gravity then flip and burn to stop.
  • Deorbit: When flying down a gravity well, this will flip and burn stopping above the ground and hovering (WARNING: Deorbit maneuver uses FULL thrust despite max burn settings)
  • GPS: Enter a full GPS and get distance, use "Engage" to proceed to GPS
  • Plot: After putting your GPS markers into the custom data "Trip GPS Points" section, use the plot command to calculate distance and prepare the ship for the trip
  • Engage: Proceed to GPS, ship will first come to a stop, then fly to the GPS and stop
  • Cancel: Stop trip, does not remove destination
  • Boost: Toggle on/off using boost for entire trips to a specified GPS (Use thrust the entire trip to gain boost speed)
  • Boost On: Turn on using boost for entire trips to a specified GPS (Use thrust the entire trip to gain boost speed)
  • Boost Off: Turn off using boost for entire trips to a specified GPS (Coast once max cruise speed has been reached)
  • Set Damp #: Allows manual entry of the rotation damping (must be between 0 and 1)
  • Set Speed: Override your ships cruising speed. When your ship reaches this speed on a trip, it will begin coasting to the destination.
  • Set Burn: Max burn allowed, script will not burn higher than this percent
  • expanse/flight_control_systems.txt
  • Last modified: 4 months ago
  • by mr_magnificent