package Mark3;
import java.awt.BorderLayout;
import java.awt.Graphics;
import java.awt.GridLayout;
import java.awt.Image;
import java.awt.event.ActionEvent;
import java.awt.event.ActionListener;
import java.awt.event.KeyAdapter;
import java.awt.event.KeyEvent;
import java.util.Scanner;
import javax.swing.ButtonGroup;
import javax.swing.ImageIcon;
import javax.swing.JButton;
import javax.swing.JFrame;
import javax.swing.JPanel;
import javax.swing.JRadioButton;
import javax.swing.Timer;
public class GameTester extends JFrame{
//tester variables
private KeyboardPanel keyboardPanel;
private static Player player;
private static PWeapon[] pWeapon;
private static Enemy[] enemy;
private static EWeapon[] eWeapon;
private static Environment[] environment;
private static Image bg0;
private static Image bg1;
private static int[] level;
private static int[] levelDim;
private static JFrame frame;
private static String theme;
private static float[] playerPoint;
//temp variables
private static int[] tempIntA0;
private static int[] tempIntA1;
private static int tempInt0;
private static int tempInt1;
private static float[] tempFloA0;
private static float[] tempFloA1;
private static float tempFlo0;
private static float tempFlo1;
//extras
public KeyboardPanel getKeyboardPanel() {
return keyboardPanel;
}
public void setKeyboardPanel(KeyboardPanel keyboardPanel) {
this.keyboardPanel = keyboardPanel;
}
public static Player getPlayer() {
return player;
}
public static void setPlayer(Player player) {
GameTester.player = player;
}
public static PWeapon[] getpWeapon() {
return pWeapon;
}
public static void setpWeapon(PWeapon[] pWeapon) {
GameTester.pWeapon = pWeapon;
}
public static Enemy[] getEnemy() {
return enemy;
}
public static void setEnemy(Enemy[] enemy) {
GameTester.enemy = enemy;
}
public static EWeapon[] geteWeapon() {
return eWeapon;
}
public static void seteWeapon(EWeapon[] eWeapon) {
GameTester.eWeapon = eWeapon;
}
public static Environment[] getEnvironment() {
return environment;
}
public static void setEnvironment(Environment[] environment) {
GameTester.environment = environment;
}
public static Image getBg0() {
return bg0;
}
public static void setBg0(Image bg0) {
GameTester.bg0 = bg0;
}
public static Image getBg1() {
return bg1;
}
public static void setBg1(Image bg1) {
GameTester.bg1 = bg1;
}
public static int[] getLevel() {
return level;
}
public static void setLevel(int[] level) {
GameTester.level = level;
}
public static int[] getLevelDim() {
return levelDim;
}
public static void setLevelDim(int[] levelDim) {
GameTester.levelDim = levelDim;
}
public static int[] getTempIntA0() {
return tempIntA0;
}
public static void setTempIntA0(int[] tempIntA0) {
GameTester.tempIntA0 = tempIntA0;
}
public static int[] getTempIntA1() {
return tempIntA1;
}
public static void setTempIntA1(int[] tempIntA1) {
GameTester.tempIntA1 = tempIntA1;
}
public static int getTempInt0() {
return tempInt0;
}
public static void setTempInt0(int tempInt0) {
GameTester.tempInt0 = tempInt0;
}
public static int getTempInt1() {
return tempInt1;
}
public static void setTempInt1(int tempInt1) {
GameTester.tempInt1 = tempInt1;
}
public static float[] getTempFloA0() {
return tempFloA0;
}
public static void setTempFloA0(float[] tempFloA0) {
GameTester.tempFloA0 = tempFloA0;
}
public static float[] getTempFloA1() {
return tempFloA1;
}
public static void setTempFloA1(float[] tempFloA1) {
GameTester.tempFloA1 = tempFloA1;
}
public static float getTempFlo0() {
return tempFlo0;
}
public static void setTempFlo0(float tempFlo0) {
GameTester.tempFlo0 = tempFlo0;
}
public static float getTempFlo1() {
return tempFlo1;
}
public static void setTempFlo1(float tempFlo1) {
GameTester.tempFlo1 = tempFlo1;
}
public static void main(String[] args){
Scanner input = new Scanner(System.in);
System.out.println("What theme?"); //menu for theme
System.out.println("1) Green");
System.out.println("2) Blue");
System.out.println("3) Brown");
int TSelect = input.nextInt(); //input from menu
System.out.println("What is your name?");
String name = input.toString();
player = new Player(name);
pWeapon = new PWeapon[0];
eWeapon = new EWeapon[0];
enemy = new Enemy[0];
//setup frame
frame = new GameTester();
frame.setTitle("Tester");
frame.setSize(600, 500);
frame.setLocationRelativeTo(null);
frame.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
frame.setVisible(true);
//following code is specific to building the level
switch (TSelect) { //switch to select theme
case 1: theme = "Green";
break;
case 2: theme = "Blue";
break;
case 3: theme = "Brown";
}
//set a switch to choose different levels for future code
int[][] layout = getMap0(); //array for level layout
levelDim = new int[] {layout.length * 50, layout[1].length * 50 }; //generate dimension of level
//setup starting point for Map0
level = new int[] {0, -150};
tempInt0 = 0; //reset temp variables
for (int i = 0; i < layout.length; i++){ //build environment array length
for (int j = 0; j < layout[1].length; j++){
if (layout[i][j] != 0){ //if (0 < layout[i][j] < 20); if 20 types of environment objects
tempInt0++;
}
}
}
Environment[] tempEnvironment = new Environment[tempInt0]; //temp environment array
tempInt1 = 0; //reset temp variables
for (int i = 0; i < layout.length; i++){ //build 1st dimension
for (int j = 0; j < layout[1].length; j++){ //build 2nd dimension
if (layout[i][j] == 1){
float point[] = {(float) (i * 50.0), (float) ((j * 50.0) + level[1])};
tempEnvironment[tempInt1] = new Environment("basicBlock", point); //basicBlock constructors
tempInt1++;
}
if (layout[i][j] == 2){
float point[] = {(float) (i * 50.0), (float) (j * 50.0)};
tempEnvironment[tempInt1] = new Environment("metalBlock", point); //metalBlock constructors
tempInt1++;
}
//add in constructors for other environmental variables
//add in constructors for enemies
}
}
environment = tempEnvironment;
//enemy = tempEnemy
}
public GameTester(){
//game tester constructor, sets up layout manager for frame
String vp = "null";
setLayout(new BorderLayout());
JPanel p1 = new AnimatedPanel(vp);
p1.setSize(600, 500);
JPanel p2 = new KeyboardPanel();
p2.setSize(0, 0);
add(p1, BorderLayout.CENTER);
add(p2, BorderLayout.SOUTH);
p2.setFocusable(true);
}
static class AnimatedPanel extends JPanel {
//player images
ImageIcon playerRight = new ImageIcon("/Users/zerosdamnation/Documents/Projects/Mark3/NinjaRight.gif");
Image playerRight2 = playerRight.getImage();
ImageIcon playerLeft = new ImageIcon("/Users/zerosdamnation/Documents/Projects/Mark3/NinjaLeft.gif");
Image playerLeft2 = playerLeft.getImage();
ImageIcon playerThrowLeft = new ImageIcon("/Users/zerosdamnation/Documents/Projects/Mark3/ninjaThrowLeft.gif");
Image playerThrowLeft2 = playerThrowLeft.getImage();
ImageIcon playerThrowRight = new ImageIcon("/Users/zerosdamnation/Documents/Projects/Mark3/ninjaThrowRight.gif");
Image playerThrowRight2 = playerThrowRight.getImage();
ImageIcon shuriken0A = new ImageIcon("/Users/zerosdamnation/Documents/Projects/Mark3/shuriken0.gif");
Image shuriken0 = shuriken0A.getImage();
ImageIcon shuriken1A = new ImageIcon("/Users/zerosdamnation/Documents/Projects/Mark3/shuriken1.gif");
Image shuriken1 = shuriken1A.getImage();
ImageIcon blueBlock = new ImageIcon("/Users/zerosdamnation/Documents/Projects/Mark3/blue.gif");
Image blueBlock2 = blueBlock.getImage();
ImageIcon brownBlock = new ImageIcon("/Users/zerosdamnation/Documents/Projects/Mark3/brown.gif");
Image brownBlock2 = brownBlock.getImage();
ImageIcon greenBlock = new ImageIcon("/Users/zerosdamnation/Documents/Projects/Mark3/green.gif");
Image greenBlock2 = greenBlock.getImage();
ImageIcon metalBlock = new ImageIcon("/Users/zerosdamnation/Documents/Projects/Mark3/metal.gif");
Image metalBlock2 = metalBlock.getImage();
ImageIcon background = new ImageIcon("/Users/zerosdamnation/Documents/Projects/Mark3/background.gif");
Image background2 = background.getImage();
public AnimatedPanel(String message){
Timer timer = new Timer(62, new TimerListener());
timer.start();
}
protected void paintComponent(Graphics g){
super.paintComponent(g);
//g.draw image(which image, # of pixels from left border, # of pixels from top border, width of image, height of image, this??)
//draw in order of display, with background first, then level, then player
g.drawImage(background2, level[0], level[1], levelDim[0] / 3, levelDim[1] * 3, this); //draw background image
for (int i = 0; i < environment.length; i++){
float[] temp = environment[i].getPoint(); //check location
if (temp[0] > 0){ //check to see if on screen
if (temp[0] < frame.getWidth()){
if (temp[1] > 0){
if (temp[1] < frame.getHeight()){
if (environment[i].metal = false){
//add in false check for platinum
if (theme == "Green"){
g.drawImage(greenBlock2, (int) temp[0], (int) temp[1], 50, 50, this);
}
if (theme == "Blue"){
g.drawImage(blueBlock2, (int) temp[0], (int) temp[1], 50, 50, this);
}
if (theme == "Brown"){
g.drawImage(brownBlock2, (int) temp[0], (int) temp[1], 50, 50, this);
}
}
if (environment[i].metal = true){
g.drawImage(metalBlock2, (int) temp[0], (int) temp[1], 50, 50, this);
}
//add in true check for platinum
}
}
}
}
}
if (player.faceRight = true){ //draw player image
if (player.throwShuriken = true){
g.drawImage(playerThrowRight2, (int) player.point[0], (int) player.point[1], 70, 90, this);
}
if (player.throwShuriken = false){
//something going on with the draw image constructor variables
g.drawImage(playerRight2, (int) player.point[0], (int) player.point[1], 70, 90, this);
}
}
if (player.faceRight = false){
if (player.throwShuriken = true){
g.drawImage(playerThrowLeft2, (int) player.point[0], (int) player.point[1], 70, 90, this);
}
if (player.throwShuriken = false){
g.drawImage(playerLeft2, (int) player.point[0], (int) player.point[1], 70, 90, this);
}
}
//draw enemy objects
for (int i = 0; i < enemy.length; i++){
}
//draw player weapons
for (int i = 0; i < pWeapon.length; i++){
//checks for weapon type
// if (pWeapon.type == blah blah blah
for (int j = 0; j < pWeapon[i].animation.length; j++){
if (j == 0){
g.drawImage(shuriken0, (int) pWeapon[i].point[0], (int) pWeapon[i].point[1], 40, 30, this);
}
if (j == 1){
g.drawImage(shuriken1, (int) pWeapon[i].point[0], (int) pWeapon[i].point[1], 40, 30, this);
}
if (j == pWeapon[i].animation.length){
j = 0;
}
}
}
//draw enemy weapons
for (int i = 0; i < eWeapon.length; i++){
}
}
class TimerListener implements ActionListener{
//setup various checks here
//for example, gravity
public void actionPerformed(ActionEvent e){
//or setup various checks here
//checks for player functions
if (player.moveLeft = true){
//checkWest(int velocity, float[] objBox){
float[] temp2 = player.getHitbox();
float[] temp3 = player.getPoint();
int temp = checkWest(-8, temp2);
if (temp == 0){
player.setMoveLeft(false);
}
temp2[0] = temp2[0] + temp;
temp2[1] = temp2[1] + temp;
temp3[0] = temp3[0] + temp;
player.setHitbox(temp2);
player.setPoint(temp3);
}
if (player.moveRight = true){
//checkWest(int velocity, float[] objBox){
float[] temp2 = player.getHitbox();
float[] temp3 = player.getPoint();
int temp = checkWest(8, temp2);
if (temp == 0){
player.setMoveLeft(false);
}
temp2[0] = temp2[0] + temp;
temp2[1] = temp2[1] + temp;
temp3[0] = temp3[0] + temp;
player.setHitbox(temp2);
player.setPoint(temp3);
}
repaint();
}
}
}
static class KeyboardPanel extends JPanel {
public KeyboardPanel(){
addKeyListener(new KeyAdapter(){
public void keyPressed(KeyEvent e){
switch (e.getKeyCode()){
case KeyEvent.VK_DOWN:
//info for going down ladder, etc..
case KeyEvent.VK_UP:
//info for going up ladder, etc...
case KeyEvent.VK_LEFT:
player.moveLeft = true;
if (player.faceRight = true){
player.setFaceRight(false);
}
case KeyEvent.VK_RIGHT:
player.moveRight = true;
if (player.faceRight = false){
player.setFaceRight(true);
}
case KeyEvent.VK_SPACE:
player.setJump(true);
case KeyEvent.VK_F:
if (pWeapon.length < 3){
PWeapon[] temp = new PWeapon[pWeapon.length + 1];
for (int i = 0; i < pWeapon.length; i++){
temp[i] = pWeapon[i];
}
float[] temp2 = player.getPoint();
if (player.faceRight = true){
temp2[0] = temp2[0] + 40;
temp2[1] = temp2[1] + 40;
PWeapon temp3 = new PWeapon("Shuriken", temp2, "right");
temp[temp.length - 1] = temp3;
}
if (player.faceRight = false){
temp2[1] = temp2[1] + 40;
PWeapon temp3 = new PWeapon("Shuriken", temp2, "left");
temp[temp.length - 1] = temp3;
}
pWeapon = temp;
}
}
}
public void keyReleased(KeyEvent e){
switch (e.getKeyCode()){
case KeyEvent.VK_LEFT:
player.moveLeft = false;
case KeyEvent.VK_RIGHT:
player.moveRight = false;
case KeyEvent.VK_SPACE:
player.setJump(false);
}
}
});
}
}
public int checkNorth(int velocity, float[] objBox){
int temp = velocity; //value for number of pixels to move
for (int i = 0; i < environment.length; i++){ //checks each environment object
if (environment[i].solid = true){ //ignores environment objects that are not solid
float[] checkBox = environment[i].getHitbox(); //gets hitbox of environment
for (int temp2 = 0; temp2 > velocity; temp2--){ //sets range for distance traveled
for (int j = (int)objBox[0]; j < objBox[1]; j++){ //checks north hitbox of the user/enemy object
for (int k = (int)checkBox[0]; k < checkBox[1]; k++){ //checks south hitbox of environment object
if (k == j && checkBox[3] == objBox[2]){ //checks to see if objects collide
if (temp2 > temp){ //checks if range is shorter than velocity
temp = temp2; //replaces range if shorter than velocity
}
}
}
}
}
}
}
return temp; //returns range to move
}
public int checkSouth(int velocity, float[] objBox){
int temp = velocity; //value for number of pixels to move
for (int i = 0; i < environment.length; i++){ //checks each environment object
if (environment[i].solid = true){ //ignores environment objects that are not solid
float[] checkBox = environment[i].getHitbox(); //gets hitbox of environment
for (int temp2 = 0; temp2 < velocity; temp2++){ //sets range for distance traveled
for (int j = (int)objBox[0]; j < objBox[1]; j++){ //checks south hitbox of the user/enemy object
for (int k = (int)checkBox[0]; k < checkBox[1]; k++){ //checks north hitbox of environment object
if (k == j && checkBox[2] == objBox[3]){ //checks to see if objects collide
if (temp2 < temp){ //checks if range is shorter than velocity
temp = temp2; //replaces range if shorter than velocity
}
}
}
}
}
}
}
return temp; //returns range to move
}
public static int checkWest(int velocity, float[] objBox){
int temp = velocity; //value for number of pixels to move
for (int i = 0; i < environment.length; i++){ //checks each environment object
if (environment[i].solid = true){ //ignores environment objects that are not solid
float[] checkBox = environment[i].getHitbox(); //gets hitbox of environment
for (int temp2 = 0; temp2 > velocity; temp2--){ //sets range for distance traveled
for (int j = (int)objBox[2]; j < objBox[3]; j++){ //checks West hitbox of the user/enemy object
for (int k = (int)checkBox[2]; k < checkBox[3]; k++){ //checks East hitbox of environment object
if (k == j && checkBox[1] == objBox[0]){ //checks to see if objects collide
if (temp2 > temp){ //checks if range is shorter than velocity
temp = temp2; //replaces range if shorter than velocity
}
}
}
}
}
}
}
return temp; //returns range to move
}
public int checkEast(int velocity, float[] objBox){
int temp = velocity; //value for number of pixels to move
for (int i = 0; i < environment.length; i++){ //checks each environment object
if (environment[i].solid = true){ //ignores environment objects that are not solid
float[] checkBox = environment[i].getHitbox(); //gets hitbox of environment
for (int temp2 = 0; temp2 < velocity; temp2++){ //sets range for distance traveled
for (int j = (int)objBox[2]; j < objBox[3]; j++){ //checks East hitbox of the user/enemy object
for (int k = (int)checkBox[2]; k < checkBox[3]; k++){ //checks West hitbox of environment object
if (k == j && checkBox[0] == objBox[1]){ //checks to see if objects collide
if (temp2 < temp){ //checks if range is shorter than velocity
temp = temp2; //replaces range if shorter than velocity
}
}
}
}
}
}
}
return temp; //returns range to move
}
public boolean checkHitbox(int[] velocity, int[] objBox, int[] checkBox){
int[] tempBox = {objBox[0] + velocity[0], objBox[1] + velocity[0], objBox[2] + velocity[1], objBox[3] + velocity[1]}; //sets up temp hitbox to check next location
for (int i = tempBox[0]; i < tempBox[1]; i++){ //checks x variables on tempBox
for (int j = tempBox[2]; j < tempBox[3]; j++){ //checks y variables on tempBox
for (int k = checkBox[0]; k < checkBox[1]; k++){ //checks x variables on checkBox
for (int l = checkBox[2]; l < checkBox[3]; l++){ //checks y variables on checkBox
if (i == k && j == l){ //checks if values are the same (if there is a collision
return true; //returns true if there is a collision
}
}
}
}
}
return false; //returns false if there isn't a collision
}
public static int[][] getMap0(){
//map 0, aka level 1
//int[][] map = {{2,3, 0}, {2,2,2}, {3,3,3}}; a better way to do it.
int[][] map = new int[32][12];
map[0][0] = 1; map[1][0] = 0; map[2][0] = 0; map[3][0] = 0; map[4][0] = 0; map[5][0] = 0; map[6][0] = 0; map[7][0] = 0;
map[8][0] = 0; map[9][0] = 0; map[10][0] = 0; map[11][0] = 0; map[12][0] = 0; map[13][0] = 0; map[14][0] = 0; map[15][0] = 0;
map[16][0] = 0; map[17][0] = 0; map[18][0] = 0; map[19][0] = 0; map[20][0] = 0; map[21][0] = 0; map[22][0] = 0; map[23][0] = 0;
map[24][0] = 0; map[25][0] = 0; map[26][0] = 0; map[27][0] = 0; map[28][0] = 0; map[29][0] = 0; map[30][0] = 0; map[31][0] = 1;
map[0][1] = 1; map[1][1] = 0; map[2][1] = 0; map[3][1] = 0; map[4][1] = 0; map[5][1] = 0; map[6][1] = 0; map[7][1] = 0;
map[8][1] = 0; map[9][1] = 0; map[10][1] = 0; map[11][1] = 0; map[12][1] = 0; map[13][1] = 0; map[14][1] = 0; map[15][1] = 0;
map[16][1] = 0; map[17][1] = 0; map[18][1] = 0; map[19][1] = 0; map[20][1] = 0; map[21][1] = 0; map[22][1] = 0; map[23][1] = 0;
map[24][1] = 0; map[25][1] = 0; map[26][1] = 0; map[27][1] = 0; map[28][1] = 0; map[29][1] = 0; map[30][1] = 0; map[31][1] = 1;
map[0][2] = 1; map[1][2] = 0; map[2][2] = 0; map[3][2] = 0; map[4][2] = 0; map[5][2] = 0; map[6][2] = 0; map[7][2] = 0;
map[8][2] = 0; map[9][2] = 0; map[10][2] = 0; map[11][2] = 0; map[12][2] = 0; map[13][2] = 0; map[14][2] = 0; map[15][2] = 0;
map[16][2] = 0; map[17][2] = 0; map[18][2] = 0; map[19][2] = 0; map[20][2] = 0; map[21][2] = 0; map[22][2] = 0; map[23][2] = 0;
map[24][2] = 0; map[25][2] = 0; map[26][2] = 0; map[27][2] = 0; map[28][2] = 0; map[29][2] = 0; map[30][2] = 0; map[31][2] = 1;
map[0][3] = 1; map[1][3] = 0; map[2][3] = 0; map[3][3] = 0; map[4][3] = 0; map[5][3] = 0; map[6][3] = 0; map[7][3] = 0;
map[8][3] = 0; map[9][3] = 0; map[10][3] = 0; map[11][3] = 0; map[12][3] = 0; map[13][3] = 0; map[14][3] = 0; map[15][3] = 0;
map[16][3] = 0; map[17][3] = 0; map[18][3] = 0; map[19][3] = 0; map[20][3] = 0; map[21][3] = 0; map[22][3] = 0; map[23][3] = 0;
map[24][3] = 0; map[25][3] = 0; map[26][3] = 0; map[27][3] = 0; map[28][3] = 0; map[29][3] = 0; map[30][3] = 0; map[31][3] = 1;
map[0][4] = 1; map[1][4] = 0; map[2][4] = 0; map[3][4] = 0; map[4][4] = 0; map[5][4] = 0; map[6][4] = 0; map[7][4] = 0;
map[8][4] = 0; map[9][4] = 0; map[10][4] = 0; map[11][4] = 0; map[12][4] = 0; map[13][4] = 0; map[14][4] = 0; map[15][4] = 0;
map[16][4] = 0; map[17][4] = 0; map[18][4] = 0; map[19][4] = 0; map[20][4] = 0; map[21][4] = 0; map[22][4] = 0; map[23][4] = 0;
map[24][4] = 0; map[25][4] = 0; map[26][4] = 0; map[27][4] = 0; map[28][4] = 0; map[29][4] = 0; map[30][4] = 0; map[31][4] = 1;
map[0][5] = 1; map[1][5] = 0; map[2][5] = 0; map[3][5] = 0; map[4][5] = 0; map[5][5] = 0; map[6][5] = 0; map[7][5] = 0;
map[8][5] = 0; map[9][5] = 0; map[10][5] = 0; map[11][5] = 0; map[12][5] = 0; map[13][5] = 0; map[14][5] = 0; map[15][5] = 0;
map[16][5] = 0; map[17][5] = 0; map[18][5] = 0; map[19][5] = 0; map[20][5] = 0; map[21][5] = 0; map[22][5] = 0; map[23][5] = 0;
map[24][5] = 0; map[25][5] = 0; map[26][5] = 0; map[27][5] = 0; map[28][5] = 0; map[29][5] = 0; map[30][5] = 0; map[31][5] = 1;
map[0][6] = 1; map[1][6] = 0; map[2][6] = 0; map[3][6] = 0; map[4][6] = 0; map[5][6] = 0; map[6][6] = 0; map[7][6] = 0;
map[8][6] = 0; map[9][6] = 0; map[10][6] = 0; map[11][6] = 0; map[12][6] = 0; map[13][6] = 0; map[14][6] = 0; map[15][6] = 0;
map[16][6] = 0; map[17][6] = 0; map[18][6] = 0; map[19][6] = 0; map[20][6] = 0; map[21][6] = 0; map[22][6] = 0; map[23][6] = 0;
map[24][6] = 0; map[25][6] = 0; map[26][6] = 0; map[27][6] = 0; map[28][6] = 0; map[29][6] = 0; map[30][6] = 0; map[31][6] = 1;
map[0][7] = 1; map[1][7] = 0; map[2][7] = 0; map[3][7] = 0; map[4][7] = 0; map[5][7] = 0; map[6][7] = 0; map[7][7] = 0;
map[8][7] = 0; map[9][7] = 0; map[10][7] = 0; map[11][7] = 0; map[12][7] = 0; map[13][7] = 0; map[14][7] = 0; map[15][7] = 0;
map[16][7] = 0; map[17][7] = 0; map[18][7] = 0; map[19][7] = 0; map[20][7] = 0; map[21][7] = 0; map[22][7] = 0; map[23][7] = 0;
map[24][7] = 0; map[25][7] = 0; map[26][7] = 0; map[27][7] = 0; map[28][7] = 0; map[29][7] = 0; map[30][7] = 0; map[31][7] = 1;
map[0][8] = 1; map[1][8] = 0; map[2][8] = 0; map[3][8] = 0; map[4][8] = 0; map[5][8] = 0; map[6][8] = 0; map[7][8] = 0;
map[8][8] = 0; map[9][8] = 0; map[10][8] = 0; map[11][8] = 0; map[12][8] = 0; map[13][8] = 0; map[14][8] = 0; map[15][8] = 0;
map[16][8] = 0; map[17][8] = 0; map[18][8] = 0; map[19][8] = 0; map[20][8] = 0; map[21][8] = 0; map[22][8] = 0; map[23][8] = 0;
map[24][8] = 0; map[25][8] = 0; map[26][8] = 0; map[27][8] = 0; map[28][8] = 0; map[29][8] = 0; map[30][8] = 0; map[31][8] = 1;
map[0][9] = 1; map[1][9] = 0; map[2][9] = 0; map[3][9] = 0; map[4][9] = 0; map[5][9] = 0; map[6][9] = 0; map[7][9] = 0;
map[8][9] = 0; map[9][9] = 0; map[10][9] = 0; map[11][9] = 0; map[12][9] = 0; map[13][9] = 0; map[14][9] = 0; map[15][9] = 0;
map[16][9] = 0; map[17][9] = 0; map[18][9] = 0; map[19][9] = 0; map[20][9] = 0; map[21][9] = 0; map[22][9] = 0; map[23][9] = 0;
map[24][9] = 0; map[25][9] = 0; map[26][9] = 0; map[27][9] = 0; map[28][9] = 0; map[29][9] = 0; map[30][9] = 0; map[31][9] = 1;
map[0][10] = 1; map[1][10] = 0; map[2][10] = 0; map[3][10] = 0; map[4][10] = 0; map[5][10] = 0; map[6][10] = 0; map[7][10] = 0;
map[8][10] = 0; map[9][10] = 0; map[10][10] = 0; map[11][10] = 0; map[12][10] = 0; map[13][10] = 0; map[14][10] = 0; map[15][10] = 0;
map[16][10] = 0; map[17][10] = 0; map[18][10] = 0; map[19][10] = 0; map[20][10] = 0; map[21][10] = 0; map[22][10] = 0; map[23][10] = 0;
map[24][10] = 0; map[25][10] = 0; map[26][10] = 0; map[27][10] = 0; map[28][10] = 0; map[29][10] = 0; map[30][10] = 0; map[31][10] = 1;
map[0][11] = 1; map[1][11] = 1; map[2][11] = 1; map[3][11] = 1; map[4][11] = 1; map[5][11] = 1; map[6][11] = 1; map[7][11] = 1;
map[8][11] = 1; map[9][11] = 1; map[10][11] = 1; map[11][11] = 1; map[12][11] = 1; map[13][11] = 1; map[14][11] = 1; map[15][11] = 1;
map[16][11] = 1; map[17][11] = 1; map[18][11] = 1; map[19][11] = 1; map[20][11] = 1; map[21][11] = 1; map[22][11] = 1; map[23][11] = 1;
map[24][11] = 1; map[25][11] = 1; map[26][11] = 1; map[27][11] = 1; map[28][11] = 1; map[29][11] = 1; map[30][11] = 1; map[31][11] = 1;
return map;
}
}