mirror of
https://gitlab.com/cable-mc/cobblemon.git
synced 2026-10-27 04:26:27 -04:00
Fix issue where locator X axis was not aligned with blockbench.
This commit is contained in:
@@ -176,6 +176,7 @@
|
||||
- Fixed typo while saving/loading NPCEntity causes data loss
|
||||
- Fixed an issue where catching a Pokémon while it was leashed to a fence would not update the fence.
|
||||
- Fixed the `dimensions` spawning condition using the incorrect ResourceLocation, causing it to not function properly.
|
||||
- Fix issue where locator X axis was not aligned with blockbench.
|
||||
|
||||
### Developer
|
||||
- A finished battle now has winners and losers set inside of `PokemonBattle` instead of them always being empty.
|
||||
|
||||
+10
-5
@@ -14,11 +14,16 @@ import com.bedrockk.molang.ast.NumberExpression
|
||||
import com.bedrockk.molang.runtime.MoLangRuntime
|
||||
import com.cobblemon.mod.common.api.codec.CodecMapped
|
||||
import com.cobblemon.mod.common.api.data.ArbitrarilyMappedSerializableCompanion
|
||||
import com.cobblemon.mod.common.util.*
|
||||
import com.cobblemon.mod.common.util.asExpression
|
||||
import com.cobblemon.mod.common.util.codec.EXPRESSION_CODEC
|
||||
import com.cobblemon.mod.common.util.getString
|
||||
import com.cobblemon.mod.common.util.math.convertSphericalToCartesian
|
||||
import com.cobblemon.mod.common.util.math.getRotationMatrix
|
||||
import com.cobblemon.mod.common.util.math.times
|
||||
import com.cobblemon.mod.common.util.readString
|
||||
import com.cobblemon.mod.common.util.resolveDouble
|
||||
import com.cobblemon.mod.common.util.resolveVec3d
|
||||
import com.cobblemon.mod.common.util.writeString
|
||||
import com.mojang.serialization.Codec
|
||||
import com.mojang.serialization.DataResult
|
||||
import com.mojang.serialization.DynamicOps
|
||||
@@ -27,10 +32,10 @@ import com.mojang.serialization.codecs.RecordCodecBuilder
|
||||
import net.minecraft.network.RegistryFriendlyByteBuf
|
||||
import net.minecraft.world.entity.Entity
|
||||
import net.minecraft.world.phys.AABB
|
||||
import net.minecraft.world.phys.Vec3
|
||||
import kotlin.math.cos
|
||||
import kotlin.math.sin
|
||||
import kotlin.random.Random
|
||||
import net.minecraft.world.phys.Vec3
|
||||
|
||||
interface ParticleEmitterShape : CodecMapped {
|
||||
companion object : ArbitrarilyMappedSerializableCompanion<ParticleEmitterShape, ParticleEmitterShapeType>(
|
||||
@@ -261,9 +266,9 @@ class BoxParticleEmitterShape(
|
||||
}
|
||||
} else {
|
||||
Vec3(
|
||||
Random.nextDouble(sizes.x) - sizes.x / 2,
|
||||
Random.nextDouble(sizes.y) - sizes.y / 2,
|
||||
Random.nextDouble(sizes.z) - sizes.z / 2
|
||||
Random.nextDouble(sizes.x) - sizes.x / 2.0,
|
||||
Random.nextDouble(sizes.y) - sizes.y / 2.0,
|
||||
Random.nextDouble(sizes.z) - sizes.z / 2.0
|
||||
)
|
||||
}
|
||||
|
||||
|
||||
@@ -10,7 +10,6 @@ package com.cobblemon.mod.common.client.render
|
||||
|
||||
import com.cobblemon.mod.common.util.math.geometry.getOrigin
|
||||
import com.cobblemon.mod.common.util.math.geometry.transformPosition
|
||||
import net.fabricmc.loader.impl.lib.sat4j.core.Vec
|
||||
import org.joml.Matrix4f
|
||||
import net.minecraft.world.phys.Vec3
|
||||
|
||||
|
||||
+1
-1
@@ -75,7 +75,7 @@ class LocatorAccess(
|
||||
|
||||
if (isRoot && null!=entity) {
|
||||
matrixStack.pushPose()
|
||||
matrixStack.scale(-1F, -1F, 1F)
|
||||
matrixStack.scale(1F, -1F, 1F)
|
||||
state.getOrPut("root") { MatrixWrapper() }.updateMatrix(matrixStack.last().pose())
|
||||
matrixStack.popPose()
|
||||
|
||||
|
||||
Reference in New Issue
Block a user