replace cos8 with cos8_t correcting an oversight
This commit is contained in:
parent
b556da8b36
commit
e95450b318
@ -10276,7 +10276,7 @@ uint16_t mode_particleBalance(void) {
|
|||||||
if (SEGMENT.check3) // random, use perlin noise
|
if (SEGMENT.check3) // random, use perlin noise
|
||||||
xgravity = ((int16_t)perlin8(SEGENV.aux0) - 128);
|
xgravity = ((int16_t)perlin8(SEGENV.aux0) - 128);
|
||||||
else // sinusoidal
|
else // sinusoidal
|
||||||
xgravity = (int16_t)cos8(SEGENV.aux0) - 128;//((int32_t)(SEGMENT.custom3 << 2) * cos8(SEGENV.aux0)
|
xgravity = (int16_t)cos8_t(SEGENV.aux0) - 128;//((int32_t)(SEGMENT.custom3 << 2) * cos8(SEGENV.aux0)
|
||||||
// scale the force
|
// scale the force
|
||||||
xgravity = (xgravity * ((SEGMENT.custom3+1) << 2)) / 128; // xgravity: -127 to +127
|
xgravity = (xgravity * ((SEGMENT.custom3+1) << 2)) / 128; // xgravity: -127 to +127
|
||||||
PartSys->applyForce(xgravity);
|
PartSys->applyForce(xgravity);
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user