Compare commits

..

14 Commits
v0.1 ... v0.1.1

Author SHA1 Message Date
Joe Z
704e6dae55 Fixed the pacer test mode's backgrounds and strikes. 2019-05-31 23:25:27 -04:00
Joe Zeng
19d1686b9d Added an example of a "multiline if block". 2019-05-30 17:09:12 -04:00
Joe Zeng
aa01479c12 It's 2019. 2019-05-30 11:32:38 -04:00
Joe Z
5a1b137c2a Made it so that level 900 no longer displays 1000 on the bottom where it should display 999. 2019-05-29 22:27:50 -04:00
Joe Z
956e826bb2 Added the ghost piece to modes that needed them. 2019-05-29 22:10:27 -04:00
Joe Z
cebe57dd1e Removed some of the extraneous static properties.
ARR and drop speed are handled by getters now.
2019-05-29 21:59:53 -04:00
smiegrin
1db0a0ef05 Allow the window to be resized freely. (#8)
TODO: add option in config (#5) to set window size, and then save the current window size when resized so the next time you open the app, it opens at the same size you closed it with.
2019-05-29 21:55:01 -04:00
Joe Z
0e7a2bb9fe Turns out I corrected some of the delays too far the other way. 2019-05-29 21:50:14 -04:00
smiegrin
31b0f60475 Corrects survival_a1.lua crash. (#7)
Due to a stupid copy-paste error.
2019-05-29 19:47:51 -04:00
Joe Z
1d6ac62d7d Added drop bonuses and fixed some of the delays. 2019-05-29 00:52:54 -04:00
Joe Zeng
b316d9617b Updated Marathon A1's combo calculation algorithm.
Apparently the 1/6/15/28 multiplier comes from updating combo before calculating the multiplier, not something that gets independently multiplied.
2019-05-28 21:26:38 -04:00
Joe Z
99f7ff72fd Fixed the credit roll in Marathon 2020. 2019-05-26 16:34:35 -04:00
Joe Z
df489a2603 So were the rulesets. 2019-05-26 11:07:28 -04:00
Joe Zeng
4105040334 Game modes are kinda out of date.
Here's to clean them up before I make the complete list.
2019-05-23 13:21:26 -04:00
38 changed files with 159 additions and 127 deletions

View File

@@ -3,8 +3,28 @@ Coding conventions
* Use tabs to indent, spaces to align. * Use tabs to indent, spaces to align.
* Specifically, spaces should not appear at the beginning of a line, and tabs should not appear _except_ at the beginning of a line. * Specifically, spaces should not appear at the beginning of a line, and tabs should not appear _except_ at the beginning of a line.
* The sole exception is in a multiline `if` statement; the initial `if` should have four spaces before it to align it with an `elseif` on the next line. * The sole exception is in a multiline `if` statement; the initial `if` should have four spaces before it to align it with an `elseif` on the next line. For example:
* Comments with lines at the end of code must be one line long. Multi-line comments must appeare in their own block.
```lua
if self.level < 900 then return 12
elseif self.level < 1200 then return 8
else return 6 end
```
* Comments at the end of lines of code must be one line long. Multi-line comments must appear in their own block.
```lua
if self.piece:isDropBlocked(self.grid) then
-- for bottomed out pieces, decrease the drop bonus if they stall on dropping it
self.drop_bonus = math.min(self.drop_bonus - 1, 0) -- by 1 point per frame
else
if piece_dy >= 1 then -- basically
self.drop_bonus = self.drop_bonus + piece_dy * 20 -- this sort of
end -- multiline comment
self.drop_bonus = self.drop_bonus + 1 -- is completely
end -- unacceptable
```
* Use `snake_case` for variables, `camelCase` for functions. * Use `snake_case` for variables, `camelCase` for functions.
@@ -15,4 +35,4 @@ By contributing source code or other assets (e.g. music, artwork, graphics) to C
You also waive all moral rights to your contributions insofar as they are used in the Cambridge repository or in any code or works deriving therefrom. You also waive all moral rights to your contributions insofar as they are used in the Cambridge repository or in any code or works deriving therefrom.
(Regarding the above clause, I will still make my best effort to provide sufficient attribution to all contributions. At the very least you'll get documentation of your contributions under SOURCES, and probably a special place in the credit roll as well.) (Notwithstanding the above clause, I will still make my best effort to provide sufficient attribution to all contributions. At the very least you'll get documentation of your contributions under SOURCES, and probably a special place in the credit roll as well.)

View File

@@ -1,6 +1,6 @@
The code in Cambridge is licensed under the MIT license. The code in Cambridge is licensed under the MIT license.
Copyright (c) 2018 Joe Zeng Copyright (c) 2018-2019 Joe Zeng
Permission is hereby granted, free of charge, to any person obtaining a copy Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal of this software and associated documentation files (the "Software"), to deal

BIN
dist/win32/OpenAL32.dll vendored Normal file

Binary file not shown.

BIN
dist/win32/SDL2.dll vendored Normal file

Binary file not shown.

BIN
dist/win32/love.dll vendored Normal file

Binary file not shown.

BIN
dist/win32/lua51.dll vendored Normal file

Binary file not shown.

BIN
dist/win32/mpg123.dll vendored Normal file

Binary file not shown.

BIN
dist/win32/msvcp120.dll vendored Normal file

Binary file not shown.

BIN
dist/win32/msvcr120.dll vendored Normal file

Binary file not shown.

BIN
dist/windows/OpenAL32.dll vendored Normal file

Binary file not shown.

BIN
dist/windows/SDL2.dll vendored Normal file

Binary file not shown.

BIN
dist/windows/love.dll vendored Normal file

Binary file not shown.

BIN
dist/windows/lua51.dll vendored Normal file

Binary file not shown.

BIN
dist/windows/mpg123.dll vendored Normal file

Binary file not shown.

BIN
dist/windows/msvcp120.dll vendored Normal file

Binary file not shown.

BIN
dist/windows/msvcr120.dll vendored Normal file

Binary file not shown.

View File

@@ -9,35 +9,22 @@ MARATHON
Modes in which the goal is to play as well as possible over a limited game interval, to ultimately achieve the title of Grand Master. Modes in which the goal is to play as well as possible over a limited game interval, to ultimately achieve the title of Grand Master.
* **MARATHON**: Get to level 999! * **MARATHON 2020**: 2020 levels of pure pain. Can you make it all the way?
* **MARATHON 2020**: 2020 levels of pure pain.
From other games: From other games:
* **MARATHON A1**: Tetris the Grand Master 1. * **MARATHON A1**: Tetris the Grand Master 1.
* **MARATHON A2**: Tetris the Grand Master 2 (TAP Master). * **MARATHON A2**: Tetris the Grand Master 2 (TAP Master).
* **MARATHON A3**: Tetris the Grand Master 3 (no exams). * **MARATHON A3**: Tetris the Grand Master 3 (no exams).
* **MARATHON N1**: NES Tetris A-type.
SURVIVAL SURVIVAL
-------- --------
Modes that concentrate on how long you can survive an increasingly fast and difficult game. Modes that concentrate on how long you can survive an increasingly fast and difficult game.
* **SURVIVAL**: * **SURVIVAL 2020**: It only gets worse. Beware of bone blocks!
From other games: From other games:
* **SURVIVAL A1**: 20G mode from Tetris the Grand Master.
* **SURVIVAL A2**: T.A. Death. * **SURVIVAL A2**: T.A. Death.
* **SURVIVAL A3**: Ti Shirase. * **SURVIVAL A3**: Ti Shirase.
RACE
----
Modes in which the goal is to achieve a fixed goal in the shortest time.
* **RACE 40L**: Clear 40 lines as fast as possible.
* **RACE 100L**: Clear 100 lines as fast as possible.
* **RACE 5K**: Clear 5,000 lines as fast as possible. Don't worry about topping out!
* **RACE 10K**: Clear 10,000 lines as fast as possible. Don't worry about topping out!

View File

@@ -17,17 +17,9 @@ A rotation system defines the following things:
* The block offsets of each piece orientation. * The block offsets of each piece orientation.
* The wall or floor kicks that will be attempted for each type of rotation. * The wall or floor kicks that will be attempted for each type of rotation.
There are three main classes/families of rotation systems: There are four rotation systems currently supported:
* **ARIKA**, commonly known as ARS. * Cambridge
* **ARIKA-CLASSIC**, commonly known as Classic ARS. * Classic ARS
* **ARIKA-TI**, commonly known as Ti-ARS, or "ARS with floorkicks". * Ti-ARS
* **STANDARD**, commonly known as SRS. * SRS
* **STANDARD**, or normal SRS.
* **STANDARD-EXP**, known as SRS-X in its original Heboris incarnation.
* **STANDARD-WORLD**, known as World Rule in TGM3.
* **CLASSIC**, commonly known as ORS or NRS (Nintendo). Also houses some traditional rotation systems.
* **CLASSIC-1989**, the no-wallkick system used by NES Tetris.
* **CLASSIC-1984**, the Electonika-60 system, where the I piece is one space higher than in CLASSIC-1989.
* **CLASSIC-SEGA**, the original Sega rotation system that spawned Arika.
* **CLASSIC-TENGEN**, the weird one with orientation problems.

View File

@@ -11,6 +11,9 @@ function love.load()
config["side_next"] = false config["side_next"] = false
config["reverse_rotate"] = true config["reverse_rotate"] = true
config["fullscreen"] = false config["fullscreen"] = false
love.window.setMode(love.graphics.getWidth(), love.graphics.getHeight(), {resizable = true});
if not config.input then if not config.input then
config.input = {} config.input = {}
scene = InputConfigScene() scene = InputConfigScene()
@@ -61,7 +64,7 @@ end
function love.draw() function love.draw()
love.graphics.push() love.graphics.push()
if love.window.getFullscreen() then
-- get offset matrix -- get offset matrix
love.graphics.setDefaultFilter("linear", "nearest") love.graphics.setDefaultFilter("linear", "nearest")
local width = love.graphics.getWidth() local width = love.graphics.getWidth()
@@ -72,7 +75,7 @@ function love.draw()
(height - scale_factor * 480) / 2 (height - scale_factor * 480) / 2
) )
love.graphics.scale(scale_factor) love.graphics.scale(scale_factor)
end
scene:render() scene:render()
love.graphics.pop() love.graphics.pop()
end end

View File

@@ -8,10 +8,10 @@ current_ruleset = 1
game_modes = { game_modes = {
require 'tetris.modes.marathon_2020', require 'tetris.modes.marathon_2020',
require 'tetris.modes.survival_2020', require 'tetris.modes.survival_2020',
require 'tetris.modes.demon_mode',
require 'tetris.modes.strategy', require 'tetris.modes.strategy',
require 'tetris.modes.interval_training', require 'tetris.modes.interval_training',
require 'tetris.modes.pacer_test', require 'tetris.modes.pacer_test',
require 'tetris.modes.demon_mode',
require 'tetris.modes.phantom_mania', require 'tetris.modes.phantom_mania',
require 'tetris.modes.phantom_mania2', require 'tetris.modes.phantom_mania2',
require 'tetris.modes.phantom_mania_n', require 'tetris.modes.phantom_mania_n',

View File

@@ -11,8 +11,8 @@ DemonModeGame.name = "Demon Mode"
DemonModeGame.hash = "DemonMode" DemonModeGame.hash = "DemonMode"
DemonModeGame.tagline = "Can you handle the ludicrous speed past level 20?" DemonModeGame.tagline = "Can you handle the ludicrous speed past level 20?"
DemonModeGame.arr = 1
DemonModeGame.drop_speed = 1
function DemonModeGame:new() function DemonModeGame:new()
DemonModeGame.super:new() DemonModeGame.super:new()

View File

@@ -114,27 +114,34 @@ function GameMode:update(inputs, ruleset)
self.hard_drop_locked = false self.hard_drop_locked = false
end end
local piece_y = self.piece.position.y
ruleset:processPiece( ruleset:processPiece(
inputs, self.piece, self.grid, self:getGravity(), self.prev_inputs, inputs, self.piece, self.grid, self:getGravity(), self.prev_inputs,
self.move, self:getLockDelay(), self:getDropSpeed(), self.move, self:getLockDelay(), self:getDropSpeed(),
self.drop_locked, self.hard_drop_locked, self.enable_hard_drop self.drop_locked, self.hard_drop_locked, self.enable_hard_drop
) )
local piece_dy = self.piece.position.y - piece_y
if inputs["up"] == true and if inputs["up"] == true and
self.piece:isDropBlocked(self.grid) and self.piece:isDropBlocked(self.grid) and
not self.hard_drop_locked and not self.hard_drop_locked then
self.instant_hard_drop self:onHardDrop(piece_dy)
then if self.instant_hard_drop then
self.piece.locked = true self.piece.locked = true
end end
end
if inputs["down"] == true and if inputs["down"] == true then
self.piece:isDropBlocked(self.grid) and self:onSoftDrop(piece_dy)
if self.piece:isDropBlocked(self.grid) and
not self.drop_locked and not self.drop_locked and
self.instant_soft_drop self.instant_soft_drop
then then
self.piece.locked = true self.piece.locked = true
end end
end
if self.piece.locked == true then if self.piece.locked == true then
self.grid:applyPiece(self.piece) self.grid:applyPiece(self.piece)
@@ -189,6 +196,14 @@ function GameMode:onLineClear(cleared_row_count) end
function GameMode:onPieceEnter() end function GameMode:onPieceEnter() end
function GameMode:onHold() end function GameMode:onHold() end
function GameMode:onSoftDrop(dropped_row_count)
self.drop_bonus = self.drop_bonus + 1 * dropped_row_count
end
function GameMode:onHardDrop(dropped_row_count)
self.drop_bonus = self.drop_bonus + 2 * dropped_row_count
end
function GameMode:onGameOver() function GameMode:onGameOver()
switchBGM(nil) switchBGM(nil)
end end
@@ -374,7 +389,8 @@ function GameMode:drawScoringInfo()
love.graphics.print( love.graphics.print(
self.das.direction .. " " .. self.das.direction .. " " ..
self.das.frames .. " " .. self.das.frames .. " " ..
st(self.prev_inputs) st(self.prev_inputs) ..
self.drop_bonus
) )
love.graphics.setFont(font_8x11) love.graphics.setFont(font_8x11)

View File

@@ -11,8 +11,8 @@ IntervalTrainingGame.name = "Interval Training"
IntervalTrainingGame.hash = "IntervalTraining" IntervalTrainingGame.hash = "IntervalTraining"
IntervalTrainingGame.tagline = "Can you clear the time hurdles when the game goes this fast?" IntervalTrainingGame.tagline = "Can you clear the time hurdles when the game goes this fast?"
IntervalTrainingGame.arr = 1
IntervalTrainingGame.drop_speed = 1
function IntervalTrainingGame:new() function IntervalTrainingGame:new()
IntervalTrainingGame.super:new() IntervalTrainingGame.super:new()
@@ -144,7 +144,7 @@ function IntervalTrainingGame:drawScoringInfo()
end end
function IntervalTrainingGame:getSectionEndLevel() function IntervalTrainingGame:getSectionEndLevel()
if self.level > 900 then return 999 if self.level >= 900 then return 999
else return math.floor(self.level / 100 + 1) * 100 end else return math.floor(self.level / 100 + 1) * 100 end
end end

View File

@@ -11,8 +11,8 @@ LigneGame.name = "Ligne"
LigneGame.hash = "Ligne" LigneGame.hash = "Ligne"
LigneGame.tagline = "How fast can you clear 40 lines?" LigneGame.tagline = "How fast can you clear 40 lines?"
LigneGame.arr = 1
LigneGame.drop_speed = 1
function LigneGame:new() function LigneGame:new()
LigneGame.super:new() LigneGame.super:new()

View File

@@ -165,7 +165,9 @@ function Marathon2020Game:onPieceEnter()
end end
function Marathon2020Game:whilePieceActive() function Marathon2020Game:whilePieceActive()
if not self.clear then
self.grade_point_decay_counter = self.grade_point_decay_counter + self.grade + 2 self.grade_point_decay_counter = self.grade_point_decay_counter + self.grade + 2
end
if self.grade_point_decay_counter > 240 then if self.grade_point_decay_counter > 240 then
self.grade_point_decay_counter = 0 self.grade_point_decay_counter = 0
self.grade_points = math.max(0, self.grade_points - 1) self.grade_points = math.max(0, self.grade_points - 1)
@@ -375,19 +377,29 @@ function Marathon2020Game:updateScore(level, drop_bonus, cleared_lines)
end end
end end
Marathon2020Game.mRollOpacityFunction = function(age) Marathon2020Game.rollOpacityFunction = function(age)
if age > 300 then return 0 if age > 300 then return 0
elseif age < 240 then return 1 elseif age < 240 then return 1
else return (300 - age) / 60 end else return (300 - age) / 60 end
end end
Marathon2020Game.rollOpacityFunction = function(age) Marathon2020Game.mRollOpacityFunction = function(age)
if age > 4 then return 0 if age > 4 then return 0
else return 1 - age / 4 end else return 1 - age / 4 end
end end
function Marathon2020Game:qualifiesForMRoll() function Marathon2020Game:qualifiesForMRoll()
return false -- until I actually have grading working return false -- until I actually have grading working
--[[
GM-roll requirements
You qualify for the GM roll if you:
- Reach level 2020
- with a grade of 50
- in less than 13:30.00 total.
]]--
end end
function Marathon2020Game:drawGrid() function Marathon2020Game:drawGrid()

View File

@@ -11,8 +11,7 @@ MarathonA1Game.name = "Marathon A1"
MarathonA1Game.hash = "MarathonA1" MarathonA1Game.hash = "MarathonA1"
MarathonA1Game.tagline = "Can you score enough points to reach the title of Grand Master?" MarathonA1Game.tagline = "Can you score enough points to reach the title of Grand Master?"
MarathonA1Game.arr = 1
MarathonA1Game.drop_speed = 1
function MarathonA1Game:new() function MarathonA1Game:new()
MarathonA1Game.super:new() MarathonA1Game.super:new()
@@ -34,11 +33,11 @@ function MarathonA1Game:new()
end end
function MarathonA1Game:getARE() function MarathonA1Game:getARE()
return 25 return 30
end end
function MarathonA1Game:getLineARE() function MarathonA1Game:getLineARE()
return 25 return 27
end end
function MarathonA1Game:getDasLimit() function MarathonA1Game:getDasLimit()
@@ -46,7 +45,7 @@ function MarathonA1Game:getDasLimit()
end end
function MarathonA1Game:getLineClearDelay() function MarathonA1Game:getLineClearDelay()
return 40 return 44
end end
function MarathonA1Game:getLockDelay() function MarathonA1Game:getLockDelay()
@@ -142,12 +141,12 @@ end
function MarathonA1Game:updateScore(level, drop_bonus, cleared_lines) function MarathonA1Game:updateScore(level, drop_bonus, cleared_lines)
if cleared_lines > 0 then if cleared_lines > 0 then
self.combo = self.combo + (cleared_lines - 1) * 2
self.score = self.score + ( self.score = self.score + (
(math.ceil((level + cleared_lines) / 4) + drop_bonus) * (math.ceil((level + cleared_lines) / 4) + drop_bonus) *
cleared_lines * (cleared_lines * 2 - 1) * self.combo cleared_lines * self.combo
) )
self.lines = self.lines + cleared_lines self.lines = self.lines + cleared_lines
self.combo = self.combo + (cleared_lines - 1) * 2
else else
self.drop_bonus = 0 self.drop_bonus = 0
self.combo = 1 self.combo = 1
@@ -172,6 +171,9 @@ end
function MarathonA1Game:drawGrid() function MarathonA1Game:drawGrid()
self.grid:draw() self.grid:draw()
if self.piece ~= nil and self.level < 100 then
self:drawGhostPiece(ruleset)
end
end end
function MarathonA1Game:drawScoringInfo() function MarathonA1Game:drawScoringInfo()
@@ -206,7 +208,7 @@ function MarathonA1Game:drawScoringInfo()
end end
function MarathonA1Game:getSectionEndLevel() function MarathonA1Game:getSectionEndLevel()
if self.level > 900 then return 999 if self.level >= 900 then return 999
else return math.floor(self.level / 100 + 1) * 100 end else return math.floor(self.level / 100 + 1) * 100 end
end end

View File

@@ -11,8 +11,8 @@ MarathonA2Game.name = "Marathon A2"
MarathonA2Game.hash = "MarathonA2" MarathonA2Game.hash = "MarathonA2"
MarathonA2Game.tagline = "The points don't matter! Can you reach the invisible roll?" MarathonA2Game.tagline = "The points don't matter! Can you reach the invisible roll?"
MarathonA2Game.arr = 1
MarathonA2Game.drop_speed = 1
function MarathonA2Game:new() function MarathonA2Game:new()
MarathonA2Game.super:new() MarathonA2Game.super:new()
@@ -35,16 +35,16 @@ function MarathonA2Game:new()
end end
function MarathonA2Game:getARE() function MarathonA2Game:getARE()
if self.level < 700 then return 25 if self.level < 700 then return 27
elseif self.level < 800 then return 16 elseif self.level < 800 then return 18
else return 12 end else return 14 end
end end
function MarathonA2Game:getLineARE() function MarathonA2Game:getLineARE()
if self.level < 600 then return 25 if self.level < 600 then return 27
elseif self.level < 700 then return 16 elseif self.level < 700 then return 18
elseif self.level < 800 then return 12 elseif self.level < 800 then return 14
else return 6 end else return 8 end
end end
function MarathonA2Game:getDasLimit() function MarathonA2Game:getDasLimit()
@@ -352,7 +352,7 @@ function MarathonA2Game:getHighscoreData()
end end
function MarathonA2Game:getSectionEndLevel() function MarathonA2Game:getSectionEndLevel()
if self.level > 900 then return 999 if self.level >= 900 then return 999
else return math.floor(self.level / 100 + 1) * 100 end else return math.floor(self.level / 100 + 1) * 100 end
end end

View File

@@ -11,8 +11,8 @@ MarathonA3Game.name = "Marathon A3"
MarathonA3Game.hash = "MarathonA3" MarathonA3Game.hash = "MarathonA3"
MarathonA3Game.tagline = "The game gets faster way more quickly! Can you get all the Section COOLs?" MarathonA3Game.tagline = "The game gets faster way more quickly! Can you get all the Section COOLs?"
MarathonA3Game.arr = 1
MarathonA3Game.drop_speed = 1
function MarathonA3Game:new() function MarathonA3Game:new()
MarathonA3Game.super:new() MarathonA3Game.super:new()
@@ -346,6 +346,9 @@ function MarathonA3Game:drawGrid()
end end
else else
self.grid:draw() self.grid:draw()
if self.piece ~= nil and self.level < 100 then
self:drawGhostPiece(ruleset)
end
end end
end end
@@ -420,7 +423,7 @@ function MarathonA3Game:getHighscoreData()
end end
function MarathonA3Game:getSectionEndLevel() function MarathonA3Game:getSectionEndLevel()
if self.level > 900 then return 999 if self.level >= 900 then return 999
else return math.floor(self.level / 100 + 1) * 100 end else return math.floor(self.level / 100 + 1) * 100 end
end end

View File

@@ -11,8 +11,8 @@ MarathonL1Game.name = "Line Attack"
MarathonL1Game.hash = "MarathonL1" MarathonL1Game.hash = "MarathonL1"
MarathonL1Game.tagline = "Can you clear the time hurdles when the game goes this fast?" MarathonL1Game.tagline = "Can you clear the time hurdles when the game goes this fast?"
MarathonL1Game.arr = 1
MarathonL1Game.drop_speed = 1
function MarathonL1Game:new() function MarathonL1Game:new()
MarathonL1Game.super:new() MarathonL1Game.super:new()

View File

@@ -11,8 +11,8 @@ PacerTest.name = "TetrisGram™ Pacer Test"
PacerTest.hash = "PacerTest" PacerTest.hash = "PacerTest"
PacerTest.tagline = "" PacerTest.tagline = ""
PacerTest.arr = 1
PacerTest.drop_speed = 1
local function getLevelFrames(level) local function getLevelFrames(level)
if level == 1 then return 72 * 60 / 8.0 if level == 1 then return 72 * 60 / 8.0
@@ -113,7 +113,7 @@ function PacerTest:checkSectionStatus()
self.section_clear = false self.section_clear = false
else else
self.strikes = self.strikes + 1 self.strikes = self.strikes + 1
if self.strikes >= 200 then if self.strikes >= 2 then
self.game_over = true self.game_over = true
fadeoutBGM(2.5) fadeoutBGM(2.5)
end end
@@ -164,7 +164,7 @@ function PacerTest:drawScoringInfo()
end end
function PacerTest:getBackground() function PacerTest:getBackground()
return self.level - 1 return math.min(self.level - 1, 20)
end end
return PacerTest return PacerTest

View File

@@ -11,8 +11,8 @@ PhantomManiaGame.name = "Phantom Mania"
PhantomManiaGame.hash = "PhantomMania" PhantomManiaGame.hash = "PhantomMania"
PhantomManiaGame.tagline = "The blocks disappear as soon as they're locked! Can you remember where everything is?" PhantomManiaGame.tagline = "The blocks disappear as soon as they're locked! Can you remember where everything is?"
PhantomManiaGame.arr = 1
PhantomManiaGame.drop_speed = 1
function PhantomManiaGame:new() function PhantomManiaGame:new()
PhantomManiaGame.super:new() PhantomManiaGame.super:new()
@@ -181,7 +181,7 @@ function PhantomManiaGame:drawScoringInfo()
end end
function PhantomManiaGame:getSectionEndLevel() function PhantomManiaGame:getSectionEndLevel()
if self.level > 900 then return 999 if self.level >= 900 then return 999
else return math.floor(self.level / 100 + 1) * 100 end else return math.floor(self.level / 100 + 1) * 100 end
end end

View File

@@ -11,8 +11,8 @@ PhantomMania2Game.name = "Phantom Mania 2"
PhantomMania2Game.hash = "PhantomMania2" PhantomMania2Game.hash = "PhantomMania2"
PhantomMania2Game.tagline = "The blocks disappear even faster now! Can you make it to level 1300?" PhantomMania2Game.tagline = "The blocks disappear even faster now! Can you make it to level 1300?"
PhantomMania2Game.arr = 1
PhantomMania2Game.drop_speed = 1
function PhantomMania2Game:new() function PhantomMania2Game:new()
PhantomMania2Game.super:new() PhantomMania2Game.super:new()

View File

@@ -11,8 +11,8 @@ PhantomManiaGame.name = "Phantom Mania N"
PhantomManiaGame.hash = "PhantomManiaN" PhantomManiaGame.hash = "PhantomManiaN"
PhantomManiaGame.tagline = "The old mode from Nullpomino." PhantomManiaGame.tagline = "The old mode from Nullpomino."
PhantomManiaGame.arr = 1
PhantomManiaGame.drop_speed = 1
function PhantomManiaGame:new() function PhantomManiaGame:new()
PhantomManiaGame.super:new() PhantomManiaGame.super:new()
@@ -182,7 +182,7 @@ function PhantomManiaGame:drawScoringInfo()
end end
function PhantomManiaGame:getSectionEndLevel() function PhantomManiaGame:getSectionEndLevel()
if self.level > 900 then return 999 if self.level >= 900 then return 999
else return math.floor(self.level / 100 + 1) * 100 end else return math.floor(self.level / 100 + 1) * 100 end
end end

View File

@@ -11,8 +11,8 @@ StrategyGame.name = "Strategy"
StrategyGame.hash = "Strategy" StrategyGame.hash = "Strategy"
StrategyGame.tagline = "You have lots of time to think! Can you use it to place a piece fast?" StrategyGame.tagline = "You have lots of time to think! Can you use it to place a piece fast?"
StrategyGame.arr = 1
StrategyGame.drop_speed = 1
function StrategyGame:new() function StrategyGame:new()
StrategyGame.super:new() StrategyGame.super:new()

View File

@@ -11,8 +11,8 @@ Survival2020Game.name = "Survival 2020"
Survival2020Game.hash = "Survival2020" Survival2020Game.hash = "Survival2020"
Survival2020Game.tagline = "A new time limit on the blocks! Can you handle being forced to perform under the total delay?" Survival2020Game.tagline = "A new time limit on the blocks! Can you handle being forced to perform under the total delay?"
Survival2020Game.arr = 1
Survival2020Game.drop_speed = 1
function Survival2020Game:new() function Survival2020Game:new()
Survival2020Game.super:new() Survival2020Game.super:new()
@@ -36,8 +36,8 @@ function Survival2020Game:getARE()
elseif self.level < 300 then return 10 elseif self.level < 300 then return 10
elseif self.level < 500 then return 6 elseif self.level < 500 then return 6
elseif self.level < 1000 then return 4 elseif self.level < 1000 then return 4
elseif self.level < 1500 then return 3 elseif self.level < 1500 then return 5
else return 2 end else return 6 end
end end
function Survival2020Game:getLineARE() function Survival2020Game:getLineARE()
@@ -71,12 +71,12 @@ end
function Survival2020Game:getTotalDelay() function Survival2020Game:getTotalDelay()
if self.level < 500 then return 60 if self.level < 500 then return 60
elseif self.level < 600 then return 45 -- lock delay: 15 elseif self.level < 600 then return 45 -- lock delay: 13
elseif self.level < 700 then return 36 elseif self.level < 700 then return 36
elseif self.level < 800 then return 27 elseif self.level < 800 then return 27
elseif self.level < 900 then return 21 elseif self.level < 900 then return 21
elseif self.level < 1000 then return 15 elseif self.level < 1000 then return 15
elseif self.level < 1100 then return 36 -- lock delay: 11 elseif self.level < 1100 then return 36 -- lock delay: 10
elseif self.level < 1200 then return 27 elseif self.level < 1200 then return 27
elseif self.level < 1300 then return 21 elseif self.level < 1300 then return 21
elseif self.level < 1400 then return 15 elseif self.level < 1400 then return 15

View File

@@ -11,8 +11,8 @@ SurvivalA1Game.name = "Survival A1"
SurvivalA1Game.hash = "SurvivalA1" SurvivalA1Game.hash = "SurvivalA1"
SurvivalA1Game.tagline = "The game starts fast and only gets faster!" SurvivalA1Game.tagline = "The game starts fast and only gets faster!"
SurvivalA1Game.arr = 1
SurvivalA1Game.drop_speed = 1
function SurvivalA1Game:new() function SurvivalA1Game:new()
SurvivalA1Game.super:new() SurvivalA1Game.super:new()
@@ -34,11 +34,11 @@ function SurvivalA1Game:new()
end end
function SurvivalA1Game:getARE() function SurvivalA1Game:getARE()
return 25 return 30
end end
function SurvivalA1Game:getLineARE() function SurvivalA1Game:getLineARE()
return 25 return 27
end end
function SurvivalA1Game:getDasLimit() function SurvivalA1Game:getDasLimit()
@@ -46,7 +46,7 @@ function SurvivalA1Game:getDasLimit()
end end
function SurvivalA1Game:getLineClearDelay() function SurvivalA1Game:getLineClearDelay()
return 40 return 44
end end
function SurvivalA1Game:getLockDelay() function SurvivalA1Game:getLockDelay()
@@ -141,9 +141,6 @@ end
function SurvivalA1Game:drawGrid() function SurvivalA1Game:drawGrid()
self.grid:draw() self.grid:draw()
if self.piece ~= nil and self.level < 100 then
self:drawGhostPiece(ruleset)
end
end end
function SurvivalA1Game:drawScoringInfo() function SurvivalA1Game:drawScoringInfo()
@@ -178,7 +175,7 @@ function SurvivalA1Game:drawScoringInfo()
end end
function SurvivalA1Game:getSectionEndLevel() function SurvivalA1Game:getSectionEndLevel()
if self.level > 900 then return 999 if self.level >= 900 then return 999
else return math.floor(self.level / 100 + 1) * 100 end else return math.floor(self.level / 100 + 1) * 100 end
end end

View File

@@ -11,8 +11,8 @@ SurvivalA2Game.name = "Survival A2"
SurvivalA2Game.hash = "SurvivalA2" SurvivalA2Game.hash = "SurvivalA2"
SurvivalA2Game.tagline = "The game starts fast and only gets faster!" SurvivalA2Game.tagline = "The game starts fast and only gets faster!"
SurvivalA2Game.arr = 1
SurvivalA2Game.drop_speed = 1
function SurvivalA2Game:new() function SurvivalA2Game:new()
SurvivalA2Game.super:new() SurvivalA2Game.super:new()
@@ -46,7 +46,7 @@ function SurvivalA2Game:getDasLimit()
end end
function SurvivalA2Game:getLineClearDelay() function SurvivalA2Game:getLineClearDelay()
return self:getLineARE() return self:getLineARE() - 2
end end
function SurvivalA2Game:getLockDelay() function SurvivalA2Game:getLockDelay()
@@ -148,7 +148,7 @@ end
function SurvivalA2Game:getSectionEndLevel() function SurvivalA2Game:getSectionEndLevel()
if self.clear then return self.level if self.clear then return self.level
elseif self.level > 900 then return 999 elseif self.level >= 900 then return 999
else return math.floor(self.level / 100 + 1) * 100 end else return math.floor(self.level / 100 + 1) * 100 end
end end

View File

@@ -11,8 +11,8 @@ SurvivalA3Game.name = "Survival A3"
SurvivalA3Game.hash = "SurvivalA3" SurvivalA3Game.hash = "SurvivalA3"
SurvivalA3Game.tagline = "The blocks turn black and white! Can you make it to level 1300?" SurvivalA3Game.tagline = "The blocks turn black and white! Can you make it to level 1300?"
SurvivalA3Game.arr = 1
SurvivalA3Game.drop_speed = 1
function SurvivalA3Game:new() function SurvivalA3Game:new()
SurvivalA3Game.super:new() SurvivalA3Game.super:new()