Jump to content

[Mod] CaptainMyShip


tangowrangler

Recommended Posts

TL;DR: This mod INTENDS to put in features and functionalities which let you captain your ship. The idea is to be able to hand down higher level commands to the ship other than going through all the maneuvers. You should have a look at the "Notes" section to find out about the numerous caveats before starting with the mod. You need to have a captain aboard and the commands only work when in keyboard control mode (i.e., you have to be in keyboard mode or shift to it for the orders to execute).

 

Updated to work with 0.14.5

 

Disclaimer: first time with lua; first time modding. i know i messed up things. let me know down below...

 

Contents:

[*]Features

[*]Installation

[*]Notes/Readme

[*]Motivation

[*]Preview

[*]Plans

 

Features:

 

Autopilot to

[*] face targeted object

[*] travel to targeted object if heading is to targeted object

[*] face and travel to targeted object

[*] initiate retrograde burn to bring craft to a stop

 

Installation:

 

Follow the readme in github.

 

https://github.com/lethargi/CaptainMyShip


  •  
     
    Notes/Readme:
     

     

    Motivation:

    It would be nice to have a mod that actually lets you captain your ship than having to be at its helm 24-7. A captains needs his chill time. So simple features like

    • flying to a station and docking
    • autohiring crew
    • boosting away from the sector
    • the ai attacks, the ai mining

    etc. I think the current modding capacities MAY allow these

     

    Could be even more complex where you can

    • plot multi-jump courses/trade-routes
    • Auto-explore greens or yellows
    • setup attack tactics,
    • thave it distribute different fighter squads to different asteroids,
    • interface for commanding other ships in the sector

    However, I do not believe it is possible to implement these features with the current modding API.

     

    Preview:

    Excuse the shitty screen grabbing and video editing; new to this stuff too.

     

     

     

    Plans:

    Most of thoughts in motivation are left as ideas to explore. There is 90% chance that i will not improve this mod. Doing just this little bit took out about 3-4 days from me. However, if i do get back to it (and for other people willing to pick it up), i have some general directions to go towards.

     

    [*]Most importantly object avoidance

    [*]Next most important interface to set the control parameters that determine the control behavior of the mods

    [*] System identification in the loop for better control

    [*]Captain information interface

    [*]Path planning in sector

    [*]Docking

    [*]Attack stances and maneuvers (Hard)

    [*]Inter-sector navigation using gates and jump

    [*]Auto-trade; Auto-hire; Auto-harvest

    CaptainMyShip_v01.zip


  • If you have thrusters for braking only accounts for the brake thrust of those; if you do not have thrusters for braking assumes brake thrust is 75% of acceleration You can force your ship to boost faster by changing the estimated brake-thrust of your vehicle in the CMSlib.initialize() function of the CMSlib.lua file. It defaults to 0.75; this number is factor of your maximum acceleration; if your brake-thrust is 3 times your acceleration, you can safely set it to 2.5 and get faster boosts. I could not find a way to obtain the brake thrust of my ship as of yet
  • Your ship needs to have a captain for the commands to work
  • The commands only work when in keyboard control mode
  • The UI is based on Nexus' mod Alpha! Carrier Commands
  • Not suited for multiplayer yet; i tried implementing all the functionality clientside to minimize the loads. this may leave options for exploits if used in a multiplayer setting. Being careful for unknown unknowns here
  • There is NO object avoidance functionality At the current state, it just points and goes to within 2kms of the target
  • All the control algorithms are hard-coded; so don't expect optimized flying
  • Due to some of the tuning, the algorithm is more suited for medium to larger ships (5-10 slots) with "average" velocities and rotation rates ( recommended < 1.5 rad/s pitch and yaw, algorithm does nothing with roll yet); it works in smaller ships but behaviour maybe wonkier and disclaimer for crashes :P
  • there MAY STILL BE  a bug which causes the ship to boost before turning for one instance if the target is changed after arriving at the destination while using boosttotarget. This is not a big deal for larger ships but for tiny ships may cause issues sometimes.
Link to comment
Share on other sites

  • 1 month later...

Good work!

Is this mod dead?

And why [rather how] use the regular ship AI, I mean set up commander onyour ship and just command it as it was another ship of your without you on board. It would need just a button "Commander on/off deck", and than issue regular command via ship menu.

 

Link to comment
Share on other sites

  • 4 months later...

I have been off of Avorion for a long time. Will pick this one up. Lost a big part of my progress as I formatted my pc without keeping backups. Will start from the stuff that is available here sadly. Hope to have something running soon. Anyone using it having queries or suggestions, do post them.

Link to comment
Share on other sites

I have been off of Avorion for a long time. Will pick this one up. Lost a big part of my progress as I formatted my pc without keeping backups. Will start from the stuff that is available here sadly. Hope to have something running soon. Anyone using it having queries or suggestions, do post them.

 

U can recover deleted files with EaseUS recovery program

 

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...