summaryrefslogtreecommitdiffstats
path: root/Matrix_5x6/Charlie
diff options
context:
space:
mode:
Diffstat (limited to 'Matrix_5x6/Charlie')
-rw-r--r--Matrix_5x6/Charlie/Charlie.pde25
1 files changed, 13 insertions, 12 deletions
diff --git a/Matrix_5x6/Charlie/Charlie.pde b/Matrix_5x6/Charlie/Charlie.pde
index ad2b5d3..d8884d0 100644
--- a/Matrix_5x6/Charlie/Charlie.pde
+++ b/Matrix_5x6/Charlie/Charlie.pde
@@ -210,6 +210,13 @@ void lauftext(char *text) {
}
+void bmauer( int x, int y){
+ scr[x][y] = 20;
+ drawscr(5);
+ fadescr_down();
+}
+
+
void mauer(int dir) {
/*
0=up 1=down 2=right 3=left
@@ -220,31 +227,25 @@ void mauer(int dir) {
case 0:
for (int i=0;i<y;i++)
for (int j=0;j<x;j++) {
- scr[j][i] = 30;
- drawscr(2);
+ bmauer(j,i);
}
break;
case 1:
for (int i=y-1;i>=0;i--)
for (int j=0;j<x;j++) {
- scr[j][i] = 30;
- drawscr(2);
+ bmauer(j,i);
}
break;
case 2:
for (int i=0;i<x;i++)
for (int j=0;j<y;j++) {
- scr[i][j] = 30;
- drawscr(2);
+ bmauer(i,j);
}
break;
case 3:
for (int i=x-1;i>=0;i--)
for (int j=0;j<y;j++) {
- scr[i][j] = 20;
- drawscr(5);
- fadescr_down();
-
+ bmauer(i,j);
}
break;
@@ -266,7 +267,7 @@ void loop() {
// schnecke(random(4));
// clrscr();
// mauer(0);
-clrscr();
-mauer(3);
+// clrscr();
+mauer(random(4));
}