修复随机点算法bug

This commit is contained in:
Atsuishio 2025-07-12 15:19:23 +08:00 committed by Light_Quanta
parent 73333a079f
commit 34c63b8c38
No known key found for this signature in database
GPG key ID: 11A39A1B8C890959

View file

@ -57,6 +57,6 @@ public class VectorTool {
}
public static Vec3 randomPos(Vec3 originPos, int radius) {
return originPos.add(new Vec3(Math.random() * radius, 0, 0).yRot((float) (360 * Math.random())));
return originPos.add(new Vec3(Math.random() * radius, 0, 0).yRot((float) (360 * Math.random()) * Mth.DEG_TO_RAD));
}
}