mojira.dev

Lynzel

Assigned

No issues.

Reported

MC-208844 Bees don't seem to use their generic.flying_speed Cannot Reproduce

Comments

Yes, it is correctly used to define how much the entity would travel forward and vertically. So if the speed is 0, it doesn't move.

But summoning bees with different speed :

/summon bee ~ ~ ~ {Attributes:[{Name:"generic.flying_speed",Base:0.3}]}
/summon bee ~ ~ ~ {Attributes:[{Name:"generic.flying_speed",Base:4.2}]}
/summon bee ~ ~ ~ {Attributes:[{Name:"generic.flying_speed",Base:121.0}]}

Shows that they all incorrectly travel at the same speed.

 

The problem is in a check of the speed against friction :

private float getFrictionInfluencedSpeed(float ) {
 if (this.onGround) {
 return getSpeed() * 0.21600002F /  *  * ;
 }
 return this.flyingSpeed;
}

If the entity is not onGround, almost always for bees, it doesn't check the entity speed against friction, it simply return the constant value that flyingSpeed is.

This issue might be related :  MC-172801