|
|
@@ -87,81 +87,81 @@ Board.prototype.getCup = function(code) { |
|
|
|
ball.classList.add("Shoot"); |
|
|
|
switch (code) |
|
|
|
{ |
|
|
|
case 'e': |
|
|
|
case 'E': |
|
|
|
root.style.setProperty('--top325', "-350"+ "px"); |
|
|
|
ball.style.top = "-350px"; |
|
|
|
case 'q': |
|
|
|
case 'Q': |
|
|
|
root.style.setProperty('--top325', "-515"+ "px"); |
|
|
|
ball.style.top = "-515px"; |
|
|
|
ball.style.left = "-155px"; |
|
|
|
return "cup1"; |
|
|
|
break; |
|
|
|
case 'r': |
|
|
|
case 'R': |
|
|
|
root.style.setProperty('--top325', "-350"+ "px"); |
|
|
|
ball.style.top = "-350px"; |
|
|
|
case 'w': |
|
|
|
case 'W': |
|
|
|
root.style.setProperty('--top325', "-515"+ "px"); |
|
|
|
ball.style.top = "-515px"; |
|
|
|
ball.style.left = "-50px"; |
|
|
|
return "cup2"; |
|
|
|
//removeCup("2"); |
|
|
|
//removeCup("2");j |
|
|
|
break; |
|
|
|
case 't': |
|
|
|
case 'T': |
|
|
|
root.style.setProperty('--top325', "-350"+ "px"); |
|
|
|
ball.style.top = "-350px"; |
|
|
|
ball.style.left = "55px"; |
|
|
|
case 'e': |
|
|
|
case 'E': |
|
|
|
root.style.setProperty('--top325', "-515"+ "px"); |
|
|
|
ball.style.top = "-515px"; |
|
|
|
ball.style.left = "50px"; |
|
|
|
return "cup3"; |
|
|
|
//removeCup("3"); |
|
|
|
break; |
|
|
|
case 'z': |
|
|
|
case 'Z': |
|
|
|
root.style.setProperty('--top325', "-350"+ "px"); |
|
|
|
ball.style.top = "-350px"; |
|
|
|
ball.style.left = "160px"; |
|
|
|
case 'r': |
|
|
|
case 'R': |
|
|
|
root.style.setProperty('--top325', "-515"+ "px"); |
|
|
|
ball.style.top = "-515px"; |
|
|
|
ball.style.left = "150px"; |
|
|
|
return "cup4"; |
|
|
|
//removeCup("4"); |
|
|
|
break; |
|
|
|
case 'd': |
|
|
|
case 'D': |
|
|
|
root.style.setProperty('--top325', "-290"+ "px"); |
|
|
|
ball.style.top = "-290px"; |
|
|
|
case 'a': |
|
|
|
case 'A': |
|
|
|
root.style.setProperty('--top325', "-430"+ "px"); |
|
|
|
ball.style.top = "-430px"; |
|
|
|
ball.style.left = "-100px"; |
|
|
|
return "cup5"; |
|
|
|
//removeCup("5"); |
|
|
|
break; |
|
|
|
case 'f': |
|
|
|
case 'F': |
|
|
|
root.style.setProperty('--top325', "-290"+ "px"); |
|
|
|
ball.style.top = "-290px"; |
|
|
|
case 's': |
|
|
|
case 'S': |
|
|
|
root.style.setProperty('--top325', "-430"+ "px"); |
|
|
|
ball.style.top = "-430px"; |
|
|
|
ball.style.left = "0px"; |
|
|
|
return "cup6"; |
|
|
|
//removeCup("6"); |
|
|
|
break; |
|
|
|
case 'g': |
|
|
|
case 'G': |
|
|
|
root.style.setProperty('--top325', "-290"+ "px"); |
|
|
|
ball.style.top = "-290px"; |
|
|
|
ball.style.left = "110px"; |
|
|
|
case 'd': |
|
|
|
case 'D': |
|
|
|
root.style.setProperty('--top325', "-430"+ "px"); |
|
|
|
ball.style.top = "-430px"; |
|
|
|
ball.style.left = "100px"; |
|
|
|
//removeCup("7"); |
|
|
|
return "cup7"; |
|
|
|
break; |
|
|
|
case 'c': |
|
|
|
case 'C': |
|
|
|
root.style.setProperty('--top325', "-220"+ "px"); |
|
|
|
ball.style.top = "-220px" |
|
|
|
case 'y': |
|
|
|
case 'Y': |
|
|
|
root.style.setProperty('--top325', "-340"+ "px"); |
|
|
|
ball.style.top = "-340px" |
|
|
|
ball.style.left = "-50px"; |
|
|
|
//removeCup("8"); |
|
|
|
return "cup8"; |
|
|
|
break; |
|
|
|
case 'v': |
|
|
|
case 'V': |
|
|
|
root.style.setProperty('--top325', "-220"+ "px"); |
|
|
|
ball.style.top = "-220px" |
|
|
|
ball.style.left = "55px"; |
|
|
|
case 'x': |
|
|
|
case 'X': |
|
|
|
root.style.setProperty('--top325', "-340"+ "px"); |
|
|
|
ball.style.top = "-340px" |
|
|
|
ball.style.left = "50px"; |
|
|
|
//removeCup("9"); |
|
|
|
return "cup9"; |
|
|
|
break; |
|
|
|
case 'b': |
|
|
|
case 'B': |
|
|
|
root.style.setProperty('--top325', "-160"+ "px"); |
|
|
|
ball.style.top = "-160px" |
|
|
|
case 'c': |
|
|
|
case 'C': |
|
|
|
root.style.setProperty('--top325', "-250"+ "px"); |
|
|
|
ball.style.top = "-250px" |
|
|
|
ball.style.left = "0px"; |
|
|
|
//removeCup("10"); |
|
|
|
return "cup10"; |