mirror of
https://github.com/SashLilac/cambridge.git
synced 2024-11-22 13:59:03 -06:00
made our debug randomizer not bad
This commit is contained in:
parent
436e4ac861
commit
abc210c69c
@ -2,17 +2,8 @@ local Randomizer = require 'tetris.randomizers.randomizer'
|
|||||||
|
|
||||||
local AlwaysRandomizer = Randomizer:extend()
|
local AlwaysRandomizer = Randomizer:extend()
|
||||||
|
|
||||||
function AlwaysRandomizer:new(piece)
|
|
||||||
self.piece = piece
|
|
||||||
self:initialize()
|
|
||||||
self.next_queue = {}
|
|
||||||
for i = 1, 30 do
|
|
||||||
table.insert(self.next_queue, self:generatePiece())
|
|
||||||
end
|
|
||||||
end
|
|
||||||
|
|
||||||
function AlwaysRandomizer:generatePiece()
|
function AlwaysRandomizer:generatePiece()
|
||||||
return self.piece
|
return "I"
|
||||||
end
|
end
|
||||||
|
|
||||||
return AlwaysRandomizer
|
return AlwaysRandomizer
|
||||||
|
Loading…
Reference in New Issue
Block a user