public void endGame(EndReason reason) {
		String endtext = reason.getreasontext() + ",Ϸ";
		switch (reason) {
		case END_REASON_SUCCESS: {
			for (Player p : players) {
				playerLeave(p, endtext);
			}
			arenastate = ArenaState.STAT_OPEN;
			clear();
			break;
		}
		case END_REASON_NOPLAYER: {
			for (Player p : players) {
				playerLeave(p, endtext);
			}
			arenastate = ArenaState.STAT_OPEN;
			clear();
			break;
		}
		case END_REASON_BOSSLEAVE: {

			arenastate = ArenaState.STAT_OPEN;
			this.arenaBoardcast(endtext + ",ָ׼״̬");
			for (Player p : players) {
				p.teleport(ready);
			}
			break;
		}
		case END_REASON_ARENADISABLE: {
			for (Player p : players) {
				playerLeave(p, endtext);
			}
			arenastate = ArenaState.STAT_DISABLED;
			clear();
			break;
		}
		case END_REASON_ARENAEDIT: {
			for (Player p : players) {
				playerLeave(p, endtext);
			}
			arenastate = ArenaState.STAT_EDIT;
			clear();
			break;
		}
		case END_REASON_UNKNOW:
		default: {
			for (Player p : players) {
				playerLeave(p, endtext);
			}
			arenastate = ArenaState.STAT_OPEN;
			clear();
			break;
		}
		}

	}