4014 Commits

Author SHA1 Message Date
adam bc810a3393 Readme position and cleanup 2026-04-30 16:48:16 -04:00
adam 34acb34ed6 Kill another non-special-system crash. 2024-05-03 04:10:29 -04:00
adam 8a9be277ae Fix crashes on non-special stars. 2024-05-03 04:01:24 -04:00
adam 902048134c ODR protection for solar system states. 2024-05-03 03:22:23 -04:00
adam d99e5cf176 Replace the starinfo statefile with C++ maps.
This breaks all save file compatibility, but I don't care.
Because of the dynamic nature of the end result I have in
mind, there's no sane way to maintain save file compatibility.

The group file code looks a bit more complex to untangle, so
that will come in another commit.

The way to save this information in the "pluggable module" form
will be to just export large JSON tables of the masks.
2024-05-03 02:03:22 -04:00
adam 41f3053764 Revert "JSONized a lot of the game state."
This reverts commit dd54bd09b7.

 Conflicts:
	sc2/src/uqm/Makeinfo

This is because when I did this, it seems that I didn't do it with
accounting for the state file.  This makes a second new-game crash.
(It may also cause crashes on other solar system loads?)
2024-04-30 14:20:31 -04:00
adam 04ac4a26e0 Get all stuff ready for retiring the QUEUE code.
The replacement isn't too much better...  But it's a
wrapper around C++ `std::list`, which means C++ code
can start to peer into it without needing to make
widespread changes to the C code that still works with it.

Over time, I can modernize all of the C code into C++ code
at whatever pace is needed.
2024-04-29 15:36:29 -04:00
adam dd54bd09b7 JSONized a lot of the game state.
The core of it was in the byte array, but...

Much of it was in some global task-specific C structs.  I'll
wind up making the macro mess a bit worse, just to get everything
into the JSON fold... then I can go make a pass that makes things
C++ and reduces the complexity down.
2024-04-29 02:38:45 -04:00
adam df807525c7 Add an MIT licened JSON lib.
This will let me make more dynamic gamestate which can
be stored in the save files (which will now just be JSON text).
2024-04-28 21:57:51 -04:00
adam 01683705d0 Started deprecation and removal of the old star index system. 2024-04-28 17:05:29 -04:00
adam bb26452d23 Made all bespoke planet generation now go thru C++.
All string dispatched, now.
2024-04-28 15:04:22 -04:00
adam fadd98b3c5 Yuffo is the star in the lore.
Spathiwa is the world.  Oops!  I should have remembered
that.  :-)
2024-04-28 03:19:23 -04:00
adam e07f567d76 Added VUX dynamics. 2024-04-28 03:12:28 -04:00
adam e9366ac986 The Mycon worlds are now dynamic. 2024-04-28 02:25:23 -04:00
adam 456d2aa40c Validation really only needs to be done once.
Also be a bit more noisy with validation.
2024-04-28 02:21:25 -04:00
adam 47c227943b Supplement argument consistency checking.
With the need to start handling the supplemental argument,
I'll need a hook for those handlers to slip in their checks
that nothing is wrong.
2024-04-28 02:21:04 -04:00
adam cd8312ebc1 On generation check that the whole starmap is properly sorted.
(I should probably make this check runtime-sticky...  with
huge dynamical games it might get a bit noticable that
we slow down for each solar system load event.)
2024-04-28 02:03:40 -04:00
adam d4f9485f90 Modern C++.
Frankly I don't care to try to support a wide variety of
"older" stuff.  I don't have the time, and I don't think
it's sensible to promote being able to play the
modified form of this game (using my dynamic system) on
toasters and coffee makers.  Most systems with the capacity
to handle what I'll wind up demanding will probably
support C++23 already.
2024-04-28 02:00:31 -04:00
adam db25fb4537 Rainbow search modernized. 2024-04-27 20:06:04 -04:00
adam cc2d7db63b Fuel tank fix on super-ship on startup. 2024-04-27 20:04:33 -04:00
adam e8a5b79e89 A bunch of extra powers at start to enable exploring to check generation 2024-04-27 19:31:14 -04:00
adam 8ae8a15886 Melnorme now are dynamic.
It seems that each Melnorme is distinct at each
system.  In my play-testing here, they stay dead if
killed.  Which is, well, sensible.

I don't remember if this was the behaviour in the original game.
2024-04-27 17:48:59 -04:00
adam 476d49e267 Rainbow worlds gen.
The index computation could stand some modernizations...
2024-04-27 14:50:18 -04:00
adam 93c7475e3c Make the dependency phase always run.
This helps as I'm renaming files.
2024-04-27 12:11:53 -04:00
adam 6bdacb1462 The last of the single-system generators. 2024-04-27 12:11:32 -04:00
adam a5c3ea37a1 Check for another kind of definition fail.
We can't be both legacy and modern at the same time.
2024-04-27 00:16:26 -04:00
adam aff534f6b5 Another 5 custom generators made C++ish. 2024-04-27 00:15:57 -04:00
adam ef18781091 Dynamically check generator registration on any use.
This helps find when there's string mismatches and/or forgotten
registrations.
2024-04-26 22:13:55 -04:00
adam 4f1b12d4c5 Dynamic Chmmr, Druuge, Supox, and Mycon Gambit.
Now there's still more to do...  But I think I can retire the
old funcptr based stuff soon.
2024-04-26 21:45:17 -04:00
adam a9d0e3ce7c Some nits. 2024-04-26 17:50:03 -04:00
adam 52b451d7f3 Check for duplicate registration. 2024-04-26 17:49:37 -04:00
adam ad80c08c64 Androsynth, Burvixese, Syreen, and the Vault are now dynamic.
Moving towards completion here.
2024-04-26 17:49:00 -04:00
adam 70b21f5e5b ZFP Scout in Rigel is now string-bound. 2024-04-26 15:42:13 -04:00
adam 2cd1265945 Dynamic generation registry for Ur-Quan wreck planet. 2024-04-26 05:20:42 -04:00
adam dab2f8ede6 Decouple the generator and the starmap defs.
I changed it to use string lookups.  This permits
hardcoded strings in the table, which defeats a bit
of static checking -- but the goal is to permit those
strings also at runtime so folks can define their
own generators as plugins.

Further, the decoupling means that there's less
tight coupling between how the generator works
and how the map is defined -- fewer forward
decls and constants for each race, etc.
2024-04-26 04:58:41 -04:00
adam 7512e273e0 Make depend target... 2024-04-26 04:00:23 -04:00
adam 45cf5dc4d7 Colony is now defined in C++ 2024-04-26 04:00:10 -04:00
adam fde9e63d8b Several generators are "sorta parameterized" -- make ready for that.
The VUX, Utwig, Melnorme and others all have branching paths
on the actual `XXX_DEFINED` enum value.  This is an ersatz
parameter.  I'll provide an extra string parameter for all
generators, that lives in the `SolarSystem` type (for now).

The table can now just mention the static string which
indicates the kind of variation to build.  (Eventually,
this will become more dynamic, once I have support for
runtime-insertion of stars.)
2024-04-26 03:40:30 -04:00
adam fbfd96674b Remove the legacy slylandro gen.
The C++ one now works fine (I think).
2024-04-26 03:39:30 -04:00
adam b496579618 Put my name in the credits because... why not? 2024-04-26 03:23:32 -04:00
adam 64842659c6 Default generation now goes thru C++ 2024-04-26 02:57:52 -04:00
adam ef041d3735 And now the shofixti are all C++! 2024-04-26 02:38:50 -04:00
adam 8ea1dd5c8a Make shofixti system gen position independent.
(Except for the star background...  I can solve that later, if I
want to.)
2024-04-26 02:12:20 -04:00
adam a6d5cbf4ca This updates how Sol generates to have more stuff.
It's a bunch of hacky things I threw together.  Some accurate,
some not.  Mostly just to play with the algorithms which
generate stuff -- I want the generation to be unaltered if I
slip in new stuff between planets.  To do this, I have to
understand when RNG gets updated, how, and what other constants
affect the generation computations.
2024-04-26 00:00:13 -04:00
adam 52ddaf0d71 Document why I cannot increase the moon count, at this time. 2024-04-25 23:46:01 -04:00
adam 7fe5c3dfbc Notes on where I'm headed. 2024-04-25 17:21:04 -04:00
adam 975183cd26 A bunch of more bits for planet data.
The original code is miserly with bits for planet data, which
made sense for a game for that generation of hardware.  I'm
fine with dozens of KB per planet...  Even with tens of thousands
of planets; modern systems won't even be stressed by the memory
usage.  A few hundred megabytes to a gigabyte are available easily
on most platforms that I care about.
2024-04-25 17:14:19 -04:00
adam 97148db2d4 And this is the first C++ generator!
Hello, gas bags!  Somehow, it seems fitting that they're the first...
they did, after all, mess up the code/settings on the probes
to wreak havoc!

Hopefully I haven't!  :-)

I think I can simplify things a lot from here...
2024-04-25 02:04:07 -04:00
adam 822e1c3004 Sly is ready to be C++'ed.
But it's still not C++'ed yet.  I put it over in ilwrath space,
just to easily get to it (and it has enough planets to make the
right one a gas giant).
2024-04-25 01:49:16 -04:00
adam 7c02232e46 C++ Generate base -- fix compiling. 2024-04-25 01:48:24 -04:00