New lock delay curve for Square

pull/4/head
Ishaan Bhardwaj 2021-02-04 10:38:00 -05:00 committed by GitHub
parent a820798e13
commit 44d0605fb7
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 2 additions and 3 deletions

View File

@ -38,8 +38,7 @@ function SquareMode:getGravity()
end
function SquareMode:getLockDelay()
if self:getGravity() <= 20 then return 30
else return 30 - math.log(self:getGravity() - 20) end
return math.ceil(30 * 0.9998 ^ self.lines)
end
function SquareMode:advanceOneFrame()
@ -97,4 +96,4 @@ function SquareMode:getBackground()
return math.floor(self.lines / 100) % 20
end
return SquareMode
return SquareMode