-
-
Notifications
You must be signed in to change notification settings - Fork 380
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Expose galaxy parameters - modify explored space radius #5941
Expose galaxy parameters - modify explored space radius #5941
Conversation
0cfad00
to
0e20c86
Compare
There are
So, I've been looking at this from a slightly different angle, and it's that we also need to have a non-circular shape for the explored bubble. The scale height for the Milky Way is (grossly simplifying) ~1000ly, which means that the circular bubble tends to look quite unnatural as it seems there's been a great migration to comparatively sparse regions of space but less expansion out "horizontally" into the denser parts of the galaxy along the main disk. I'd like to implement a squashed sphere instead, that matches the density falloff of the galaxy a bit better. I'll take a look at this PR when I get there - currently have several other things vying for my attention right now IRL. |
I really want to see this in master before the February 2025 release. I think just reading the parameters from a file is a first (minimal) step. |
You could call You can also create one by hand. |
That works perfectly. If there's no Good job, all works |
@fluffyfreak thanks! I'll have to try this out after the weekend, and un-draft this PR, with the aim of getting it merged before next release unless someone else supersedes me with a better implementation. |
0e20c86
to
880b79e
Compare
OK, pushed. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
In general this is a good idea, there's just a few things that need to be cleaned up.
In addition to the comments below, src/GalaxyConfig.h/cpp
needs to be moved to the galaxy
subdirectory.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Provisionally approved pending testing, thanks!
Expose parameters for explored space: 'min', 'max' range and 'mix' (drop off) parameters. Note: any change to this file will break saves. But we want it for modders.
4e5a58e
to
84f6229
Compare
Squishy-squashed to single commit now. Any change to the parameters would potentially break saves / missions, I assume, as the universe becomes different. This will - for now - be an undocumented feature? Ideally, one should perhaps insert some text at the top of galaxy.ini describing the parameters, and that it breaks saves? |
Undocumented feature is fine. This is more of a power-user thing, as changes to the explored radius can potentially leave factions without homeworlds, leading to assertions. (I typically have to delete all factions beyond the "main three" when working on galaxy code...) |
omg, I went to look at the Factions code to see if I could fix that ... it's been over 12 years since I wrote them 🤯 I think I need a lie down |
On the plus side I could set those values to like 3,3,3 and it still didn't crash 👍 what kind of assertions do you hit? |
If a faction's homeworld does not exist (set the system index to something like 99) the game will segfault/assert when attempting to compute whether systems are within the faction's influence radius. I don't remember the exact line offhand, but it's very easy to reproduce by modifying one or more faction files and starting a game. |
I've always felt the 700 ly radius we have of explored worlds is much too big.
A user (crux_72) has used pioneer universe for many years as basis as dungeon master for a RPG, but only plays a few hand-made system, and expressed the need to change the radius for explored systems, such that he could tailor it for his needs.
I think it's a good idea, and seems like a very simple thing to do.
...Apparently not for piglet brained people, thus this PR is WIP. Problem: it doesn't create the new galaxy.ini file, as I expected. I've pretty much copy-pasted the pattern for how we do with the usual config.ini file, but my initialization differs in sufficiently different way as to not be used by the game.Since @Web-eWorks is currently going through the galaxy generation code, I'll open this
not-yet-workingvery small fix.If anyone want to take over, or re-implement this from scratch, you're more than welcome.