Hello folks,
I am playing with some bots here but when i try retrieve the inventory items
from the bot I just get the folders and no items bellow is an example code:
private Inventory Inventory;
private void button1_Click(object sender, EventArgs e)
{
Inventory = Client.Inventory.Store;
InventoryFolder rootFolder = Inventory.RootFolder;
List<InventoryBase> contents =
Client.Inventory.Store.GetContents(rootFolder);
foreach (InventoryBase i in contents)
{
if (i is InventoryFolder)
{
InventoryFolder folderr = (InventoryFolder)i;
List<InventoryBase> contentss =
Client.Inventory.Store.GetContents(folderr);
if (contentss.Count > 0)
{
foreach (InventoryBase ii in contentss)
{
if (ii is InventoryFolder)
{
MessageBox.Show("This is a folder: " +
ii.ToString());
}
if (ii is InventoryItem)
{
MessageBox.Show("This is an Item: " +
ii.ToString());
}
//MessageBox.Show("is > 0 " +
contentss.ToString());
}
}
//MessageBox.Show(i.ToString());
}
if (i is InventoryItem)
{
MessageBox.Show("I am an Item: " + i.ToString());
}
}
}
what am i doing wrong??? there is a trick to retrieve items??
_______________________________________________
Opensim-users mailing list
[email protected]
https://lists.berlios.de/mailman/listinfo/opensim-users