mirror of
https://github.com/opensim/opensim.git
synced 2026-08-05 08:55:56 +08:00
Thank you Snoopy, for a patch that implements group permissions.
Applied with changes: - removed spammy debug message - corrected tab formatting
This commit is contained in:
@@ -1526,10 +1526,14 @@ namespace OpenSim.Region.Framework.Scenes
|
||||
return;
|
||||
|
||||
if (part.OwnerID != remoteClient.AgentId)
|
||||
return;
|
||||
|
||||
if ((part.OwnerMask & (uint)PermissionMask.Modify) == 0)
|
||||
return;
|
||||
{
|
||||
// Group permissions
|
||||
if ( (part.GroupID == UUID.Zero) || (remoteClient.GetGroupPowers(part.GroupID) == 0) || ((part.GroupMask & (uint)PermissionMask.Modify) == 0) )
|
||||
return;
|
||||
} else {
|
||||
if ((part.OwnerMask & (uint)PermissionMask.Modify) == 0)
|
||||
return;
|
||||
}
|
||||
|
||||
if (!Permissions.CanCreateObjectInventory(
|
||||
itemBase.InvType, part.UUID, remoteClient.AgentId))
|
||||
@@ -1598,13 +1602,18 @@ namespace OpenSim.Region.Framework.Scenes
|
||||
destId);
|
||||
return;
|
||||
}
|
||||
|
||||
|
||||
// Must own the object, and have modify rights
|
||||
if (srcPart.OwnerID != destPart.OwnerID)
|
||||
return;
|
||||
|
||||
if ((destPart.OwnerMask & (uint)PermissionMask.Modify) == 0)
|
||||
return;
|
||||
{
|
||||
// Group permissions
|
||||
if ( (destPart.GroupID == UUID.Zero) || (destPart.GroupID != srcPart.GroupID) ||
|
||||
((destPart.GroupMask & (uint)PermissionMask.Modify) == 0) )
|
||||
return;
|
||||
} else {
|
||||
if ((destPart.OwnerMask & (uint)PermissionMask.Modify) == 0)
|
||||
return;
|
||||
}
|
||||
|
||||
if (destPart.ScriptAccessPin != pin)
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user