Jump to content

[WIP] Stranded! Banished with Kerbals


TV4Fun

Recommended Posts

Development GitHub Repo: https://github.com/TV4Fun/Stranded (License: MIT)

I am asking the experienced KSP mod devs here for input. How hard does this sound to make? Is it feasible to do in KSP? What would be the best place to start? Would anyone like to join me in developing it?

I have an idea for a mod that is kicking around my head and stubbornly refusing to leave. I have a bit of experience with development in Unity, but none with making KSP mods,  so I have no idea how feasible this is or where to begin on implementing it. I've looked a bit at the source code for MechJeb and Kerbalism, as they both do things along similar lines and could well be components of this mod. I had first thought to develop this as a standalone game, but it occurred to me that a lot of the basic engine functionality is already implemented in KSP and various mods, so it might just be a matter of tying them together.

Stranded dares to ask that important question, "what if Kerbal Space Program was a strategy game?" The basic thought for a start is to add a UI to KSP where you manage things on a higher level, ordering ships/kerbals to go from one place to another and them doing it automatically, adding colony building along the lines of Banished/Surviving Mars while still retaining the underlying mechanics and including some life support/resource management, but also having the ability to zoom in and directly fly a ship or walk a Kerbal through your Kolony if you want. KSP's design and simulation system give us a chance to have a mechanic like Spore where you can design your own ships and buildings, but have those design choices actually mean something, and KSP already having the physics and building system implemented and optimized over many years of development saves a lot of time compared to making something from scratch.

I see this as a single player city/base/Kolony-building game using parts we already have for building surface bases in KSP but with a gods-eye/Settlers/Rimworld type interface where a colony consists of many Kerbals who are AI controlled and follow player commands indirectly. I.e. the player designates something to be built and, assuming resources are available for it, Kerbals come out and build it. You would initially have to ship in resources for the colony to build with but would eventually be able to mine resources locally for continued sustenance and expansion. I would use the existing Kerbal world and assets to start with, but eventually could add customizations for different planets and even different star systems. A recent game that does something similar is Moons of Ardan, though I found its implementation a bit simplistic. Really what I want is to take the basic loop of KSP career mode and automate some of the more tedious parts of it, allowing multiple concurrent missions and building complex bases without requiring the player to manage each individual.

What do you guys think? Does this sound worth doing? How would I go about doing it? The very first proof of concept I had in mind was to implement an RTS-style point and click interface, where you would control a Kerbal walking along the ground from a birds-eye view and could click on the ground to get him to walk to that point. Next have multiple Kerbals controlled like this at once, click one to select it and tell it where to go, and have them all walking to different places at the same time. How would I do that?

Edited by TV4Fun
Unbury Github link
Link to comment
Share on other sites

If anyone is curious or would like to contribute, I have set up a rudimentary version of this at https://github.com/TV4Fun/Stranded (License: MIT). At present, if you are on the ground in flight mode, you can press K to spawn a Kerbal at the mouse cursor. It and any other Kerbals you spawn will then walk slowly towards wherever the mouse is pointing. It's really quite creepy.

Edited by TV4Fun
Link to comment
Share on other sites

  • 3 weeks later...

Okay, I am now working on a narrow portion of this with automated EVA construction, which I am calling MechBill. So far I have implemented a procedurally controlled KerbalEVA class and a version of the construction UI that can be called from outside EVA and used to create tasks with ghost parts. More to follow. Comments and contributions on my code are welcome.

Link to comment
Share on other sites

In the latest update, the EVA construction UI is available when flying any vessel. You can select a part in inventory and place it somewhere on your vessel. If you have any engineers on the ship, one will come out and automatically fly to the targeted placement. Next up is to have them fly to the container with the part, retrieve the part, fly to the target location, and have them weld it on. I thought about using KIS-based attachment instead of stock, but for a first pass, I don't want to require any more outside mods than necessary.

Link to comment
Share on other sites

On 5/22/2023 at 3:28 PM, TV4Fun said:

Okay, I am now working on a narrow portion of this with automated EVA construction, which I am calling MechBill. So far I have implemented a procedurally controlled KerbalEVA class and a version of the construction UI that can be called from outside EVA and used to create tasks with ghost parts. More to follow. Comments and contributions on my code are welcome.

I'm quite interested in this concept - particularly this feature!  Sounds awesome.  Stockish as much as possible is great.

29 minutes ago, TV4Fun said:

You can select a part in inventory and place it somewhere on your vessel. If you have any engineers on the ship, one will come out and automatically fly to the targeted placement.

It would work well with the Sandcastle mod as well.

 MKS or the Davon Supply Mod might do something similar to the the automated routes etc.

But a stock-a-like solution (particularly for MKS) would be nice to try! 

Link to comment
Share on other sites

I've added some 3D pathfinding so Kerbals can navigate around obstacles instead of trying to just fly through them. It worked pretty well to navigate around the wing of my big orbital spaceplane and attach a solar panel to the tail. It could benefit from some optimization and parameter tweaking, as it introduces a noticeable slowdown right now, but I think that is fixable.

Link to comment
Share on other sites

7 hours ago, Nightside said:

I love watching this mod develop @TV4Fun, but I couldn't see what happened in that video :(

Yes, it's hard to give a good demonstration at YouTube resolutions. Look at the cupola in the lower left when I place the solar panel at 0:10. You should see a Kerbal spawn there and navigate to the tail where the solar panel is, going around the spaceplane body in the process. When I place the Communotron at 0:42, another Kerbal spawns from the right side of the spaceplane cockpit, so they are both moving to their respective targets simultaneously.

Edited by TV4Fun
Link to comment
Share on other sites

This thread is quite old. Please consider starting a new thread rather than reviving this one.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...