function AnimalRecordList(type) {
	this.type = type;

	this.posY = 0;

	this.animals = [];
	this.activeAnimalIndex = 0;

	this.texts = new Array();


	var bgColor = MainColor.LIGHT_CHOCO_HEX;
	if(this.type === Animal.TYPE_MENU) {
		bgColor = MainColor.LIGHT_CHOCO_HEX;
		this.posY = AnimalRecordList.ANIMAL_LIST_MENU_POS_Y;
	}
	else {
		bgColor = AnimalRecordList.COLOR_TYPING_EXAM_STAGE_BACKGROUND_HEX;
		this.posY = AnimalRecordList.ANIMAL_LIST_EXAM_POS_Y;
	}
	game.add.graphics()
		.beginFill(bgColor, 1)
		.drawRect(0, this.posY, game.world.width, 80);


	// make animals and score texts
	var animalCount = Animal.SPECIES_DATA.length;
	var lineWidth = GAME_SCREEN_SIZE.x - AnimalRecordList.MARGIN_X * 2;
	// console.log("lineWidth : " + lineWidth);
	var offsetAnimal = lineWidth / (animalCount - 1);
	// console.log("animalCount : " + animalCount);
	// console.log("offsetAnimal : " + offsetAnimal);

	this.makeAnimals(animalCount, lineWidth, offsetAnimal);
	this.makeScoreTexts(animalCount, lineWidth, offsetAnimal);
}

AnimalRecordList.prototype.makeAnimals = function(animalCount, lineWidth, offsetAnimal) {
	var posY = 0;
	if(this.type === Animal.TYPE_MENU)
		posY = AnimalRecordList.ANIMAL_LIST_MENU_POS_Y + AnimalRecordList.ANIMAL_OFFSET_Y;
	else
		posY = AnimalRecordList.ANIMAL_LIST_EXAM_POS_Y + AnimalRecordList.ANIMAL_OFFSET_Y;

	for(var i = 0; i < animalCount; i++) {
		this.animals[i] = new Animal(
			Animal.TYPE_ICON,
			i,
			AnimalRecordList.MARGIN_X + offsetAnimal * i,
			posY
		);
		if(this.type === Animal.TYPE_EXAM)
			this.inactivate(i);
	}

	if(this.type === Animal.TYPE_EXAM) {
		this.activate(this.activeAnimalIndex);
		this.tweenAnimation(Animal.ANIMATION_TYPE_DAMAGE);
	}
}

AnimalRecordList.prototype.makeScoreTexts = function(animalCount, lineWidth, offsetAnimal) {
	var titleTextStyle = { font: "16px Nanum Gothic", fill: "#fff", align: "center"};

	for(var i = 0; i < animalCount; i++) {
		var animalData = Animal.SPECIES_DATA[i];

		var recordText = game.add.text(
			0,	// center of animal image
			AnimalRecordList.RECORD_TEXT_OFFSET_Y,
			"", titleTextStyle
		);
		recordText.anchor.set(0.5);
		recordText.addColor(AnimalRecordList.COLOR_SCORE_MENU_DEFAULT_TEXT, 0);
		recordText.stroke = "#333";
		recordText.strokeThickness = 3;
		recordText.setShadow(1, 1, 'rgba(0, 0, 0, 0.5)', 2);

		this.animals[i].sprite.addChild(recordText);
		this.texts.push(recordText);
	}
}

AnimalRecordList.prototype.printScore = function(recordType) {
	var count = this.texts.length;
	for(var i = 0; i < count; i++) {
		var animalData = Animal.SPECIES_DATA[i];
		var recordText = this.texts[i];

		var typingCountWithUnit = "";
		if(recordType == Animal.TYPE_PRACTICE)
			typingCountWithUnit = RecordUtil.getRecordValueWithUnit(animalData.typingPracticeCount, 1);
		else
			typingCountWithUnit = RecordUtil.getRecordValueWithUnit(animalData.typingTestCount, 1);
		recordText.text = typingCountWithUnit;

		/*
		if(this.type === AnimalRecordList.TYPE_MENU)
			recordText.addColor(AnimalRecordList.COLOR_SCORE_MENU_DEFAULT_TEXT, 0);
		else
			recordText.addColor(AnimalRecordList.COLOR_SCORE_DEFAULT_TEXT, 0);
		*/
	}

}

AnimalRecordList.prototype.activate = function(index) {
	this.inactivate(this.activeAnimalIndex);

	this.activeAnimalIndex = index;

	this.animals[this.activeAnimalIndex].setScale(2);
	this.animals[index].setAlpha(1);
	this.animate(this.activeAnimalIndex);
}

AnimalRecordList.prototype.inactivate = function(index) {
	this.animals[index].stopAnimation();
	this.animals[index].setScale(1);
	this.animals[index].setAlpha(AnimalRecordList.ALPHA_INACTIVE);
}

AnimalRecordList.prototype.animate = function(index) {
	var animalData = Animal.SPECIES_DATA[index];
	this.animals[index].startAnimation(animalData);
}

AnimalRecordList.prototype.stopAnimation = function() {
	this.animals[this.activeAnimalIndex].stopAnimation();
}

AnimalRecordList.prototype.tweenAnimation = function(animationType) {
	this.animals[this.activeAnimalIndex].tweenAnimation(animationType);
}

AnimalRecordList.prototype.show = function() {
	var count = this.animals.length;
	for(var i = 0; i < count; i++)
		this.animals[i].show();
}

AnimalRecordList.prototype.hide = function() {
	var count = this.animals.length;
	for(var i = 0; i < count; i++)
		this.animals[i].hide();
}

AnimalRecordList.prototype.applyLoadedFont = function() {
	var count = this.texts.length;
	for(var i = 0; i < count; i++) {
		this.texts[i].font = "Nanum Gothic";
	}
}


AnimalRecordList.POS_Y 					= 780;
AnimalRecordList.HIDE_POS_Y				= 1000;

AnimalRecordList.MARGIN_X				= 100;
AnimalRecordList.ANIMAL_LIST_POS_Y		= 90;
AnimalRecordList.RECORD_TEXT_OFFSET_Y	= 36;

AnimalRecordList.ALPHA_INACTIVE			= 0.3;


AnimalRecordList.ANIMAL_LIST_MENU_POS_Y			= 690;	// 70; //640;
AnimalRecordList.ANIMAL_LIST_EXAM_POS_Y			= 60;	// 638;
AnimalRecordList.ANIMAL_OFFSET_Y				= 30;
AnimalRecordList.RECORD_TEXT_MENU_OFFSET_Y		= 35;
AnimalRecordList.COLOR_SCORE_MENU_DEFAULT_TEXT	= MainColor.OLD_LACE_STRING;

AnimalRecordList.COLOR_BG								= MainColor.CHOCO_HEX;
AnimalRecordList.COLOR_TYPING_EXAM_STAGE_BACKGROUND_HEX	= MainColor.DARKEST_GRAY_HEX;

AnimalRecordList.COLOR_SCORE_DEFAULT_TEXT	= "#bbddff";
AnimalRecordList.COLOR_SCORE_CLEARED_TEXT	= "#ffffff";