// .txt

beginzonescript;

variables;

short im_hostile = 0;
short max_crime = 200;
short last_abil;
short counter = 0;
short mess1 == 0;
short mess2 == 0;

body;

beginstate INIT_STATE;
	last_abil = get_current_tick();

//	set_name(,"");

	add_range_to_group(3464,3469,43);
	set_name(30043,"Wastes Banshee");
	set_level(30043,30);
	set_aggression(30043,60);

	add_range_to_group(3470,3475,44);
	set_aggression(30044,60);
	
	add_range_to_group(3476,3481,45);
	set_level(30045,30);
	set_aggression(30045,60);
	
	add_range_to_group(3482,3487,46);
	set_aggression(30046,60);
	
	sf(32,10,1);
	set_obj_act_at_dist(5780,1);
	set_obj_act_at_dist(5781,1);
	
	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;
	//	}

	// if (gf(,) == 0) {
	//if (get_ran(1,0,100) < 10)
	//	give_char_text_bubble(,"");
	//	}

	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();
		
		if (gf(32,10) == 0) {
			counter = counter + 1;

			if (counter == 1) {
				print_str_color("All of the pylons but the southeast one begin to pulse.",3);
				
				sf(32,11,1);
				sf(32,12,1);
				sf(32,14,1);
				sf(32,15,1);

				sf(32,13,0);
				
				if (mess1 == 0) {
					mess1 = 1;
					begin_talk_mode(6);
					}
				}
			if (counter == 2) {
				print_str_color("All of the pylons but the southeast one pulse more quickly.",3);
				}
			if (counter == 3) {
				print_str_color("The pylons are close to discharging their energy.",3);
				
				inc_flag(32,16,1);
				
				sf(32,11,3);
				sf(32,12,3);
				sf(32,14,3);
				sf(32,15,3);
				
				if (mess2 == 0) {
					mess2 = 1;
					begin_talk_mode(5);
					}
				}

			if (counter == 4) {
				print_str_color("All of the pylons but the northeast one begin to pulse.",3);
				
				sf(32,11,1);
				sf(32,12,1);
				sf(32,13,1);
				sf(32,15,1);

				sf(32,14,0);

				}
			if (counter == 5) {
				print_str_color("All of the pylons but the northeast one pulse more quickly.",3);
				}
			if (counter == 6) {
				print_str_color("The pylons are close to discharging their energy.",3);
				
				inc_flag(32,16,1);
				
				sf(32,11,3);
				sf(32,12,3);
				sf(32,13,3);
				sf(32,15,3);
				}

			if (counter == 7) {
				print_str_color("All of the pylons but the northwest one begin to pulse.",3);
				
				sf(32,12,1);
				sf(32,13,1);
				sf(32,14,1);
				sf(32,15,1);

				sf(32,11,0);

				}
			if (counter == 8) {
				print_str_color("All of the pylons but the northwest one pulse more quickly.",3);
				}
			if (counter == 9) {
				print_str_color("The pylons are close to discharging their energy.",3);
				
				inc_flag(32,16,1);
				
				sf(32,12,3);
				sf(32,13,3);
				sf(32,14,3);
				sf(32,15,3);
				}

			if (counter == 10) {
				print_str_color("All of the pylons but the southwest one begin to pulse.",3);
				
				sf(32,11,1);
				sf(32,13,1);
				sf(32,14,1);
				sf(32,15,1);

				sf(32,12,0);

				}
			if (counter == 11) {
				print_str_color("All of the pylons but the southwest one pulse more quickly.",3);
				}
			if (counter == 12) {
				print_str_color("The pylons are close to discharging their energy.",3);
			
				inc_flag(32,16,1);
				
				sf(32,11,3);
				sf(32,13,3);
				sf(32,14,3);
				sf(32,15,3);
				
				counter = 0;
				}


			}
		}
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);
