Skip to content
This repository was archived by the owner on Oct 27, 2025. It is now read-only.

Commit 7fcfa6a

Browse files
committed
cleanup & format
1 parent edea3ce commit 7fcfa6a

File tree

686 files changed

+1712
-1705
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

686 files changed

+1712
-1705
lines changed

src/commonMain/kotlin/org/chorus_oss/chorus/experimental/block/state/CommonStates.kt

Lines changed: 51 additions & 51 deletions
Original file line numberDiff line numberDiff line change
@@ -21,21 +21,21 @@ object CommonStates {
2121

2222
val attachedBit: BlockState<Boolean> = BlockState.from("attached_bit")
2323

24-
val attachment: BlockState<String> = BlockState.Companion.from(
24+
val attachment: BlockState<String> = BlockState.from(
2525
"attachment", Attachment.entries
2626
)
2727

28-
val bambooLeafSize: BlockState<String> = BlockState.Companion.from(
28+
val bambooLeafSize: BlockState<String> = BlockState.from(
2929
"bamboo_leaf_size", BambooLeafSize.entries
3030
)
3131

32-
val bambooStalkThickness: BlockState<String> = BlockState.Companion.from(
32+
val bambooStalkThickness: BlockState<String> = BlockState.from(
3333
"bamboo_stalk_thickness", BambooStalkThickness.entries
3434
)
3535

3636
val bigDripleafHead: BlockState<Boolean> = BlockState.from("big_dripleaf_head")
3737

38-
val bigDripleafTilt: BlockState<String> = BlockState.Companion.from(
38+
val bigDripleafTilt: BlockState<String> = BlockState.from(
3939
"big_dripleaf_tilt", BigDripleafTilt.entries
4040
)
4141

@@ -61,21 +61,21 @@ object CommonStates {
6161

6262
val candles: BlockState<Int> = BlockState.from("candles", 3)
6363

64-
val cauldronLiquid: BlockState<String> = BlockState.Companion.from(
64+
val cauldronLiquid: BlockState<String> = BlockState.from(
6565
"cauldron_liquid", CauldronLiquid.entries
6666
)
6767

68-
val chemistryTableType: BlockState<String> = BlockState.Companion.from(
68+
val chemistryTableType: BlockState<String> = BlockState.from(
6969
"chemistry_table_type", ChemistryTableType.entries
7070
)
7171

72-
val chiselType: BlockState<String> = BlockState.Companion.from(
72+
val chiselType: BlockState<String> = BlockState.from(
7373
"chisel_type", ChiselType.entries
7474
)
7575

7676
val clusterCount: BlockState<Int> = BlockState.from("cluster_count", 3)
7777

78-
val color: BlockState<String> = BlockState.Companion.from(
78+
val color: BlockState<String> = BlockState.from(
7979
"color", Color.entries
8080
)
8181

@@ -93,17 +93,17 @@ object CommonStates {
9393

9494
val coveredBit: BlockState<Boolean> = BlockState.from("covered_bit")
9595

96-
val crackedState: BlockState<String> = BlockState.Companion.from(
96+
val crackedState: BlockState<String> = BlockState.from(
9797
"cracked_state", CrackedState.entries
9898
)
9999

100100
val crafting: BlockState<Boolean> = BlockState.from("crafting")
101101

102-
val creakingHeartState: BlockState<String> = BlockState.Companion.from(
102+
val creakingHeartState: BlockState<String> = BlockState.from(
103103
"creaking_heart_state", CreakingHeartState.entries
104104
)
105105

106-
val damage: BlockState<String> = BlockState.Companion.from(
106+
val damage: BlockState<String> = BlockState.from(
107107
"damage", Damage.entries
108108
)
109109

@@ -114,21 +114,21 @@ object CommonStates {
114114
// Horizontal-index based
115115
val direction: BlockState<Int> = BlockState.from("direction", 3)
116116

117-
val dirtType: BlockState<String> = BlockState.Companion.from(
117+
val dirtType: BlockState<String> = BlockState.from(
118118
"dirt_type", DirtType.entries
119119
)
120120

121121
val disarmedBit: BlockState<Boolean> = BlockState.from("disarmed_bit")
122122

123123
val doorHingeBit: BlockState<Boolean> = BlockState.from("door_hinge_bit")
124124

125-
val doublePlantType: BlockState<String> = BlockState.Companion.from(
125+
val doublePlantType: BlockState<String> = BlockState.from(
126126
"double_plant_type", DoublePlantType.entries
127127
)
128128

129129
val dragDown: BlockState<Boolean> = BlockState.from("drag_down")
130130

131-
val dripstoneThickness: BlockState<String> = BlockState.Companion.from(
131+
val dripstoneThickness: BlockState<String> = BlockState.from(
132132
"dripstone_thickness", DripstoneThickness.entries
133133
)
134134

@@ -138,7 +138,7 @@ object CommonStates {
138138

139139
val extinguished: BlockState<Boolean> = BlockState.from("extinguished")
140140

141-
val coralColor: BlockState<String> = BlockState.Companion.from(
141+
val coralColor: BlockState<String> = BlockState.from(
142142
"coral_color", CoralColor.entries
143143
)
144144

@@ -174,52 +174,52 @@ object CommonStates {
174174

175175
val kelpAge: BlockState<Int> = BlockState.from("kelp_age", 25)
176176

177-
val leverDirection: BlockState<String> = BlockState.Companion.from(
177+
val leverDirection: BlockState<String> = BlockState.from(
178178
"lever_direction", LeverDirection.entries
179179
)
180180

181181
val liquidDepth: BlockState<Int> = BlockState.from("liquid_depth", 15)
182182

183183
val lit: BlockState<Boolean> = BlockState.from("lit")
184184

185-
val minecraftBlockFace: BlockState<String> = BlockState.Companion.from(
185+
val minecraftBlockFace: BlockState<String> = BlockState.from(
186186
"minecraft:block_face", BlockFace.entries
187187
)
188188

189189
// CommonPropertyMap#CARDINAL_BLOCKFACE
190-
val minecraftCardinalDirection: BlockState<String> = BlockState.Companion.from(
190+
val minecraftCardinalDirection: BlockState<String> = BlockState.from(
191191
"minecraft:cardinal_direction", MinecraftCardinalDirection.entries
192192
)
193193

194-
val minecraftFacingDirection: BlockState<String> = BlockState.Companion.from(
194+
val minecraftFacingDirection: BlockState<String> = BlockState.from(
195195
"minecraft:facing_direction", BlockFace.entries
196196
)
197197

198-
val minecraftVerticalHalf: BlockState<String> = BlockState.Companion.from(
198+
val minecraftVerticalHalf: BlockState<String> = BlockState.from(
199199
"minecraft:vertical_half", MinecraftVerticalHalf.entries
200200
)
201201

202202
val moisturizedAmount: BlockState<Int> = BlockState.from("moisturized_amount", 7)
203203

204-
val monsterEggStoneType: BlockState<String> = BlockState.Companion.from(
204+
val monsterEggStoneType: BlockState<String> = BlockState.from(
205205
"monster_egg_stone_type", MonsterEggStoneType.entries
206206
)
207207

208208
val multiFaceDirectionBits: BlockState<Int> = BlockState.from("multi_face_direction_bits", 63)
209209

210-
val newLeafType: BlockState<String> = BlockState.Companion.from(
210+
val newLeafType: BlockState<String> = BlockState.from(
211211
"new_leaf_type", NewLeafType.entries
212212
)
213213

214214
val occupiedBit: BlockState<Boolean> = BlockState.from("occupied_bit")
215215

216-
val oldLeafType: BlockState<String> = BlockState.Companion.from(
216+
val oldLeafType: BlockState<String> = BlockState.from(
217217
"old_leaf_type", OldLeafType.entries
218218
)
219219

220220
val openBit: BlockState<Boolean> = BlockState.from("open_bit")
221221

222-
val orientation: BlockState<String> = BlockState.Companion.from(
222+
val orientation: BlockState<String> = BlockState.from(
223223
"orientation", Orientation.entries
224224
)
225225

@@ -229,17 +229,17 @@ object CommonStates {
229229

230230
val persistentBit: BlockState<Boolean> = BlockState.from("persistent_bit")
231231

232-
val pillarAxis: BlockState<String> = BlockState.Companion.from(
232+
val pillarAxis: BlockState<String> = BlockState.from(
233233
"pillar_axis", BlockFace.Axis.entries
234234
)
235235

236-
val portalAxis: BlockState<String> = BlockState.Companion.from(
236+
val portalAxis: BlockState<String> = BlockState.from(
237237
"portal_axis", PortalAxis.entries
238238
)
239239

240240
val poweredBit: BlockState<Boolean> = BlockState.from("powered_bit")
241241

242-
val prismarineBlockType: BlockState<String> = BlockState.Companion.from(
242+
val prismarineBlockType: BlockState<String> = BlockState.from(
243243
"prismarine_block_type", PrismarineBlockType.entries
244244
)
245245

@@ -259,69 +259,69 @@ object CommonStates {
259259

260260
val rotation: BlockState<Int> = BlockState.from("rotation", 3)
261261

262-
val sandType: BlockState<String> = BlockState.Companion.from(
262+
val sandType: BlockState<String> = BlockState.from(
263263
"sand_type", SandType.entries
264264
)
265265

266266
val sculkSensorPhase: BlockState<Int> = BlockState.from("sculk_sensor_phase", 2)
267267

268-
val seaGrassType: BlockState<String> = BlockState.Companion.from(
268+
val seaGrassType: BlockState<String> = BlockState.from(
269269
"sea_grass_type", SeaGrassType.entries
270270
)
271271

272-
val spongeType: BlockState<String> = BlockState.Companion.from(
272+
val spongeType: BlockState<String> = BlockState.from(
273273
"sponge_type", SpongeType.entries
274274
)
275275

276276
val stability: BlockState<Int> = BlockState.from("stability", 7)
277277

278278
val stabilityCheck: BlockState<Boolean> = BlockState.from("stability_check")
279279

280-
val stoneBrickType: BlockState<String> = BlockState.Companion.from(
280+
val stoneBrickType: BlockState<String> = BlockState.from(
281281
"stone_brick_type", StoneBrickType.entries
282282
)
283283

284-
val stoneSlabType: BlockState<String> = BlockState.Companion.from(
284+
val stoneSlabType: BlockState<String> = BlockState.from(
285285
"stone_slab_type", StoneSlabType.entries
286286
)
287287

288-
val stoneSlabType2: BlockState<String> = BlockState.Companion.from(
288+
val stoneSlabType2: BlockState<String> = BlockState.from(
289289
"stone_slab_type_2", StoneSlabType2.entries
290290
)
291291

292-
val stoneSlabType3: BlockState<String> = BlockState.Companion.from(
292+
val stoneSlabType3: BlockState<String> = BlockState.from(
293293
"stone_slab_type_3", StoneSlabType3.entries
294294
)
295295

296-
val stoneSlabType4: BlockState<String> = BlockState.Companion.from(
296+
val stoneSlabType4: BlockState<String> = BlockState.from(
297297
"stone_slab_type_4", StoneSlabType4.entries
298298
)
299299

300300
val strippedBit: BlockState<Boolean> = BlockState.from("stripped_bit")
301301

302-
val structureBlockType: BlockState<String> = BlockState.Companion.from(
302+
val structureBlockType: BlockState<String> = BlockState.from(
303303
"structure_block_type", StructureBlockType.entries
304304
)
305305

306-
val structureVoidType: BlockState<String> = BlockState.Companion.from(
306+
val structureVoidType: BlockState<String> = BlockState.from(
307307
"structure_void_type", StructureVoidType.entries
308308
)
309309

310310
val suspendedBit: BlockState<Boolean> = BlockState.from("suspended_bit")
311311

312-
val tallGrassType: BlockState<String> = BlockState.Companion.from(
312+
val tallGrassType: BlockState<String> = BlockState.from(
313313
"tall_grass_type", TallGrassType.entries
314314
)
315315

316316
val toggleBit: BlockState<Boolean> = BlockState.from("toggle_bit")
317317

318-
val torchFacingDirection: BlockState<String> = BlockState.Companion.from(
318+
val torchFacingDirection: BlockState<String> = BlockState.from(
319319
"torch_facing_direction", TorchFacingDirection.entries
320320
)
321321

322322
val triggeredBit: BlockState<Boolean> = BlockState.from("triggered_bit")
323323

324-
val turtleEggCount: BlockState<String> = BlockState.Companion.from(
324+
val turtleEggCount: BlockState<String> = BlockState.from(
325325
"turtle_egg_count", TurtleEggCount.entries
326326
)
327327

@@ -335,39 +335,39 @@ object CommonStates {
335335

336336
val vineDirectionBits: BlockState<Int> = BlockState.from("vine_direction_bits", 15)
337337

338-
val wallBlockType: BlockState<String> = BlockState.Companion.from(
338+
val wallBlockType: BlockState<String> = BlockState.from(
339339
"wall_block_type", WallBlockType.entries
340340
)
341341

342-
val wallConnectionTypeEast: BlockState<String> = BlockState.Companion.from(
342+
val wallConnectionTypeEast: BlockState<String> = BlockState.from(
343343
"wall_connection_type_east", WallConnectionType.entries
344344
)
345345

346-
val wallConnectionTypeNorth: BlockState<String> = BlockState.Companion.from(
346+
val wallConnectionTypeNorth: BlockState<String> = BlockState.from(
347347
"wall_connection_type_north", WallConnectionType.entries
348348
)
349349

350-
val wallConnectionTypeSouth: BlockState<String> = BlockState.Companion.from(
350+
val wallConnectionTypeSouth: BlockState<String> = BlockState.from(
351351
"wall_connection_type_south", WallConnectionType.entries
352352
)
353353

354-
val wallConnectionTypeWest: BlockState<String> = BlockState.Companion.from(
354+
val wallConnectionTypeWest: BlockState<String> = BlockState.from(
355355
"wall_connection_type_west", WallConnectionType.entries
356356
)
357357

358-
val paleMossCarpetSideEast: BlockState<String> = BlockState.Companion.from(
358+
val paleMossCarpetSideEast: BlockState<String> = BlockState.from(
359359
"pale_moss_carpet_side_east", PaleMossCarpetSide.entries
360360
)
361361

362-
val paleMossCarpetSideNorth: BlockState<String> = BlockState.Companion.from(
362+
val paleMossCarpetSideNorth: BlockState<String> = BlockState.from(
363363
"pale_moss_carpet_side_north", PaleMossCarpetSide.entries
364364
)
365365

366-
val paleMossCarpetSideSouth: BlockState<String> = BlockState.Companion.from(
366+
val paleMossCarpetSideSouth: BlockState<String> = BlockState.from(
367367
"pale_moss_carpet_side_south", PaleMossCarpetSide.entries
368368
)
369369

370-
val paleMossCarpetSideWest: BlockState<String> = BlockState.Companion.from(
370+
val paleMossCarpetSideWest: BlockState<String> = BlockState.from(
371371
"pale_moss_carpet_side_west", PaleMossCarpetSide.entries
372372
)
373373

@@ -381,13 +381,13 @@ object CommonStates {
381381

382382
val weirdoDirection: BlockState<Int> = BlockState.from("weirdo_direction", 3)
383383

384-
val woodType: BlockState<String> = BlockState.Companion.from(
384+
val woodType: BlockState<String> = BlockState.from(
385385
"wood_type", WoodType.entries
386386
)
387387

388388
val trialSpawnerState: BlockState<Int> = BlockState.from("trial_spawner_state", 5)
389389

390-
val vaultState: BlockState<String> = BlockState.Companion.from(
390+
val vaultState: BlockState<String> = BlockState.from(
391391
"vault_state", VaultState.entries
392392
)
393393

src/commonMain/kotlin/org/chorus_oss/chorus/experimental/utils/BlockStates.kt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,7 @@ object BlockStates {
3434
)
3535

3636
return Buffer().run {
37-
Tag.Companion.serialize(tag, this, TagSerialization.LE, isRoot = true)
37+
Tag.serialize(tag, this, TagSerialization.LE, isRoot = true)
3838
`FNV1A-32`(this.readByteArray())
3939
}
4040
}

src/commonMain/kotlin/org/chorus_oss/chorus/math/VectorMath.kt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@ object VectorMath {
2323
val axis =
2424
if (vector.x != 0.0) BlockFace.Axis.X else if (vector.z != 0.0) BlockFace.Axis.Z else BlockFace.Axis.Y
2525
val direction = vector.getAxis(axis)
26-
return BlockFace.Companion.fromAxis(if (direction < 0) AxisDirection.NEGATIVE else AxisDirection.POSITIVE, axis)
26+
return BlockFace.fromAxis(if (direction < 0) AxisDirection.NEGATIVE else AxisDirection.POSITIVE, axis)
2727
}
2828

2929
fun getPassByVector3(from: Vector3, to: Vector3): List<Vector3> {

src/jvmMain/kotlin/Chorus.kt

Lines changed: 0 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,6 @@
11
package org.chorus_oss.chorus
22

3-
import com.github.ajalt.clikt.core.CliktCommand
43
import com.github.ajalt.clikt.core.main
5-
import com.github.ajalt.clikt.parameters.options.flag
6-
import com.github.ajalt.clikt.parameters.options.option
74
import io.netty.util.ResourceLeakDetector
85
import io.netty.util.internal.logging.InternalLoggerFactory
96
import io.netty.util.internal.logging.Log4J2LoggerFactory
@@ -15,10 +12,6 @@ import org.chorus_oss.chorus.nbt.stream.PGZIPOutputStream
1512
import org.chorus_oss.chorus.utils.Loggable
1613
import org.chorus_oss.chorus.utils.Utils.dynamic
1714

18-
fun main(args: Array<String>) {
19-
Chorus.main(args)
20-
}
21-
2215
/**
2316
* _____ _
2417
* / ____|| |

src/jvmMain/kotlin/block/BlockAnvil.kt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@ open class BlockAnvil @JvmOverloads constructor(blockstate: BlockState = propert
3030
Damage.UNDAMAGED -> Companion.properties.defaultState
3131
Damage.SLIGHTLY_DAMAGED -> BlockChippedAnvil.properties.defaultState
3232
Damage.VERY_DAMAGED -> BlockDamagedAnvil.properties.defaultState
33-
Damage.BROKEN -> BlockAir.Companion.STATE
33+
Damage.BROKEN -> BlockAir.STATE
3434
}
3535
}
3636

src/jvmMain/kotlin/block/BlockCutCopperSlab.kt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ package org.chorus_oss.chorus.block
33
import org.chorus_oss.chorus.block.property.CommonBlockProperties
44
import org.chorus_oss.chorus.block.property.enums.OxidizationLevel
55

6-
open class BlockCutCopperSlab constructor(
6+
open class BlockCutCopperSlab(
77
blockState: BlockState = properties.defaultState,
88
doubleSlabId: String = BlockID.DOUBLE_CUT_COPPER_SLAB,
99
) : BlockSlabCopperBase(blockState, doubleSlabId) {

0 commit comments

Comments
 (0)