"use strict";

// Two figures from the Gargoyle Conflict, one oddly familiar
var GO_BayStatue = function(frame){
	this.sprite = new Sprite(GO_BayStatue.spriteSheet,"BayStatue");
	this.sprite.collision_flags = 
		DEFINE_SPRITE_COLLISION_FLAGS.SPRITES_PASSIVE;
	this.sprite.setBoundingBox(6,1,25,31);
	this.sprite.game_object = this; // no longer a generic GO

	this.name = "BayStatue";

	//this.checks = 0;
	this.sprite.frame = frame;
};
GO_BayStatue.spriteImg = SDS_Load_Image("art/sheets/sprite/bayshrine_statues.png");
GO_BayStatue.spriteSheet = new TileSheet(5, 5, 1, 0, GO_BayStatue.spriteImg);

GO_BayStatue.prototype = new GameObject(
	new Sprite(
		GO_BayStatue.spriteSheet,
		"BayStatue"
	),
	"BayStatue"
	);

	GO_BayStatue.prototype.interactions = DEFINE_GAMEOBJECT_INTERACTIONS.CHECK;

	GO_BayStatue.prototype.Update = function(){

	};

	GO_BayStatue.prototype.checkEvent = function(sourceGO){
		//++this.checks;
		//this.checks = Math.min(this.checks,2);

		if (GLOBAL_DIARY.check(5,"AWAKE") && !GLOBAL_DIARY.check(5,"BLESSING")){
			return "GD_Meli_statue_"+this.sprite.frame; // filed under Ernest for convenience
		}
		else{
			return "GD_Ernest_statue_"+this.sprite.frame;
		}
	};
