def createstartstate(): table = Block(Block.TABLE, "Table") # make height 2 tower topped by triangle t1 = Block(Block.SQUARE, 1) t2 = Block(Block.SQUARE, 2) t3 = Block(Block.TRIANGLE, 3) # place single square on table t4 = Block(Block.SQUARE, 4) t1.place(table) t2.place(t1) t3.place(t2) t4.place(table) return [table, t1, t2, t3, t4]
def test_001(): table = Block(Block.TABLE, 1) # make height 3 tower topped by triangle t1 = Block(Block.SQUARE, 2) t2 = Block(Block.SQUARE, 3) t3 = Block(Block.SQUARE, 4) t4 = Block(Block.TRIANGLE, 5) t1.place(table) t2.place(t1) t3.place(t2) t4.place(t3) # make problem file gg = GoalGen20130330() gg.makeshop2pfile([table, t1, t2, t3, t4], "problemfile_001")
def test_002(): table = Block(Block.TABLE, 1) # make height 3 tower, not topped by triangle t1 = Block(Block.SQUARE, 2) t2 = Block(Block.SQUARE, 3) t3 = Block(Block.SQUARE, 4) t4 = Block(5, Block.TRIANGLE) t1.place(table) t2.place(t1) t3.place(t2) t4.place(table) t1.isonfire = True t3.isonfire = True # make problem file gg = GoalGen20130330() gg.makeshop2pfile([table, t1, t2, t3, t4], "problemfile_002")