@@ -57,6 +57,29 @@ class refPWindow extends PApplet {
5757 String [] stringsToSave= {strToSave};
5858 saveStrings (filename, stringsToSave);
5959 }
60+ if (blueSide== Left ) {
61+ if (keyPressed && key == ' 5' ) {
62+ blueRP++ ;
63+ }
64+ if (keyPressed && key == ' 6' ) {
65+ blueRP++ ;
66+ redRP++ ;
67+ }
68+ if (keyPressed && key == ' 7' ) {
69+ redRP++ ;
70+ }
71+ } else {
72+ if (keyPressed && key == ' 7' ) {
73+ blueRP++ ;
74+ }
75+ if (keyPressed && key == ' 6' ) {
76+ blueRP++ ;
77+ redRP++ ;
78+ }
79+ if (keyPressed && key == ' 5' ) {
80+ redRP++ ;
81+ }
82+ }
6083 }
6184 if (state> 2 ) {
6285 state= - 1 ;
@@ -73,7 +96,7 @@ class refPWindow extends PApplet {
7396 text (" (b) " + ms[state+ 1 ], width * . 6 , height * . 8 , width * . 1 , height * . 2 );
7497 popStyle ();
7598
76- if (state== 0 || state== 1 ) {
99+ if (state== 0 || state== 1 ) {// match or review
77100 rectMode (CENTER );
78101 textSize (20 );
79102 if (blueSide== Right ) {
@@ -101,6 +124,9 @@ class refPWindow extends PApplet {
101124 text (" (d) Tech Foul" , width * . 3 , height * . 5 , width * . 09 , height * . 2 );
102125 text (" (g) Climb" , width * . 4 , height * . 3 , width * . 09 , height * . 15 );
103126 rectMode (CORNER );
127+ fill (0 );
128+ text (" ANTI Tech=e Foul=r" , width * . 3 , height * . 16 );
129+ text (" ANTI Foul=u Tech=i" , width * . 6 , height * . 16 );
104130 }
105131 if (plateOverride) {
106132 rectMode (CENTER );
@@ -337,7 +363,36 @@ class refPWindow extends PApplet {
337363 blueTechFoulMillis= millis ();
338364 }
339365 }
340-
366+ // /////////////////////////////////////////////////////////
367+ if (key == ' u' ) {
368+ if (blueSide== Left ) {
369+ redPenaltyScore+= foulValue;
370+ } else {
371+ bluePenaltyScore+= foulValue;
372+ }
373+ }
374+ if (key == ' i' ) {
375+ if (blueSide== Left ) {
376+ redPenaltyScore+= techFoulValue;
377+ } else {
378+ bluePenaltyScore+= techFoulValue;
379+ }
380+ }
381+ if (key == ' r' ) {
382+ if (blueSide== Right ) {
383+ redPenaltyScore+= foulValue;
384+ } else {
385+ bluePenaltyScore+= foulValue;
386+ }
387+ }
388+ if (key == ' e' ) {
389+ if (blueSide== Right ) {
390+ redPenaltyScore+= techFoulValue;
391+ } else {
392+ bluePenaltyScore+= techFoulValue;
393+ }
394+ }
395+ // ///////////////////////////////////////////
341396 if (key == ' g' ) {
342397 if (blueSide== Right ) {
343398 redClimbs++ ;
0 commit comments