I got new problem with an if that not work...
I need to check if my mount looted something, so i inserted this code:
Code: Select all
if (mount_who.backpack)
foreach oggetto in (EnumerateItemsInContainer(mount_who.backpack))
MoveObjectToLocation(oggetto, mount_who.x, mount_who.y, mount_who.z, mount_who.realm, MOVEOBJECT_FORCELOCATION);
endforeach
endif
Code: Select all
var enumItems := EnumerateItemsInContainer(mount_who.backpack);
if(enumItems.size() != 0)
foreach oggetto in enumItems
MoveObjectToLocation(oggetto, mount_who.x, mount_who.y, mount_who.z, mount_who.realm, MOVEOBJECT_FORCELOCATION);
endforeach
endif
I can't find a solution, someone can help me?
Thanks