// basicnpc.txt
// A very simple, naive text. Creature attacks anything it hates nearby.
// Once it has won, it returns to its home.
// NPC that doesn't move or do anything
//   Cell 1,2 - Stuff done flag. If both 0, nothing. Otherwise when this is killed, set to 1.

begincreaturescript;

variables;

short i,target;

body;

beginstate INIT_STATE;
	set_walk_speed(ME,0);
	set_combat_activity(ME,2);
	set_char_unkillable(ME,1);
	set_name(ME,"Shadowy Slith");
	
	if (gf(160,0) > 0)
		erase_char(ME);
	break;

beginstate DEAD_STATE;

break;

beginstate START_STATE; 
	set_attitude(ME,4);
	if ((gf(160,0) > 0) && (get_nearest_party_char(8) >= 0))
		talk_no_exit(190);
break;

beginstate TALKING_STATE;
	if (gf(160,0) == 0)
		begin_talk_mode(14);
		else talk_no_exit(190);
break;