Disarm
Removes items from both hands (right and left) to the character’s backpack.
Iterates through RhandLayer and LhandLayer, calling UnEquip for each occupied layer.
Returns False if the character is disconnected or if moving an item from a hand to the backpack failed. Returns True if both hands are empty after the call (including when they were already empty).
In Python, the implementation uses MoveItem for each hand layer.
Снимает предметы из обеих рук (правой и левой) в рюкзак персонажа.
Перебирает RhandLayer и LhandLayer, вызывая UnEquip для каждого занятого слоя.
Возвращает False, если персонаж не подключён или перемещение предмета из руки в рюкзак не удалось. Возвращает True, если обе руки пусты после вызова (включая случай, когда они были пусты изначально).
В Python реализация использует MoveItem для каждого слоя руки.
function Disarm: Boolean;
def Disarm() -> bool: ...
begin
if ObjAtLayer(RhandLayer) <> 0 then
begin
if Disarm then
AddToSystemJournal('Hands disarmed')
else
AddToSystemJournal('Disarm failed');
Wait(1000);
end;
end.
if ObjAtLayerEx(RhandLayer(), Self()) != 0:
if Disarm():
AddToSystemJournal('Hands disarmed')
else:
AddToSystemJournal('Disarm failed')
Wait(1000)