//ヘッダーファイル
let button_start = document.getElementById("start_button");
let button1 = document.getElementById("html_button1");
let button2 = document.getElementById("html_button2");
let button3 = document.getElementById("html_button3");
let button4 = document.getElementById("html_button4");
let box = document.getElementById("html_box");
let label1 = document.getElementById("html_label1");
let canvas1 =document.getElementById("html_canvas");
let ctx = canvas1.getContext("2d");
let mx = 0;
let my = 0;
let img1 = new Image();
let img2 = new Image();
let img3 = new Image();
img1.src = "images/title.png"
img2.src = "images/perfect.png"
img3.src = "images/sit_neko.png"

// サウンド
let sound1 = new Audio;
let sound2 = new Audio;
let sound3= new Audio;
let sound4 = new Audio;
let sound5 = new Audio;
let sound6 = new Audio;
let sound7 = new Audio;
let sound8 = new Audio;
let sound9 = new Audio;
let sound10 = new Audio;
sound1.src = "sounds/01.mp3";
sound2.src = "sounds/02.mp3";
sound3.src = "sounds/03.mp3";
sound4.src = "sounds/04.mp3";
sound5.src = "sounds/05.mp3";
sound6.src = "sounds/06.mp3";
sound7.src = "sounds/07.mp3";
sound8.src = "sounds/08.mp3";
sound9.src = "sounds/09.mp3";
sound10.src = "sounds/10.mp3";


// デバッグスイッチ
let debug_sw = 0;   //0:OFF 1:ON

// ヒントスイッチ
let hint_sw = 0;   //0:OFF 1:ON

//選択された数字　セレクト番号
let sel_num = 0;

//画面全体の表示範囲
let GAMEN_start_x, GAMEN_start_y;
let GAMEN_width, GAMEN_height;

//碁盤目の表示範囲
let GOBAN_start_x, GOBAN_start_y;
let GOBAN_width, GOBAN_height;

//セレクト画面の表示範囲
let SELECT_start_x, SELECT_start_y;
let SELECT_width, SELECT_height;

let KOUSHI_ofs_x = 20;
let KOUSHI_ofs_y = 20;
let KOUSHI_width = 40;
let KOUSHI_height = 40;
let KOMA_su = 9;

let BACK_col1 = "white";
let BACK_col2 = "#ffee88";
let BACK_col3 = "#ee88ff";
let KOUSHI_col1 = "black";
let KOUSHI_col2 = "blue";

let SEN_haba1 = 1;
let SEN_haba2 = 1.5;
let SEN_haba3 = 2;

let MOJI_col1 = "midnightblue";
let MOJI_col2 = "red";
let MOJI_col3 = "gray";
let MOJI_col4 = "black";
let MOJI_font = "46px serif";

function print(str){
    console.log(str);
    label1.insertAdjacentHTML("beforeend", "<p>" + str + "</p>");
}
