Thanks, nlin, for a patch implementing persistence for "When Left Clicked"
object property. Fix issue 2149.0.6.0-stable
parent
fac18f608d
commit
e0d092ec53
|
@ -941,6 +941,7 @@ namespace OpenSim.Data.MySQL
|
||||||
createCol(prims, "SalePrice", typeof(Int32));
|
createCol(prims, "SalePrice", typeof(Int32));
|
||||||
createCol(prims, "SaleType", typeof (Int16));
|
createCol(prims, "SaleType", typeof (Int16));
|
||||||
|
|
||||||
|
createCol(prims, "ClickAction", typeof (Byte));
|
||||||
|
|
||||||
// Add in contraints
|
// Add in contraints
|
||||||
prims.PrimaryKey = new DataColumn[] {prims.Columns["UUID"]};
|
prims.PrimaryKey = new DataColumn[] {prims.Columns["UUID"]};
|
||||||
|
@ -1225,6 +1226,8 @@ namespace OpenSim.Data.MySQL
|
||||||
prim.SalePrice = Convert.ToInt32(row["SalePrice"]);
|
prim.SalePrice = Convert.ToInt32(row["SalePrice"]);
|
||||||
prim.ObjectSaleType = Convert.ToByte(row["SaleType"]);
|
prim.ObjectSaleType = Convert.ToByte(row["SaleType"]);
|
||||||
|
|
||||||
|
prim.ClickAction = Convert.ToByte(row["ClickAction"]);
|
||||||
|
|
||||||
return prim;
|
return prim;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -1532,6 +1535,8 @@ namespace OpenSim.Data.MySQL
|
||||||
row["SalePrice"] = prim.SalePrice;
|
row["SalePrice"] = prim.SalePrice;
|
||||||
row["SaleType"] = Convert.ToInt16(prim.ObjectSaleType);
|
row["SaleType"] = Convert.ToInt16(prim.ObjectSaleType);
|
||||||
|
|
||||||
|
byte clickAction = prim.ClickAction;
|
||||||
|
row["ClickAction"] = clickAction;
|
||||||
}
|
}
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
|
|
|
@ -0,0 +1,6 @@
|
||||||
|
begin;
|
||||||
|
|
||||||
|
ALTER TABLE prims ADD COLUMN ClickAction tinyint NOT NULL default 0;
|
||||||
|
|
||||||
|
commit;
|
||||||
|
|
|
@ -4772,6 +4772,20 @@ namespace OpenSim.Region.ClientStack.LindenUDP
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
|
|
||||||
|
case PacketType.ObjectClickAction:
|
||||||
|
ObjectClickActionPacket ocpacket = (ObjectClickActionPacket)Pack;
|
||||||
|
Scene tScene = (Scene)m_scene;
|
||||||
|
|
||||||
|
foreach (ObjectClickActionPacket.ObjectDataBlock odata in ocpacket.ObjectData)
|
||||||
|
{
|
||||||
|
byte action = odata.ClickAction;
|
||||||
|
uint localId = odata.ObjectLocalID;
|
||||||
|
SceneObjectPart part = tScene.GetSceneObjectPart(localId);
|
||||||
|
part.ClickAction = action;
|
||||||
|
}
|
||||||
|
|
||||||
|
break;
|
||||||
|
|
||||||
#endregion
|
#endregion
|
||||||
|
|
||||||
#region Inventory/Asset/Other related packets
|
#region Inventory/Asset/Other related packets
|
||||||
|
|
Loading…
Reference in New Issue