Merge commit '30320505fa54640baf4ecaff8bb743f62ef01f86' into bigmerge
commit
8639b037e1
|
@ -56,17 +56,17 @@ namespace OpenSim.Tests.Common
|
||||||
return CreateAsset(id, AssetType.Notecard, "hello", UUID.Random());
|
return CreateAsset(id, AssetType.Notecard, "hello", UUID.Random());
|
||||||
}
|
}
|
||||||
|
|
||||||
/// <summary>
|
// /// <summary>
|
||||||
/// Create and store a notecard asset with a random uuid and dummy text.
|
// /// Create and store a notecard asset with a random uuid and dummy text.
|
||||||
/// </summary>
|
// /// </summary>
|
||||||
/// <param name="creatorId">/param>
|
// /// <param name="creatorId">/param>
|
||||||
/// <returns></returns>
|
// /// <returns></returns>
|
||||||
public static AssetBase CreateNotecardAsset(Scene scene, UUID creatorId)
|
// public static AssetBase CreateNotecardAsset(Scene scene, UUID creatorId)
|
||||||
{
|
// {
|
||||||
AssetBase asset = CreateAsset(UUID.Random(), AssetType.Notecard, "hello", creatorId);
|
// AssetBase asset = CreateAsset(UUID.Random(), AssetType.Notecard, "hello", creatorId);
|
||||||
scene.AssetService.Store(asset);
|
// scene.AssetService.Store(asset);
|
||||||
return asset;
|
// return asset;
|
||||||
}
|
// }
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Create an asset from the given object.
|
/// Create an asset from the given object.
|
||||||
|
|
|
@ -86,11 +86,18 @@ namespace OpenSim.Tests.Common
|
||||||
AssetBase asset = null;
|
AssetBase asset = null;
|
||||||
|
|
||||||
if (type == InventoryType.Notecard)
|
if (type == InventoryType.Notecard)
|
||||||
asset = AssetHelpers.CreateNotecardAsset(scene, userId);
|
{
|
||||||
|
asset = AssetHelpers.CreateNotecardAsset();
|
||||||
|
asset.CreatorID = userId.ToString();
|
||||||
|
}
|
||||||
else if (type == InventoryType.Object)
|
else if (type == InventoryType.Object)
|
||||||
|
{
|
||||||
asset = AssetHelpers.CreateAsset(assetId, SceneHelpers.CreateSceneObject(1, userId));
|
asset = AssetHelpers.CreateAsset(assetId, SceneHelpers.CreateSceneObject(1, userId));
|
||||||
|
}
|
||||||
else
|
else
|
||||||
|
{
|
||||||
throw new Exception(string.Format("Inventory type {0} not supported", type));
|
throw new Exception(string.Format("Inventory type {0} not supported", type));
|
||||||
|
}
|
||||||
|
|
||||||
scene.AssetService.Store(asset);
|
scene.AssetService.Store(asset);
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue