Quote Originally Posted by Not Cat View Post
Since a few people were PMing me asking for it. This script uses potions on whatever player you choose. It uses potions from the first backpack you open and starts working its way through the backpacks until all the potions are used. You can change the player name and potion type really easy. I wish I could give credit to who made it, but I can't find the thread I found it in from forever ago.


How to set up the backpacks: imgur.com/SmkUDVt.png

Code:
local drinkTarget = 'Player Name'
local manaPot = 'Mana Potion'
 
Module.New('mana drink helper', function(module)
    local drinkID = Creature.New(drinkTarget):ID()
    local cont = Container.GetFirst()
    local count = 0
    if cont:ItemCount() >= 1 then
        count = cont:ItemCount() - 1
    end
 
    if(cont:GetItemData(count).id == Item.GetItemIDFromDualInput(manaPot)) and drinkID ~= 0 then
        cont:UseItemWithCreature(count, drinkID)
    elseif (Item.isContainer(cont:GetItemData(count).id)) then
        cont:UseItem(count, true)
    end
    module:Delay(1000)
end)
This is perfect mate, much appreciated. And thanks to everyone else who helped me out too!

I am assuming with this I need a house out of the way of people who can see me to prevent being reported? Where did you train and use this?

Regards,
BnW