OsNpcCreate

From OpenSimulator

Revision as of 05:02, 30 June 2011 by Makopoppo (Talk | contribs)

Jump to: navigation, search
key osNpcCreate(string firstname, string lastname, vector position, key cloneFrom);
No descriptions provided
Threat Level High
Permissions No permissions specified
Extra Delay No function delay specified
Example(s)
// touch to create npc in front of this emitter
// touch again to destroy
 
key npc;
 
default
{
    touch_start(integer number)
    {
        vector npcPos = llGetPos() + <1,0,0>;
        npc = osNpcCreate("Jane", "Bot", npcPos, llGetOwnerKey(llGetKey()));
        state hasNPC;
    }
}
 
state hasNPC
{
    touch_start(integer number)
    {
        osNpcRemove(npc);
        npc = NULL_KEY;
        state default;
    }
}
Notes
*This function creates a NPC(Non Player Character) clone from an already existing avatar UUID Key.
  • Note: This function may not work as you have intended. See Mantis #5148 for more information.
Personal tools
General
About This Wiki