SHOW:
|
|
- or go back to the newest paste.
| 1 | - | set sgfirst to 0. |
| 1 | + | |
| 2 | set sggo to true. | |
| 3 | set sgf to 8. | |
| 4 | set sgpr to 4. | |
| 5 | function sgd {
| |
| 6 | parameter l. parameter d. | |
| 7 | - | parameter sglabel. parameter sgdetail. |
| 7 | + | If l:length > sgpr set sgpr to l:length. |
| 8 | - | If sglabel:length > sgpr set sgpr to sglabel:length. |
| 8 | + | print (l:padleft(sgpr) + ": " +round(d,2)):padright(terminal:width) at (0, sgp). |
| 9 | - | print (sglabel:padleft(sgpr) + ": " +round(sgdetail,2)):padright(terminal:width) at (0, sgp). |
| 9 | + | |
| 10 | }. | |
| 11 | lock twr to ship:availablethrust/ship:mass/body:mu*body:position:sqrmagnitude. | |
| 12 | if not (defined(deploy)) set deploy to 0. | |
| 13 | - | lock sgtwr to ship:availablethrust/ship:mass/body:mu*body:position:sqrmagnitude. |
| 13 | + | |
| 14 | - | list engines in sgengines. |
| 14 | + | |
| 15 | - | function sgfueltime {
|
| 15 | + | |
| 16 | - | set sgtotal to 0. |
| 16 | + | |
| 17 | - | for sge in sgengines set sgtotal to choose sgtotal+sge:consumedresources["liquid fuel"]:fuelflow if sge:consumedresources:haskey("liquid fuel") else sgtotal.
|
| 17 | + | |
| 18 | - | return choose ship:liquidfuel/sgtotal if sgtotal > 0 else -1. |
| 18 | + | |
| 19 | sgd("alt radar",alt:radar).
| |
| 20 | sgd("groundspeed",groundspeed).
| |
| 21 | sgd("twr",twr).
| |
| 22 | sgd("oxidizer", ship:oxidizer).
| |
| 23 | sgd("liquidfuel", ship:liquidfuel).
| |
| 24 | sgd("eta minutes", alt:radar / -ship:verticalspeed / 60).
| |
| 25 | - | set sgp to sgfirst. |
| 25 | + | sgd("electric charge", ship:electriccharge).
|
| 26 | ||
| 27 | Print "":padright(terminal:width) at (0,sgp). | |
| 28 | Set sgp to sgp + 1. | |
| 29 | - | sgd("terrain alt",ship:geoposition:terrainheight).
|
| 29 | + | |
| 30 | ||
| 31 | - | sgd("twr",sgtwr).
|
| 31 | + | sgd("deploy",deploy).
|
| 32 | ||
| 33 | Print "":padright(terminal:width) at (0,sgp). | |
| 34 | - | sgd("ore", ship:ore).
|
| 34 | + | |
| 35 | - | sgd("EC", ship:electriccharge).
|
| 35 | + | |
| 36 | - | sgd("Fuel Time", sgfueltime()/60).
|
| 36 | + | |
| 37 | } | |
| 38 | - | sgd("lat", ship:geoposition:lat).
|
| 38 | + |