PDA

View Full Version : Mana potter (multiple backpacks) - Mana trainer



texmex47
12-01-2015, 08:02 PM
Hello!

I am currently mana training a lot on my character (more than 200 backpacks of potions),
and I found this great script to mana pot my main character:


function pumpMana()
local charToPump = Creature.New("Eternal Oblivion")
local charToPumpPos = charToPump:Position()
local manaId = 238
local backpack = Container.GetByName("shopping bag")
if (Self.DistanceFromPosition(charToPumpPos.x, charToPumpPos.y, charToPumpPos.z) <= 2) and (Self.Position().z == charToPumpPos.z) then
for spots = 0, backpack:ItemCount() do
local item = backpack:GetItemData(spots)
if (item.id == manaId) then
backpack:UseItemWithCreature(spots, charToPump:ID())
break
end
end
end
end
while true do
pumpMana()
wait(900,1100)
end

But how can I make it work with multiple backpacks?
I have now opened 15 backpacks of potions, but when first backpack is empty, it stop potting.
And I must close it manually.

Is there a way to make it continue to next backpack of potions, without closing it manually?
I want to be able to be 100% afk when potting the other character.

Need to make some array with backpacks, but idk how - i suck at coding.
And i want it to finish the first bp in line, before going to the next

ososzayat
12-02-2015, 08:48 PM
with this simple one u don't even have to open bps xD

Name = "CHARACTER-NAME"
ItemToUse = 238


while true do
Creature.Follow(Name)
Self.UseItemWithFollow(ItemToUse)
sleep(math.random(140,420))
end



Have fun ;)

Edit: you have to carry manas on your cap

texmex47
12-02-2015, 10:13 PM
with this simple one u don't even have to open bps xD

Name = "CHARACTER-NAME"
ItemToUse = 238


while true do
Creature.Follow(Name)
Self.UseItemWithFollow(ItemToUse)
sleep(math.random(140,420))
end



Have fun ;)

Edit: you have to carry manas on your cap

But if you read my post, i dont cap pots on myself.
I have 200 backpacks on the floor, it's impossible to cap it xD

viser14
12-03-2015, 02:35 AM
But if you read my post, i dont cap pots on myself.
I have 200 backpacks on the floor, it's impossible to cap it xD

maybe you need more levels, you get x cap per level depending on vocation.
im serious, you really do.
but seriously, i jest.

ososzayat
12-08-2015, 02:33 AM
But if you read my post, i dont cap pots on myself.
I have 200 backpacks on the floor, it's impossible to cap it xD

you can add NPC buyer and stand next to it.. like if cap < x then buy 100 manas~~
if u needed this i can tell you how to do :D

texmex47
12-10-2015, 11:30 PM
you can add NPC buyer and stand next to it.. like if cap < x then buy 100 manas~~
if u needed this i can tell you how to do :D

fixed it. i just put potion on ground, and use browse field.
it works with multiple pages.
got 150+ pages of potions. let's go! :D

spook
12-11-2015, 12:09 AM
can you post this script? i need 2 please :D!

viser14
12-11-2015, 05:30 AM
can you post this script? i need 2 please :D!

+1 to that !

Aristeus
12-11-2015, 10:56 AM
This script will check the amount of mana potions in a backpack, if it's zero it'll click the last slot in the backpack (which should be your cascaded backpacks). You only have to have one backpack open for this to work.


local manas = 268 --- Id of mana potions
local index = 0 --- Index of your backpack (first backpack is 0)

Module.New('GoDeeper-Mana', function(module)
if (Self.ItemCount(manas, index) == 0) then
local bp = Container.New(index)
bp:UseItem(19,true)
end
module:Delay(math.random(400,600))
end)

texmex47
04-17-2016, 02:50 PM
can you post this script? i need 2 please :D!


+1 to that !

Sorry for the late reply!
Here is the script I used to pot my main char with bot chars.



function pumpMana()
local charToPump = Creature.New("Bubble") --name of your main char
local charToPumpPos = charToPump:Position()
local manaId = 238 --id of potion
local backpack = Container.GetByName("browse field")
if (Self.DistanceFromPosition(charToPumpPos.x, charToPumpPos.y, charToPumpPos.z) <= 2) and (Self.Position().z == charToPumpPos.z) then
for spots = 0, backpack:ItemCount() do
local item = backpack:GetItemData(spots)
if (item.id == manaId) then
backpack:UseItemWithCreature(spots, charToPump:ID())
break
end
end
end
end
while true do
pumpMana()
wait(900,1100)
end


I also found a bug to not get kicked (anti idle, WITHOUT BOT).
So my lvl 80 mage uses GMP on my mainchar, through browse field.
And on my mainchar, I dont use bot, I just put coins/stones on my hotkey to weight it down (utana vid hotkey).
But I noticed that if I keep browse field open on my mainchar too, it doesn't get kicked after 15min.
I AFK'd for 24 hours (WITHOUT BOT!!!) on my mainchar by doing this.

I think the Tibia client thinks my mainchar used the potions on itself because browse field kept changing. Used potions were moved to the top of the stack automatically with these new "pages".
And it's something that makes the client think my character is moving them. But in reality, its my other char that pots me. I dont know why it works, but it works.

Keep browse field open on botchar + manual char, and you never get kick after 15min.

Weathercock
04-27-2016, 09:30 AM
Hey, guys! Any chance someone can help me. I'd like to increase my magic level by sitting in a secluded Depot. I wanted to use the first two DP's - one for holding mana potions and the other for empty potions. Only problem is I'm not exactly sure how to code this. Any help?

Pat
10-13-2017, 01:15 AM
Thanks