mirror of
https://github.com/opensim/opensim.git
synced 2026-08-08 10:15:33 +08:00
add npc create option OS_NPC_OBJECT_GROUP. with it the npc will be created with the group of the object with the script, if that object owner is member of that group. This should allow parcel access by group to work now, and not much else. The groupTitle will also be set, it the region option NoNPCGroup is not active.
This commit is contained in:
@@ -64,6 +64,7 @@ namespace OpenSim.Region.OptionalModules.World.NPC
|
||||
private UUID m_uuid = UUID.Random();
|
||||
private readonly Scene m_scene;
|
||||
private readonly UUID m_ownerID;
|
||||
private UUID m_hostGroupID;
|
||||
|
||||
public List<uint> SelectedObjects {get; private set;}
|
||||
|
||||
@@ -77,6 +78,7 @@ namespace OpenSim.Region.OptionalModules.World.NPC
|
||||
m_scene = scene;
|
||||
m_ownerID = ownerID;
|
||||
SenseAsAgent = senseAsAgent;
|
||||
m_hostGroupID = UUID.Zero;
|
||||
}
|
||||
|
||||
public NPCAvatar(
|
||||
@@ -89,6 +91,7 @@ namespace OpenSim.Region.OptionalModules.World.NPC
|
||||
m_scene = scene;
|
||||
m_ownerID = ownerID;
|
||||
SenseAsAgent = senseAsAgent;
|
||||
m_hostGroupID = UUID.Zero;
|
||||
}
|
||||
|
||||
public IScene Scene
|
||||
@@ -576,7 +579,8 @@ namespace OpenSim.Region.OptionalModules.World.NPC
|
||||
}
|
||||
public UUID ActiveGroupId
|
||||
{
|
||||
get { return UUID.Zero; }
|
||||
get { return m_hostGroupID; }
|
||||
set { m_hostGroupID = value; }
|
||||
}
|
||||
|
||||
public string ActiveGroupName
|
||||
@@ -591,7 +595,7 @@ namespace OpenSim.Region.OptionalModules.World.NPC
|
||||
|
||||
public bool IsGroupMember(UUID groupID)
|
||||
{
|
||||
return false;
|
||||
return (m_hostGroupID == groupID);
|
||||
}
|
||||
|
||||
public ulong GetGroupPowers(UUID groupID)
|
||||
|
||||
Reference in New Issue
Block a user