I used the script for the texture change on voice command, it works great for an object that is one Prim. But if it's say one object 4 Prims it only changes one of the prims to the 'commanded' texture. Is it a problem with the script or the object? I want all four prims in the object to be the new texture, not one part pink and the other three white.
Please help.
integer CHAT_CHANNEL = 5;integer FACE = ALL_SIDES;
default
{
state_entry()
{
llListen(CHAT_CHANNEL, "", llGetOwner(), ""

}
listen(integer channel, string name, key id, string message)
{
if (llGetInventoryKey(message) != NULL_KEY)
{
llSetTexture(message, FACE);
} else {
integer num = llGetInventoryNumber(INVENTORY_TEXTURE);
integer i;
for (i = 0; i < num; ++i) {
string texture = llGetInventoryName(INVENTORY_TEXTURE, i);
if (texture == message) {
llSetTexture(texture, FACE);
return;
}
}
}
}
}