test
This commit is contained in:
parent
37776af5db
commit
ab03d5f10c
4045 changed files with 286212 additions and 3 deletions
28
.config/Code/User/History/a5c4c11/E5y1.cpp
Normal file
28
.config/Code/User/History/a5c4c11/E5y1.cpp
Normal file
|
@ -0,0 +1,28 @@
|
|||
#include "GameLevel.h"
|
||||
#include "util.h"
|
||||
|
||||
class Level1 : public GameLevel{
|
||||
|
||||
public:
|
||||
|
||||
Level1(Paddle paddle, Ball ball) : GameLevel(paddle, ball){
|
||||
for(int i=0;i<25;i++){
|
||||
for(int j=0;j<15;j++){
|
||||
if(i<5) bricks[i][j] = new Brick(colors[GREEN]);
|
||||
else if(i<10) bricks[i][j] = new Brick(colors[PINK]);
|
||||
else if(i<15) bricks[i][j] = new Brick(colors[BLUE]);
|
||||
else if(i<20) bricks[i][j] = new Brick(colors[RED]);
|
||||
else bricks[i][j] = new Brick(colors[YELLOW]);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Ball& getBall(){
|
||||
return ball;
|
||||
}
|
||||
Paddle& getPaddle(){
|
||||
return paddle;
|
||||
}
|
||||
|
||||
|
||||
};
|
Loading…
Add table
Add a link
Reference in a new issue