fix(radar): detect unloaded VS ships and fix radius config double clamp on 1.18.2#28
Open
yuuri5656 wants to merge 6 commits intoSuperSpaceEye:1.18.2from
Open
fix(radar): detect unloaded VS ships and fix radius config double clamp on 1.18.2#28yuuri5656 wants to merge 6 commits intoSuperSpaceEye:1.18.2from
yuuri5656 wants to merge 6 commits intoSuperSpaceEye:1.18.2from
Conversation
There was a problem hiding this comment.
Pull request overview
This PR targets radar reliability and config correctness on Minecraft 1.18.2 by changing Valkyrien Skies ship enumeration to catch previously-missed ships, fixing the default Double config bounds so -1 is preserved, and updating build settings to JVM 17.
Changes:
- Update radar ship scanning to enumerate ships via
level.shipObjectWorld.allShips, apply radius filtering, and deduplicate by ship id. - Fix config delegate default bounds for doubles to allow negative values (so sentinel values like
-1aren’t clamped). - Configure Kotlin compilation to target JVM 17; adjust Gradle properties (but the current diff includes unresolved conflicts and generated build artifacts).
Reviewed changes
Copilot reviewed 10 out of 36 changed files in this pull request and generated 5 comments.
Show a summary per file
| File | Description |
|---|---|
| gradle.properties | Updates Gradle JVM/memory settings and local jar path config (currently contains merge-conflict markers). |
| build.gradle | Sets Kotlin JVM target to 17 across projects. |
| common/src/main/kotlin/net/spaceeye/someperipherals/stuff/radar/scanInRadius.kt | Changes ship scanning to enumerate all ships, filter by distance, and dedupe results. |
| common/src/main/kotlin/net/spaceeye/someperipherals/config/ConfigTypes.kt | Changes CDouble default range to allow negative values. |
| common/AcceleratedRaycasting-0.0.1-dev.jar | Adds a vendored binary jar (likely a local/dev dependency). |
| fabric/build/tmp/sourcesJar/MANIFEST.MF | Generated build artifact. |
| fabric/build/tmp/shadowJar/MANIFEST.MF | Generated build artifact. |
| fabric/build/tmp/remapSourcesJar/MANIFEST.MF | Generated build artifact. |
| fabric/build/tmp/remapJar/MANIFEST.MF | Generated build artifact. |
| fabric/build/tmp/jar/MANIFEST.MF | Generated build artifact. |
| fabric/build/tmp/.cache/expanded/expanded.lock | Generated build cache/lock artifact. |
| fabric/build/resources/main/some_peripherals.mixins.json | Generated build artifact. |
| fabric/build/resources/main/fabric.mod.json | Generated build artifact. |
| fabric/build/devlibs/Some-Peripherals-0.0.12-dev.jar | Generated build artifact (binary). |
| fabric/build/classes/kotlin/main/net/spaceeye/someperipherals/fabric/SomePeripheralsFabricClient.class | Generated build artifact (compiled class). |
| fabric/build/classes/kotlin/main/net/spaceeye/someperipherals/fabric/SomePeripheralsFabric.class | Generated build artifact (compiled class). |
| fabric/build/classes/kotlin/main/net/spaceeye/someperipherals/fabric/PlatformUtilsImpl.class | Generated build artifact (compiled class). |
| fabric/build/classes/kotlin/main/net/spaceeye/someperipherals/fabric/FabricConfigBuilder.class | Generated build artifact (compiled class). |
| fabric/build/classes/kotlin/main/net/spaceeye/someperipherals/fabric/FabricConfigBuilder$makeItem$1.class | Generated build artifact (compiled class). |
| fabric/build/classes/kotlin/main/net/spaceeye/someperipherals/fabric/FabricConfigBuilder$makeItem$2.class | Generated build artifact (compiled class). |
| fabric/build/classes/kotlin/main/net/spaceeye/someperipherals/fabric/FabricConfigBuilder$makeItem$3.class | Generated build artifact (compiled class). |
| fabric/build/classes/kotlin/main/net/spaceeye/someperipherals/fabric/FabricConfigBuilder$makeItem$4.class | Generated build artifact (compiled class). |
| fabric/build/classes/kotlin/main/net/spaceeye/someperipherals/fabric/FabricConfigBuilder$makeItem$5.class | Generated build artifact (compiled class). |
| fabric/build/classes/kotlin/main/net/spaceeye/someperipherals/fabric/FabricConfigBuilder$makeItem$6.class | Generated build artifact (compiled class). |
| fabric/build/classes/kotlin/main/net/spaceeye/someperipherals/fabric/FabricConfigBuilder$makeItem$7.class | Generated build artifact (compiled class). |
| fabric/build/classes/kotlin/main/net/spaceeye/someperipherals/fabric/FabricConfigBuilder$makeItem$8.class | Generated build artifact (compiled class). |
| fabric/build/classes/kotlin/main/net/spaceeye/someperipherals/fabric/FabricBlockEntityInventory.class | Generated build artifact (compiled class). |
| fabric/build/classes/kotlin/main/net/spaceeye/someperipherals/fabric/ExtendedItemStackHandler.class | Generated build artifact (compiled class). |
| fabric/build/classes/kotlin/main/META-INF/Some-Peripherals.kotlin_module | Generated build artifact. |
| fabric/build/classes/java/main/net/spaceeye/someperipherals/fabric/integrations/cc/SomePeripheralsPeripheralProviderFabric.class | Generated build artifact (compiled class). |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
common/src/main/kotlin/net/spaceeye/someperipherals/stuff/radar/scanInRadius.kt
Show resolved
Hide resolved
common/src/main/kotlin/net/spaceeye/someperipherals/config/ConfigTypes.kt
Show resolved
Hide resolved
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Background
Radar had a long-range ship detection issue where some ships were not detected, and Radar config values (
max_entity_search_radius/max_ship_search_radius) could be clamped to4.9E-324instead of preserving-1.Also, build stability issues were observed on 1.18.2 environments.
Root Cause
CDoubleusedDouble.MIN_VALUEas a lower bound, which is the smallest positive value, not a negative lower bound.Changes
level.shipObjectWorld.allShips.dx*dx + dy*dy + dz*dz <= radiusSq).ship.id.CDoubledefault range to support negative values (NEGATIVE_INFINITY..POSITIVE_INFINITY) so-1is preserved.Scope / Impact
scan,scanForShipspath).Verification
Executed and confirmed:
.gradlew.bat build→ BUILD SUCCESSFULmax_entity_search_radius = -1is preserved.max_ship_search_radius = -1is preserved.