Rivmun / FootprintParticle

A simple Minecraft mod that adds footprint for mobs.
GNU General Public License v3.0
7 stars 0 forks source link

Horse & spider gen pos #16

Closed Rivmun closed 1 year ago

Rivmun commented 1 year ago

https://github.com/Rivmun/FootprintParticle/blob/143bf98ee967012c3cc90cd068606bca91700f06/src/main/java/rimo/footprintparticle/mixin/LivingEntityMixin.java#L63

Something was wrong and listed here.

Rivmun commented 1 year ago

About entity rotation: https://github.com/Rivmun/FootprintParticle/blob/b00460e1f048010414acda1756e5bcc25958fa5a/src/main/java/rimo/footprintparticle/mixin/LivingEntityMixin.java#L37 It's should be (((getX() || getZ()) && isOnGround()) || ...)

Rivmun commented 1 year ago

Note: When convert the entity.getRotationClient().y (express as entity's yaw) to a directional vec3d or vec3f, should be:

vec3d.x = -sin(rotationClient.y)
vec3d.z =  cos(rotationClient.y)

Remember the minus at x component.

The 2 task in this issue is a same point of the yaw conversion matter.