Changed the Phantom Mania non-N requirement back to automatic GM at 999.

(Only N should have the 31-tetris rule.)
This commit is contained in:
Joe Zeng 2023-04-11 12:18:11 -04:00
parent 323c457809
commit a4b7a41a15
3 changed files with 16 additions and 8 deletions

View File

@ -1 +1 @@
version = "v0.3.1"
version = "v0.3.2"

View File

@ -28,7 +28,6 @@ function PhantomManiaGame:new()
self.combo = 1
self.tetrises = 0
self.section_tetrises = {[0] = 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}
self.section_req = true
self.randomizer = History6RollsRandomizer()
end
@ -120,11 +119,6 @@ function PhantomManiaGame:onLineClear(cleared_row_count)
self.level = 999
end
self.clear = true
for i = 0, 9 do
if self.section_tetrises[i] < (i == 9 and 1 or 2) then
self.section_req = false
end
end
else
self.level = new_level
end
@ -175,6 +169,10 @@ local function getLetterGrade(level, clear)
end
end
function PhantomManiaGame:qualifiesForGM()
return true
end
function PhantomManiaGame:drawScoringInfo()
PhantomManiaGame.super.drawScoringInfo(self)
@ -195,7 +193,7 @@ function PhantomManiaGame:drawScoringInfo()
if getLetterGrade(self.level, self.clear) ~= "" then
if self.roll_frames > 1982 then love.graphics.setColor(1, 0.5, 0, 1)
elseif self.level == 999 and self.clear then love.graphics.setColor(0, 1, 0, 1) end
if self.level == 999 and self.section_req and self.tetrises >= 31 then
if self.level == 999 and self:qualifiesForGM() then
love.graphics.printf("GM", text_x, 140, 90, "left")
else
love.graphics.printf(getLetterGrade(self.level, self.clear), text_x, 140, 90, "left")

View File

@ -13,4 +13,14 @@ function PhantomManiaNGame:new()
self.enable_hold = true
end
function PhantomManiaNGame:qualifiesForGM()
if self.tetrises < 31 then return false end
for i = 0, 9 do
if self.section_tetrises[i] < (i == 9 and 1 or 2) then
return false
end
end
return true
end
return PhantomManiaNGame