DspOptiMod
Dyson Swarm render optimization (one glowing band per orbit) + rockets build all nodes first (exactly 30 per node, no overflow), frames only after every node is complete.
About this mod Machine translation
DspOptiMod
Dyson sphere program BepInEx optimization mod (net472, Harmony patch).
Function
- Dyson cloud rendering optimization (Swarm)
- The original DysonSwarm.DrawPost() performs programmatic drawing of each solar sail (sailCursor * 12 quadrilateral vertices, huge overhead for 100,000 sails).
- This mod replaces the entire perspective rendering: each track only draws a translucent glowing ring (GL immediate mode + Hidden/Internal-Colored),
The color is taken from the orbitColorsHSVA that comes with the orbit, and the transparency increases with the number of sails.
- The solar sail bullet (trajectory light point) being launched is still rendered according to the original version, and the launch process is visible.
- The fine grid of sails in the near area (within 2500m) is retained by default and can be turned off altogether by setting DisableNearPass=true in the configuration.
- Small rocket construction sequence (Rocket)
- The original DysonNode.ConstructSp() fills this node with the structure points sent by the rocket and then starts building the framework of this node.
- This mod is changed to: After all the node bodies of the entire Dyson Sphere are completed, structural points will be allocated to the frame.
- Rocket target selection (PickAutoNode/spReqOrder) does not need to be modified. It counts the total demand of "node + framework" and is naturally compatible.
Configuration (BepInEx/config/byboy.dspopti.cfg)
| key | default | description |
|---|---|---|
| Swarm.OptimizeSwarm | true | Turn on Dyson cloud band rendering |
| Swarm.DisableNearPass | false | Turn off even near sail fine rendering |
| Swarm.RingSegments | 128 | Number of ring segments |
| Swarm.RingWidthFactor | 0.025 | Ring width coefficient (×orbit radius) |
| Swarm.RingMinAlpha | 0.25 | The minimum transparency of the ring |
| Swarm.RingAlphaScale | 0.6 | Ring base transparency |
| Rocket.NodesFirst | true (formerly FramesFirst) | Start building the frame after all nodes are completed |
F9 in the game can instantly switch on and off Dyson cloud rendering optimization.
build
dotnet build -m:1 -nodeReuse:false -c Release
Automatically copied to the game BepInEx/plugins/ after building (can use -p:GameDir=... to overwrite the game directory).
Below ref/ is the decompiled reference code (exported by ilspycmd), which is for reference only and does not participate in compilation.
Install & use Install: BepInEx plugin
- The archive from playbuff is the mod itself — usually a BepInEx plugin (a .dll or a plugin folder once unzipped).
- Recommended: use a community mod manager (such as r2modman) — pick this game, import the mod, and the manager sets up BepInEx and its dependencies for you.
- Manual route: install the BepInEx loader in the game folder, then drop the unzipped .dll or plugin folder into BepInEx/plugins/.
- Launch the game — the BepInEx console logs every plugin it loads; seeing this mod in the log means it is installed.
Mods with listed dependencies need those installed too, or they will not load. Options are usually changed in-game or in the plugin's config file.
Install these first, or the mod will not work: