Se for uma action, seguindo o exemplo do leandro no tutorial dele...
-- Check potion
ManasToLeave = getuseroption("ManasToLeave")
ManaType = getuseroption("ManaType")
--
HPToLeave = getuseroption("HPToLeave")
HPname = getuseroption("HPname")
--
cap = getuseroption("CapToLeave")
if itemcount(ManaType) < tonumber(ManasToLeave) or itemcount(HPname) < tonumber(HPToLeave) or $cap < tonumber(cap)
then
setsetting('Targeting/Enabled', 'no')
gotolabel(0, "saida")
else
gotolabel("Hunt")
end
caso queira em vez de desligar o targeting, colocar para se o char ficar trapado ele atacar o mostro, é só ir no targeting, clicar com o direito na oplçao only if trapped no bicho q vc queira copiar a parte setting, ficando assim, exermplo:
setsetting('Targeting/Creatures/Poison Spider/Setting1/OnlyIfTrapped', 'no')
dai vc muda pra yes....
setsetting('Targeting/Creatures/Poison Spider/Setting1/OnlyIfTrapped', 'yes')
e troca lem cima onde está....
setsetting('Targeting/Enabled', 'no') pra setsetting('Targeting/Creatures/Poison Spider/Setting1/OnlyIfTrapped', 'yes')
Dai colocando o targeting ele vai desligar, se caso vc fiquei trapado por algum bicho, vc vai morrer, pois o targeting foi desligado, se colocar para only if trapped, vai atacar o bicho quando o mesmo atrapalhar o andar do char.
Ficando assim no final as 2 opções que te falei....
-- Check potion
ManasToLeave = getuseroption("ManasToLeave")
ManaType = getuseroption("ManaType")
--
HPToLeave = getuseroption("HPToLeave")
HPname = getuseroption("HPname")
--
cap = getuseroption("CapToLeave")
if itemcount(ManaType) < tonumber(ManasToLeave) or itemcount(HPname) < tonumber(HPToLeave) or $cap < tonumber(cap)
then
setsetting('Targeting/Enabled', 'no')
gotolabel(0, "saida")
else
gotolabel("Hunt")
end
ou
-- Check potion
ManasToLeave = getuseroption("ManasToLeave")
ManaType = getuseroption("ManaType")
--
HPToLeave = getuseroption("HPToLeave")
HPname = getuseroption("HPname")
--
cap = getuseroption("CapToLeave")
if itemcount(ManaType) < tonumber(ManasToLeave) or itemcount(HPname) < tonumber(HPToLeave) or $cap < tonumber(cap)
then
setsetting('Targeting/Creatures/Poison Spider/Setting1/OnlyIfTrapped', 'yes')
gotolabel(0, "saida")
else
gotolabel("Hunt")
end
no caso desse ultimo se for mais de um bicho, que com certeza vai ser mais de um, vou vc coloca um por um, ou no targeting vc faz uma categoria, assim....
Targeting > Category a (escreva como se fosse o nome de um bicho) > depois na coluna Category vc escreve "a", sem as aspas e resumi tudo ha setsetting('Targeting/Creatures/Category a/Setting1/OnlyIfTrapped', 'yes')
Lmebre-se de ter uma action de open bp antes de entrar na hunt escrever para only if trapped no.....setsetting('Targeting/Creatures/Category a/Setting1/OnlyIfTrapped', 'no'), ou coloque como um persistent.