oruxtozz
03-05-2016, 07:57 AM
I have a magic trainer, that I think doesnt work as good as I would wanted..
I will copy in the script below.
What I would want is an magic trainer that casts spells and drink manas from open bps on the ground.
Perfect if I could have 9 containers open and he drinks from that.
And spamm as much spells as possible, I'd assume utana vid, exura vita utani gran hur would work.
I have no idea who made this script I'm using but it wasnt me so I'm not taking credits.
Anyway if I open more then 3 backpacks it bugs, and just drink mana without casting spell.
If I add utani gran hur, it still will only cast utana vid and exura vita.
This is what I have:
local manatype = "great mana potion" -- name of potion
local manapercent = 70 -- mana percent to stop using potions
local listspells = -- list of spells to cast
{
"exura vita",
"utana vid",
}
--[[ DO NOT EDIT ANYTHING BELOW THIS LINE ]]--
function ManaPercent()
return math.abs(Self.Mana() * 100 / Self.MaxMana())
end
local manaid = Item.GetID(manatype)
Module('ManaFromContainers', function(mod)
if ManaPercent() < manapercent then
for indexContainer=0, #Container.GetAll()-1 do
local container = Container.New(indexContainer)
for spot=0, container:ItemCount()-1 do
if container:GetItemData(spot).id == manaid then
container:UseItemWithCreature(spot, Self.ID())
end
end
end
end
mod:Delay(600)
end)
Module("BurnMana", function(mod)
for _, spell in ipairs(listspells) do
Self.Cast(spell)
end
mod:Delay(200)
end)
I will copy in the script below.
What I would want is an magic trainer that casts spells and drink manas from open bps on the ground.
Perfect if I could have 9 containers open and he drinks from that.
And spamm as much spells as possible, I'd assume utana vid, exura vita utani gran hur would work.
I have no idea who made this script I'm using but it wasnt me so I'm not taking credits.
Anyway if I open more then 3 backpacks it bugs, and just drink mana without casting spell.
If I add utani gran hur, it still will only cast utana vid and exura vita.
This is what I have:
local manatype = "great mana potion" -- name of potion
local manapercent = 70 -- mana percent to stop using potions
local listspells = -- list of spells to cast
{
"exura vita",
"utana vid",
}
--[[ DO NOT EDIT ANYTHING BELOW THIS LINE ]]--
function ManaPercent()
return math.abs(Self.Mana() * 100 / Self.MaxMana())
end
local manaid = Item.GetID(manatype)
Module('ManaFromContainers', function(mod)
if ManaPercent() < manapercent then
for indexContainer=0, #Container.GetAll()-1 do
local container = Container.New(indexContainer)
for spot=0, container:ItemCount()-1 do
if container:GetItemData(spot).id == manaid then
container:UseItemWithCreature(spot, Self.ID())
end
end
end
end
mod:Delay(600)
end)
Module("BurnMana", function(mod)
for _, spell in ipairs(listspells) do
Self.Cast(spell)
end
mod:Delay(200)
end)