diff --git a/OpenSim/Framework/PrimitiveBaseShape.cs b/OpenSim/Framework/PrimitiveBaseShape.cs index 856f8194c6..d0af5a88da 100644 --- a/OpenSim/Framework/PrimitiveBaseShape.cs +++ b/OpenSim/Framework/PrimitiveBaseShape.cs @@ -53,7 +53,11 @@ namespace OpenSim.Framework public enum PCodeEnum : byte { Primitive = 9, - Avatar = 47 + Avatar = 47, + Grass = 95, + NewTree = 111, + ParticleSystem = 143, + Tree = 255 } public enum Extrusion : byte diff --git a/OpenSim/Region/ClientStack/ClientView.cs b/OpenSim/Region/ClientStack/ClientView.cs index d53201fa30..15540eac23 100644 --- a/OpenSim/Region/ClientStack/ClientView.cs +++ b/OpenSim/Region/ClientStack/ClientView.cs @@ -2126,7 +2126,7 @@ namespace OpenSim.Region.ClientStack SetDefaultPrimPacketValues(objupdate); objupdate.UpdateFlags = flags; SetPrimPacketShapeData(objupdate, primShape); - // if ((primShape.PCode == 111) || (primShape.PCode == 255)) + if ((primShape.PCode == (byte)PCode.NewTree) || (primShape.PCode == (byte)PCode.Tree) || (primShape.PCode == (byte)PCode.Grass)) { objupdate.Data = new byte[1]; @@ -2206,7 +2206,7 @@ namespace OpenSim.Region.ClientStack objdata.ParentID = 0; objdata.OwnerID = LLUUID.Zero; objdata.Scale = new LLVector3(1, 1, 1); - objdata.PCode = 47; + objdata.PCode = (byte)PCode.Avatar; if (textureEntry != null) { objdata.TextureEntry = textureEntry; diff --git a/OpenSim/Region/Environment/Scenes/InnerScene.cs b/OpenSim/Region/Environment/Scenes/InnerScene.cs index 5d99f2255e..3e5610c258 100644 --- a/OpenSim/Region/Environment/Scenes/InnerScene.cs +++ b/OpenSim/Region/Environment/Scenes/InnerScene.cs @@ -335,7 +335,7 @@ namespace OpenSim.Region.Environment.Scenes objupdate.ObjectData[0].ParentID = 0; objupdate.ObjectData[0].OwnerID = LLUUID.Zero; objupdate.ObjectData[0].Scale = new LLVector3(1, 1, 1); - objupdate.ObjectData[0].PCode = 47; + objupdate.ObjectData[0].PCode = (byte)PCode.Avatar; objupdate.ObjectData[0].TextureEntry = ScenePresence.DefaultTexture; objupdate.ObjectData[0].ID = av.LocalId; diff --git a/OpenSim/Region/Environment/Scenes/Scene.cs b/OpenSim/Region/Environment/Scenes/Scene.cs index 19dbbc9cfb..9466ab90d5 100644 --- a/OpenSim/Region/Environment/Scenes/Scene.cs +++ b/OpenSim/Region/Environment/Scenes/Scene.cs @@ -1121,7 +1121,7 @@ namespace OpenSim.Region.Environment.Scenes SceneObjectPart rootPart = sceneOb.GetChildPart(sceneOb.UUID); // if grass or tree, make phantom //rootPart.TrimPermissions(); - if ((rootPart.Shape.PCode == 95) || (rootPart.Shape.PCode == 255) || (rootPart.Shape.PCode == 111)) + if ((rootPart.Shape.PCode == (byte)PCode.Grass) || (rootPart.Shape.PCode == (byte)PCode.Tree) || (rootPart.Shape.PCode == (byte)PCode.NewTree)) { rootPart.AddFlag(LLObject.ObjectFlags.Phantom); //rootPart.ObjectFlags += (uint)LLObject.ObjectFlags.Phantom;