class Game { // 게임 클래스
      constructor(name) { // 생성자
        this.monster = null; 
        this.hero = null; 
        this.monsterList = [
          (중략)
        ];
        this.start(); 
      }
      start() { // 게임 시작 메서드
        $gameMenu.addEventListener('submit', this.onGameMenuInput);
        $battleMenu.addEventListener('submit', this.onBattleMenuInput); 
        this.changeScreen('game');
      }
      changeScreen(screen) { // 화면 전환 메서드
        if (screen === 'start') { // 초기 화면
          $startScreen.style.display = 'block'; // 초기 화면 보이기
          $gameMenu.style.display = 'none'; // 일반 메뉴 화면 숨기기
          $battleMenu.style.display = 'none'; // 전투 메뉴 화면 숨기기
        } else if (screen === 'game') { // 일반 메뉴 
          $startScreen.style.display = 'none';
          $gameMenu.style.display = 'block'; // 일반 메뉴 화면 보이기
          $battleMenu.style.display = 'none';
    
    신간 소식 구독하기
    뉴스레터에 가입하시고 이메일로 신간 소식을 받아 보세요.