Jump to content

Home

Making a npc appear after a conversation


bindo245

Recommended Posts

To spawn your NPC use this script:

 

void main() 
{ 
   float x = x_coord_here; 
   float y = y_coord_here; 
   float z = z_coord_here; 
   float r = orientation_here; 

   vector vCre = Vector(x, y, z); 
   location lCre = Location(r, vCre); 

   object oCre = CreateObject(OBJECT_TYPE_CREATURE, "resref_here", lCre); 

}

 

Replace the blahblah_here with the relevant co-ordinates and resref...

 

And to go to a new module:

 

void main()
{
StartNewModule("module_name_here");
}

 

Replace module_name_here with the name of the module eg: danm13 etc...

Link to comment
Share on other sites

Try this one, it does exactly the same thing but to me it's a simpler way of doing it;

void main() 
{ 
CreateObject(OBJECT_TYPE_CREATURE, "NPC_TAG", Location(Vector(-75.87156, -26.69725, 0.00000), 0.0));

} 

 

Just replace those digits with the location you want to spawn the NPC.

 

--Stream

Link to comment
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...