made rng positions more random (#33)

coins will still consistently spawn in the same formation
This commit is contained in:
Isaac0-dev 2024-05-09 23:24:03 +10:00 committed by GitHub
parent 7b4a223b67
commit 59dfcb6483
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -26,7 +26,7 @@ void rng_position_init(f32 x, f32 y, f32 z) {
for (u8 i = 0; i < RNG_POSITION_MAX; i++) {
if (sRngPosition[i].life != 0) { continue; }
sRngPosition[i].life = RNG_POSITION_LIFE;
sRngPosition[i].seed = (u16)((position[0] / (3 * RNG_POSITION_MATCH_DIST)) + (position[1] / (3 * RNG_POSITION_MATCH_DIST)));
sRngPosition[i].seed = (u16)((position[0] / 3) + (position[1] / 3));
vec3f_copy(sRngPosition[i].position, position);
gOverrideRngPosition = &sRngPosition[i];
return;