aboutsummaryrefslogtreecommitdiffstatshomepage
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--OpenSim/Region/OptionalModules/World/NPC/NPCModule.cs11
-rw-r--r--bin/OpenSim.ini.example6
-rw-r--r--bin/OpenSimDefaults.ini4
3 files changed, 17 insertions, 4 deletions
diff --git a/OpenSim/Region/OptionalModules/World/NPC/NPCModule.cs b/OpenSim/Region/OptionalModules/World/NPC/NPCModule.cs
index fcfacc6..d139b25 100644
--- a/OpenSim/Region/OptionalModules/World/NPC/NPCModule.cs
+++ b/OpenSim/Region/OptionalModules/World/NPC/NPCModule.cs
@@ -44,15 +44,18 @@ namespace OpenSim.Region.OptionalModules.World.NPC
44 { 44 {
45 private static readonly ILog m_log = LogManager.GetLogger(MethodBase.GetCurrentMethod().DeclaringType); 45 private static readonly ILog m_log = LogManager.GetLogger(MethodBase.GetCurrentMethod().DeclaringType);
46 46
47 // private const bool m_enabled = false;
48
49 private Dictionary<UUID, NPCAvatar> m_avatars = new Dictionary<UUID, NPCAvatar>(); 47 private Dictionary<UUID, NPCAvatar> m_avatars = new Dictionary<UUID, NPCAvatar>();
50 private Dictionary<UUID, AvatarAppearance> m_appearanceCache = new Dictionary<UUID, AvatarAppearance>(); 48 private Dictionary<UUID, AvatarAppearance> m_appearanceCache = new Dictionary<UUID, AvatarAppearance>();
51 49
52 public void Initialise(Scene scene, IConfigSource source) 50 public void Initialise(Scene scene, IConfigSource source)
53 { 51 {
54 scene.RegisterModuleInterface<INPCModule>(this); 52 IConfig config = source.Configs["NPC"];
55 scene.EventManager.OnSignificantClientMovement += HandleOnSignificantClientMovement; 53
54 if (config != null && config.GetBoolean("Enabled", false))
55 {
56 scene.RegisterModuleInterface<INPCModule>(this);
57 scene.EventManager.OnSignificantClientMovement += HandleOnSignificantClientMovement;
58 }
56 } 59 }
57 60
58 public void HandleOnSignificantClientMovement(ScenePresence presence) 61 public void HandleOnSignificantClientMovement(ScenePresence presence)
diff --git a/bin/OpenSim.ini.example b/bin/OpenSim.ini.example
index 5da80c0..1a87b79 100644
--- a/bin/OpenSim.ini.example
+++ b/bin/OpenSim.ini.example
@@ -716,6 +716,12 @@
716 ; Enabled = true; 716 ; Enabled = true;
717 717
718 718
719[NPC]
720 ;# {Enabled} {} {Enable Non Player Character (NPC) facilities} {true false} false
721 ;; Enable media on a prim facilities
722 ; Enabled = false
723
724
719[PrimLimitsModule] 725[PrimLimitsModule]
720 ;# {EnforcePrimLimits} {} {Enforce parcel prim limits} {true false} false 726 ;# {EnforcePrimLimits} {} {Enforce parcel prim limits} {true false} false
721 ;; Enable parcel prim limits. Off by default to emulate pre-existing behavior. 727 ;; Enable parcel prim limits. Off by default to emulate pre-existing behavior.
diff --git a/bin/OpenSimDefaults.ini b/bin/OpenSimDefaults.ini
index 59088c4..d74f373 100644
--- a/bin/OpenSimDefaults.ini
+++ b/bin/OpenSimDefaults.ini
@@ -1366,6 +1366,10 @@
1366 ; Enable media on a prim facilities 1366 ; Enable media on a prim facilities
1367 Enabled = true; 1367 Enabled = true;
1368 1368
1369[NPC]
1370 ;; Enable media on a prim facilities
1371 Enabled = false
1372
1369;; 1373;;
1370;; If you are using a simian grid frontend you can enable 1374;; If you are using a simian grid frontend you can enable
1371;; this module to upload tile images for the mapping fn 1375;; this module to upload tile images for the mapping fn