/*     */   @EventHandler(priority=EventPriority.HIGHEST)
/*     */   public void onPlayerGameModeChange(PlayerGameModeChangeEvent event)
/*     */   {
/* 277 */     if (!event.isCancelled())
/*     */     {
/* 279 */       if (Main.getAPI().isBeingSpectated(event.getPlayer()))
/*     */       {
/* 281 */         for (Player p : Main.getAPI().getSpectators(event.getPlayer()))
/*     */         {
/* 283 */           p.setGameMode(event.getNewGameMode());
/*     */         }
/*     */       }
/*     */     }
/*     */   }