mirror of
https://github.com/SashLilac/cambridge.git
synced 2024-11-21 23:49:03 -06:00
Compare commits
2 Commits
83e197b5d6
...
06225bd35a
Author | SHA1 | Date | |
---|---|---|---|
|
06225bd35a | ||
|
e68238cbce |
@ -13,8 +13,9 @@ function ReplayScene:new(replay, game_mode, ruleset, inputs)
|
|||||||
self.retry_ruleset = ruleset
|
self.retry_ruleset = ruleset
|
||||||
self.secret_inputs = inputs
|
self.secret_inputs = inputs
|
||||||
self.game = game_mode(self.secret_inputs)
|
self.game = game_mode(self.secret_inputs)
|
||||||
|
self.game.save_replay = false
|
||||||
self.ruleset = ruleset(self.game)
|
self.ruleset = ruleset(self.game)
|
||||||
self.game:initialize(self.ruleset, true)
|
self.game:initialize(self.ruleset)
|
||||||
self.inputs = {
|
self.inputs = {
|
||||||
left=false,
|
left=false,
|
||||||
right=false,
|
right=false,
|
||||||
|
@ -104,7 +104,7 @@ function GameMode:getSkin()
|
|||||||
return "2tie"
|
return "2tie"
|
||||||
end
|
end
|
||||||
|
|
||||||
function GameMode:initialize(ruleset, replay)
|
function GameMode:initialize(ruleset)
|
||||||
-- generate next queue
|
-- generate next queue
|
||||||
self.used_randomizer = (
|
self.used_randomizer = (
|
||||||
table.equalvalues(
|
table.equalvalues(
|
||||||
@ -114,11 +114,10 @@ function GameMode:initialize(ruleset, replay)
|
|||||||
self.randomizer or BagRandomizer(table.keys(ruleset.colourscheme))
|
self.randomizer or BagRandomizer(table.keys(ruleset.colourscheme))
|
||||||
)
|
)
|
||||||
self.ruleset = ruleset
|
self.ruleset = ruleset
|
||||||
self.save_replay = not replay
|
|
||||||
for i = 1, math.max(self.next_queue_length, 1) do
|
for i = 1, math.max(self.next_queue_length, 1) do
|
||||||
table.insert(self.next_queue, self:getNextPiece(ruleset))
|
table.insert(self.next_queue, self:getNextPiece(ruleset))
|
||||||
end
|
end
|
||||||
self.lock_on_soft_drop = ({ruleset.softdrop_lock, self.instant_soft_drop, false, true})[config.gamesettings.manlock]
|
self.lock_on_soft_drop = ({ruleset.softdrop_lock, self.instant_soft_drop, false, true })[config.gamesettings.manlock]
|
||||||
self.lock_on_hard_drop = ({ruleset.harddrop_lock, self.instant_hard_drop, true, false})[config.gamesettings.manlock]
|
self.lock_on_hard_drop = ({ruleset.harddrop_lock, self.instant_hard_drop, true, false})[config.gamesettings.manlock]
|
||||||
end
|
end
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user