Skip to content

Cleanup#6

Merged
SolAstrius merged 17 commits into
SolAstrius:mainfrom
TechTastic:cleanup
May 11, 2026
Merged

Cleanup#6
SolAstrius merged 17 commits into
SolAstrius:mainfrom
TechTastic:cleanup

Conversation

@TechTastic
Copy link
Copy Markdown
Contributor

@TechTastic TechTastic commented May 11, 2026

So, I was informed that your addon exists! I think its a great expansion of existing peripherals!

However, you do many unnecessary things and duplicate a LOT of work you didnt need to, so I am here to rectify it all!

Aeronautics

  • GasProviderPeripheral
    • This should be a GenericSource, not a standalone peripheral. Being a generic means that it will co-existing with other generics (inventory, fluid, energy) as well as apply to every BlockEntity that implements GasProviderData without needing explicit support!

Simulated

  • AltitudeSensorPeripheral
    • Duplicate work is a sin IMO. So I made your AltltudeSensorPeripheral extend the original and kept in your methods for proper documentation. This, in and of itself, will likely be a fix for many of your peripherals from the look of it.
  • DirectionalLinkPeripheral
    • Completely duplicate peripheral with no added features. Removed in favor of the original for feature parity.
  • Docking Connector peripheral and elements
    • Completely duplicate work again. Removed in favor of the originals.
  • GimbalSensorPeripheral
    • Another duplicated peripheral that just needed to be expanded ala AltitudeSensorPeripheral
  • LinkedTypewriterPeripheral
    • First, Id rather like to be credited for code I write, but regardless, you never needed AttachedComputerHandler as that was simply a wrapper class used to avoid loading CC: Tweaked classes when CC: Tweaked wasnt installed. But your addon needs no such protections. Also, LinkedTypewriterPeripheral otherwise was a duplicate of the original.
  • ModulatingLinkPeripheral
    • Completely removed in favor of its original.
  • NamePlatePeripheral
    • Duplicate
  • NavTablePeripheral
    • Duplicate, extends original, kept original methods for documentation.
  • OpticalSensorPeripheral
    • Duplicate
  • SwivelBearingPeripheral
    • Irreconcilable differences due to SimKineticPeripheral, not fixable at the moment
  • TorsionSpringPeripheral
    • Irreconcilable differences due to SimKineticPeripheral, not fixable at the moment
  • VelocitySensorPeripheral
    • Another duplicated peripheral that just needed to be expanded ala AltitudeSensorPeripheral
  • SimKineticPeripheral
    • While this still exists due to SwivelBearingPeripheral and TorsionSpringPeripheral still using it, I have also name a KineticSource generic similar to GasProviderSource so all KineticBlockEntity instances will have these methods except for those which currently have peripherals

Create

  • CreativeMotorPeripheral
    • Duplicate
  • SpeedControllerPeripheral
    • Duplicate
  • SpeedGaugePeripheral
    • Duplicate
  • StressGaugePeripheral
    • Duplicate
  • SequencedGearshiftPeripheral
    • Now extends original, could not keep methods for documentation due to final

Going Further

So, these are all the quick fixes, but the real issue is on the de-registering and breaking of existing peripherals, duplicating existing classes, and copying classes that you dont need.

I dont know if an AI told you to do this or something, but you can just extend or implement existing classes and have their methods carry over, you do not need to re-create classes.

@TechTastic TechTastic marked this pull request as ready for review May 11, 2026 15:26
10 SCADA methods (selfId/sourceId/networkId/kind/speed/stress/...) now declared
once on the KineticScadaSurface interface as @LuaFunction default methods,
implemented by both KineticPeripheral and SimKineticPeripheral via a
single-line scadaBlockEntity() accessor. No more triplicated wrappers.

Also restores the four Create-side SCADA wrappers (CreativeMotor,
SpeedController, SpeedGauge, StressGauge) that the earlier deletes removed:
the KineticSource generic only composes onto bare BlockEntities without an
existing IPeripheral, so blocks that Create or Avionics already wraps need the
SCADA pack via inheritance. Bare kinetic BEs (encased shafts, gearboxes,
mixers) still get SCADA via KineticSource.

Bumps cct-javadoc to 1.10.0-mainthread.4, which adds interface scanning so the
doclet picks up @LuaFunction default methods on interfaces.
@SolAstrius
Copy link
Copy Markdown
Owner

I have temporarily restored the create stuff, so that the docs do not degrade, but I'm exploring other solutions.

Otherwise, LGTM, merging!

@SolAstrius SolAstrius merged commit 63ef473 into SolAstrius:main May 11, 2026
1 check passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants