if (distance_to_object(obj_player) < 30){
	if (obj_player.y < y+32){
		depth = obj_player.depth-10
	} else {
		depth = obj_player.depth+10
	}
}
if (var_door_mode != 1){
	if (distance_to_object(obj_player) < 6){
		if (!instance_exists(obj_message_axe) and (obj_player.var_player_mode != "NorthAxe") and (obj_player.var_player_mode != "SouthAxe")){
			instance_create_depth(obj_player.x,obj_player.y,depth-10,obj_message_axe)
			if (keyboard_check(69)){
				if (obj_player.y > y+32){
					obj_player.var_player_mode = "NorthAxe"
					obj_player.var_player_CanMove = 0
					if (!instance_exists(obj_axeBar)){
						instance_create_depth(x+32,y,depth-40,obj_axeBar)
						var_door_mode = 1
					}
				} else {
					obj_player.var_player_mode = "SouthAxe"
					obj_player.var_player_CanMove = 0
					if (!instance_exists(obj_axeBar)){
						instance_create_depth(x+32,y,depth-40,obj_axeBar)
						var_door_mode = 1
					}
				
				}
			}
		}
	}
} else {
	if (!instance_exists(obj_axeBar)) and (distance_to_object(obj_player) < 15){
		instance_destroy(self)
		if (obj_player.var_player_mode == "NorthAxe"){
			obj_player.var_player_CanMove = 1
			obj_player.var_player_animation = 0
			obj_player.var_player_mode = "North"
		} else {
			obj_player.var_player_CanMove = 1
			obj_player.var_player_animation = 0
			obj_player.var_player_mode = "South"
		}
	}
}