fix fuzzy_stripey missing segment when dy > 0
also makes it try harder to approach the target weight, by default
This commit is contained in:
parent
dca00e4fb6
commit
fa9b6939cf
@ -517,7 +517,7 @@ fuzzy = {
|
|||||||
p = 0xffff,
|
p = 0xffff,
|
||||||
n = 0,
|
n = 0,
|
||||||
interval = 3,
|
interval = 3,
|
||||||
tries = 2,
|
tries = 4,
|
||||||
}
|
}
|
||||||
mknew(fuzzy, function(x)
|
mknew(fuzzy, function(x)
|
||||||
local p = (x.p or fuzzy.p) & 0xffff
|
local p = (x.p or fuzzy.p) & 0xffff
|
||||||
@ -578,7 +578,7 @@ function fuzzy_stripey:update()
|
|||||||
fz.tries = self.tries
|
fz.tries = self.tries
|
||||||
self.y += self.dy
|
self.y += self.dy
|
||||||
if (self.y <= -self.gap) self.y += self.gap
|
if (self.y <= -self.gap) self.y += self.gap
|
||||||
if (self.y >= self.gap) self.y -= self.gap
|
if (self.y >= 0) self.y -= self.gap
|
||||||
fz:update()
|
fz:update()
|
||||||
end
|
end
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user