if ${POI.NeedRestock} { if ${Inventory.FreeSlots} > 0 { if (${POI.Name.Equal[${Inventory.FoodMerch}]} || ${POI.Name.Equal[${Inventory.DrinkMerch}]} || ${POI.Name.Equal[${Inventory.AmmoMerch}]}) && !${POI.IsBlacklisted} { if ${POI.InUseRange} { if ${WoWScript[MerchantFrame:IsVisible()]} { This.NPCState_NPC_Wait_Until:Set[${Math.Calc[${LavishScript.RunningTime}+(${This.NPCState_Interact_Wait_Until_Timeout} * ${Bot.GlobalCooldown})]}] return OB_RESTOCK } else { if ${WoWScript[GetGossipOptions()](exists)} { This.NPCState_NPC_Wait_Until:Set[${Math.Calc[${LavishScript.RunningTime}+(${This.NPCState_Interact_Wait_Until_Timeout} * ${Bot.GlobalCooldown})]}] return OB_MOREGOSSIP } else { This.NPCState_NPC_Wait_Until:Set[${Math.Calc[${LavishScript.RunningTime}+(${This.NPCState_Interact_Wait_Until_Timeout} * ${Bot.GlobalCooldown})]}] return OB_USE_NPC } } } else { if !${WoWScript["GetContainerItemCooldown(${Item[Hearthstone].Bag.Number}, ${Item[Hearthstone].Slot})", 2]} { Move -stop Bot.ForcedStateWait:Set[${This.InTenths[010]}] Item[Hearthstone]:Use Bot.ForcedStateWait:Set[${This.InTenths[120]}] } return OB_NPC_MOVE } } else { if ${Inventory.NeedRestock[1].Equal[Food]} && ${Inventory.FoodMerch.NotEqual[""]} && ${POI.SetPOINamed[${Inventory.FoodMerch}]} { if !${WoWScript["GetContainerItemCooldown(${Item[Hearthstone].Bag.Number}, ${Item[Hearthstone].Slot})", 2]} { Move -stop Bot.ForcedStateWait:Set[${This.InTenths[010]}] Item[Hearthstone]:Use Bot.ForcedStateWait:Set[${This.InTenths[120]}] } return OB_NPC_MOVE } if ${Inventory.NeedRestock[1].Equal[Water]} && ${Inventory.DrinkMerch.NotEqual[""]} && ${POI.SetPOINamed[${Inventory.DrinkMerch}]} { if !${WoWScript["GetContainerItemCooldown(${Item[Hearthstone].Bag.Number}, ${Item[Hearthstone].Slot})", 2]} { Move -stop Bot.ForcedStateWait:Set[${This.InTenths[010]}] Item[Hearthstone]:Use Bot.ForcedStateWait:Set[${This.InTenths[120]}] } return OB_NPC_MOVE } if (${Inventory.NeedRestock[1].Equal[Ammo]} || ${Inventory.NeedRestock[1].Equal[Arrow]}) && ${Inventory.AmmoMerch.NotEqual[""]} && ${POI.SetPOINamed[${Inventory.AmmoMerch}]} { if !${WoWScript["GetContainerItemCooldown(${Item[Hearthstone].Bag.Number}, ${Item[Hearthstone].Slot})", 2]} { Move -stop Bot.ForcedStateWait:Set[${This.InTenths[010]}] Item[Hearthstone]:Use Bot.ForcedStateWait:Set[${This.InTenths[120]}] } return OB_NPC_MOVE } This:Output[Not enough mapping data to RESTOCK POI !] ;no return here try other NPC } } else { POI.NeedRestock:Set[FALSE] } }