Skip to content

Commit 2cbf343

Browse files
committed
chore: small cleanup..
1 parent c935484 commit 2cbf343

37 files changed

+62
-32
lines changed

src/main/java/org/cobalt/mixin/client/MinecraftMixin.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
package org.cobalt.mixin.client;
22

3+
import java.util.List;
34
import kotlin.Pair;
45
import net.minecraft.client.Minecraft;
56
import org.cobalt.api.addon.Addon;
@@ -10,7 +11,6 @@
1011
import org.spongepowered.asm.mixin.injection.At;
1112
import org.spongepowered.asm.mixin.injection.Inject;
1213
import org.spongepowered.asm.mixin.injection.callback.CallbackInfo;
13-
import java.util.List;
1414

1515
@Mixin(Minecraft.class)
1616
public class MinecraftMixin {

src/main/kotlin/org/cobalt/api/event/EventBus.kt

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,22 +1,17 @@
11
package org.cobalt.api.event
22

3-
import java.io.File
4-
import java.io.IOException
53
import java.lang.invoke.LambdaMetafactory
64
import java.lang.invoke.MethodHandles
75
import java.lang.invoke.MethodType
86
import java.lang.reflect.Method
9-
import java.net.URLDecoder
107
import java.util.*
118
import java.util.concurrent.ConcurrentHashMap
129
import java.util.function.Consumer
13-
import java.util.zip.ZipFile
1410
import org.cobalt.api.event.annotation.SubscribeEvent
1511

1612
object EventBus {
1713

1814
private val listeners = ConcurrentHashMap<Class<*>, List<ListenerData>>()
19-
2015
private val registered = ConcurrentHashMap.newKeySet<Any>()
2116
private val dynamicRunnable = ConcurrentHashMap<Class<out Event>, MutableList<(Event) -> Unit>>()
2217

src/main/kotlin/org/cobalt/api/pathfinder/Node.kt

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -46,4 +46,5 @@ class Node(
4646

4747
return this.depth.compareTo(other.depth)
4848
}
49+
4950
}

src/main/kotlin/org/cobalt/api/pathfinder/PathExecutor.kt

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -174,4 +174,5 @@ object PathExecutor {
174174
)
175175
}
176176
}
177+
177178
}

src/main/kotlin/org/cobalt/api/pathfinder/pathfinder/AStarPathfinder.kt

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -174,4 +174,5 @@ class AStarPathfinder(configuration: PathfinderConfiguration) : AbstractPathfind
174174
val openSetNodes: Long2ObjectMap<Node> = Long2ObjectOpenHashMap()
175175
val closedSet: LongSet = LongOpenHashSet()
176176
}
177+
177178
}

src/main/kotlin/org/cobalt/api/pathfinder/pathfinder/AbstractPathfinder.kt

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -278,20 +278,16 @@ abstract class AbstractPathfinder(
278278
}
279279

280280
protected abstract fun insertStartNode(node: Node, fCost: Double, openSet: PrimitiveMinHeap)
281-
282281
protected abstract fun extractBestNode(openSet: PrimitiveMinHeap): Node
283-
284282
protected abstract fun initializeSearch()
285-
286283
protected abstract fun markNodeAsExpanded(node: Node)
287-
288284
protected abstract fun performAlgorithmCleanup()
289-
290285
protected abstract fun processSuccessors(
291286
requestStart: PathPosition,
292287
requestTarget: PathPosition,
293288
currentNode: Node,
294289
openSet: PrimitiveMinHeap,
295290
searchContext: SearchContext,
296291
)
292+
297293
}

src/main/kotlin/org/cobalt/api/pathfinder/pathfinder/heap/PrimitiveMinHeap.kt

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -137,4 +137,5 @@ class PrimitiveMinHeap(initialCapacity: Int) {
137137
costs[current] = costToMove
138138
nodeToIndexMap.put(nodeToMove, current)
139139
}
140+
140141
}

src/main/kotlin/org/cobalt/api/pathfinder/pathfinder/processing/EvaluationContextImpl.kt

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -48,4 +48,5 @@ class EvaluationContextImpl(
4848

4949
override val grandparentPathPosition: PathPosition?
5050
get() = parentEngineNode?.parent?.position
51+
5152
}

src/main/kotlin/org/cobalt/api/pathfinder/pathfinder/processing/SearchContextImpl.kt

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -15,4 +15,5 @@ class SearchContextImpl(
1515
) : SearchContext {
1616

1717
override val sharedData: MutableMap<String, Any> = HashMap()
18+
1819
}

src/main/kotlin/org/cobalt/api/pathfinder/pathing/INeighborStrategy.kt

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,9 +4,10 @@ import org.cobalt.api.pathfinder.wrapper.PathPosition
44
import org.cobalt.api.pathfinder.wrapper.PathVector
55

66
fun interface INeighborStrategy {
7-
fun getOffsets(): Iterable<PathVector>
87

8+
fun getOffsets(): Iterable<PathVector>
99
fun getOffsets(currentPosition: PathPosition): Iterable<PathVector> {
1010
return getOffsets()
1111
}
12+
1213
}

0 commit comments

Comments
 (0)