Tom's Simple Storage Mod (Fabric)

Tom's Simple Storage Mod (Fabric)

16M Downloads

Wireless Terminal(s) Range is Double the Config Number

Quatroctus opened this issue ยท 0 comments

commented

As the title says, both of the Wireless Terminals have double the advertised range, this is caused by the following line in the StorageTerminalBlockEntity.java file.

return player.level() == level && !(player.distanceToSqr(this.worldPosition.getX() + 0.5D, this.worldPosition.getY() + 0.5D, this.worldPosition.getZ() + 0.5D) > d*2*d*2);

Multiplying d*2*d*2 this is the same as (2*d)^2 the Player::distanceToSqr function returns the distance squared. To resolve remove the multiplications of 2. Or update the text/config setting.