From bce98f9670ae027bbf727a4ba20f52cd17765793 Mon Sep 17 00:00:00 2001 From: Adam Frisby Date: Fri, 21 Aug 2009 13:12:51 +1000 Subject: * Fixing an issue with NPC's and Circuit Codes. --- OpenSim/Region/OptionalModules/World/NPC/NPCModule.cs | 3 +++ 1 file changed, 3 insertions(+) (limited to 'OpenSim/Region/OptionalModules/World/NPC') diff --git a/OpenSim/Region/OptionalModules/World/NPC/NPCModule.cs b/OpenSim/Region/OptionalModules/World/NPC/NPCModule.cs index 94349f6..775dc91 100644 --- a/OpenSim/Region/OptionalModules/World/NPC/NPCModule.cs +++ b/OpenSim/Region/OptionalModules/World/NPC/NPCModule.cs @@ -44,6 +44,9 @@ namespace OpenSim.Region.OptionalModules.World.NPC public UUID CreateNPC(string firstname, string lastname,Vector3 position, Scene scene, UUID cloneAppearanceFrom) { NPCAvatar npcAvatar = new NPCAvatar(firstname, lastname, position, scene); + npcAvatar.CircuitCode = (uint) Util.RandomClass.Next(0, int.MaxValue); + + scene.ClientManager.Add(npcAvatar.CircuitCode, npcAvatar); scene.AddNewClient(npcAvatar); ScenePresence sp; -- cgit v1.1