// .txt

beginzonescript;

variables;

short im_hostile = 0;
short max_crime = 3;
short last_abil;
short counter = 0;

body;

beginstate INIT_STATE;
	last_abil = get_current_tick();

//	set_name(,"");

	add_range_to_group(3349,3354,37);
	set_name(30037,"Shafrir's Sentinel");
	set_level(30037,40);
	set_attack_bonus(30037,50);

	add_range_to_group(3355,3359,38);
	set_level(30038,28);
	set_name(30038,"Woods Widow");
	set_name(3359,"Aranea Mage");
	set_aggression(30038,60);
	
	add_range_to_group(3360,3364,39);
	set_level(30039,28);
	set_name(30039,"Woods Widow");
	set_name(3364,"Aranea Mage");
	set_aggression(30039,60);
	
	add_range_to_group(3365,3369,40);
	set_level(30040,28);
	set_name(30040,"Woods Widow");
	set_name(3369,"Aranea Archmage");
	place_particle_num(3369,10,12,6);		
	set_level(3369,35);
	set_new_abil(3369,9);
	
	set_aggression(30040,60);
	
	add_range_to_group(3370,3375,41);
	set_level(30041,28);
	set_name(30041,"Woods Widow");
	set_name(3374,"Aranea Mage");
	set_aggression(30041,60);
	
	set_name(3348,"Shafrir");
	set_level(3348,50);
	set_boss_level(3348,2);
	set_attack_bonus(3348,60);
	
	set_crime_tolerance(max_crime);

	break;

beginstate EXIT_STATE;

break;

beginstate START_STATE;
		
	if ((get_crime_level() >= max_crime) && (im_hostile == 0)) {
		make_zone_hostile();
		im_hostile = 1;
		sf(31,6,1);
		}

	if (gf(31,6) == 0) {
		if (get_ran(1,0,100) < 10)
			give_char_text_bubble(3348,"How useful!");
		if (get_ran(1,0,100) < 10)
			give_char_text_bubble(3348,"Help me to experiment!");
		if (get_ran(1,0,100) < 10)
			give_char_text_bubble(3348,"I can use you!");
		if (get_ran(1,0,100) < 10)
			give_char_text_bubble(3348,"Give me things!");
		}

	//if (((is_combat()) && (tick_difference(last_abil,get_current_tick()) > 0)) || ((is_group()) && (tick_difference(last_abil,get_current_tick()) > 5))) {
	//	last_abil = get_current_tick();
	//	}
break;

beginstate 10;
break;

beginstate 11;
break;

beginstate 12;
break;

beginstate 13;
break;

//	print_str("");
//	set_terrain_string_range(".",1);
//	set_terrain_string_range("The sign says - .",1);
