-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathLevelP.java
More file actions
54 lines (27 loc) · 984 Bytes
/
Copy pathLevelP.java
File metadata and controls
54 lines (27 loc) · 984 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
package com.smiths;
import java.util.ArrayList;
import org.andengine.entity.primitive.Rectangle;
import org.andengine.entity.scene.Scene;
import org.andengine.opengl.vbo.VertexBufferObjectManager;
import org.andengine.util.color.Color;
//level definition
public class LevelP
{
public LevelP(VertexBufferObjectManager vBOM, Scene scene, ArrayList<Rectangle> horizontals, ArrayList<Rectangle> verticals )
{
verticals.add(new Rectangle(-1000,-1000,1000,1500,vBOM));
verticals.add(new Rectangle(500,-1000,850,1500,vBOM));
horizontals.add(new Rectangle(-1000, 300, 20000, 512, vBOM));
horizontals.add(new Rectangle(150,150,150, 10, vBOM));
for(int i=0; i<horizontals.size(); i++)
{
scene.attachChild(horizontals.get(i));
horizontals.get(i).setColor(Color.BLACK);
}
for(int i=0; i<verticals.size(); i++)
{
scene.attachChild(verticals.get(i));
verticals.get(i).setColor(Color.BLACK);
}
}
}