View Single Post
  #1  
Old 05-07-2002, 05:48 AM
Malevolent
Hill Giant
 
Join Date: Mar 2002
Posts: 171
Default Simple wolf actions

Stuff in NPC::Process() somewhere

Code:
	/********************************************
	Wolf actions
	********************************************/

	if (this->GetRace()==42)
	if (!IsEngaged() && !ismovinghome())	
	if (rand()%2950==2) {
		switch(rand()%10){
		case 0:
			
		case 1:
		case 3:
		case 5:
		case 7:
		case 9:
			this->DoAnim(33);
			entity_list.MessageClose(this,true,50,MT_Emote, "%s scratches their ears.", GetName());
			this->DoAnim(38);
			break;
		case 2:
		case 4:
		case 6:
		case 8:
		case 10:
			this->DoAnim(33);
			this->DoAnim(38);

			switch (rand()%5){

			case 0:
			case 1:
				entity_list.Message(0, MT_Emote, "%s howls loudly.", GetName());			
				break;
			case 2:
			case 3:
				entity_list.Message(0, MT_Emote, "%s howls softly into the air.", GetName());			
				break;
			case 4:
			case 5:
			default:
				entity_list.Message(0, MT_Emote, "%s begins to howl.", GetName());			
				break;
			}
			break;
		
		default:
			break;
		}
	}
Reply With Quote