class View { String font[] = new String[5]; Field field = model.field; Ball ball = model.ball; Player p1 = model.p1; Player p2 = model.p2; View() { font[0] = "xxx x xxx xxx x x xxx xxx xxx xxx xxx"; font[1] = "x x x x x x x x x x x x x x"; font[2] = "x x x xxx xxx xxx xxx xxx x xxx xxx"; font[3] = "x x x x x x x x x x x x x"; font[4] = "xxx x xxx xxx x xxx xxx x xxx xxx"; } void draw() { scale(10); noStroke(); //clear screen fill(0,150); rect(0,0,width,height); //field fill(255); rect(0,0,field.w,1); rect(0,field.h-1,field.w,1); for (int i=1; i9) return; for (int i=0; i<5; i++) { for (int j=0; j<3; j++) { if (font[i].charAt(4*value+j)=='x') { rect(x+j,y+i,1,1); } } } } }